Skip to content

Commit 9fdaa1d

Browse files
committed
Add more defs
For forward compatibility ggml-org#1607
1 parent a4648c1 commit 9fdaa1d

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

ggml-cuda.cu

+7-2
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,18 @@
2525
#define cublasSetStream hipblasSetStream
2626
#define cublasSgemm hipblasSgemm
2727
#define cublasStatus_t hipblasStatus_t
28+
#define cudaDeviceProp hipDeviceProp_t
2829
#define cudaDeviceSynchronize hipDeviceSynchronize
2930
#define cudaError_t hipError_t
30-
#define cudaEvent_t hipEvent_t
3131
#define cudaEventCreateWithFlags hipEventCreateWithFlags
3232
#define cudaEventDisableTiming hipEventDisableTiming
3333
#define cudaEventRecord hipEventRecord
34+
#define cudaEvent_t hipEvent_t
3435
#define cudaFree hipFree
3536
#define cudaFreeHost hipHostFree
37+
#define cudaGetDevice hipGetDevice
38+
#define cudaGetDeviceCount hipGetDeviceCount
39+
#define cudaGetDeviceProperties hipGetDeviceProperties
3640
#define cudaGetErrorString hipGetErrorString
3741
#define cudaGetLastError hipGetLastError
3842
#define cudaMalloc hipMalloc
@@ -43,11 +47,12 @@
4347
#define cudaMemcpyDeviceToHost hipMemcpyDeviceToHost
4448
#define cudaMemcpyHostToDevice hipMemcpyHostToDevice
4549
#define cudaOccupancyMaxPotentialBlockSize hipOccupancyMaxPotentialBlockSize
46-
#define cudaStream_t hipStream_t
50+
#define cudaSetDevice hipSetDevice
4751
#define cudaStreamCreateWithFlags hipStreamCreateWithFlags
4852
#define cudaStreamNonBlocking hipStreamNonBlocking
4953
#define cudaStreamSynchronize hipStreamSynchronize
5054
#define cudaStreamWaitEvent hipStreamWaitEvent
55+
#define cudaStream_t hipStream_t
5156
#define cudaSuccess hipSuccess
5257
#else
5358
#include <cuda_runtime.h>

0 commit comments

Comments
 (0)