HIP: Heterogenous-computing Interface for Portability
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Classes | Macros | Typedefs | Enumerations
Global enum and defines

Classes

struct  dim3
 

Macros

#define hipStreamDefault   0x00
 Flags that can be used with hipStreamCreateWithFlags. More...
 
#define hipStreamNonBlocking   0x01
 Stream does not implicitly synchronize with null stream.
 
#define hipEventDefault   0x0
 Flags that can be used with hipEventCreateWithFlags: More...
 
#define hipEventBlockingSync   0x1
 Waiting will yield CPU. Power-friendly and usage-friendly but may increase latency.
 
#define hipEventDisableTiming   0x2
 Disable event's capability to record timing information. May improve performance.
 
#define hipEventInterprocess   0x4
 Event can support IPC. More...
 

Typedefs

typedef enum hipError_t hipError_t
 
typedef enum hipFuncCache hipFuncCache
 
typedef enum hipSharedMemConfig hipSharedMemConfig
 
typedef struct dim3 dim3
 

Enumerations

enum  hipError_t {
  hipSuccess = 0, hipErrorMemoryAllocation, hipErrorMemoryFree, hipErrorUnknownSymbol,
  hipErrorOutOfResources, hipErrorInvalidValue, hipErrorInvalidResourceHandle, hipErrorInvalidDevice,
  hipErrorNoDevice, hipErrorNotReady, hipErrorUnknown, hipErrorTbd
}
 
enum  hipFuncCache { hipFuncCachePreferNone, hipFuncCachePreferShared, hipFuncCachePreferL1, hipFuncCachePreferEqual }
 
enum  hipSharedMemConfig { hipSharedMemBankSizeDefault, hipSharedMemBankSizeFourByte, hipSharedMemBankSizeEightByte }
 
enum  hipMemcpyKind {
  hipMemcpyHostToHost = 0, hipMemcpyHostToDevice = 1, hipMemcpyDeviceToHost = 2, hipMemcpyDeviceToDevice =3,
  hipMemcpyDefault = 4
}
 

Detailed Description

Macro Definition Documentation

#define hipEventDefault   0x0

Flags that can be used with hipEventCreateWithFlags:

Default flags

#define hipEventInterprocess   0x4

Event can support IPC.

Warning
- not supported in HIP.
#define hipStreamDefault   0x00

Flags that can be used with hipStreamCreateWithFlags.

Default stream creation flags. These are used with hipStreamCreate().

Typedef Documentation

typedef struct dim3 dim3

Struct for data in 3D

typedef enum hipFuncCache hipFuncCache
Warning
On AMD devices and recent NVIDIA devices, these hints and controls are ignored.
Warning
On AMD devices and recent NVIDIA devices, these hints and controls are ignored.

Enumeration Type Documentation

enum hipError_t
Enumerator
hipSuccess 

Successful completion.

hipErrorMemoryAllocation 

Memory allocation error.

hipErrorMemoryFree 

Memory free error.

hipErrorUnknownSymbol 

Unknown symbol.

hipErrorOutOfResources 

Out of resources error.

hipErrorInvalidValue 

One or more of the paramters passed to the API call is NULL or not in an acceptable range.

hipErrorInvalidResourceHandle 

Resource handle (hipEvent_t or hipStream_t) invalid.

hipErrorInvalidDevice 

DeviceID must be in range 0...#compute-devices.

hipErrorNoDevice 

Call to cudaGetDeviceCount returned 0 devices.

hipErrorNotReady 

indicates that asynchronous operations enqueued earlier are not ready. This is not actually an error, but is used to distinguish from hipSuccess (which indicates completion). APIs that return this error include hipEventQuery and hipStreamQuery.

hipErrorUnknown 

Unknown error.

hipErrorTbd 

Marker that more error codes are needed.

Warning
On AMD devices and recent NVIDIA devices, these hints and controls are ignored.
Enumerator
hipFuncCachePreferNone 

no preference for shared memory or L1 (default)

hipFuncCachePreferShared 

prefer larger shared memory and smaller L1 cache

hipFuncCachePreferL1 

prefer larger L1 cache and smaller shared memory

hipFuncCachePreferEqual 

prefer equal size L1 cache and shared memory

Memory copy types

Enumerator
hipMemcpyHostToHost 

Host-to-Host Copy.

hipMemcpyHostToDevice 

Host-to-Device Copy.

hipMemcpyDeviceToHost 

Device-to-Host Copy.

hipMemcpyDeviceToDevice 

Device-to-Device Copy.

hipMemcpyDefault 

Runtime will automatically determine copy-kind based on virtual addresses.

Warning
On AMD devices and recent NVIDIA devices, these hints and controls are ignored.
Enumerator
hipSharedMemBankSizeDefault 

The compiler selects a device-specific value for the banking.

hipSharedMemBankSizeFourByte 

Shared mem is banked at 4-bytes intervals and performs best when adjacent threads access data 4 bytes apart.

hipSharedMemBankSizeEightByte 

Shared mem is banked at 8-byte intervals and performs best when adjacent threads access data 4 bytes apart.