Core Functionality

Core Functionality#

ROCprofiler-SDK developer API: Core Functionality
ROCprofiler-SDK developer API 1.4.1
ROCm Profiling API and tools
Core Functionality

Macros

#define HIPFILE_VERSION_MAJOR   0
 hipFile major version number
 
#define HIPFILE_VERSION_MINOR   3
 hipFile minor version number
 
#define HIPFILE_VERSION_PATCH   0
 hipFile patch version number
 

Enumerations

enum  hipFileSizeTConfigParameter_t {
  hipFileParamProfileStats ,
  hipFileParamExecutionMaxIOQueueDepth ,
  hipFileParamExecutionMaxIOThreads ,
  hipFileParamExecutionMinIOThresholdSizeKB ,
  hipFileParamExecutionMaxRequestParallelism ,
  hipFileParamPropertiesMaxDirectIOSizeKB ,
  hipFileParamPropertiesMaxDeviceCacheSizeKB ,
  hipFileParamPropertiesPerBufferCacheSizeKB ,
  hipFileParamPropertiesMaxDevicePinnedMemSizeKB ,
  hipFileParamPropertiesIOBatchsize ,
  hipFileParamPollthresholdSizeKB ,
  hipFileParamPropertiesBatchIOTimeoutMs
}
 size_t configuration parameters More...
 
enum  hipFileBoolConfigParameter_t {
  hipFileParamPropertiesUsePollMode ,
  hipFileParamPropertiesAllowCompatMode ,
  hipFileParamForceCompatMode ,
  hipFileParamFsMiscApiCheckAggressive ,
  hipFileParamExecutionParallelIO ,
  hipFileParamProfileNvtx ,
  hipFileParamPropertiesAllowSystemMemory ,
  hipFileParamUsePcip2pdma ,
  hipFileParamPreferIOUring ,
  hipFileParamForceOdirectMode ,
  hipFileParamSkipTopologyDetection ,
  hipFileParamStreamMemopsBypass
}
 Boolean configuration parameters. More...
 
enum  hipFileStringConfigParameter_t {
  hipFileParamLoggingLevel ,
  hipFileParamEnvLogfilePath ,
  hipFileParamLogDir
}
 String configuration parameters. More...
 

Functions

hipFileError_t hipFileGetVersion (unsigned *major, unsigned *minor, unsigned *patch)
 Get the version of the hipFile library.
 
hipFileError_t hipFileGetParameterSizeT (hipFileSizeTConfigParameter_t param, unsigned long *value)
 Get the value of a size_t configuration parameter.
 
hipFileError_t hipFileGetParameterBool (hipFileBoolConfigParameter_t param, bool *value)
 Get the value of a Boolean configuration parameter.
 
hipFileError_t hipFileGetParameterString (hipFileStringConfigParameter_t param, char *desc_str, int len)
 Get the value of a string configuration parameter.
 
hipFileError_t hipFileSetParameterSizeT (hipFileSizeTConfigParameter_t param, unsigned long value)
 Set the value of a size_t configuration parameter.
 
hipFileError_t hipFileSetParameterBool (hipFileBoolConfigParameter_t param, bool value)
 Set the value of a Boolean configuration parameter.
 
hipFileError_t hipFileSetParameterString (hipFileStringConfigParameter_t param, const char *desc_str)
 Set the value of a string configuration parameter.
 

Detailed Description

Macro Definition Documentation

◆ HIPFILE_VERSION_MAJOR

#define HIPFILE_VERSION_MAJOR   0

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

hipFile major version number

Definition at line 84 of file hipfile.h.

◆ HIPFILE_VERSION_MINOR

#define HIPFILE_VERSION_MINOR   3

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

hipFile minor version number

Definition at line 89 of file hipfile.h.

◆ HIPFILE_VERSION_PATCH

#define HIPFILE_VERSION_PATCH   0

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

hipFile patch version number

Definition at line 94 of file hipfile.h.

Enumeration Type Documentation

◆ hipFileBoolConfigParameter_t

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

Boolean configuration parameters.

Enumerator
hipFileParamPropertiesUsePollMode 

Use poll mode.

hipFileParamPropertiesAllowCompatMode 

Allow compatibility mode.

hipFileParamForceCompatMode 

Force compatibility mode.

hipFileParamFsMiscApiCheckAggressive 

Use aggressive checks in API calls.

hipFileParamExecutionParallelIO 

Allow parallel IO execution.

hipFileParamProfileNvtx 

Use NVTX profiler.

hipFileParamPropertiesAllowSystemMemory 

Allow system memory use.

hipFileParamUsePcip2pdma 

Use P2P DMA.

hipFileParamPreferIOUring 

Prefer io_uring.

hipFileParamForceOdirectMode 

Force O_DIRECT mode.

hipFileParamSkipTopologyDetection 

Skip topology detection.

hipFileParamStreamMemopsBypass 

Bypass stream memory operations.

Definition at line 947 of file hipfile.h.

947 {
948 hipFileParamPropertiesUsePollMode, //!< Use poll mode
949 hipFileParamPropertiesAllowCompatMode, //!< Allow compatibility mode
950 hipFileParamForceCompatMode, //!< Force compatibility mode
951 hipFileParamFsMiscApiCheckAggressive, //!< Use aggressive checks in API calls
952 hipFileParamExecutionParallelIO, //!< Allow parallel IO execution
953 hipFileParamProfileNvtx, //!< Use NVTX profiler
954 hipFileParamPropertiesAllowSystemMemory, //!< Allow system memory use
955 hipFileParamUsePcip2pdma, //!< Use P2P DMA
956 hipFileParamPreferIOUring, //!< Prefer io_uring
957 hipFileParamForceOdirectMode, //!< Force O_DIRECT mode
958 hipFileParamSkipTopologyDetection, //!< Skip topology detection
959 hipFileParamStreamMemopsBypass, //!< Bypass stream memory operations
hipFileBoolConfigParameter_t
Boolean configuration parameters.
Definition hipfile.h:947
@ hipFileParamSkipTopologyDetection
Skip topology detection.
Definition hipfile.h:958
@ hipFileParamUsePcip2pdma
Use P2P DMA.
Definition hipfile.h:955
@ hipFileParamForceOdirectMode
Force O_DIRECT mode.
Definition hipfile.h:957
@ hipFileParamForceCompatMode
Force compatibility mode.
Definition hipfile.h:950
@ hipFileParamFsMiscApiCheckAggressive
Use aggressive checks in API calls.
Definition hipfile.h:951
@ hipFileParamExecutionParallelIO
Allow parallel IO execution.
Definition hipfile.h:952
@ hipFileParamPreferIOUring
Prefer io_uring.
Definition hipfile.h:956
@ hipFileParamPropertiesAllowSystemMemory
Allow system memory use.
Definition hipfile.h:954
@ hipFileParamProfileNvtx
Use NVTX profiler.
Definition hipfile.h:953
@ hipFileParamStreamMemopsBypass
Bypass stream memory operations.
Definition hipfile.h:959
@ hipFileParamPropertiesUsePollMode
Use poll mode.
Definition hipfile.h:948
@ hipFileParamPropertiesAllowCompatMode
Allow compatibility mode.
Definition hipfile.h:949

◆ hipFileSizeTConfigParameter_t

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

size_t configuration parameters

Enumerator
hipFileParamProfileStats 

Statistics.

hipFileParamExecutionMaxIOQueueDepth 

Max IO queue depth.

hipFileParamExecutionMaxIOThreads 

Max number of IO threads.

hipFileParamExecutionMinIOThresholdSizeKB 

Min IO threshold (KiB)

hipFileParamExecutionMaxRequestParallelism 

Max request parallelism.

hipFileParamPropertiesMaxDirectIOSizeKB 

Max direct IO size (KiB)

hipFileParamPropertiesMaxDeviceCacheSizeKB 

Max device cache size (KiB)

hipFileParamPropertiesPerBufferCacheSizeKB 

Max buffer cache size (KiB)

hipFileParamPropertiesMaxDevicePinnedMemSizeKB 

Max device pinned memory size (KiB)

hipFileParamPropertiesIOBatchsize 

IO batch size.

hipFileParamPollthresholdSizeKB 

Poll threshold size (KiB)

hipFileParamPropertiesBatchIOTimeoutMs 

Batch IO timeout (ms)

Definition at line 928 of file hipfile.h.

928 {
929 hipFileParamProfileStats, //!< Statistics
930 hipFileParamExecutionMaxIOQueueDepth, //!< Max IO queue depth
931 hipFileParamExecutionMaxIOThreads, //!< Max number of IO threads
932 hipFileParamExecutionMinIOThresholdSizeKB, //!< Min IO threshold (KiB)
933 hipFileParamExecutionMaxRequestParallelism, //!< Max request parallelism
934 hipFileParamPropertiesMaxDirectIOSizeKB, //!< Max direct IO size (KiB)
935 hipFileParamPropertiesMaxDeviceCacheSizeKB, //!< Max device cache size (KiB)
936 hipFileParamPropertiesPerBufferCacheSizeKB, //!< Max buffer cache size (KiB)
937 hipFileParamPropertiesMaxDevicePinnedMemSizeKB, //!< Max device pinned memory size (KiB)
938 hipFileParamPropertiesIOBatchsize, //!< IO batch size
939 hipFileParamPollthresholdSizeKB, //!< Poll threshold size (KiB)
940 hipFileParamPropertiesBatchIOTimeoutMs, //!< Batch IO timeout (ms)
hipFileSizeTConfigParameter_t
size_t configuration parameters
Definition hipfile.h:928
@ hipFileParamPropertiesMaxDeviceCacheSizeKB
Max device cache size (KiB)
Definition hipfile.h:935
@ hipFileParamExecutionMaxRequestParallelism
Max request parallelism.
Definition hipfile.h:933
@ hipFileParamPropertiesMaxDirectIOSizeKB
Max direct IO size (KiB)
Definition hipfile.h:934
@ hipFileParamExecutionMinIOThresholdSizeKB
Min IO threshold (KiB)
Definition hipfile.h:932
@ hipFileParamPropertiesMaxDevicePinnedMemSizeKB
Max device pinned memory size (KiB)
Definition hipfile.h:937
@ hipFileParamExecutionMaxIOThreads
Max number of IO threads.
Definition hipfile.h:931
@ hipFileParamExecutionMaxIOQueueDepth
Max IO queue depth.
Definition hipfile.h:930
@ hipFileParamPropertiesIOBatchsize
IO batch size.
Definition hipfile.h:938
@ hipFileParamPollthresholdSizeKB
Poll threshold size (KiB)
Definition hipfile.h:939
@ hipFileParamPropertiesPerBufferCacheSizeKB
Max buffer cache size (KiB)
Definition hipfile.h:936
@ hipFileParamProfileStats
Statistics.
Definition hipfile.h:929
@ hipFileParamPropertiesBatchIOTimeoutMs
Batch IO timeout (ms)
Definition hipfile.h:940

◆ hipFileStringConfigParameter_t

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

String configuration parameters.

Enumerator
hipFileParamLoggingLevel 

Logging level.

hipFileParamEnvLogfilePath 

Logfile path.

hipFileParamLogDir 

Logfile directory.

Definition at line 966 of file hipfile.h.

966 {
967 hipFileParamLoggingLevel, //!< Logging level
968 hipFileParamEnvLogfilePath, //!< Logfile path
969 hipFileParamLogDir, //!< Logfile directory
hipFileStringConfigParameter_t
String configuration parameters.
Definition hipfile.h:966
@ hipFileParamLoggingLevel
Logging level.
Definition hipfile.h:967
@ hipFileParamEnvLogfilePath
Logfile path.
Definition hipfile.h:968
@ hipFileParamLogDir
Logfile directory.
Definition hipfile.h:969

Function Documentation

◆ hipFileGetParameterBool()

hipFileError_t hipFileGetParameterBool ( hipFileBoolConfigParameter_t  param,
bool *  value 
)

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

Get the value of a Boolean configuration parameter.

\warn_not_implemented

Parameters
paramThe configuration parameter
valueThe location to store the value of the configuration parameter
Returns
\hipfile_error_return
Note
If the driver is open, the value returned is the value currently in use by the driver.
If the driver is closed, the value returned is the value that was last set by hipFileSetParameter*.

◆ hipFileGetParameterSizeT()

hipFileError_t hipFileGetParameterSizeT ( hipFileSizeTConfigParameter_t  param,
unsigned long *  value 
)

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

Get the value of a size_t configuration parameter.

\warn_not_implemented

Parameters
paramThe configuration parameter
valueThe location to store the value of the configuration parameter
Returns
\hipfile_error_return
Note
If the driver is open, the value returned is the value currently in use by the driver.
If the driver is closed, the value returned is the value that was last set by hipFileSetParameter*.

◆ hipFileGetParameterString()

hipFileError_t hipFileGetParameterString ( hipFileStringConfigParameter_t  param,
char *  desc_str,
int  len 
)

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

Get the value of a string configuration parameter.

\warn_not_implemented

Parameters
paramThe configuration parameter
desc_strThe location to store the value of the configuration parameter
lenThe length of the desc_str parameter
Returns
\hipfile_error_return
Note
If the driver is open, the value returned is the value currently in use by the driver.
If the driver is closed, the value returned is the value that was last set by hipFileSetParameter*.

◆ hipFileGetVersion()

hipFileError_t hipFileGetVersion ( unsigned *  major,
unsigned *  minor,
unsigned *  patch 
)

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

Get the version of the hipFile library.

Parameters
[out]majorThe major version
[out]minorThe minor version
[out]patchThe patch version
Note
Parameters can be set to NULL to ignore that part of the version
Returns
\hipfile_error_return

◆ hipFileSetParameterBool()

hipFileError_t hipFileSetParameterBool ( hipFileBoolConfigParameter_t  param,
bool  value 
)

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

Set the value of a Boolean configuration parameter.

\warn_not_implemented

Parameters
paramThe configuration parameter
valueThe value of the configuration parameter
Returns
\hipfile_error_return
Note
Configuration parameter values may only be set when the driver is closed. Values are applied when the driver is opened.

◆ hipFileSetParameterSizeT()

hipFileError_t hipFileSetParameterSizeT ( hipFileSizeTConfigParameter_t  param,
unsigned long  value 
)

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

Set the value of a size_t configuration parameter.

\warn_not_implemented

Parameters
paramThe configuration parameter
valueThe value of the configuration parameter
Returns
\hipfile_error_return
Note
Configuration parameter values may only be set when the driver is closed. Values are applied when the driver is opened.

◆ hipFileSetParameterString()

hipFileError_t hipFileSetParameterString ( hipFileStringConfigParameter_t  param,
const char *  desc_str 
)

#include <rocprofiler-sdk/hipfile/details/hipfile.h>

Set the value of a string configuration parameter.

\warn_not_implemented

Parameters
paramThe configuration parameter
desc_strThe value of the configuration parameter
Returns
\hipfile_error_return
Note
Configuration parameter values may only be set when the driver is closed. Values are applied when the driver is opened.