summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support
diff options
context:
space:
mode:
authorPaul Robinson <paul.robinson@sony.com>2017-02-28 20:24:55 +0000
committerPaul Robinson <paul.robinson@sony.com>2017-02-28 20:24:55 +0000
commitcddd60445ec8d07cf3465037a20a645f13a7deec (patch)
tree299ae93a0e10b19a34efc4bb2b2be947be43cd3e /llvm/lib/Support
parent781249833bfbcf30bfaa83022481ae54c39c82c0 (diff)
downloadbcm5719-llvm-cddd60445ec8d07cf3465037a20a645f13a7deec.tar.gz
bcm5719-llvm-cddd60445ec8d07cf3465037a20a645f13a7deec.zip
[DWARFv5] Emit new unit header format.
Requesting DWARF v5 will now get you the new compile-unit and type-unit headers. llvm-dwarfdump will also recognize them. Differential Revision: http://reviews.llvm.org/D30206 llvm-svn: 296514
Diffstat (limited to 'llvm/lib/Support')
-rw-r--r--llvm/lib/Support/Dwarf.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/llvm/lib/Support/Dwarf.cpp b/llvm/lib/Support/Dwarf.cpp
index 8950e8c919a..f13da62e4a8 100644
--- a/llvm/lib/Support/Dwarf.cpp
+++ b/llvm/lib/Support/Dwarf.cpp
@@ -304,6 +304,17 @@ StringRef llvm::dwarf::ApplePropertyString(unsigned Prop) {
}
}
+StringRef llvm::dwarf::UnitTypeString(unsigned UT) {
+ switch (UT) {
+ default:
+ return StringRef();
+#define HANDLE_DW_UT(ID, NAME) \
+ case DW_UT_##NAME: \
+ return "DW_UT_" #NAME;
+#include "llvm/Support/Dwarf.def"
+ }
+}
+
StringRef llvm::dwarf::AtomTypeString(unsigned AT) {
switch (AT) {
case dwarf::DW_ATOM_null:
OpenPOWER on IntegriCloud