summaryrefslogtreecommitdiffstats
path: root/llvm/test
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/test')
-rw-r--r--llvm/test/Bitcode/Inputs/invalid-abbrev-fixed-size-too-big.bcbin0 -> 612 bytes
-rw-r--r--llvm/test/Bitcode/Inputs/invalid-abbrev-vbr-size-too-big.bcbin0 -> 612 bytes
-rw-r--r--llvm/test/Bitcode/invalid.test7
3 files changed, 7 insertions, 0 deletions
diff --git a/llvm/test/Bitcode/Inputs/invalid-abbrev-fixed-size-too-big.bc b/llvm/test/Bitcode/Inputs/invalid-abbrev-fixed-size-too-big.bc
new file mode 100644
index 00000000000..8fa28960d72
--- /dev/null
+++ b/llvm/test/Bitcode/Inputs/invalid-abbrev-fixed-size-too-big.bc
Binary files differ
diff --git a/llvm/test/Bitcode/Inputs/invalid-abbrev-vbr-size-too-big.bc b/llvm/test/Bitcode/Inputs/invalid-abbrev-vbr-size-too-big.bc
new file mode 100644
index 00000000000..35d00ba154b
--- /dev/null
+++ b/llvm/test/Bitcode/Inputs/invalid-abbrev-vbr-size-too-big.bc
Binary files differ
diff --git a/llvm/test/Bitcode/invalid.test b/llvm/test/Bitcode/invalid.test
index 5431368a0ad..b6c2ed3e8d6 100644
--- a/llvm/test/Bitcode/invalid.test
+++ b/llvm/test/Bitcode/invalid.test
@@ -66,3 +66,10 @@ RUN: not llvm-dis -disable-output %p/Inputs/invalid-fp-shift.bc 2>&1 | \
RUN: FileCheck --check-prefix=FP-SHIFT %s
FP-SHIFT: Invalid record
+
+RUN: not llvm-dis -disable-output %p/Inputs/invalid-abbrev-vbr-size-too-big.bc 2>&1 | \
+RUN: FileCheck --check-prefix=HUGE-ABBREV-OP %s
+RUN: not llvm-dis -disable-output %p/Inputs/invalid-abbrev-fixed-size-too-big.bc 2>&1 | \
+RUN: FileCheck --check-prefix=HUGE-ABBREV-OP %s
+
+HUGE-ABBREV-OP: Fixed or VBR abbrev record with size > MaxChunkData
OpenPOWER on IntegriCloud