1
2#ifndef ELF_RELOC
3#error "ELF_RELOC must be defined"
4#endif
5
6ELF_RELOC(R_RISCV_NONE, 0)
7ELF_RELOC(R_RISCV_32, 1)
8ELF_RELOC(R_RISCV_64, 2)
9ELF_RELOC(R_RISCV_RELATIVE, 3)
10ELF_RELOC(R_RISCV_COPY, 4)
11ELF_RELOC(R_RISCV_JUMP_SLOT, 5)
12ELF_RELOC(R_RISCV_TLS_DTPMOD32, 6)
13ELF_RELOC(R_RISCV_TLS_DTPMOD64, 7)
14ELF_RELOC(R_RISCV_TLS_DTPREL32, 8)
15ELF_RELOC(R_RISCV_TLS_DTPREL64, 9)
16ELF_RELOC(R_RISCV_TLS_TPREL32, 10)
17ELF_RELOC(R_RISCV_TLS_TPREL64, 11)
18ELF_RELOC(R_RISCV_TLSDESC, 12)
19ELF_RELOC(R_RISCV_BRANCH, 16)
20ELF_RELOC(R_RISCV_JAL, 17)
21ELF_RELOC(R_RISCV_CALL, 18)
22ELF_RELOC(R_RISCV_CALL_PLT, 19)
23ELF_RELOC(R_RISCV_GOT_HI20, 20)
24ELF_RELOC(R_RISCV_TLS_GOT_HI20, 21)
25ELF_RELOC(R_RISCV_TLS_GD_HI20, 22)
26ELF_RELOC(R_RISCV_PCREL_HI20, 23)
27ELF_RELOC(R_RISCV_PCREL_LO12_I, 24)
28ELF_RELOC(R_RISCV_PCREL_LO12_S, 25)
29ELF_RELOC(R_RISCV_HI20, 26)
30ELF_RELOC(R_RISCV_LO12_I, 27)
31ELF_RELOC(R_RISCV_LO12_S, 28)
32ELF_RELOC(R_RISCV_TPREL_HI20, 29)
33ELF_RELOC(R_RISCV_TPREL_LO12_I, 30)
34ELF_RELOC(R_RISCV_TPREL_LO12_S, 31)
35ELF_RELOC(R_RISCV_TPREL_ADD, 32)
36ELF_RELOC(R_RISCV_ADD8, 33)
37ELF_RELOC(R_RISCV_ADD16, 34)
38ELF_RELOC(R_RISCV_ADD32, 35)
39ELF_RELOC(R_RISCV_ADD64, 36)
40ELF_RELOC(R_RISCV_SUB8, 37)
41ELF_RELOC(R_RISCV_SUB16, 38)
42ELF_RELOC(R_RISCV_SUB32, 39)
43ELF_RELOC(R_RISCV_SUB64, 40)
44ELF_RELOC(R_RISCV_GOT32_PCREL, 41)
45ELF_RELOC(R_RISCV_ALIGN, 43)
46ELF_RELOC(R_RISCV_RVC_BRANCH, 44)
47ELF_RELOC(R_RISCV_RVC_JUMP, 45)
48ELF_RELOC(R_RISCV_RVC_LUI, 46)
49ELF_RELOC(R_RISCV_RELAX, 51)
50ELF_RELOC(R_RISCV_SUB6, 52)
51ELF_RELOC(R_RISCV_SET6, 53)
52ELF_RELOC(R_RISCV_SET8, 54)
53ELF_RELOC(R_RISCV_SET16, 55)
54ELF_RELOC(R_RISCV_SET32, 56)
55ELF_RELOC(R_RISCV_32_PCREL, 57)
56ELF_RELOC(R_RISCV_IRELATIVE, 58)
57ELF_RELOC(R_RISCV_PLT32, 59)
58ELF_RELOC(R_RISCV_SET_ULEB128, 60)
59ELF_RELOC(R_RISCV_SUB_ULEB128, 61)
60ELF_RELOC(R_RISCV_TLSDESC_HI20, 62)
61ELF_RELOC(R_RISCV_TLSDESC_LOAD_LO12, 63)
62ELF_RELOC(R_RISCV_TLSDESC_ADD_LO12, 64)
63ELF_RELOC(R_RISCV_TLSDESC_CALL, 65)
64

source code of llvm/include/llvm/BinaryFormat/ELFRelocs/RISCV.def