[PATCH] D53386: AMDGPU: Add options to enable/disable code object v3
Konstantin Zhuravlyov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 17 13:58:13 PDT 2018
kzhuravl created this revision.
kzhuravl added reviewers: artem.tamazov, t-tye.
Herald added subscribers: tpr, dstuttard, yaxunl, nhaehnle, wdng, jvesely.
https://reviews.llvm.org/D53386
Files:
include/clang/Driver/Options.td
test/Driver/amdgpu-features.c
Index: test/Driver/amdgpu-features.c
===================================================================
--- test/Driver/amdgpu-features.c
+++ test/Driver/amdgpu-features.c
@@ -6,6 +6,12 @@
// RUN: | FileCheck --check-prefix=CHECK-MAMDGPU-DEBUGGER-ABI-1-0 %s
// CHECK-MAMDGPU-DEBUGGER-ABI-1-0: "-target-feature" "+amdgpu-debugger-insert-nops" "-target-feature" "+amdgpu-debugger-emit-prologue"
+// RUN: %clang -### -target amdgcn -mcpu=gfx700 -mcode-object-v3 %s 2>&1 | FileCheck --check-prefix=CODE-OBJECT-V3 %s
+// CODE-OBJECT-V3: "-target-feature" "+code-object-v3"
+
+// RUN: %clang -### -target amdgcn -mcpu=gfx700 -mno-code-object-v3 %s 2>&1 | FileCheck --check-prefix=NO-CODE-OBJECT-V3 %s
+// NO-CODE-OBJECT-V3: "-target-feature" "-code-object-v3"
+
// RUN: %clang -### -target amdgcn -mcpu=gfx700 -mxnack %s 2>&1 | FileCheck --check-prefix=XNACK %s
// XNACK: "-target-feature" "+xnack"
Index: include/clang/Driver/Options.td
===================================================================
--- include/clang/Driver/Options.td
+++ include/clang/Driver/Options.td
@@ -2085,6 +2085,11 @@
Group<m_Group>,
HelpText<"Generate additional code for specified <version> of debugger ABI (AMDGPU only)">,
MetaVarName<"<version>">;
+
+def mcode_object_v3 : Flag<["-"], "mcode-object-v3">, Group<m_amdgpu_Features_Group>,
+ HelpText<"Enable code object v3 (AMDGPU only)">;
+def mno_code_object_v3 : Flag<["-"], "mno-code-object-v3">, Group<m_amdgpu_Features_Group>,
+ HelpText<"Disable code object v3 (AMDGPU only)">;
def mxnack : Flag<["-"], "mxnack">, Group<m_amdgpu_Features_Group>,
HelpText<"Enable XNACK (AMDGPU only)">;
def mno_xnack : Flag<["-"], "mno-xnack">, Group<m_amdgpu_Features_Group>,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D53386.170035.patch
Type: text/x-patch
Size: 1723 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181017/1be83ef0/attachment.bin>
More information about the llvm-commits
mailing list