forked from OSchip/llvm-project
65 lines
1.6 KiB
Plaintext
65 lines
1.6 KiB
Plaintext
# Check ELF flags merging.
|
|
|
|
# RUN: yaml2obj -format=elf -docnum 1 %s > %t-none.o
|
|
# RUN: yaml2obj -format=elf -docnum 2 %s > %t-noreorder.o
|
|
# RUN: yaml2obj -format=elf -docnum 3 %s > %t-micro.o
|
|
|
|
# RUN: lld -flavor gnu -target mips64el -shared -o %t.so \
|
|
# RUN: %t-none.o %t-noreorder.o %t-micro.o
|
|
# RUN: llvm-readobj -file-headers %t.so | FileCheck %s
|
|
|
|
# CHECK: Flags [ (0x82000001)
|
|
# CHECK-NEXT: EF_MIPS_ARCH_64R2 (0x80000000)
|
|
# CHECK-NEXT: EF_MIPS_MICROMIPS (0x2000000)
|
|
# CHECK-NEXT: EF_MIPS_NOREORDER (0x1)
|
|
# CHECK-NEXT: ]
|
|
|
|
# none.o
|
|
---
|
|
FileHeader:
|
|
Class: ELFCLASS64
|
|
Data: ELFDATA2LSB
|
|
Type: ET_REL
|
|
Machine: EM_MIPS
|
|
Flags: [EF_MIPS_ARCH_5]
|
|
|
|
Sections:
|
|
- Name: .text
|
|
Type: SHT_PROGBITS
|
|
Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
|
|
AddressAlign: 0x10
|
|
Size: 0x08
|
|
|
|
# noreorder.o
|
|
---
|
|
FileHeader:
|
|
Class: ELFCLASS64
|
|
Data: ELFDATA2LSB
|
|
Type: ET_REL
|
|
Machine: EM_MIPS
|
|
Flags: [EF_MIPS_ARCH_64, EF_MIPS_NOREORDER]
|
|
|
|
Sections:
|
|
- Name: .text
|
|
Type: SHT_PROGBITS
|
|
Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
|
|
AddressAlign: 0x10
|
|
Size: 0x08
|
|
|
|
# micro.o
|
|
---
|
|
FileHeader:
|
|
Class: ELFCLASS64
|
|
Data: ELFDATA2LSB
|
|
Type: ET_REL
|
|
Machine: EM_MIPS
|
|
Flags: [EF_MIPS_ARCH_64R2, EF_MIPS_MICROMIPS]
|
|
|
|
Sections:
|
|
- Name: .text
|
|
Type: SHT_PROGBITS
|
|
Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
|
|
AddressAlign: 0x10
|
|
Size: 0x08
|
|
...
|