mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 20:23:11 +01:00
036854fbd0
Have it return a ErrorOr<Range> and delete section_begin and section_end. llvm-svn: 285807
81 lines
3.7 KiB
Plaintext
81 lines
3.7 KiB
Plaintext
RUN: not llvm-dwarfdump %p/Inputs/invalid-bad-rel-type.elf 2>&1 | FileCheck %s
|
|
RUN: not llvm-objdump -s %p/Inputs/invalid-strtab-type.elf 2>&1 | FileCheck %s
|
|
RUN: not llvm-objdump -s %p/Inputs/invalid-strtab-size.elf 2>&1 | FileCheck %s
|
|
RUN: not llvm-objdump -s %p/Inputs/invalid-strtab-zero-size.elf 2>&1 | FileCheck %s
|
|
CHECK: Invalid data was encountered while parsing the file
|
|
|
|
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
|
|
|
|
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 data was encountered while parsing the file
|
|
|
|
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
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-section-index.elf 2>&1 | FileCheck --check-prefix=INVALID-SECTION-INDEX %s
|
|
INVALID-SECTION-INDEX: Invalid section index
|
|
|
|
RUN: not llvm-readobj -s %p/Inputs/invalid-section-size.elf 2>&1 | FileCheck --check-prefix=INVALID-SECTION-SIZE %s
|
|
INVALID-SECTION-SIZE: Invalid data was encountered while parsing the file
|
|
|
|
|
|
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 data was encountered while parsing the file
|
|
|
|
|
|
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.
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-e_shnum.elf 2>&1 | FileCheck --check-prefix=INVALID-SH-NUM %s
|
|
INVALID-SH-NUM: Invalid data was encountered while parsing the file.
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-ext-symtab-index.elf-x86-64 2>&1 | \
|
|
RUN: FileCheck --check-prefix=INVALID-EXT-SYMTAB-INDEX %s
|
|
INVALID-EXT-SYMTAB-INDEX: Invalid symbol table index
|
|
|
|
RUN: not llvm-readobj -r %p/Inputs/invalid-relocation-sec-sh_offset.elf-i386 2>&1 | \
|
|
RUN: FileCheck --check-prefix=INVALID-RELOC-SH-OFFSET %s
|
|
RUN: not llvm-readobj -r %p/Inputs/invalid-relocation-sec-sh_offset.elf-x86-64 2>&1 | \
|
|
RUN: FileCheck --check-prefix=INVALID-RELOC-SH-OFFSET %s
|
|
INVALID-RELOC-SH-OFFSET: Invalid data was encountered while parsing the file
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-sections-address-alignment.x86-64 2>&1 | \
|
|
RUN: FileCheck --check-prefix=INVALID-SEC-ADDRESS-ALIGNMENT %s
|
|
INVALID-SEC-ADDRESS-ALIGNMENT: Invalid data was encountered while parsing the file
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-section-size2.elf 2>&1 | \
|
|
RUN: FileCheck --check-prefix=INVALID-SECTION-SIZE2 %s
|
|
INVALID-SECTION-SIZE2: Invalid data was encountered while parsing the file.
|
|
|
|
RUN: not llvm-readobj -t %p/Inputs/invalid-sections-num.elf 2>&1 | FileCheck --check-prefix=INVALID-SECTION-NUM %s
|
|
INVALID-SECTION-NUM: Invalid data was encountered while parsing the file.
|