]> granicus.if.org Git - clang/commitdiff
AMDGPU: Don't emit debugger subtarget features
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Thu, 21 Feb 2019 21:31:43 +0000 (21:31 +0000)
committerMatt Arsenault <Matthew.Arsenault@amd.com>
Thu, 21 Feb 2019 21:31:43 +0000 (21:31 +0000)
Keep the flag around for compatability.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@354624 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Driver/ToolChains/AMDGPU.cpp
test/Driver/amdgpu-features.c

index b9300bcc42e778b49fdd213ef8fd7b85446b0d93..7f6ddabb2ac1deb3d5e55cd913aab5e5882d9450 100644 (file)
@@ -38,15 +38,8 @@ void amdgpu::Linker::ConstructJob(Compilation &C, const JobAction &JA,
 void amdgpu::getAMDGPUTargetFeatures(const Driver &D,
                                      const llvm::opt::ArgList &Args,
                                      std::vector<StringRef> &Features) {
-  if (const Arg *dAbi = Args.getLastArg(options::OPT_mamdgpu_debugger_abi)) {
-    StringRef value = dAbi->getValue();
-    if (value == "1.0") {
-      Features.push_back("+amdgpu-debugger-insert-nops");
-      Features.push_back("+amdgpu-debugger-emit-prologue");
-    } else {
-      D.Diag(diag::err_drv_clang_unsupported) << dAbi->getAsString(Args);
-    }
-  }
+  if (const Arg *dAbi = Args.getLastArg(options::OPT_mamdgpu_debugger_abi))
+    D.Diag(diag::err_drv_clang_unsupported) << dAbi->getAsString(Args);
 
   handleTargetFeaturesGroup(
     Args, Features, options::OPT_m_amdgpu_Features_Group);
index 15bcfed1550d19fba7a43811b5da9a46cf72278c..6b0f103fb6bc7cfcbd2d0b4bc7bc05082ced77de 100644 (file)
@@ -4,7 +4,7 @@
 
 // RUN: %clang -### -target amdgcn -x cl -S -emit-llvm -mcpu=kaveri -mamdgpu-debugger-abi=1.0 %s -o - 2>&1 \
 // 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"
+// CHECK-MAMDGPU-DEBUGGER-ABI-1-0: the clang compiler does not support '-mamdgpu-debugger-abi=1.0'
 
 // 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"