1 ## Test that llvm-readobj/llvm-readelf shows proper relocation type
2 ## names and values for mips target.
4 # RUN: yaml2obj %s -o %t-mips.o
5 # RUN: llvm-readobj -r --expand-relocs %t-mips.o | FileCheck %s
7 # CHECK: Type: R_MIPS_NONE (0)
8 # CHECK: Type: R_MIPS_16 (1)
9 # CHECK: Type: R_MIPS_32 (2)
10 # CHECK: Type: R_MIPS_REL32 (3)
11 # CHECK: Type: R_MIPS_26 (4)
12 # CHECK: Type: R_MIPS_HI16 (5)
13 # CHECK: Type: R_MIPS_LO16 (6)
14 # CHECK: Type: R_MIPS_GPREL16 (7)
15 # CHECK: Type: R_MIPS_LITERAL (8)
16 # CHECK: Type: R_MIPS_GOT16 (9)
17 # CHECK: Type: R_MIPS_PC16 (10)
18 # CHECK: Type: R_MIPS_CALL16 (11)
19 # CHECK: Type: R_MIPS_GPREL32 (12)
20 # CHECK: Type: R_MIPS_SHIFT5 (16)
21 # CHECK: Type: R_MIPS_SHIFT6 (17)
22 # CHECK: Type: R_MIPS_64 (18)
23 # CHECK: Type: R_MIPS_GOT_DISP (19)
24 # CHECK: Type: R_MIPS_GOT_PAGE (20)
25 # CHECK: Type: R_MIPS_GOT_OFST (21)
26 # CHECK: Type: R_MIPS_GOT_HI16 (22)
27 # CHECK: Type: R_MIPS_GOT_LO16 (23)
28 # CHECK: Type: R_MIPS_SUB (24)
29 # CHECK: Type: R_MIPS_INSERT_A (25)
30 # CHECK: Type: R_MIPS_INSERT_B (26)
31 # CHECK: Type: R_MIPS_DELETE (27)
32 # CHECK: Type: R_MIPS_HIGHER (28)
33 # CHECK: Type: R_MIPS_HIGHEST (29)
34 # CHECK: Type: R_MIPS_CALL_HI16 (30)
35 # CHECK: Type: R_MIPS_CALL_LO16 (31)
36 # CHECK: Type: R_MIPS_SCN_DISP (32)
37 # CHECK: Type: R_MIPS_REL16 (33)
38 # CHECK: Type: R_MIPS_ADD_IMMEDIATE (34)
39 # CHECK: Type: R_MIPS_PJUMP (35)
40 # CHECK: Type: R_MIPS_RELGOT (36)
41 # CHECK: Type: R_MIPS_JALR (37)
42 # CHECK: Type: R_MIPS_TLS_DTPMOD32 (38)
43 # CHECK: Type: R_MIPS_TLS_DTPREL32 (39)
44 # CHECK: Type: R_MIPS_TLS_DTPMOD64 (40)
45 # CHECK: Type: R_MIPS_TLS_DTPREL64 (41)
46 # CHECK: Type: R_MIPS_TLS_GD (42)
47 # CHECK: Type: R_MIPS_TLS_LDM (43)
48 # CHECK: Type: R_MIPS_TLS_DTPREL_HI16 (44)
49 # CHECK: Type: R_MIPS_TLS_DTPREL_LO16 (45)
50 # CHECK: Type: R_MIPS_TLS_GOTTPREL (46)
51 # CHECK: Type: R_MIPS_TLS_TPREL32 (47)
52 # CHECK: Type: R_MIPS_TLS_TPREL64 (48)
53 # CHECK: Type: R_MIPS_TLS_TPREL_HI16 (49)
54 # CHECK: Type: R_MIPS_TLS_TPREL_LO16 (50)
55 # CHECK: Type: R_MIPS_GLOB_DAT (51)
56 # CHECK: Type: R_MIPS_COPY (126)
57 # CHECK: Type: R_MIPS_JUMP_SLOT (127)
58 # CHECK: Type: R_MIPS_NUM (218)
74 AddressAlign: 0x0000000000000004
75 EntSize: 0x0000000000000008
78 - Offset: 0x0000000000000000
80 - Offset: 0x0000000000000004
82 - Offset: 0x0000000000000008
84 - Offset: 0x000000000000000C
86 - Offset: 0x0000000000000010
88 - Offset: 0x0000000000000014
90 - Offset: 0x0000000000000018
92 - Offset: 0x000000000000001C
94 - Offset: 0x0000000000000020
96 - Offset: 0x0000000000000024
98 - Offset: 0x0000000000000028
100 - Offset: 0x000000000000002C
102 - Offset: 0x0000000000000030
104 - Offset: 0x0000000000000034
106 - Offset: 0x0000000000000038
108 - Offset: 0x000000000000003C
110 - Offset: 0x0000000000000040
111 Type: R_MIPS_GOT_DISP
112 - Offset: 0x0000000000000044
113 Type: R_MIPS_GOT_PAGE
114 - Offset: 0x0000000000000048
115 Type: R_MIPS_GOT_OFST
116 - Offset: 0x000000000000004C
117 Type: R_MIPS_GOT_HI16
118 - Offset: 0x0000000000000050
119 Type: R_MIPS_GOT_LO16
120 - Offset: 0x0000000000000054
122 - Offset: 0x0000000000000058
123 Type: R_MIPS_INSERT_A
124 - Offset: 0x000000000000005C
125 Type: R_MIPS_INSERT_B
126 - Offset: 0x0000000000000060
128 - Offset: 0x0000000000000064
130 - Offset: 0x0000000000000068
132 - Offset: 0x000000000000006C
133 Type: R_MIPS_CALL_HI16
134 - Offset: 0x0000000000000070
135 Type: R_MIPS_CALL_LO16
136 - Offset: 0x0000000000000074
137 Type: R_MIPS_SCN_DISP
138 - Offset: 0x0000000000000078
140 - Offset: 0x000000000000007C
141 Type: R_MIPS_ADD_IMMEDIATE
142 - Offset: 0x0000000000000080
144 - Offset: 0x0000000000000084
146 - Offset: 0x0000000000000088
148 - Offset: 0x000000000000008C
149 Type: R_MIPS_TLS_DTPMOD32
150 - Offset: 0x0000000000000090
151 Type: R_MIPS_TLS_DTPREL32
152 - Offset: 0x0000000000000094
153 Type: R_MIPS_TLS_DTPMOD64
154 - Offset: 0x0000000000000098
155 Type: R_MIPS_TLS_DTPREL64
156 - Offset: 0x000000000000009C
158 - Offset: 0x00000000000000A0
160 - Offset: 0x00000000000000A4
161 Type: R_MIPS_TLS_DTPREL_HI16
162 - Offset: 0x00000000000000A8
163 Type: R_MIPS_TLS_DTPREL_LO16
164 - Offset: 0x00000000000000AC
165 Type: R_MIPS_TLS_GOTTPREL
166 - Offset: 0x00000000000000B0
167 Type: R_MIPS_TLS_TPREL32
168 - Offset: 0x00000000000000B4
169 Type: R_MIPS_TLS_TPREL64
170 - Offset: 0x00000000000000B8
171 Type: R_MIPS_TLS_TPREL_HI16
172 - Offset: 0x00000000000000BC
173 Type: R_MIPS_TLS_TPREL_LO16
174 - Offset: 0x00000000000000C0
175 Type: R_MIPS_GLOB_DAT
176 - Offset: 0x00000000000000C4
178 - Offset: 0x00000000000000C8
179 Type: R_MIPS_JUMP_SLOT
180 - Offset: 0x00000000000000CC