[PATCH] D100126: AMDGPU: Add gfx90c support to code object v2 for backwards compatibility
Konstantin Zhuravlyov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 8 13:55:20 PDT 2021
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG4fae63c612a7: AMDGPU: Add gfx90c support to code object v2 for backwards compatibility (authored by kzhuravl).
Changed prior to commit:
https://reviews.llvm.org/D100126?vs=336188&id=336215#toc
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D100126/new/
https://reviews.llvm.org/D100126
Files:
llvm/docs/AMDGPUUsage.rst
llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
llvm/test/CodeGen/AMDGPU/tid-code-object-v2-backwards-compatibility.ll
Index: llvm/test/CodeGen/AMDGPU/tid-code-object-v2-backwards-compatibility.ll
===================================================================
--- /dev/null
+++ llvm/test/CodeGen/AMDGPU/tid-code-object-v2-backwards-compatibility.ll
@@ -0,0 +1,6 @@
+; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx90c -mattr=-xnack --amdhsa-code-object-version=2 < %s 2>&1 | FileCheck --check-prefix=GFX90C-VALID %s
+; RUN: not --crash llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx90c --amdhsa-code-object-version=2 < %s 2>&1 | FileCheck --check-prefix=GFX90C-ERROR %s
+
+; GFX90C-VALID: .hsa_code_object_isa 9,0,12,"AMD","AMDGPU"
+; GFX90C-VALID: .amd_amdgpu_isa "amdgcn-amd-amdhsa--gfx90c"
+; GFX90C-ERROR: LLVM ERROR: AMD GPU code object V2 does not support processor gfx90c with XNACK being ON or ANY
Index: llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
===================================================================
--- llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
+++ llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
@@ -438,6 +438,11 @@
} else if (Processor == "gfx906") {
if (isXnackOnOrAny())
Processor = "gfx907";
+ } else if (Processor == "gfx90c") {
+ if (isXnackOnOrAny())
+ report_fatal_error(
+ "AMD GPU code object V2 does not support processor " + Processor +
+ " with XNACK being ON or ANY");
} else {
report_fatal_error(
"AMD GPU code object V2 does not support processor " + Processor);
Index: llvm/docs/AMDGPUUsage.rst
===================================================================
--- llvm/docs/AMDGPUUsage.rst
+++ llvm/docs/AMDGPUUsage.rst
@@ -1360,34 +1360,35 @@
.. table:: AMDGPU Code Object V2 Supported Processors and Fixed Target Feature Settings
:name: amdgpu-elf-note-record-supported_processors-v2-table
- ==================== ==========================
- Note Record ISA Name Target ID
- ==================== ==========================
- ``AMD:AMDGPU:6:0:0`` ``gfx600``
- ``AMD:AMDGPU:6:0:1`` ``gfx601``
- ``AMD:AMDGPU:6:0:2`` ``gfx602``
- ``AMD:AMDGPU:7:0:0`` ``gfx700``
- ``AMD:AMDGPU:7:0:1`` ``gfx701``
- ``AMD:AMDGPU:7:0:2`` ``gfx702``
- ``AMD:AMDGPU:7:0:3`` ``gfx703``
- ``AMD:AMDGPU:7:0:4`` ``gfx704``
- ``AMD:AMDGPU:7:0:5`` ``gfx705``
- ``AMD:AMDGPU:8:0:0`` ``gfx802``
- ``AMD:AMDGPU:8:0:1`` ``gfx801:xnack+``
- ``AMD:AMDGPU:8:0:2`` ``gfx802``
- ``AMD:AMDGPU:8:0:3`` ``gfx803``
- ``AMD:AMDGPU:8:0:4`` ``gfx803``
- ``AMD:AMDGPU:8:0:5`` ``gfx805``
- ``AMD:AMDGPU:8:1:0`` ``gfx810:xnack+``
- ``AMD:AMDGPU:9:0:0`` ``gfx900:xnack-``
- ``AMD:AMDGPU:9:0:1`` ``gfx900:xnack+``
- ``AMD:AMDGPU:9:0:2`` ``gfx902:xnack-``
- ``AMD:AMDGPU:9:0:3`` ``gfx902:xnack+``
- ``AMD:AMDGPU:9:0:4`` ``gfx904:xnack-``
- ``AMD:AMDGPU:9:0:5`` ``gfx904:xnack+``
- ``AMD:AMDGPU:9:0:6`` ``gfx906:sramecc-:xnack-``
- ``AMD:AMDGPU:9:0:7`` ``gfx906:sramecc-:xnack+``
- ==================== ==========================
+ ===================== ==========================
+ Note Record ISA Name Target ID
+ ===================== ==========================
+ ``AMD:AMDGPU:6:0:0`` ``gfx600``
+ ``AMD:AMDGPU:6:0:1`` ``gfx601``
+ ``AMD:AMDGPU:6:0:2`` ``gfx602``
+ ``AMD:AMDGPU:7:0:0`` ``gfx700``
+ ``AMD:AMDGPU:7:0:1`` ``gfx701``
+ ``AMD:AMDGPU:7:0:2`` ``gfx702``
+ ``AMD:AMDGPU:7:0:3`` ``gfx703``
+ ``AMD:AMDGPU:7:0:4`` ``gfx704``
+ ``AMD:AMDGPU:7:0:5`` ``gfx705``
+ ``AMD:AMDGPU:8:0:0`` ``gfx802``
+ ``AMD:AMDGPU:8:0:1`` ``gfx801:xnack+``
+ ``AMD:AMDGPU:8:0:2`` ``gfx802``
+ ``AMD:AMDGPU:8:0:3`` ``gfx803``
+ ``AMD:AMDGPU:8:0:4`` ``gfx803``
+ ``AMD:AMDGPU:8:0:5`` ``gfx805``
+ ``AMD:AMDGPU:8:1:0`` ``gfx810:xnack+``
+ ``AMD:AMDGPU:9:0:0`` ``gfx900:xnack-``
+ ``AMD:AMDGPU:9:0:1`` ``gfx900:xnack+``
+ ``AMD:AMDGPU:9:0:2`` ``gfx902:xnack-``
+ ``AMD:AMDGPU:9:0:3`` ``gfx902:xnack+``
+ ``AMD:AMDGPU:9:0:4`` ``gfx904:xnack-``
+ ``AMD:AMDGPU:9:0:5`` ``gfx904:xnack+``
+ ``AMD:AMDGPU:9:0:6`` ``gfx906:sramecc-:xnack-``
+ ``AMD:AMDGPU:9:0:7`` ``gfx906:sramecc-:xnack+``
+ ``AMD:AMDGPU:9:0:12`` ``gfx90c:xnack-``
+ ===================== ==========================
.. _amdgpu-note-records-v3-v4:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D100126.336215.patch
Type: text/x-patch
Size: 4351 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210408/734df20b/attachment.bin>
More information about the llvm-commits
mailing list