[PATCH] D59008: [AMDGPU] Switch default dwarf version to 5
Scott Linder via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Mar 28 11:19:58 PDT 2019
scott.linder updated this revision to Diff 192688.
scott.linder added a comment.
Add a test to confirm split-dwarf is supported for the amdhsa OS in the driver.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D59008/new/
https://reviews.llvm.org/D59008
Files:
lib/Driver/ToolChains/AMDGPU.h
test/Driver/amdgpu-toolchain.c
test/Driver/split-debug.c
Index: test/Driver/split-debug.c
===================================================================
--- test/Driver/split-debug.c
+++ test/Driver/split-debug.c
@@ -38,6 +38,9 @@
// RUN: %clang -target x86_64-pc-freebsd12 -gsplit-dwarf -c -### %s 2> %t
// RUN: FileCheck -check-prefix=CHECK-OPTION < %t %s
//
+// RUN: %clang -target amdgcn-amd-amdhsa -gsplit-dwarf -c -### %s 2> %t
+// RUN: FileCheck -check-prefix=CHECK-OPTION < %t %s
+//
// CHECK-OPTION: "-split-dwarf-file" "split-debug.dwo"
// RUN: %clang -target x86_64-unknown-linux-gnu -gsplit-dwarf -S -### %s 2> %t
Index: test/Driver/amdgpu-toolchain.c
===================================================================
--- test/Driver/amdgpu-toolchain.c
+++ test/Driver/amdgpu-toolchain.c
@@ -3,4 +3,4 @@
// AS_LINK: ld.lld{{.*}} "-shared"
// RUN: %clang -### -g -target amdgcn--amdhsa -mcpu=kaveri %s 2>&1 | FileCheck -check-prefix=DWARF_VER %s
-// DWARF_VER: "-dwarf-version=2"
+// DWARF_VER: "-dwarf-version=5"
Index: lib/Driver/ToolChains/AMDGPU.h
===================================================================
--- lib/Driver/ToolChains/AMDGPU.h
+++ lib/Driver/ToolChains/AMDGPU.h
@@ -55,7 +55,7 @@
public:
AMDGPUToolChain(const Driver &D, const llvm::Triple &Triple,
const llvm::opt::ArgList &Args);
- unsigned GetDefaultDwarfVersion() const override { return 2; }
+ unsigned GetDefaultDwarfVersion() const override { return 5; }
bool IsIntegratedAssemblerDefault() const override { return true; }
llvm::opt::DerivedArgList *
TranslateArgs(const llvm::opt::DerivedArgList &Args, StringRef BoundArch,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D59008.192688.patch
Type: text/x-patch
Size: 1616 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190328/eb7a7856/attachment.bin>
More information about the cfe-commits
mailing list