Kernels Handling

Kernels Handling#

rocprofiler: Kernels Handling

Data Structures

struct  rocprofiler_kernel_id_t
 Kernel identifier that represent a unique id for every kernel. More...
 

Enumerations

enum  rocprofiler_kernel_info_kind_t { ROCPROFILER_KERNEL_NAME = 0 }
 Kernel Information Types, can be used by rocprofiler_query_kernel_info. More...
 

Functions

ROCPROFILER_API rocprofiler_status_t rocprofiler_query_kernel_info_size (rocprofiler_kernel_info_kind_t kind, rocprofiler_kernel_id_t kernel_id, size_t *data_size) ROCPROFILER_VERSION_9_0
 Query Kernel Information Data size to allow the user to allocate the right size for the information data requested, the information will be collected using rocprofiler_kernel_id_t by using rocprofiler_query_kernel_info and the user need to identify one type of information available in ::rocprofiler_kernel_info_t. More...
 
ROCPROFILER_API rocprofiler_status_t rocprofiler_query_kernel_info (rocprofiler_kernel_info_kind_t kind, rocprofiler_kernel_id_t kernel_id, const char **data) ROCPROFILER_VERSION_9_0
 Query Kernel Information Data using an allocated data pointer by the user, user can get the size of the data using rocprofiler_query_kernel_info_size, the user can get the data using rocprofiler_kernel_id_t and the user need to identify one type of information available in ::rocprofiler_kernel_info_t. More...
 

Detailed Description

Enumeration Type Documentation

◆ rocprofiler_kernel_info_kind_t

Kernel Information Types, can be used by rocprofiler_query_kernel_info.

Enumerator
ROCPROFILER_KERNEL_NAME 

Kernel Name Information Type.

Function Documentation

◆ rocprofiler_query_kernel_info()

ROCPROFILER_API rocprofiler_status_t rocprofiler_query_kernel_info ( rocprofiler_kernel_info_kind_t  kind,
rocprofiler_kernel_id_t  kernel_id,
const char **  data 
)

Query Kernel Information Data using an allocated data pointer by the user, user can get the size of the data using rocprofiler_query_kernel_info_size, the user can get the data using rocprofiler_kernel_id_t and the user need to identify one type of information available in ::rocprofiler_kernel_info_t.

Parameters
[in]kindInformation kind requested by the user
[in]kernel_idKernel ID
[out]dataInformation Data
Return values
ROCPROFILER_STATUS_SUCCESS,ifthe information was found
ROCPROFILER_STATUS_ERROR_NOT_INITIALIZED,ifrocprofiler_initialize wasn't called before or if rocprofiler_finalize is called
ROCPROFILER_STATUS_ERROR_KERNEL_NOT_FOUND
if the kernel was not found in the saved kernels
ROCPROFILER_STATUS_ERROR_KERNEL_INFORMATION_MISSING
if the kernel was found in the saved kernels but the required information is missing

◆ rocprofiler_query_kernel_info_size()

ROCPROFILER_API rocprofiler_status_t rocprofiler_query_kernel_info_size ( rocprofiler_kernel_info_kind_t  kind,
rocprofiler_kernel_id_t  kernel_id,
size_t *  data_size 
)

Query Kernel Information Data size to allow the user to allocate the right size for the information data requested, the information will be collected using rocprofiler_kernel_id_t by using rocprofiler_query_kernel_info and the user need to identify one type of information available in ::rocprofiler_kernel_info_t.

Parameters
[in]kernel_info_typeThe tyoe of information needed
[in]kernel_idKernel ID
[out]data_sizeKernel Information Data size
Return values
ROCPROFILER_STATUS_SUCCESS,ifthe information was found
ROCPROFILER_STATUS_ERROR_NOT_INITIALIZED,ifrocprofiler_initialize wasn't called before or if rocprofiler_finalize is called
ROCPROFILER_STATUS_ERROR_KERNEL_NOT_FOUND
if the kernel was not found in the saved kernels
ROCPROFILER_STATUS_ERROR_KERNEL_INFORMATION_MISSING
if the kernel was found in the saved counters but the required information is missing