LLVM OpenMP 19.0.0git
Modules | Macros | Functions | Variables
Threads

Give names to threads. More...

Collaboration diagram for Threads:

Modules

 Domains
 Domains group.
 
 IDs
 IDs group.
 
 String Handles
 String Handles group.
 
 Task Group
 Task Group.
 
 Tasks
 A task instance represents a piece of work performed by a particular thread for a period of time.
 
 Markers
 Markers represent a single discreet event in time.
 
 
 Relations
 Instances of named entities can be explicitly associated with other instances using instance IDs and the relationship API calls.
 
 Counters
 Counters are user-defined objects with a monotonically increasing value.
 

Macros

#define __itt_thread_set_name   __itt_thread_set_nameA
 
#define __itt_thread_set_name_ptr   __itt_thread_set_nameA_ptr
 
#define __itt_timestamp_none   ((__itt_timestamp)-1LL)
 
#define __itt_counter_set_value   ITTNOTIFY_VOID(counter_set_value)
 
#define __itt_counter_set_value_ptr   ITTNOTIFY_NAME(counter_set_value)
 
#define __itt_counter_create_typed   __itt_counter_create_typedA
 
#define __itt_counter_create_typed_ptr   __itt_counter_create_typedA_ptr
 
#define __itt_counter_create_typedA   ITTNOTIFY_DATA(counter_create_typedA)
 
#define __itt_counter_create_typedA_ptr   ITTNOTIFY_NAME(counter_create_typedA)
 
#define __itt_counter_create_typedW   ITTNOTIFY_DATA(counter_create_typedW)
 
#define __itt_counter_create_typedW_ptr   ITTNOTIFY_NAME(counter_create_typedW)
 
#define __itt_counter_destroy   ITTNOTIFY_VOID(counter_destroy)
 
#define __itt_counter_destroy_ptr   ITTNOTIFY_NAME(counter_destroy)
 

Functions

void ITTAPI __itt_thread_set_nameA (const char *name)
 Sets thread name of calling thread.
 
void ITTAPI __itt_thread_set_nameW (const wchar_t *name)
 
__itt_clock_domain *ITTAPI __itt_clock_domain_create (__itt_get_clock_info_fn fn, void *fn_data)
 Create a clock domain.
 
void ITTAPI __itt_clock_domain_reset (void)
 Recalculate clock domains frequencies and clock base timestamps.
 
void ITTAPI __itt_id_create_ex (const __itt_domain *domain, __itt_clock_domain *clock_domain, unsigned long long timestamp, __itt_id id)
 Create an instance of identifier.
 
void ITTAPI __itt_id_destroy_ex (const __itt_domain *domain, __itt_clock_domain *clock_domain, unsigned long long timestamp, __itt_id id)
 Destroy an instance of identifier.
 
void ITTAPI __itt_task_begin_ex (const __itt_domain *domain, __itt_clock_domain *clock_domain, unsigned long long timestamp, __itt_id taskid, __itt_id parentid, __itt_string_handle *name)
 Begin a task instance.
 
void ITTAPI __itt_task_begin_fn_ex (const __itt_domain *domain, __itt_clock_domain *clock_domain, unsigned long long timestamp, __itt_id taskid, __itt_id parentid, void *fn)
 Begin a task instance.
 
void ITTAPI __itt_task_end_ex (const __itt_domain *domain, __itt_clock_domain *clock_domain, unsigned long long timestamp)
 End the current task instance.
 
void ITTAPI __itt_counter_set_value (__itt_counter id, void *value_ptr)
 Set the counter value.
 
void ITTAPI __itt_counter_set_value_ex (__itt_counter id, __itt_clock_domain *clock_domain, unsigned long long timestamp, void *value_ptr)
 Set the counter value.
 
__itt_counter ITTAPI __itt_counter_create_typedA (const char *name, const char *domain, __itt_metadata_type type)
 Create a typed counter with given name/domain.
 
__itt_counter ITTAPI __itt_counter_create_typedW (const wchar_t *name, const wchar_t *domain, __itt_metadata_type type)
 
 ITT_STUB (ITTAPI, __itt_counter, counter_create_typedA,(const char *name, const char *domain, __itt_metadata_type type)) ITT_STUB(ITTAPI
 
void ITTAPI __itt_counter_destroy (__itt_counter id)
 Destroy the counter identified by the pointer previously returned by __itt_counter_create() or __itt_counter_create_typed()
 

Variables

 __itt_counter
 
 counter_create_typedW
 

Detailed Description

Give names to threads.

Macro Definition Documentation

◆ __itt_counter_create_typed

#define __itt_counter_create_typed   __itt_counter_create_typedA

Definition at line 3460 of file ittnotify.h.

◆ __itt_counter_create_typed_ptr

#define __itt_counter_create_typed_ptr   __itt_counter_create_typedA_ptr

Definition at line 3461 of file ittnotify.h.

◆ __itt_counter_create_typedA

#define __itt_counter_create_typedA   ITTNOTIFY_DATA(counter_create_typedA)

Definition at line 3481 of file ittnotify.h.

◆ __itt_counter_create_typedA_ptr

#define __itt_counter_create_typedA_ptr   ITTNOTIFY_NAME(counter_create_typedA)

Definition at line 3482 of file ittnotify.h.

◆ __itt_counter_create_typedW

#define __itt_counter_create_typedW   ITTNOTIFY_DATA(counter_create_typedW)

Definition at line 3483 of file ittnotify.h.

◆ __itt_counter_create_typedW_ptr

#define __itt_counter_create_typedW_ptr   ITTNOTIFY_NAME(counter_create_typedW)

Definition at line 3484 of file ittnotify.h.

◆ __itt_counter_destroy

#define __itt_counter_destroy   ITTNOTIFY_VOID(counter_destroy)

Definition at line 3520 of file ittnotify.h.

◆ __itt_counter_destroy_ptr

#define __itt_counter_destroy_ptr   ITTNOTIFY_NAME(counter_destroy)

Definition at line 3521 of file ittnotify.h.

◆ __itt_counter_set_value

#define __itt_counter_set_value   ITTNOTIFY_VOID(counter_set_value)

Definition at line 3404 of file ittnotify.h.

◆ __itt_counter_set_value_ptr

#define __itt_counter_set_value_ptr   ITTNOTIFY_NAME(counter_set_value)

Definition at line 3405 of file ittnotify.h.

◆ __itt_thread_set_name

#define __itt_thread_set_name   __itt_thread_set_nameA

Definition at line 484 of file ittnotify.h.

◆ __itt_thread_set_name_ptr

#define __itt_thread_set_name_ptr   __itt_thread_set_nameA_ptr

Definition at line 485 of file ittnotify.h.

◆ __itt_timestamp_none

#define __itt_timestamp_none   ((__itt_timestamp)-1LL)

Definition at line 2140 of file ittnotify.h.

Function Documentation

◆ __itt_clock_domain_create()

__itt_clock_domain *ITTAPI __itt_clock_domain_create ( __itt_get_clock_info_fn  fn,
void fn_data 
)

Create a clock domain.

Certain applications require the capability to trace their application using a clock domain different than the CPU, for instance the instrumentation of events that occur on a GPU. Because the set of domains is expected to be static over the application's execution time, there is no mechanism to destroy a domain. Any domain can be accessed by any thread in the process, regardless of which thread created the domain. This call is thread-safe.

Parameters
[in]fnA pointer to a callback function which retrieves alternative CPU timestamps
[in]fn_dataArgument for a callback function; may be NULL

◆ __itt_clock_domain_reset()

void ITTAPI __itt_clock_domain_reset ( void  )

Recalculate clock domains frequencies and clock base timestamps.

◆ __itt_counter_create_typedA()

__itt_counter ITTAPI __itt_counter_create_typedA ( const char name,
const char domain,
__itt_metadata_type  type 
)

Create a typed counter with given name/domain.

After __itt_counter_create_typed() is called, __itt_counter_inc(id), __itt_counter_inc_delta(id, delta), __itt_counter_set_value(id, value_ptr) or __itt_counter_set_value_ex(id, clock_domain, timestamp, value_ptr) can be used to change the value of the counter

◆ __itt_counter_create_typedW()

__itt_counter ITTAPI __itt_counter_create_typedW ( const wchar_t *  name,
const wchar_t *  domain,
__itt_metadata_type  type 
)

◆ __itt_counter_destroy()

void ITTAPI __itt_counter_destroy ( __itt_counter  id)

Destroy the counter identified by the pointer previously returned by __itt_counter_create() or __itt_counter_create_typed()

◆ __itt_counter_set_value()

void ITTAPI __itt_counter_set_value ( __itt_counter  id,
void value_ptr 
)

Set the counter value.

◆ __itt_counter_set_value_ex()

void ITTAPI __itt_counter_set_value_ex ( __itt_counter  id,
__itt_clock_domain *  clock_domain,
unsigned long long  timestamp,
void value_ptr 
)

Set the counter value.

◆ __itt_id_create_ex()

void ITTAPI __itt_id_create_ex ( const __itt_domain *  domain,
__itt_clock_domain *  clock_domain,
unsigned long long  timestamp,
__itt_id  id 
)

Create an instance of identifier.

This establishes the beginning of the lifetime of an instance of the given ID in the trace. Once this lifetime starts, the ID can be used to tag named entity instances in calls such as __itt_task_begin, and to specify relationships among identified named entity instances, using the Relations APIs.

Parameters
[in]domainThe domain controlling the execution of this call.
[in]clock_domainThe clock domain controlling the execution of this call.
[in]timestampThe user defined timestamp.
[in]idThe ID to create.

◆ __itt_id_destroy_ex()

void ITTAPI __itt_id_destroy_ex ( const __itt_domain *  domain,
__itt_clock_domain *  clock_domain,
unsigned long long  timestamp,
__itt_id  id 
)

Destroy an instance of identifier.

This ends the lifetime of the current instance of the given ID value in the trace. Any relationships that are established after this lifetime ends are invalid. This call must be performed before the given ID value can be reused for a different named entity instance.

Parameters
[in]domainThe domain controlling the execution of this call.
[in]clock_domainThe clock domain controlling the execution of this call.
[in]timestampThe user defined timestamp.
[in]idThe ID to destroy.

◆ __itt_task_begin_ex()

void ITTAPI __itt_task_begin_ex ( const __itt_domain *  domain,
__itt_clock_domain *  clock_domain,
unsigned long long  timestamp,
__itt_id  taskid,
__itt_id  parentid,
__itt_string_handle *  name 
)

Begin a task instance.

Parameters
[in]domainThe domain for this task
[in]clock_domainThe clock domain controlling the execution of this call.
[in]timestampThe user defined timestamp.
[in]taskidThe instance ID for this task instance, or __itt_null
[in]parentidThe parent instance to which this task instance belongs, or __itt_null
[in]nameThe name of this task

◆ __itt_task_begin_fn_ex()

void ITTAPI __itt_task_begin_fn_ex ( const __itt_domain *  domain,
__itt_clock_domain *  clock_domain,
unsigned long long  timestamp,
__itt_id  taskid,
__itt_id  parentid,
void fn 
)

Begin a task instance.

Parameters
[in]domainThe domain for this task
[in]clock_domainThe clock domain controlling the execution of this call.
[in]timestampThe user defined timestamp.
[in]taskidThe identifier for this task instance, or __itt_null
[in]parentidThe parent of this task, or __itt_null
[in]fnThe pointer to the function you are tracing

◆ __itt_task_end_ex()

void ITTAPI __itt_task_end_ex ( const __itt_domain *  domain,
__itt_clock_domain *  clock_domain,
unsigned long long  timestamp 
)

End the current task instance.

Parameters
[in]domainThe domain for this task
[in]clock_domainThe clock domain controlling the execution of this call.
[in]timestampThe user defined timestamp.

◆ __itt_thread_set_nameA()

void ITTAPI __itt_thread_set_nameA ( const char name)

Sets thread name of calling thread.

Parameters
[in]name- name of thread

◆ __itt_thread_set_nameW()

void ITTAPI __itt_thread_set_nameW ( const wchar_t *  name)

◆ ITT_STUB()

ITT_STUB ( ITTAPI  ,
__itt_counter  ,
counter_create_typedA  ,
(const char *name, const char *domain, __itt_metadata_type type  
)

Variable Documentation

◆ __itt_counter

__itt_counter

Definition at line 3474 of file ittnotify.h.

◆ counter_create_typedW

counter_create_typedW

Definition at line 3474 of file ittnotify.h.