summaryrefslogtreecommitdiffstats
path: root/llvm/test/tools/llvm-dwp
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2016-05-16 23:26:29 +0000
committerDavid Blaikie <dblaikie@gmail.com>2016-05-16 23:26:29 +0000
commit7bb62ef1e9932d01ab2ba8102882ae3d4b416073 (patch)
treed06bcfd3dac707b35c299f1f44353f855be61bef /llvm/test/tools/llvm-dwp
parenta5560500c602899bf027a43e52b513b4b8dc2d2e (diff)
downloadbcm5719-llvm-7bb62ef1e9932d01ab2ba8102882ae3d4b416073.tar.gz
bcm5719-llvm-7bb62ef1e9932d01ab2ba8102882ae3d4b416073.zip
llvm-dwp: Add error handling for invalid (non-CU) top level tag in debug_info.dwo
The diagnostic could be improved a bit to include information about which input file had the mistake (& which unit (counted, since the name of the unit won't be accessible) within the input). llvm-svn: 269723
Diffstat (limited to 'llvm/test/tools/llvm-dwp')
-rw-r--r--llvm/test/tools/llvm-dwp/Inputs/non_cu_top_level.dwobin0 -> 1153 bytes
-rw-r--r--llvm/test/tools/llvm-dwp/X86/non_cu_top_level.test3
2 files changed, 3 insertions, 0 deletions
diff --git a/llvm/test/tools/llvm-dwp/Inputs/non_cu_top_level.dwo b/llvm/test/tools/llvm-dwp/Inputs/non_cu_top_level.dwo
new file mode 100644
index 00000000000..26f276ad053
--- /dev/null
+++ b/llvm/test/tools/llvm-dwp/Inputs/non_cu_top_level.dwo
Binary files differ
diff --git a/llvm/test/tools/llvm-dwp/X86/non_cu_top_level.test b/llvm/test/tools/llvm-dwp/X86/non_cu_top_level.test
new file mode 100644
index 00000000000..60b8742cdc2
--- /dev/null
+++ b/llvm/test/tools/llvm-dwp/X86/non_cu_top_level.test
@@ -0,0 +1,3 @@
+RUN: not llvm-dwp %p/../Inputs/non_cu_top_level.dwo -o %t 2>&1 | FileCheck %s
+
+CHECK: error: top level DIE is not a compile unit
OpenPOWER on IntegriCloud