diff options
author | Wolfgang Pieb <Wolfgang.Pieb@sony.com> | 2017-06-06 01:22:34 +0000 |
---|---|---|
committer | Wolfgang Pieb <Wolfgang.Pieb@sony.com> | 2017-06-06 01:22:34 +0000 |
commit | 77d3e938f846a8c02b0d4db59840d10f9b4dca54 (patch) | |
tree | 244bac1cccb6e7d89c9f6ee68a5bf7f61654e6bd /llvm/test/DebugInfo/dwarfdump-str-offsets-invalid.test | |
parent | 7bda19581229e4b78ccab72a2102d251cc1ab279 (diff) | |
download | bcm5719-llvm-77d3e938f846a8c02b0d4db59840d10f9b4dca54.tar.gz bcm5719-llvm-77d3e938f846a8c02b0d4db59840d10f9b4dca54.zip |
[DWARF] Adding support for the DWARF v5 string offsets table (consumer/reader part only).
Reviewers: dblaikie, aprantl
Differential Revision: https://reviews.llvm.org/D32779
llvm-svn: 304759
Diffstat (limited to 'llvm/test/DebugInfo/dwarfdump-str-offsets-invalid.test')
-rw-r--r-- | llvm/test/DebugInfo/dwarfdump-str-offsets-invalid.test | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/llvm/test/DebugInfo/dwarfdump-str-offsets-invalid.test b/llvm/test/DebugInfo/dwarfdump-str-offsets-invalid.test new file mode 100644 index 00000000000..45916d28de0 --- /dev/null +++ b/llvm/test/DebugInfo/dwarfdump-str-offsets-invalid.test @@ -0,0 +1,24 @@ +; Verify that llvm-dwarfdump handles invalid string offset tables. + +RUN: llvm-dwarfdump %p/Inputs/dwarfdump-str-offsets-invalid-1.x86_64.o | \ +RUN: FileCheck --check-prefix=INVALIDCONTRIB %s +RUN: llvm-dwarfdump %p/Inputs/dwarfdump-str-offsets-invalid-2.x86_64.o | \ +RUN: FileCheck --check-prefix=INVALIDCONTRIB %s +RUN: llvm-dwarfdump %p/Inputs/dwarfdump-str-offsets-invalid-3.x86_64.o | \ +RUN: FileCheck --check-prefix=INVALIDCONTRIB %s +RUN: llvm-dwarfdump %p/Inputs/dwarfdump-str-offsets-invalid-4.x86_64.o | \ +RUN: FileCheck --check-prefix=INVALIDLENGTH %s +RUN: llvm-dwarfdump %p/Inputs/dwarfdump-str-offsets-invalid-5.x86_64.o | \ +RUN: FileCheck --check-prefix=INVALIDSECTIONLENGTH %s + +INVALIDCONTRIB: .debug_str_offsets contents: +INVALIDCONTRIB-NOT: contents: +INVALIDCONTRIB: error: invalid contribution to string offsets table in section .debug_str_offsets. + +INVALIDLENGTH: .debug_str_offsets contents: +INVALIDLENGTH-NOT: contents: +INVALIDLENGTH: error: contribution to string offsets table in section .debug_str_offsets has invalid length. + +INVALIDSECTIONLENGTH: .debug_str_offsets contents: +INVALIDSECTIONLENGTH-NOT: contents: +INVALIDSECTIONLENGTH: error: size of .debug_str_offsets is not a multiple of 4. |