Skip to content

Commit

Permalink
[HIPIFY][doc] CUDA 12.6.0 is the latest supported release (LLVM 20.x)
Browse files Browse the repository at this point in the history
+ `CUDA 12.6.0` is supported by LLVM >= 20.0.0, but might work with the `hipify-clang` built against LLVM 19.x
+ Updated the regenerated `hipify-perl` and `CUDA2HIP` docs accordingly
+ Tested on Windows 11 and Ubuntu 23.10
  • Loading branch information
emankov committed Sep 12, 2024
1 parent 5f0a916 commit 5e0739a
Show file tree
Hide file tree
Showing 8 changed files with 30 additions and 8 deletions.
4 changes: 4 additions & 0 deletions bin/hipify-perl
Original file line number Diff line number Diff line change
Expand Up @@ -10022,6 +10022,8 @@ sub warnUnsupportedFunctions {
"cudaErrorInvalidTextureBinding",
"cudaErrorInvalidTexture",
"cudaErrorInvalidSurface",
"cudaErrorInvalidResourceType",
"cudaErrorInvalidResourceConfiguration",
"cudaErrorInvalidPc",
"cudaErrorInvalidNormSetting",
"cudaErrorInvalidHostPointer",
Expand All @@ -10032,6 +10034,7 @@ sub warnUnsupportedFunctions {
"cudaErrorIncompatibleDriverContext",
"cudaErrorIllegalInstruction",
"cudaErrorHardwareStackError",
"cudaErrorFunctionNotLoaded",
"cudaErrorExternalDevice",
"cudaErrorDuplicateVariableName",
"cudaErrorDuplicateTextureName",
Expand Down Expand Up @@ -11109,6 +11112,7 @@ sub warnUnsupportedFunctions {
"CU_COREDUMP_SKIP_NONRELOCATED_ELF_IMAGES",
"CU_COREDUMP_SKIP_LOCAL_MEMORY",
"CU_COREDUMP_SKIP_GLOBAL_MEMORY",
"CU_COREDUMP_SKIP_CONSTBANK_MEMORY",
"CU_COREDUMP_SKIP_ABORT",
"CU_COREDUMP_PIPE",
"CU_COREDUMP_MAX",
Expand Down
8 changes: 4 additions & 4 deletions docs/hipify-clang.rst
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,8 @@ Dependencies
- `12.3.2 <https://developer.nvidia.com/cuda-downloads>`_ :sup:`4`
- **Latest stable config**
- **Latest stable config**
* - `19.0.0 git <https://github.com/llvm/llvm-project>`_
- `12.5.1 <https://developer.nvidia.com/cuda-downloads>`_
* - `20.0.0 git <https://github.com/llvm/llvm-project>`_
- `12.6.0 <https://developer.nvidia.com/cuda-12-6-0-download-archive>`_
- ✅
- ✅

Expand Down Expand Up @@ -822,8 +822,8 @@ Tested configurations:
- ``2019.16.11.38, 2022.17.10.5``
- ``3.30.0``
- ``3.12.5``
* - ``19.0.0git``
- ``7.0 - 12.5.1``
* - ``20.0.0git``
- ``7.0 - 12.6.0``
- ``8.0.5 - 9.4.0``
- ``2019.16.11.38, 2022.17.10.5``
- ``3.30.0``
Expand Down
1 change: 1 addition & 0 deletions docs/tables/CUDA_Driver_API_functions_supported_by_HIP.md
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,7 @@
|`CU_COREDUMP_MAX`|12.1| | | | | | | | | |
|`CU_COREDUMP_PIPE`|12.1| | | | | | | | | |
|`CU_COREDUMP_SKIP_ABORT`|12.5| | | | | | | | | |
|`CU_COREDUMP_SKIP_CONSTBANK_MEMORY`|12.6| | | | | | | | | |
|`CU_COREDUMP_SKIP_GLOBAL_MEMORY`|12.5| | | | | | | | | |
|`CU_COREDUMP_SKIP_LOCAL_MEMORY`|12.5| | | | | | | | | |
|`CU_COREDUMP_SKIP_NONRELOCATED_ELF_IMAGES`|12.5| | | | | | | | | |
Expand Down
3 changes: 3 additions & 0 deletions docs/tables/CUDA_Runtime_API_functions_supported_by_HIP.md
Original file line number Diff line number Diff line change
Expand Up @@ -1033,6 +1033,7 @@
|`cudaErrorECCUncorrectable`| | | | |`hipErrorECCNotCorrectable`|1.6.0| | | | |
|`cudaErrorExternalDevice`| | | | | | | | | | |
|`cudaErrorFileNotFound`|10.1| | | |`hipErrorFileNotFound`|1.6.0| | | | |
|`cudaErrorFunctionNotLoaded`|12.6| | | | | | | | | |
|`cudaErrorGraphExecUpdateFailure`|10.2| | | |`hipErrorGraphExecUpdateFailure`|5.0.0| | | | |
|`cudaErrorHardwareStackError`| | | | | | | | | | |
|`cudaErrorHostMemoryAlreadyRegistered`| | | | |`hipErrorHostMemoryAlreadyRegistered`|1.6.0| | | | |
Expand All @@ -1059,7 +1060,9 @@
|`cudaErrorInvalidPc`| | | | | | | | | | |
|`cudaErrorInvalidPitchValue`| | | | |`hipErrorInvalidPitchValue`|4.2.0| | | | |
|`cudaErrorInvalidPtx`| | | | |`hipErrorInvalidKernelFile`|1.6.0| | | | |
|`cudaErrorInvalidResourceConfiguration`|12.6| | | | | | | | | |
|`cudaErrorInvalidResourceHandle`| | | | |`hipErrorInvalidHandle`|1.6.0| | | | |
|`cudaErrorInvalidResourceType`|12.6| | | | | | | | | |
|`cudaErrorInvalidSource`|10.1| | | |`hipErrorInvalidSource`|1.6.0| | | | |
|`cudaErrorInvalidSurface`| | | | | | | | | | |
|`cudaErrorInvalidSymbol`| | | | |`hipErrorInvalidSymbol`|1.6.0| | | | |
Expand Down
9 changes: 6 additions & 3 deletions src/CUDA2HIP_Driver_API_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1873,11 +1873,11 @@ const std::map<llvm::StringRef, hipCounter> CUDA_DRIVER_TYPE_NAME_MAP {
{"CUDA_ERROR_EXTERNAL_DEVICE", {"hipErrorExternalDevice", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 911
// cudaErrorInvalidClusterSize
{"CUDA_ERROR_INVALID_CLUSTER_SIZE", {"hipErrorInvalidClusterSize", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 912
//
// cudaErrorFunctionNotLoaded
{"CUDA_ERROR_FUNCTION_NOT_LOADED", {"hipErrorFunctionNotLoaded", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 913
//
// cudaErrorInvalidResourceType
{"CUDA_ERROR_INVALID_RESOURCE_TYPE", {"hipErrorInvalidResourceType", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 914
//
// cudaErrorInvalidResourceConfiguration
{"CUDA_ERROR_INVALID_RESOURCE_CONFIGURATION", {"hipErrorInvalidResourceConfiguration", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 915
// cudaErrorUnknown
{"CUDA_ERROR_UNKNOWN", {"hipErrorUnknown", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES}}, // 999
Expand Down Expand Up @@ -2665,6 +2665,8 @@ const std::map<llvm::StringRef, hipCounter> CUDA_DRIVER_TYPE_NAME_MAP {
//
{"CU_COREDUMP_SKIP_ABORT", {"HIP_COREDUMP_SKIP_ABORT", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES, HIP_UNSUPPORTED}},
//
{"CU_COREDUMP_SKIP_CONSTBANK_MEMORY", {"HIP_COREDUMP_SKIP_CONSTBANK_MEMORY", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES, HIP_UNSUPPORTED}},
//
{"CU_COREDUMP_LIGHTWEIGHT_FLAGS", {"HIP_COREDUMP_LIGHTWEIGHT_FLAGS", "", CONV_NUMERIC_LITERAL, API_DRIVER, SEC::DATA_TYPES, HIP_UNSUPPORTED}},

//
Expand Down Expand Up @@ -3851,6 +3853,7 @@ const std::map<llvm::StringRef, cudaAPIversions> CUDA_DRIVER_TYPE_NAME_VER_MAP {
{"CUdevSmResourceSplit_flags", {CUDA_125, CUDA_0, CUDA_0 }},
{"CU_DEV_SM_RESOURCE_SPLIT_IGNORE_SM_COSCHEDULING", {CUDA_125, CUDA_0, CUDA_0 }},
{"CU_DEV_SM_RESOURCE_SPLIT_MAX_POTENTIAL_CLUSTER_SIZE", {CUDA_125, CUDA_0, CUDA_0 }},
{"CU_COREDUMP_SKIP_CONSTBANK_MEMORY", {CUDA_126, CUDA_0, CUDA_0 }},
};

const std::map<llvm::StringRef, hipAPIversions> HIP_DRIVER_TYPE_NAME_VER_MAP {
Expand Down
9 changes: 9 additions & 0 deletions src/CUDA2HIP_Runtime_API_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1119,6 +1119,12 @@ const std::map<llvm::StringRef, hipCounter> CUDA_RUNTIME_TYPE_NAME_MAP {
{"cudaErrorExternalDevice", {"hipErrorExternalDevice", "", CONV_NUMERIC_LITERAL, API_RUNTIME, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 911
// CUDA_ERROR_INVALID_CLUSTER_SIZE
{"cudaErrorInvalidClusterSize", {"hipErrorInvalidClusterSize", "", CONV_NUMERIC_LITERAL, API_RUNTIME, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 912
// CUDA_ERROR_FUNCTION_NOT_LOADED
{"cudaErrorFunctionNotLoaded", {"hipErrorFunctionNotLoaded", "", CONV_NUMERIC_LITERAL, API_RUNTIME, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 913
// CUDA_ERROR_INVALID_RESOURCE_TYPE
{"cudaErrorInvalidResourceType", {"hipErrorInvalidResourceType", "", CONV_NUMERIC_LITERAL, API_RUNTIME, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 914
// CUDA_ERROR_INVALID_RESOURCE_CONFIGURATION
{"cudaErrorInvalidResourceConfiguration", {"hipErrorInvalidResourceConfiguration", "", CONV_NUMERIC_LITERAL, API_RUNTIME, SEC::DATA_TYPES, HIP_UNSUPPORTED}}, // 915
// CUDA_ERROR_UNKNOWN
{"cudaErrorUnknown", {"hipErrorUnknown", "", CONV_NUMERIC_LITERAL, API_RUNTIME, SEC::DATA_TYPES}}, // 999
// Deprecated since CUDA 4.1
Expand Down Expand Up @@ -2827,6 +2833,9 @@ const std::map<llvm::StringRef, cudaAPIversions> CUDA_RUNTIME_TYPE_NAME_VER_MAP
{"cudaDevAttrD3D12CigSupported", {CUDA_125, CUDA_0, CUDA_0 }},
{"cudaLaunchAttributePreferredSharedMemoryCarveout", {CUDA_125, CUDA_0, CUDA_0 }},
{"cudaKernelNodeAttributePreferredSharedMemoryCarveout", {CUDA_125, CUDA_0, CUDA_0 }},
{"cudaErrorFunctionNotLoaded", {CUDA_126, CUDA_0, CUDA_0 }},
{"cudaErrorInvalidResourceType", {CUDA_126, CUDA_0, CUDA_0 }},
{"cudaErrorInvalidResourceConfiguration", {CUDA_126, CUDA_0, CUDA_0 }},
};

const std::map<llvm::StringRef, hipAPIversions> HIP_RUNTIME_TYPE_NAME_VER_MAP {
Expand Down
1 change: 1 addition & 0 deletions src/Statistics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -490,6 +490,7 @@ std::string Statistics::getCudaVersion(const cudaVersions &ver) {
case CUDA_123: return "12.3";
case CUDA_124: return "12.4";
case CUDA_125: return "12.5";
case CUDA_126: return "12.6";
case CUDNN_10: return "1.0.0";
case CUDNN_20: return "2.0.0";
case CUDNN_30: return "3.0.0";
Expand Down
3 changes: 2 additions & 1 deletion src/Statistics.h
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,8 @@ enum cudaVersions {
CUDA_123 = 12030,
CUDA_124 = 12040,
CUDA_125 = 12050,
CUDA_LATEST = CUDA_125,
CUDA_126 = 12060,
CUDA_LATEST = CUDA_126,
CUDNN_10 = 100,
CUDNN_20 = 200,
CUDNN_30 = 300,
Expand Down

0 comments on commit 5e0739a

Please sign in to comment.