## Test that llvm-readobj/llvm-readelf shows proper relocation type
## names and values for arm target.
# RUN: yaml2obj %s -o %t-arm.o
# RUN: llvm-readobj -r --expand-relocs %t-arm.o | FileCheck %s
# CHECK: Type: R_ARM_NONE (0)
# CHECK: Type: R_ARM_PC24 (1)
# CHECK: Type: R_ARM_ABS32 (2)
# CHECK: Type: R_ARM_REL32 (3)
# CHECK: Type: R_ARM_LDR_PC_G0 (4)
# CHECK: Type: R_ARM_ABS16 (5)
# CHECK: Type: R_ARM_ABS12 (6)
# CHECK: Type: R_ARM_THM_ABS5 (7)
# CHECK: Type: R_ARM_ABS8 (8)
# CHECK: Type: R_ARM_SBREL32 (9)
# CHECK: Type: R_ARM_THM_CALL (10)
# CHECK: Type: R_ARM_THM_PC8 (11)
# CHECK: Type: R_ARM_BREL_ADJ (12)
# CHECK: Type: R_ARM_TLS_DESC (13)
# CHECK: Type: R_ARM_THM_SWI8 (14)
# CHECK: Type: R_ARM_XPC25 (15)
# CHECK: Type: R_ARM_THM_XPC22 (16)
# CHECK: Type: R_ARM_TLS_DTPMOD32 (17)
# CHECK: Type: R_ARM_TLS_DTPOFF32 (18)
# CHECK: Type: R_ARM_TLS_TPOFF32 (19)
# CHECK: Type: R_ARM_COPY (20)
# CHECK: Type: R_ARM_GLOB_DAT (21)
# CHECK: Type: R_ARM_JUMP_SLOT (22)
# CHECK: Type: R_ARM_RELATIVE (23)
# CHECK: Type: R_ARM_GOTOFF32 (24)
# CHECK: Type: R_ARM_BASE_PREL (25)
# CHECK: Type: R_ARM_GOT_BREL (26)
# CHECK: Type: R_ARM_CALL (28)
# CHECK: Type: R_ARM_JUMP24 (29)
# CHECK: Type: R_ARM_THM_JUMP24 (30)
# CHECK: Type: R_ARM_BASE_ABS (31)
# CHECK: Type: R_ARM_ALU_PCREL_7_0 (32)
# CHECK: Type: R_ARM_ALU_PCREL_15_8 (33)
# CHECK: Type: R_ARM_ALU_PCREL_23_15 (34)
# CHECK: Type: R_ARM_LDR_SBREL_11_0_NC (35)
# CHECK: Type: R_ARM_ALU_SBREL_19_12_NC (36)
# CHECK: Type: R_ARM_ALU_SBREL_27_20_CK (37)
# CHECK: Type: R_ARM_TARGET1 (38)
# CHECK: Type: R_ARM_SBREL31 (39)
# CHECK: Type: R_ARM_V4BX (40)
# CHECK: Type: R_ARM_TARGET2 (41)
# CHECK: Type: R_ARM_PREL31 (42)
# CHECK: Type: R_ARM_MOVW_ABS_NC (43)
# CHECK: Type: R_ARM_MOVT_ABS (44)
# CHECK: Type: R_ARM_MOVW_PREL_NC (45)
# CHECK: Type: R_ARM_MOVT_PREL (46)
# CHECK: Type: R_ARM_THM_MOVW_ABS_NC (47)
# CHECK: Type: R_ARM_THM_MOVT_ABS (48)
# CHECK: Type: R_ARM_THM_MOVW_PREL_NC (49)
# CHECK: Type: R_ARM_THM_MOVT_PREL (50)
# CHECK: Type: R_ARM_THM_JUMP19 (51)
# CHECK: Type: R_ARM_THM_JUMP6 (52)
# CHECK: Type: R_ARM_THM_ALU_PREL_11_0 (53)
# CHECK: Type: R_ARM_THM_PC12 (54)
# CHECK: Type: R_ARM_ABS32_NOI (55)
# CHECK: Type: R_ARM_REL32_NOI (56)
# CHECK: Type: R_ARM_ALU_PC_G0_NC (57)
# CHECK: Type: R_ARM_ALU_PC_G0 (58)
# CHECK: Type: R_ARM_ALU_PC_G1_NC (59)
# CHECK: Type: R_ARM_ALU_PC_G1 (60)
# CHECK: Type: R_ARM_ALU_PC_G2 (61)
# CHECK: Type: R_ARM_LDR_PC_G1 (62)
# CHECK: Type: R_ARM_LDR_PC_G2 (63)
# CHECK: Type: R_ARM_LDRS_PC_G0 (64)
# CHECK: Type: R_ARM_LDRS_PC_G1 (65)
# CHECK: Type: R_ARM_LDRS_PC_G2 (66)
# CHECK: Type: R_ARM_LDC_PC_G0 (67)
# CHECK: Type: R_ARM_LDC_PC_G1 (68)
# CHECK: Type: R_ARM_LDC_PC_G2 (69)
# CHECK: Type: R_ARM_ALU_SB_G0_NC (70)
# CHECK: Type: R_ARM_ALU_SB_G0 (71)
# CHECK: Type: R_ARM_ALU_SB_G1_NC (72)
# CHECK: Type: R_ARM_ALU_SB_G1 (73)
# CHECK: Type: R_ARM_ALU_SB_G2 (74)
# CHECK: Type: R_ARM_LDR_SB_G0 (75)
# CHECK: Type: R_ARM_LDR_SB_G1 (76)
# CHECK: Type: R_ARM_LDR_SB_G2 (77)
# CHECK: Type: R_ARM_LDRS_SB_G0 (78)
# CHECK: Type: R_ARM_LDRS_SB_G1 (79)
# CHECK: Type: R_ARM_LDRS_SB_G2 (80)
# CHECK: Type: R_ARM_LDC_SB_G0 (81)
# CHECK: Type: R_ARM_LDC_SB_G1 (82)
# CHECK: Type: R_ARM_LDC_SB_G2 (83)
# CHECK: Type: R_ARM_MOVW_BREL_NC (84)
# CHECK: Type: R_ARM_MOVT_BREL (85)
# CHECK: Type: R_ARM_MOVW_BREL (86)
# CHECK: Type: R_ARM_THM_MOVW_BREL_NC (87)
# CHECK: Type: R_ARM_THM_MOVT_BREL (88)
# CHECK: Type: R_ARM_THM_MOVW_BREL (89)
# CHECK: Type: R_ARM_TLS_GOTDESC (90)
# CHECK: Type: R_ARM_TLS_CALL (91)
# CHECK: Type: R_ARM_TLS_DESCSEQ (92)
# CHECK: Type: R_ARM_THM_TLS_CALL (93)
# CHECK: Type: R_ARM_PLT32_ABS (94)
# CHECK: Type: R_ARM_GOT_ABS (95)
# CHECK: Type: R_ARM_GOT_PREL (96)
# CHECK: Type: R_ARM_GOT_BREL12 (97)
# CHECK: Type: R_ARM_GOTOFF12 (98)
# CHECK: Type: R_ARM_GOTRELAX (99)
# CHECK: Type: R_ARM_GNU_VTENTRY (100)
# CHECK: Type: R_ARM_GNU_VTINHERIT (101)
# CHECK: Type: R_ARM_THM_JUMP11 (102)
# CHECK: Type: R_ARM_THM_JUMP8 (103)
# CHECK: Type: R_ARM_TLS_GD32 (104)
# CHECK: Type: R_ARM_TLS_LDM32 (105)
# CHECK: Type: R_ARM_TLS_LDO32 (106)
# CHECK: Type: R_ARM_TLS_IE32 (107)
# CHECK: Type: R_ARM_TLS_LE32 (108)
# CHECK: Type: R_ARM_TLS_LDO12 (109)
# CHECK: Type: R_ARM_TLS_LE12 (110)
# CHECK: Type: R_ARM_TLS_IE12GP (111)
# CHECK: Type: R_ARM_PRIVATE_0 (112)
# CHECK: Type: R_ARM_PRIVATE_1 (113)
# CHECK: Type: R_ARM_PRIVATE_2 (114)
# CHECK: Type: R_ARM_PRIVATE_3 (115)
# CHECK: Type: R_ARM_PRIVATE_4 (116)
# CHECK: Type: R_ARM_PRIVATE_5 (117)
# CHECK: Type: R_ARM_PRIVATE_6 (118)
# CHECK: Type: R_ARM_PRIVATE_7 (119)
# CHECK: Type: R_ARM_PRIVATE_8 (120)
# CHECK: Type: R_ARM_PRIVATE_9 (121)
# CHECK: Type: R_ARM_PRIVATE_10 (122)
# CHECK: Type: R_ARM_PRIVATE_11 (123)
# CHECK: Type: R_ARM_PRIVATE_12 (124)
# CHECK: Type: R_ARM_PRIVATE_13 (125)
# CHECK: Type: R_ARM_PRIVATE_14 (126)
# CHECK: Type: R_ARM_PRIVATE_15 (127)
# CHECK: Type: R_ARM_ME_TOO (128)
# CHECK: Type: R_ARM_THM_TLS_DESCSEQ16 (129)
# CHECK: Type: R_ARM_THM_TLS_DESCSEQ32 (130)
# CHECK: Type: R_ARM_IRELATIVE (160)
# CHECK: Type: R_ARM_GOTFUNCDESC (161)
# CHECK: Type: R_ARM_GOTOFFFUNCDESC (162)
# CHECK: Type: R_ARM_FUNCDESC (163)
# CHECK: Type: R_ARM_FUNCDESC_VALUE (164)
# CHECK: Type: R_ARM_TLS_GD32_FDPIC (165)
# CHECK: Type: R_ARM_TLS_LDM32_FDPIC (166)
# CHECK: Type: R_ARM_TLS_IE32_FDPIC (167)
--- !ELF
FileHeader:
Class: ELFCLASS32
Data: ELFDATA2LSB
Type: ET_REL
Machine: EM_ARM
Sections:
- Name: .rel.text
Type: SHT_REL
Relocations:
- Type: R_ARM_NONE
- Type: R_ARM_PC24
- Type: R_ARM_ABS32
- Type: R_ARM_REL32
- Type: R_ARM_LDR_PC_G0
- Type: R_ARM_ABS16
- Type: R_ARM_ABS12
- Type: R_ARM_THM_ABS5
- Type: R_ARM_ABS8
- Type: R_ARM_SBREL32
- Type: R_ARM_THM_CALL
- Type: R_ARM_THM_PC8
- Type: R_ARM_BREL_ADJ
- Type: R_ARM_TLS_DESC
- Type: R_ARM_THM_SWI8
- Type: R_ARM_XPC25
- Type: R_ARM_THM_XPC22
- Type: R_ARM_TLS_DTPMOD32
- Type: R_ARM_TLS_DTPOFF32
- Type: R_ARM_TLS_TPOFF32
- Type: R_ARM_COPY
- Type: R_ARM_GLOB_DAT
- Type: R_ARM_JUMP_SLOT
- Type: R_ARM_RELATIVE
- Type: R_ARM_GOTOFF32
- Type: R_ARM_BASE_PREL
- Type: R_ARM_GOT_BREL
- Type: R_ARM_PLT32
- Type: R_ARM_CALL
- Type: R_ARM_JUMP24
- Type: R_ARM_THM_JUMP24
- Type: R_ARM_BASE_ABS
- Type: R_ARM_ALU_PCREL_7_0
- Type: R_ARM_ALU_PCREL_15_8
- Type: R_ARM_ALU_PCREL_23_15
- Type: R_ARM_LDR_SBREL_11_0_NC
- Type: R_ARM_ALU_SBREL_19_12_NC
- Type: R_ARM_ALU_SBREL_27_20_CK
- Type: R_ARM_TARGET1
- Type: R_ARM_SBREL31
- Type: R_ARM_V4BX
- Type: R_ARM_TARGET2
- Type: R_ARM_PREL31
- Type: R_ARM_MOVW_ABS_NC
- Type: R_ARM_MOVT_ABS
- Type: R_ARM_MOVW_PREL_NC
- Type: R_ARM_MOVT_PREL
- Type: R_ARM_THM_MOVW_ABS_NC
- Type: R_ARM_THM_MOVT_ABS
- Type: R_ARM_THM_MOVW_PREL_NC
- Type: R_ARM_THM_MOVT_PREL
- Type: R_ARM_THM_JUMP19
- Type: R_ARM_THM_JUMP6
- Type: R_ARM_THM_ALU_PREL_11_0
- Type: R_ARM_THM_PC12
- Type: R_ARM_ABS32_NOI
- Type: R_ARM_REL32_NOI
- Type: R_ARM_ALU_PC_G0_NC
- Type: R_ARM_ALU_PC_G0
- Type: R_ARM_ALU_PC_G1_NC
- Type: R_ARM_ALU_PC_G1
- Type: R_ARM_ALU_PC_G2
- Type: R_ARM_LDR_PC_G1
- Type: R_ARM_LDR_PC_G2
- Type: R_ARM_LDRS_PC_G0
- Type: R_ARM_LDRS_PC_G1
- Type: R_ARM_LDRS_PC_G2
- Type: R_ARM_LDC_PC_G0
- Type: R_ARM_LDC_PC_G1
- Type: R_ARM_LDC_PC_G2
- Type: R_ARM_ALU_SB_G0_NC
- Type: R_ARM_ALU_SB_G0
- Type: R_ARM_ALU_SB_G1_NC
- Type: R_ARM_ALU_SB_G1
- Type: R_ARM_ALU_SB_G2
- Type: R_ARM_LDR_SB_G0
- Type: R_ARM_LDR_SB_G1
- Type: R_ARM_LDR_SB_G2
- Type: R_ARM_LDRS_SB_G0
- Type: R_ARM_LDRS_SB_G1
- Type: R_ARM_LDRS_SB_G2
- Type: R_ARM_LDC_SB_G0
- Type: R_ARM_LDC_SB_G1
- Type: R_ARM_LDC_SB_G2
- Type: R_ARM_MOVW_BREL_NC
- Type: R_ARM_MOVT_BREL
- Type: R_ARM_MOVW_BREL
- Type: R_ARM_THM_MOVW_BREL_NC
- Type: R_ARM_THM_MOVT_BREL
- Type: R_ARM_THM_MOVW_BREL
- Type: R_ARM_TLS_GOTDESC
- Type: R_ARM_TLS_CALL
- Type: R_ARM_TLS_DESCSEQ
- Type: R_ARM_THM_TLS_CALL
- Type: R_ARM_PLT32_ABS
- Type: R_ARM_GOT_ABS
- Type: R_ARM_GOT_PREL
- Type: R_ARM_GOT_BREL12
- Type: R_ARM_GOTOFF12
- Type: R_ARM_GOTRELAX
- Type: R_ARM_GNU_VTENTRY
- Type: R_ARM_GNU_VTINHERIT
- Type: R_ARM_THM_JUMP11
- Type: R_ARM_THM_JUMP8
- Type: R_ARM_TLS_GD32
- Type: R_ARM_TLS_LDM32
- Type: R_ARM_TLS_LDO32
- Type: R_ARM_TLS_IE32
- Type: R_ARM_TLS_LE32
- Type: R_ARM_TLS_LDO12
- Type: R_ARM_TLS_LE12
- Type: R_ARM_TLS_IE12GP
- Type: R_ARM_PRIVATE_0
- Type: R_ARM_PRIVATE_1
- Type: R_ARM_PRIVATE_2
- Type: R_ARM_PRIVATE_3
- Type: R_ARM_PRIVATE_4
- Type: R_ARM_PRIVATE_5
- Type: R_ARM_PRIVATE_6
- Type: R_ARM_PRIVATE_7
- Type: R_ARM_PRIVATE_8
- Type: R_ARM_PRIVATE_9
- Type: R_ARM_PRIVATE_10
- Type: R_ARM_PRIVATE_11
- Type: R_ARM_PRIVATE_12
- Type: R_ARM_PRIVATE_13
- Type: R_ARM_PRIVATE_14
- Type: R_ARM_PRIVATE_15
- Type: R_ARM_ME_TOO
- Type: R_ARM_THM_TLS_DESCSEQ16
- Type: R_ARM_THM_TLS_DESCSEQ32
- Type: R_ARM_IRELATIVE
- Type: R_ARM_GOTFUNCDESC
- Type: R_ARM_GOTOFFFUNCDESC
- Type: R_ARM_FUNCDESC
- Type: R_ARM_FUNCDESC_VALUE
- Type: R_ARM_TLS_GD32_FDPIC
- Type: R_ARM_TLS_LDM32_FDPIC
- Type: R_ARM_TLS_IE32_FDPIC