mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-05 07:48:45 +00:00
engine: the gfx906 compat layer maps the two stream-priority CUDA names (a gfx906 build blocker: dflash2.cpp and verify.cpp use them)
The gfx906 source build of docs/AMD_HIP.md stops at: engine/src/core/dflash2.cpp:222:5: error: use of undeclared identifier 'cudaDeviceGetStreamPriorityRange'; did you mean 'hipDeviceGetStreamPriorityRange'? engine/src/core/dflash2.cpp:223:9: error: use of undeclared identifier 'cudaStreamCreateWithPriority'; did you mean 'hipStreamCreateWithPriority'? The same two names appear in engine/src/core/verify.cpp (1202, 1221, 1227, 4611). Every other CUDA name those files use is already in the compat layer; these two were missing, so `cmake -S engine -DSTRATA_HIP_GFX906=ON` - the documented gfx906 build - does not compile. The HIP signatures match (hipDeviceGetStreamPriorityRange(int*, int*) and hipStreamCreateWithPriority(hipStream_t*, unsigned int, int)), so they are plain aliases next to cudaStreamCreateWithFlags and the other cudaDevice* names.
This commit is contained in:
1 parent
58ee322772
commit
6407cc70b3
1 file changed
+2
@@ -98,6 +98,7 @@ inline hipError_t strata_device_get_attribute(int* v, hipDeviceAttribute_t a, in
|
||||
#define cudaDeviceCanAccessPeer hipDeviceCanAccessPeer
|
||||
#define cudaDeviceEnablePeerAccess hipDeviceEnablePeerAccess
|
||||
#define cudaDeviceDisablePeerAccess hipDeviceDisablePeerAccess
|
||||
#define cudaDeviceGetStreamPriorityRange hipDeviceGetStreamPriorityRange
|
||||
#define cudaDriverGetVersion hipDriverGetVersion
|
||||
#define cudaRuntimeGetVersion hipRuntimeGetVersion
|
||||
#define cudaSetDeviceFlags hipSetDeviceFlags
|
||||
@@ -130,6 +131,7 @@ template <typename T> inline hipError_t strata_host_alloc(T** p, size_t bytes, u
|
||||
#define cudaHostGetDevicePointer hipHostGetDevicePointer
|
||||
#define cudaStreamCreate hipStreamCreate
|
||||
#define cudaStreamCreateWithFlags hipStreamCreateWithFlags
|
||||
#define cudaStreamCreateWithPriority hipStreamCreateWithPriority
|
||||
#define cudaStreamDestroy hipStreamDestroy
|
||||
#define cudaStreamSynchronize hipStreamSynchronize
|
||||
#define cudaStreamQuery hipStreamQuery
|
||||
|
||||
Reference in new issue
Block a user