File Handle API#
|
ROCprofiler-SDK developer API 1.3.5
ROCm Profiling API and tools
|
Data Structures | |
| struct | hipFileFSOps_t |
| IO operations for RDMA filesystems. More... | |
| struct | hipFileDescr_t |
| Top-level structure for performing GPU IO. More... | |
Typedefs | |
| typedef void * | hipFileHandle_t |
| Opaque file handle used by the GPU IO driver/library. | |
Enumerations | |
| enum | hipFileFileHandleType_t { hipFileHandleTypeOpaqueFD = 1 , hipFileHandleTypeOpaqueWin32 = 2 , hipFileHandleTypeUserspaceFS = 3 } |
| Type of file handle being used. More... | |
Functions | |
| hipFileError_t | hipFileHandleRegister (hipFileHandle_t *fh, hipFileDescr_t *descr) |
| Registers an open file for GPU IO. | |
| void | hipFileHandleDeregister (hipFileHandle_t fh) |
| Deregisters a file from GPU IO. | |
| hipFileError_t | hipFileBufRegister (const void *buffer_base, unsigned long length, int flags) |
| Registers a GPU memory region to be used with GPU IO. | |
| hipFileError_t | hipFileBufDeregister (const void *buffer_base) |
| Deregisters a GPU memory region from being used with GPU IO. | |
Detailed Description
Data Structure Documentation
◆ hipFileDescr_t
| struct hipFileDescr_t |
Top-level structure for performing GPU IO.
hipFileHandleTypeOpaqueFD -> handle.fd non-negative, fs_ops ignored hipFileHandleTypeOpaqueWin32 -> handle.hFile non-NULL, fs_ops ignored hipFileHandleTypeUserspaceFS -> handle.fd non-negative, fs_ops non-NULL
Collaboration diagram for hipFileDescr_t:| Data Fields | ||
|---|---|---|
| const hipFileFSOps_t * | fs_ops | Userspace RDMA filesystem operations. |
| union hipFileDescr_t.handle | handle | Union containing the OS-specific file handle. |
| hipFileFileHandleType_t | type | Type of file handle being used. |
Typedef Documentation
◆ hipFileHandle_t
| typedef void* hipFileHandle_t |
#include <rocprofiler-sdk/hipfile/details/hipfile.h>
Opaque file handle used by the GPU IO driver/library.
Enumeration Type Documentation
◆ hipFileFileHandleType_t
#include <rocprofiler-sdk/hipfile/details/hipfile.h>
Type of file handle being used.
| Enumerator | |
|---|---|
| hipFileHandleTypeOpaqueFD | POSIX file descriptor. |
| hipFileHandleTypeOpaqueWin32 | Win32 HANDLE file handle. |
| hipFileHandleTypeUserspaceFS | Userspace RDMA filesystem. |
Definition at line 425 of file hipfile.h.
Function Documentation
◆ hipFileBufDeregister()
| hipFileError_t hipFileBufDeregister | ( | const void * | buffer_base | ) |
#include <rocprofiler-sdk/hipfile/details/hipfile.h>
Deregisters a GPU memory region from being used with GPU IO.
- Parameters
-
[in] buffer_base \buffer_base_param
- Returns
- \hipfile_error_return
◆ hipFileBufRegister()
| hipFileError_t hipFileBufRegister | ( | const void * | buffer_base, |
| unsigned long | length, | ||
| int | flags | ||
| ) |
#include <rocprofiler-sdk/hipfile/details/hipfile.h>
Registers a GPU memory region to be used with GPU IO.
The memory region should be allocated by the user before being passed to the API call
- Note
- If the library has not already been initialized, the first call to
hipFileBufRegister()will initialize the library and increment the reference count.
- Parameters
-
[in] buffer_base \buffer_base_param [in] length Size of the allocated buffer in bytes [in] flags Control flags for this buffer
- Returns
- \hipfile_error_return
◆ hipFileHandleDeregister()
| void hipFileHandleDeregister | ( | hipFileHandle_t | fh | ) |
#include <rocprofiler-sdk/hipfile/details/hipfile.h>
Deregisters a file from GPU IO.
- Parameters
-
[in] fh \hipfile_handle_param
◆ hipFileHandleRegister()
| hipFileError_t hipFileHandleRegister | ( | hipFileHandle_t * | fh, |
| hipFileDescr_t * | descr | ||
| ) |
#include <rocprofiler-sdk/hipfile/details/hipfile.h>
Registers an open file for GPU IO.
- Note
- If the library has not already been initialized, the first call to
hipFileHandleRegister()will initialize the library and increment the reference count.
- Parameters
-
[out] fh \hipfile_handle_param [in] descr Parameters for opening the file
- Returns
- \hipfile_error_return
Generated by