69 lines
1.5 KiB
Plaintext
69 lines
1.5 KiB
Plaintext
# Check grouping of multiple consecutive relocations in case of N32
|
|
# and 64-bit MIPS ABIs.
|
|
|
|
# RUN: yaml2obj -format=elf %s > %t.o
|
|
# RUN: lld -flavor old-gnu -target mips -o %t.exe %t.o
|
|
# RUN: llvm-objdump -s -t %t.exe | FileCheck %s
|
|
|
|
# CHECK: Contents of section .text:
|
|
# CHECK-NEXT: 10000130 00001001 00002004
|
|
|
|
# CHECK: 10002000 l .data 00000004 D0
|
|
|
|
---
|
|
FileHeader:
|
|
Class: ELFCLASS32
|
|
Data: ELFDATA2MSB
|
|
Type: ET_REL
|
|
Machine: EM_MIPS
|
|
Flags: [EF_MIPS_PIC, EF_MIPS_CPIC, EF_MIPS_ARCH_64, EF_MIPS_ABI2]
|
|
|
|
Sections:
|
|
- Name: .text
|
|
Type: SHT_PROGBITS
|
|
Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
|
|
AddressAlign: 16
|
|
Size: 8
|
|
|
|
- Name: .rel.text
|
|
Type: SHT_RELA
|
|
Link: .symtab
|
|
AddressAlign: 4
|
|
Info: .text
|
|
Relocations:
|
|
- Offset: 0
|
|
Symbol: D0
|
|
Type: R_MIPS_32
|
|
Addend: 0x10000
|
|
- Offset: 0
|
|
Symbol: D0
|
|
Type: R_MIPS_HI16
|
|
- Offset: 4
|
|
Symbol: D0
|
|
Type: R_MIPS_32
|
|
Addend: 4
|
|
- Offset: 4
|
|
Symbol: D0
|
|
Type: R_MIPS_LO16
|
|
|
|
- Name: .data
|
|
Type: SHT_PROGBITS
|
|
Flags: [ SHF_WRITE, SHF_ALLOC ]
|
|
AddressAlign: 16
|
|
Size: 4
|
|
|
|
Symbols:
|
|
Local:
|
|
- Name: D0
|
|
Type: STT_FUNC
|
|
Section: .data
|
|
Value: 0
|
|
Size: 4
|
|
Global:
|
|
- Name: __start
|
|
Type: STT_FUNC
|
|
Section: .text
|
|
Value: 0
|
|
Size: 8
|
|
...
|