]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - test/elf/Mips/jalx-align-err.test
Vendor import of lld trunk r233088:
[FreeBSD/FreeBSD.git] / test / elf / Mips / jalx-align-err.test
1 # Check that LLD shows an error if jalx target value is not word-aligned.
2
3 # RUN: yaml2obj -format=elf %s > %t-obj
4 # RUN: not lld -flavor gnu -target mipsel -e T0 -o %t-exe %t-obj 2>&1 \
5 # RUN:       | FileCheck %s
6
7 # CHECK: The jalx target 0x400116 is not word-aligned
8
9 !ELF
10 FileHeader: !FileHeader
11   Class:   ELFCLASS32
12   Data:    ELFDATA2LSB
13   Type:    ET_REL
14   Machine: EM_MIPS
15   Flags:   [ EF_MIPS_CPIC, EF_MIPS_ABI_O32, EF_MIPS_ARCH_32R2,
16              EF_MIPS_MICROMIPS ]
17
18 Sections:
19 - Name:         .text
20   Type:         SHT_PROGBITS
21   Size:         8
22   AddressAlign: 16
23   Flags:        [ SHF_ALLOC, SHF_EXECINSTR ]
24
25 - Name: .rel.text
26   Type: SHT_REL
27   Info: .text
28   AddressAlign: 4
29   Relocations:
30     - Offset: 0
31       Symbol: T1
32       Type:   R_MICROMIPS_26_S1
33
34 Symbols:
35   Global:
36     - Name:    T0
37       Section: .text
38       Type:    STT_FUNC
39       Value:   0
40       Size:    4
41       Other:   [ STO_MIPS_MICROMIPS ]
42     - Name:    T1
43       Section: .text
44       Type:    STT_FUNC
45       Value:   6
46       Size:    2