NVTX
v3
NVIDIA Tools Extension Library
|
Go to the source code of this file.
Classes | |
union | nvtxMessageValue_t |
struct | nvtxEventAttributes_t |
Event Attribute Structure. More... | |
union | nvtxEventAttributes_t::payload_t |
Payload assigned to this event. More... | |
struct | nvtxResourceAttributes_t |
Resource Attribute Structure. More... | |
union | nvtxResourceAttributes_t::identifier_t |
Identifier for the resource. More... | |
Macros | |
#define | NVTX_VERSION 3 |
#define | NVTX_API |
#define | NVTX_INLINE_STATIC inline static |
#define | NVTX_DECLSPEC NVTX_INLINE_STATIC |
#define | NVTX_VERSIONED_IDENTIFIER_L3(NAME, VERSION) NAME##_v##VERSION |
#define | NVTX_VERSIONED_IDENTIFIER_L2(NAME, VERSION) NVTX_VERSIONED_IDENTIFIER_L3(NAME, VERSION) |
#define | NVTX_VERSIONED_IDENTIFIER(NAME) NVTX_VERSIONED_IDENTIFIER_L2(NAME, NVTX_VERSION) |
#define | NVTX_SUCCESS 0 |
#define | NVTX_FAIL 1 |
#define | NVTX_ERR_INIT_LOAD_PROPERTY 2 |
#define | NVTX_ERR_INIT_ACCESS_LIBRARY 3 |
#define | NVTX_ERR_INIT_LOAD_LIBRARY 4 |
#define | NVTX_ERR_INIT_MISSING_LIBRARY_ENTRY_POINT 5 |
#define | NVTX_ERR_INIT_FAILED_LIBRARY_ENTRY_POINT 6 |
#define | NVTX_ERR_NO_INJECTION_LIBRARY_AVAILABLE 7 |
#define | NVTX_EVENT_ATTRIB_STRUCT_SIZE ( (uint16_t)( sizeof(nvtxEventAttributes_t) ) ) |
#define | NVTX_NO_PUSH_POP_TRACKING ((int)-2) |
#define | NVTX_IMPL_GUARD /* Ensure other headers cannot included directly */ |
Enumerations | |
enum | nvtxColorType_t { NVTX_COLOR_UNKNOWN = 0, NVTX_COLOR_ARGB = 1 } |
enum | nvtxMessageType_t { NVTX_MESSAGE_UNKNOWN = 0, NVTX_MESSAGE_TYPE_ASCII = 1, NVTX_MESSAGE_TYPE_UNICODE = 2, NVTX_MESSAGE_TYPE_REGISTERED = 3 } |
enum | nvtxPayloadType_t { NVTX_PAYLOAD_UNKNOWN = 0, NVTX_PAYLOAD_TYPE_UNSIGNED_INT64 = 1, NVTX_PAYLOAD_TYPE_INT64 = 2, NVTX_PAYLOAD_TYPE_DOUBLE = 3, NVTX_PAYLOAD_TYPE_UNSIGNED_INT32 = 4, NVTX_PAYLOAD_TYPE_INT32 = 5, NVTX_PAYLOAD_TYPE_FLOAT = 6 } |
Functions | |
NVTX_DECLSPEC void NVTX_API | nvtxInitialize (const void *reserved) |
Force initialization (optional) More... | |
Marker | |
NVTX_DECLSPEC void NVTX_API | nvtxDomainMarkEx (nvtxDomainHandle_t domain, const nvtxEventAttributes_t *eventAttrib) |
Marks an instantaneous event in the application. More... | |
NVTX_DECLSPEC void NVTX_API | nvtxMarkEx (const nvtxEventAttributes_t *eventAttrib) |
Marks an instantaneous event in the application. More... | |
NVTX_DECLSPEC void NVTX_API | nvtxMarkA (const char *message) |
Marks an instantaneous event in the application. More... | |
NVTX_DECLSPEC void NVTX_API | nvtxMarkW (const wchar_t *message) |
Process Ranges | |
NVTX_DECLSPEC nvtxRangeId_t NVTX_API | nvtxDomainRangeStartEx (nvtxDomainHandle_t domain, const nvtxEventAttributes_t *eventAttrib) |
Starts a process range in a domain. More... | |
NVTX_DECLSPEC nvtxRangeId_t NVTX_API | nvtxRangeStartEx (const nvtxEventAttributes_t *eventAttrib) |
Starts a process range. More... | |
NVTX_DECLSPEC nvtxRangeId_t NVTX_API | nvtxRangeStartA (const char *message) |
Starts a process range. More... | |
NVTX_DECLSPEC nvtxRangeId_t NVTX_API | nvtxRangeStartW (const wchar_t *message) |
NVTX_DECLSPEC void NVTX_API | nvtxDomainRangeEnd (nvtxDomainHandle_t domain, nvtxRangeId_t id) |
Ends a process range. More... | |
NVTX_DECLSPEC void NVTX_API | nvtxRangeEnd (nvtxRangeId_t id) |
Ends a process range. More... | |
Thread Ranges | |
NVTX_DECLSPEC int NVTX_API | nvtxDomainRangePushEx (nvtxDomainHandle_t domain, const nvtxEventAttributes_t *eventAttrib) |
Starts a nested thread range. More... | |
NVTX_DECLSPEC int NVTX_API | nvtxRangePushEx (const nvtxEventAttributes_t *eventAttrib) |
Starts a nested thread range. More... | |
NVTX_DECLSPEC int NVTX_API | nvtxRangePushA (const char *message) |
Starts a nested thread range. More... | |
NVTX_DECLSPEC int NVTX_API | nvtxRangePushW (const wchar_t *message) |
NVTX_DECLSPEC int NVTX_API | nvtxDomainRangePop (nvtxDomainHandle_t domain) |
Ends a nested thread range. More... | |
NVTX_DECLSPEC int NVTX_API | nvtxRangePop (void) |
Ends a nested thread range. More... | |
NVTX_DECLSPEC void NVTX_API | nvtxDomainResourceDestroy (nvtxResourceHandle_t resource) |
Destroy a resource object to track and associate data with OS and middleware objects. More... | |
Functions for NVTX Category Naming | |
NVTX_DECLSPEC void NVTX_API | nvtxDomainNameCategoryA (nvtxDomainHandle_t domain, uint32_t category, const char *name) |
Annotate an NVTX category used within a domain. More... | |
NVTX_DECLSPEC void NVTX_API | nvtxDomainNameCategoryW (nvtxDomainHandle_t domain, uint32_t category, const wchar_t *name) |
NVTX_DECLSPEC void NVTX_API | nvtxNameCategoryA (uint32_t category, const char *name) |
Annotate an NVTX category. More... | |
NVTX_DECLSPEC void NVTX_API | nvtxNameCategoryW (uint32_t category, const wchar_t *name) |
Functions for OS Threads Naming | |
NVTX_DECLSPEC void NVTX_API | nvtxNameOsThreadA (uint32_t threadId, const char *name) |
Annotate an OS thread. More... | |
NVTX_DECLSPEC void NVTX_API | nvtxNameOsThreadW (uint32_t threadId, const wchar_t *name) |
NVTX_DECLSPEC nvtxStringHandle_t NVTX_API | nvtxDomainRegisterStringA (nvtxDomainHandle_t domain, const char *string) |
Register a string. More... | |
NVTX_DECLSPEC nvtxStringHandle_t NVTX_API | nvtxDomainRegisterStringW (nvtxDomainHandle_t domain, const wchar_t *string) |
NVTX_DECLSPEC nvtxDomainHandle_t NVTX_API | nvtxDomainCreateA (const char *name) |
Register a NVTX domain. More... | |
NVTX_DECLSPEC nvtxDomainHandle_t NVTX_API | nvtxDomainCreateW (const wchar_t *name) |
NVTX_DECLSPEC void NVTX_API | nvtxDomainDestroy (nvtxDomainHandle_t domain) |
Unregister a NVTX domain. More... | |
Functions for Generic Resource Naming | |
enum | nvtxResourceGenericType_t { NVTX_RESOURCE_TYPE_UNKNOWN = 0, NVTX_RESOURCE_TYPE_GENERIC_POINTER = NVTX_RESOURCE_MAKE_TYPE(GENERIC, 1), NVTX_RESOURCE_TYPE_GENERIC_HANDLE = NVTX_RESOURCE_MAKE_TYPE(GENERIC, 2), NVTX_RESOURCE_TYPE_GENERIC_THREAD_NATIVE = NVTX_RESOURCE_MAKE_TYPE(GENERIC, 3), NVTX_RESOURCE_TYPE_GENERIC_THREAD_POSIX = NVTX_RESOURCE_MAKE_TYPE(GENERIC, 4) } |
Generic resource type for when a resource class is not available. More... | |
NVTX_DECLSPEC nvtxResourceHandle_t NVTX_API | nvtxDomainResourceCreate (nvtxDomainHandle_t domain, nvtxResourceAttributes_t *attribs) |
Create a resource object to track and associate data with OS and middleware objects. More... | |
#define NVTX_EVENT_ATTRIB_STRUCT_SIZE ( (uint16_t)( sizeof(nvtxEventAttributes_t) ) ) |
Size of the nvtxEventAttributes_t structure.
Definition at line 231 of file nvToolsExt.h.
#define NVTX_SUCCESS 0 |
The nvToolsExt library depends on stdint.h. If the build tool chain in use does not include stdint.h then define NVTX_STDINT_TYPES_ALREADY_DEFINED and define the following types:
#define NVTX_STDINT_TYPES_ALREADY_DEFINED if you are using your own header file. Result Codes
Definition at line 219 of file nvToolsExt.h.
#define NVTX_VERSION 3 |
Tools Extension API version
Definition at line 155 of file nvToolsExt.h.
NVTX_DECLSPEC void NVTX_API nvtxInitialize | ( | const void * | reserved | ) |
Force initialization (optional)
Force NVTX library to initialize. The first call to any NVTX API function will automatically initialize the entire API. This can make the first call much slower than subsequent calls. In applications where the first call to NVTX may be in a performance-critical section, calling nvtxInitialize before any performance-critical sections will ensure NVTX initialization occurs at an acceptable time. Since nvtxInitialize takes no parameters and has no expected behavior besides initialization, it is convenient to add a call to nvtxInitialize in NVTX-instrumented applications that need to force earlier initialization without changing any other code. For example, if an app's first NVTX call is nvtxDomainCreate, and it is difficult to move that call earlier because the domain handle must be stored in an object only created at that point, adding a call to nvtxInitialize at the top of main() will ensure the later call to nvtxDomainCreate is as fast as possible.
reserved | - must be zero or NULL. |