1 //===- HexagonRelocationFunction.h ----------------------------------------===// 2 // 3 // The MCLinker Project 4 // 5 // This file is distributed under the University of Illinois Open Source 6 // License. See LICENSE.TXT for details. 7 // 8 //===----------------------------------------------------------------------===// 9 #define DECL_HEXAGON_APPLY_RELOC_FUNC(Name) \ 10 static HexagonRelocator::Result Name (Relocation& pEntry, \ 11 HexagonRelocator& pParent); 12 13 #define DECL_HEXAGON_APPLY_RELOC_FUNCS \ 14 DECL_HEXAGON_APPLY_RELOC_FUNC(none) \ 15 DECL_HEXAGON_APPLY_RELOC_FUNC(relocB22PCREL) \ 16 DECL_HEXAGON_APPLY_RELOC_FUNC(relocB15PCREL) \ 17 DECL_HEXAGON_APPLY_RELOC_FUNC(relocLO16) \ 18 DECL_HEXAGON_APPLY_RELOC_FUNC(relocHI16) \ 19 DECL_HEXAGON_APPLY_RELOC_FUNC(reloc32) \ 20 DECL_HEXAGON_APPLY_RELOC_FUNC(reloc16) \ 21 DECL_HEXAGON_APPLY_RELOC_FUNC(reloc8) \ 22 DECL_HEXAGON_APPLY_RELOC_FUNC(relocB13PCREL) \ 23 DECL_HEXAGON_APPLY_RELOC_FUNC(reloc32PCREL) \ 24 DECL_HEXAGON_APPLY_RELOC_FUNC(unsupport) 25 26 27 #define DECL_HEXAGON_APPLY_RELOC_FUNC_PTRS \ 28 { &none, 0, "R_HEX_NONE" }, \ 29 { &relocB22PCREL, 1, "R_HEX_B22_PCREL" }, \ 30 { &relocB15PCREL, 2, "R_HEX_B15_PCREL" }, \ 31 { &unsupport, 3, "R_HEX_B7_PCREL" }, \ 32 { &relocLO16, 4, "R_HEX_LO16" }, \ 33 { &relocHI16, 5, "R_HEX_HI16" }, \ 34 { &reloc32, 6, "R_HEX_32" }, \ 35 { &reloc16, 7, "R_HEX_16" }, \ 36 { &reloc8, 8, "R_HEX_8" }, \ 37 { &unsupport, 9, "R_HEX_GPREL16_0" }, \ 38 { &unsupport, 10, "R_HEX_GPREL16_1" }, \ 39 { &unsupport, 11, "R_HEX_GPREL16_2" }, \ 40 { &unsupport, 12, "R_HEX_GPREL16_3" }, \ 41 { &unsupport, 13, "R_HEX_HL16" }, \ 42 { &relocB13PCREL, 14, "R_HEX_B13_PCREL" }, \ 43 { &unsupport, 15, "R_HEX_B9_PCREL" }, \ 44 { &unsupport, 16, "R_HEX_B32_PCREL_X" }, \ 45 { &unsupport, 17, "R_HEX_32_6_X" }, \ 46 { &unsupport, 18, "R_HEX_B22_PCREL_X" }, \ 47 { &unsupport, 19, "R_HEX_B15_PCREL_X" }, \ 48 { &unsupport, 20, "R_HEX_B13_PCREL_X" }, \ 49 { &unsupport, 21, "R_HEX_B9_PCREL_X" }, \ 50 { &unsupport, 22, "R_HEX_B7_PCREL_X" }, \ 51 { &unsupport, 23, "R_HEX_16_X" }, \ 52 { &unsupport, 24, "R_HEX_12_X" }, \ 53 { &unsupport, 25, "R_HEX_11_X" }, \ 54 { &unsupport, 26, "R_HEX_10_X" }, \ 55 { &unsupport, 27, "R_HEX_9_X" }, \ 56 { &unsupport, 28, "R_HEX_8_X" }, \ 57 { &unsupport, 29, "R_HEX_7_X" }, \ 58 { &unsupport, 30, "R_HEX_6_X" }, \ 59 { &reloc32PCREL, 31, "R_HEX_32_PCREL" }, \ 60 { &unsupport, 32, "R_HEX_COPY" }, \ 61 { &unsupport, 33, "R_HEX_GLOB_DAT" }, \ 62 { &unsupport, 34, "R_HEX_JMP_SLOT" }, \ 63 { &unsupport, 35, "R_HEX_RELATIVE" }, \ 64 { &unsupport, 36, "R_HEX_PLT_B22_PCREL" }, \ 65 { &unsupport, 37, "R_HEX_GOTREL_LO16" }, \ 66 { &unsupport, 38, "R_HEX_GOTREL_HI16" }, \ 67 { &unsupport, 39, "R_HEX_GOTREL_32" }, \ 68 { &unsupport, 40, "R_HEX_GOT_LO16" }, \ 69 { &unsupport, 41, "R_HEX_GOT_HI16" }, \ 70 { &unsupport, 42, "R_HEX_GOT_32" }, \ 71 { &unsupport, 43, "R_HEX_GOT_16" }, \ 72 { &unsupport, 44, "R_HEX_DTPMOD_32" }, \ 73 { &unsupport, 45, "R_HEX_DTPREL_LO16" }, \ 74 { &unsupport, 46, "R_HEX_DTPREL_HI16" }, \ 75 { &unsupport, 47, "R_HEX_DTPREL_32" }, \ 76 { &unsupport, 48, "R_HEX_DTPREL_16" }, \ 77 { &unsupport, 49, "R_HEX_GD_PLT_B22_PCREL" }, \ 78 { &unsupport, 50, "R_HEX_GD_GOT_LO16" }, \ 79 { &unsupport, 51, "R_HEX_GD_GOT_HI16" }, \ 80 { &unsupport, 52, "R_HEX_GD_GOT_32" }, \ 81 { &unsupport, 53, "R_HEX_GD_GOT_16" }, \ 82 { &unsupport, 54, "R_HEX_IE_LO16" }, \ 83 { &unsupport, 55, "R_HEX_IE_HI16" }, \ 84 { &unsupport, 56, "R_HEX_IE_32" }, \ 85 { &unsupport, 57, "R_HEX_IE_GOT_LO16" }, \ 86 { &unsupport, 58, "R_HEX_IE_GOT_HI16" }, \ 87 { &unsupport, 59, "R_HEX_IE_GOT_32" }, \ 88 { &unsupport, 60, "R_HEX_IE_GOT_16" }, \ 89 { &unsupport, 61, "R_HEX_TPREL_LO16" }, \ 90 { &unsupport, 62, "R_HEX_TPREL_HI16" }, \ 91 { &unsupport, 63, "R_HEX_TPREL_32" }, \ 92 { &unsupport, 64, "R_HEX_TPREL_16" }, \ 93 { &unsupport, 65, "R_HEX_6_PCREL_X" }, \ 94 { &unsupport, 66, "R_HEX_GOTREL_32_6_X" }, \ 95 { &unsupport, 67, "R_HEX_GOTREL_16_X" }, \ 96 { &unsupport, 68, "R_HEX_GOTREL_11_X" }, \ 97 { &unsupport, 69, "R_HEX_GOT_32_6_X" }, \ 98 { &unsupport, 70, "R_HEX_GOT_16_X" }, \ 99 { &unsupport, 71, "R_HEX_GOT_11_X" }, \ 100 { &unsupport, 72, "R_HEX_DTPREL_32_6_X" }, \ 101 { &unsupport, 73, "R_HEX_DTPREL_16_X" }, \ 102 { &unsupport, 74, "R_HEX_DTPREL_11_X" }, \ 103 { &unsupport, 75, "R_HEX_GD_GOT_32_6_X" }, \ 104 { &unsupport, 76, "R_HEX_GD_GOT_16_X" }, \ 105 { &unsupport, 77, "R_HEX_GD_GOT_11_X" }, \ 106 { &unsupport, 78, "R_HEX_IE_32_6_X" }, \ 107 { &unsupport, 79, "R_HEX_IE_16_X" }, \ 108 { &unsupport, 80, "R_HEX_IE_GOT_32_6_X" }, \ 109 { &unsupport, 81, "R_HEX_IE_GOT_16_X" }, \ 110 { &unsupport, 82, "R_HEX_IE_GOT_11_X" }, \ 111 { &unsupport, 83, "R_HEX_TPREL_32_6_X" }, \ 112 { &unsupport, 84, "R_HEX_TPREL_16_X" }, \ 113 { &unsupport, 85, "R_HEX_TPREL_11_X" } 114