diff --git a/CMakeLists.txt b/CMakeLists.txt index 635c9a18..e850a380 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -80,7 +80,7 @@ option(AOTRITON_INHERIT_SYSTEM_SITE_TRITON "Use system site packages and verify set(AOTRITON_USE_LOCAL_TRITON_WHEEL "" CACHE STRING "Substitute install from third_party/triton with install from local pip wheel package.") set(AOTRITON_GPU_BUILD_TIMEOUT "8.0" CACHE STRING "GPU kernel compiler times out after X minutes. 0 for indefinite. Highly recommended if AOTRITON_BUILD_FOR_TUNING=On.") option(AOTRITON_TERMINATE_WHEN_GPU_BUILD_TIMEOUT "compile.py will return error when GPU built timeout. Defensive option for CI" OFF) -set(AOTRITON_TARGET_ARCH "gfx90a;gfx942;gfx950;gfx1100;gfx1101;gfx1102;gfx1103;gfx1151;gfx1150;gfx1201;gfx1200" CACHE STRING "Target GPU Architecture. Select all GPUs within the given list") +set(AOTRITON_TARGET_ARCH "gfx908;gfx90a;gfx942;gfx950;gfx1100;gfx1101;gfx1102;gfx1103;gfx1151;gfx1150;gfx1201;gfx1200" CACHE STRING "Target GPU Architecture. Select all GPUs within the given list") set(TARGET_GPUS "OBSOLETE" CACHE STRING "OBSOLETE. To select only one GPU, use AOTRITON_TARGET_ARCH or AOTRITON_OVERRIDE_TARGET_GPUS.") set(AOTRITON_OVERRIDE_TARGET_GPUS "" CACHE STRING "Override AOTRITON_TARGET_ARCH, and only build for GPUs within this list.") set(AOTRITON_ALT_TRITON_WHEEL_CONFIG_FILE "" CACHE STRING "Specify how to use alternative Triton wheels for different architectures in a YAML config file.") diff --git a/include/aotriton/util.h b/include/aotriton/util.h index accc2c85..3cc15f99 100644 --- a/include/aotriton/util.h +++ b/include/aotriton/util.h @@ -52,6 +52,7 @@ enum AOTRITON_API GpuVendor : uint16_t { // More bits for potential non-PCI architectures enum AOTRITON_API Gpu : uint64_t { GPU_ARCH_UNKNOWN = 0, + GPU_AMD_ARCH_GFX908_MOD0 = TRICAT(GpuVendor::kAMD, 0x908, 0), GPU_AMD_ARCH_GFX90A_MOD0 = TRICAT(GpuVendor::kAMD, 0x90a, 0), GPU_AMD_ARCH_GFX942_MOD0 = TRICAT(GpuVendor::kAMD, 0x942, 0), GPU_AMD_ARCH_GFX942_MOD1 = TRICAT(GpuVendor::kAMD, 0x942, 1), diff --git a/requirements-tuning.txt b/requirements-tuning.txt index 75fb1838..aa8bc950 100644 --- a/requirements-tuning.txt +++ b/requirements-tuning.txt @@ -5,3 +5,4 @@ filelock celery[pyamqp,sqlalchemy] psycopg # the more mature psycopg2 needs extra binaries. dacite +textual \ No newline at end of file diff --git a/v2python/gpu_targets.py b/v2python/gpu_targets.py index 622def31..131b9ede 100644 --- a/v2python/gpu_targets.py +++ b/v2python/gpu_targets.py @@ -4,6 +4,7 @@ from collections import defaultdict AOTRITON_SUPPORTED_GPUS = ( + 'gfx908_mod0', 'gfx90a_mod0', 'gfx942_mod0', # 'gfx942_mod1', @@ -21,6 +22,7 @@ } AOTRITON_ARCH_WARPSIZE = { + 'gfx908' : 64, 'gfx90a' : 64, 'gfx942' : 64, 'gfx950' : 64, diff --git a/v3python/compile.py b/v3python/compile.py index 014140e4..326dfac5 100644 --- a/v3python/compile.py +++ b/v3python/compile.py @@ -14,7 +14,7 @@ from triton.backends.compiler import GPUTarget -KNOWN_TARGETS_64 = ['gfx90a', 'gfx942', 'gfx950'] +KNOWN_TARGETS_64 = ['gfx908', 'gfx90a', 'gfx942', 'gfx950'] KNOWN_TARGETS_32 = ['gfx1100', 'gfx1101', 'gfx1102', 'gfx1103', 'gfx1150', 'gfx1151', 'gfx1200', 'gfx1201', 'gfx1250'] KNOWN_TARGETS = { diff --git a/v3python/gpu_targets.py b/v3python/gpu_targets.py index a9387dac..8fcc757a 100644 --- a/v3python/gpu_targets.py +++ b/v3python/gpu_targets.py @@ -4,6 +4,7 @@ from collections import defaultdict AOTRITON_SUPPORTED_GPUS = ( + 'gfx908_mod0', 'gfx90a_mod0', 'gfx942_mod0', # 'gfx942_mod1', @@ -33,6 +34,7 @@ } AOTRITON_ARCH_TO_PACK = { + 'gfx908' : 'gfx908', 'gfx90a' : 'gfx90a', 'gfx942' : 'gfx942', 'gfx950' : 'gfx950', @@ -52,6 +54,7 @@ } AOTRITON_ARCH_WARPSIZE = { + 'gfx908' : 64, 'gfx90a' : 64, 'gfx942' : 64, 'gfx950' : 64, @@ -67,6 +70,7 @@ } AOTRITON_ARCH_PRODUCTION_LINE = { + 'gfx908' : 'CDNA', 'gfx90a' : 'CDNA', 'gfx942' : 'CDNA', 'gfx950' : 'CDNA', diff --git a/v3src/util.cc b/v3src/util.cc index 0ed58b64..f361a9a5 100644 --- a/v3src/util.cc +++ b/v3src/util.cc @@ -46,6 +46,7 @@ struct LazyGpu { }; std::unordered_map LazyGpu::string_to_classifier = { + { "gfx908", DummyClassifier() }, { "gfx90a", DummyClassifier() }, { "gfx942", DummyClassifier() }, {"gfx1100", DummyClassifier() }, @@ -74,7 +75,8 @@ getGpuFromStream(hipStream_t stream) { bool isArchExperimentallySupported(hipStream_t stream) { auto gpu = getGpuFromStream(stream); uint32_t vendor_arch = Gpu2VendorArch(gpu); - return (vendor_arch == CAT32(GpuVendor::kAMD, 0x1150) || + return (vendor_arch == CAT32(GpuVendor::kAMD, 0x908) || + vendor_arch == CAT32(GpuVendor::kAMD, 0x1150) || vendor_arch == CAT32(GpuVendor::kAMD, 0x1151) || vendor_arch == CAT32(GpuVendor::kAMD, 0x1100) || vendor_arch == CAT32(GpuVendor::kAMD, 0x1101) ||