Advanced Multi-Physics (AMP)
On-Line Documentation
Functions
AMP::Thread Namespace Reference

Functions

int getCurrentProcessor ()
 Function to return the processor number that the current thread is running on.
 
std::thread::native_handle_type getCurrentThread ()
 Return the native handle to the current thread.
 
int getNumberOfProcessors ()
 Function to return the number of processors available.
 
std::vector< int > getProcessAffinity ()
 Function to return the affinity of the current process.
 
std::vector< int > getThreadAffinity (std::thread::native_handle_type thread)
 
void setProcessAffinity (const std::vector< int > &procs)
 Function to set the affinity of the current process.
 
void setThreadAffinity (std::thread::native_handle_type thread, const std::vector< int > &procs)
 

Function Documentation

◆ getCurrentProcessor()

int AMP::Thread::getCurrentProcessor ( )

Function to return the processor number that the current thread is running on.

◆ getCurrentThread()

std::thread::native_handle_type AMP::Thread::getCurrentThread ( )

Return the native handle to the current thread.

◆ getNumberOfProcessors()

int AMP::Thread::getNumberOfProcessors ( )

Function to return the number of processors available.

◆ getProcessAffinity()

std::vector< int > AMP::Thread::getProcessAffinity ( )

Function to return the affinity of the current process.

◆ getThreadAffinity()

std::vector< int > AMP::Thread::getThreadAffinity ( std::thread::native_handle_type  thread)

Function to return the affinity of the given thread

Parameters
threadThe native thread handle

◆ setProcessAffinity()

void AMP::Thread::setProcessAffinity ( const std::vector< int > &  procs)

Function to set the affinity of the current process.

◆ setThreadAffinity()

void AMP::Thread::setThreadAffinity ( std::thread::native_handle_type  thread,
const std::vector< int > &  procs 
)

Set the given thread to have the specified affinity

Parameters
threadThe native thread handle
procsThe processors to use



Advanced Multi-Physics (AMP)
Oak Ridge National Laboratory
Idaho National Laboratory
Los Alamos National Laboratory
This page automatically produced from the
source code by doxygen
Last updated: Tue Mar 10 2026 13:06:45.
Comments on this page