diff options
| author | Konstantin Zhuravlyov <kzhuravl_dev@outlook.com> | 2016-05-31 22:47:11 +0000 |
|---|---|---|
| committer | Konstantin Zhuravlyov <kzhuravl_dev@outlook.com> | 2016-05-31 22:47:11 +0000 |
| commit | 81fbadb63f4d28f62950e2e2c4967f1429b3ca55 (patch) | |
| tree | a655a9b92d069924cfae73d9ccca6abfb95b9880 | |
| parent | 90b8b8db2e0271961bd707a8d3ba0c030f762d56 (diff) | |
| download | bcm5719-llvm-81fbadb63f4d28f62950e2e2c4967f1429b3ca55.tar.gz bcm5719-llvm-81fbadb63f4d28f62950e2e2c4967f1429b3ca55.zip | |
[AMDGPU] Set default dwarf version to 2
Differential Revision: http://reviews.llvm.org/D20640
llvm-svn: 271347
| -rw-r--r-- | clang/lib/Driver/ToolChains.h | 1 | ||||
| -rw-r--r-- | clang/test/Driver/amdgpu-toolchain.c | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/clang/lib/Driver/ToolChains.h b/clang/lib/Driver/ToolChains.h index 244c22a9646..030943dabbb 100644 --- a/clang/lib/Driver/ToolChains.h +++ b/clang/lib/Driver/ToolChains.h @@ -943,6 +943,7 @@ protected: public: AMDGPUToolChain(const Driver &D, const llvm::Triple &Triple, const llvm::opt::ArgList &Args); + unsigned GetDefaultDwarfVersion() const override { return 2; } bool IsIntegratedAssemblerDefault() const override { return true; } }; diff --git a/clang/test/Driver/amdgpu-toolchain.c b/clang/test/Driver/amdgpu-toolchain.c index 833b49df5d4..52a71975b7f 100644 --- a/clang/test/Driver/amdgpu-toolchain.c +++ b/clang/test/Driver/amdgpu-toolchain.c @@ -1,3 +1,6 @@ // RUN: %clang -### -target amdgcn--amdhsa -x assembler -mcpu=kaveri %s 2>&1 | FileCheck -check-prefix=AS_LINK %s // AS_LINK: clang{{.*}} "-cc1as" // 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" |

