2015-06-19 22:58:43 +02:00
|
|
|
RUN: not llvm-dwarfdump %p/Inputs/invalid-bad-rel-type.elf 2>&1 | FileCheck %s
|
2015-06-29 16:02:24 +02:00
|
|
|
RUN: not llvm-objdump -s %p/Inputs/invalid-strtab-type.elf 2>&1 | FileCheck %s
|
2015-06-29 16:39:25 +02:00
|
|
|
RUN: not llvm-objdump -s %p/Inputs/invalid-strtab-size.elf 2>&1 | FileCheck %s
|
2015-06-19 22:58:43 +02:00
|
|
|
CHECK: Invalid data was encountered while parsing the file
|
2015-06-29 16:12:14 +02:00
|
|
|
|
|
|
|
RUN: not llvm-objdump -s %p/Inputs/invalid-strtab-non-null.elf 2>&1 | FileCheck --check-prefix=NON-NULL %s
|
|
|
|
NON-NULL: String table must end with a null terminator
|
2015-06-30 16:59:20 +02:00
|
|
|
|
|
|
|
Test the sh_entsize are invalid
|
|
|
|
RUN: llvm-readobj -s %p/Inputs/invalid-sh_entsize.elf | FileCheck --check-prefix=SECTION %s
|
|
|
|
|
|
|
|
SECTION: Name: .dynsym
|
|
|
|
SECTION-NEXT: Type: SHT_DYNSYM
|
|
|
|
SECTION-NEXT: Flags [
|
|
|
|
SECTION-NEXT: SHF_ALLOC
|
|
|
|
SECTION-NEXT: ]
|
|
|
|
SECTION-NEXT: Address:
|
|
|
|
SECTION-NEXT: Offset:
|
|
|
|
SECTION-NEXT: Size:
|
|
|
|
SECTION-NEXT: Link:
|
|
|
|
SECTION-NEXT: Info:
|
|
|
|
SECTION-NEXT: AddressAlignment:
|
|
|
|
SECTION-NEXT: EntrySize: 32
|
|
|
|
|
|
|
|
SECTION: Name: .symtab
|
|
|
|
SECTION-NEXT: Type: SHT_SYMTAB
|
|
|
|
SECTION-NEXT: Flags [
|
|
|
|
SECTION-NEXT: ]
|
|
|
|
SECTION-NEXT: Address:
|
|
|
|
SECTION-NEXT: Offset:
|
|
|
|
SECTION-NEXT: Size:
|
|
|
|
SECTION-NEXT: Link:
|
|
|
|
SECTION-NEXT: Info:
|
|
|
|
SECTION-NEXT: AddressAlignment:
|
|
|
|
SECTION-NEXT: EntrySize: 32
|
|
|
|
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-sh_entsize.elf 2>&1 | FileCheck --check-prefix=INVALID-SYM-SIZE %s
|
|
|
|
INVALID-SYM-SIZE: Invalid symbol size
|
2015-06-30 20:23:07 +02:00
|
|
|
|
2016-02-17 16:38:21 +01:00
|
|
|
RUN: not llvm-readobj --dyn-symbols %p/Inputs/invalid-sh_entsize.elf 2>&1 | FileCheck --check-prefix=INVALID-DYNSYM-SIZE %s
|
|
|
|
INVALID-DYNSYM-SIZE: Invalid entity size
|
|
|
|
|
2015-06-30 20:23:07 +02:00
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-section-index.elf 2>&1 | FileCheck --check-prefix=INVALID-SECTION-INDEX %s
|
|
|
|
|
2015-07-01 14:56:27 +02:00
|
|
|
INVALID-SECTION-INDEX: Invalid section index
|
2015-06-30 21:58:10 +02:00
|
|
|
|
|
|
|
RUN: not llvm-readobj -s %p/Inputs/invalid-section-size.elf 2>&1 | FileCheck --check-prefix=INVALID-SECTION-SIZE %s
|
2015-07-02 13:48:48 +02:00
|
|
|
INVALID-SECTION-SIZE: Invalid section header entry size (e_shentsize) in ELF header
|
2015-07-23 05:24:22 +02:00
|
|
|
|
|
|
|
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-symbol-table-size.elf 2>&1 | FileCheck --check-prefix=INVALID-SYMTAB-SIZE %s
|
|
|
|
INVALID-SYMTAB-SIZE: Invalid symbol table size
|
2015-08-24 23:09:41 +02:00
|
|
|
|
|
|
|
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-xindex-size.elf 2>&1 | FileCheck --check-prefix=INVALID-XINDEX-SIZE %s
|
|
|
|
INVALID-XINDEX-SIZE: Invalid data was encountered while parsing the file.
|