Updated hipErrorString and CUDAErrorTohipError (#1365)
Этот коммит содержится в:
коммит произвёл
Maneesh Gupta
родитель
5c4f78bac3
Коммит
0722704f35
@@ -216,38 +216,80 @@ inline static hipError_t hipCUDAErrorTohipError(cudaError_t cuError) {
|
||||
switch (cuError) {
|
||||
case cudaSuccess:
|
||||
return hipSuccess;
|
||||
case cudaErrorProfilerDisabled:
|
||||
return hipErrorProfilerDisabled;
|
||||
case cudaErrorProfilerNotInitialized:
|
||||
return hipErrorProfilerNotInitialized;
|
||||
case cudaErrorProfilerAlreadyStarted:
|
||||
return hipErrorProfilerAlreadyStarted;
|
||||
case cudaErrorProfilerAlreadyStopped:
|
||||
return hipErrorProfilerAlreadyStopped;
|
||||
case cudaErrorInsufficientDriver:
|
||||
return hipErrorInsufficientDriver;
|
||||
case cudaErrorUnsupportedLimit:
|
||||
return hipErrorUnsupportedLimit;
|
||||
case cudaErrorPeerAccessUnsupported:
|
||||
return hipErrorPeerAccessUnsupported;
|
||||
case cudaErrorInvalidGraphicsContext:
|
||||
return hipErrorInvalidGraphicsContext;
|
||||
case cudaErrorSharedObjectSymbolNotFound:
|
||||
return hipErrorSharedObjectSymbolNotFound;
|
||||
case cudaErrorSharedObjectInitFailed:
|
||||
return hipErrorSharedObjectInitFailed;
|
||||
case cudaErrorOperatingSystem:
|
||||
return hipErrorOperatingSystem;
|
||||
case cudaErrorSetOnActiveProcess:
|
||||
return hipErrorSetOnActiveProcess;
|
||||
case cudaErrorIllegalAddress:
|
||||
return hipErrorIllegalAddress;
|
||||
case cudaErrorInvalidSymbol:
|
||||
return hipErrorInvalidSymbol;
|
||||
case cudaErrorMissingConfiguration:
|
||||
return hipErrorMissingConfiguration;
|
||||
case cudaErrorMemoryAllocation:
|
||||
return hipErrorMemoryAllocation;
|
||||
case cudaErrorLaunchOutOfResources:
|
||||
return hipErrorLaunchOutOfResources;
|
||||
case cudaErrorInvalidValue:
|
||||
return hipErrorInvalidValue;
|
||||
case cudaErrorInvalidResourceHandle:
|
||||
return hipErrorInvalidResourceHandle;
|
||||
case cudaErrorInvalidDevice:
|
||||
return hipErrorInvalidDevice;
|
||||
case cudaErrorInvalidMemcpyDirection:
|
||||
return hipErrorInvalidMemcpyDirection;
|
||||
case cudaErrorInvalidDevicePointer:
|
||||
return hipErrorInvalidDevicePointer;
|
||||
case cudaErrorInitializationError:
|
||||
return hipErrorInitializationError;
|
||||
case cudaErrorNoDevice:
|
||||
return hipErrorNoDevice;
|
||||
case cudaErrorNotReady:
|
||||
return hipErrorNotReady;
|
||||
case cudaErrorLaunchFailure:
|
||||
return hipErrorLaunchFailure;
|
||||
case cudaErrorPriorLaunchFailure:
|
||||
return hipErrorPriorLaunchFailure;
|
||||
case cudaErrorLaunchOutOfResources:
|
||||
return hipErrorLaunchOutOfResources;
|
||||
case cudaErrorInvalidDeviceFunction:
|
||||
return hipErrorInvalidDeviceFunction;
|
||||
case cudaErrorInvalidConfiguration:
|
||||
return hipErrorInvalidConfiguration;
|
||||
case cudaErrorInvalidDevice:
|
||||
return hipErrorInvalidDevice;
|
||||
case cudaErrorInvalidValue:
|
||||
return hipErrorInvalidValue;
|
||||
case cudaErrorInvalidDevicePointer:
|
||||
return hipErrorInvalidDevicePointer;
|
||||
case cudaErrorInvalidMemcpyDirection:
|
||||
return hipErrorInvalidMemcpyDirection;
|
||||
case cudaErrorUnknown:
|
||||
return hipErrorUnknown;
|
||||
case cudaErrorPeerAccessNotEnabled:
|
||||
return hipErrorPeerAccessNotEnabled;
|
||||
case cudaErrorInvalidResourceHandle:
|
||||
return hipErrorInvalidResourceHandle;
|
||||
case cudaErrorNotReady:
|
||||
return hipErrorNotReady;
|
||||
case cudaErrorNoDevice:
|
||||
return hipErrorNoDevice;
|
||||
case cudaErrorPeerAccessAlreadyEnabled:
|
||||
return hipErrorPeerAccessAlreadyEnabled;
|
||||
case cudaErrorPeerAccessNotEnabled:
|
||||
return hipErrorPeerAccessNotEnabled;
|
||||
case cudaErrorHostMemoryAlreadyRegistered:
|
||||
return hipErrorHostMemoryAlreadyRegistered;
|
||||
case cudaErrorHostMemoryNotRegistered:
|
||||
return hipErrorHostMemoryNotRegistered;
|
||||
case cudaErrorUnsupportedLimit:
|
||||
return hipErrorUnsupportedLimit;
|
||||
case cudaErrorMapBufferObjectFailed:
|
||||
return hipErrorMapBufferObjectFailed;
|
||||
case cudaErrorAssert:
|
||||
return hipErrorAssert;
|
||||
case cudaErrorNotSupported:
|
||||
return hipErrorNotSupported;
|
||||
default:
|
||||
return hipErrorUnknown; // Note - translated error.
|
||||
}
|
||||
|
||||
@@ -1671,6 +1671,8 @@ const char* ihipErrorString(hipError_t hip_error) {
|
||||
return "hipErrorProfilerAlreadyStarted";
|
||||
case hipErrorProfilerAlreadyStopped:
|
||||
return "hipErrorProfilerAlreadyStopped";
|
||||
case hipErrorInsufficientDriver:
|
||||
return "hipErrorInsufficientDriver";
|
||||
case hipErrorInvalidImage:
|
||||
return "hipErrorInvalidImage";
|
||||
case hipErrorInvalidContext:
|
||||
@@ -1725,6 +1727,8 @@ const char* ihipErrorString(hipError_t hip_error) {
|
||||
return "hipErrorNotFound";
|
||||
case hipErrorIllegalAddress:
|
||||
return "hipErrorIllegalAddress";
|
||||
case hipErrorInvalidSymbol:
|
||||
return "hipErrorInvalidSymbol";
|
||||
|
||||
case hipErrorMissingConfiguration:
|
||||
return "hipErrorMissingConfiguration";
|
||||
@@ -1773,6 +1777,12 @@ const char* ihipErrorString(hipError_t hip_error) {
|
||||
return "hipErrorHostMemoryAlreadyRegistered";
|
||||
case hipErrorHostMemoryNotRegistered:
|
||||
return "hipErrorHostMemoryNotRegistered";
|
||||
case hipErrorMapBufferObjectFailed:
|
||||
return "hipErrorMapBufferObjectFailed";
|
||||
case hipErrorAssert:
|
||||
return "hipErrorAssert";
|
||||
case hipErrorNotSupported:
|
||||
return "hipErrorNotSupported";
|
||||
case hipErrorTbd:
|
||||
return "hipErrorTbd";
|
||||
default:
|
||||
|
||||
Ссылка в новой задаче
Block a user