1 //===-- HexagonFixupKinds.h - Hexagon Specific Fixup Entries --------------===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #ifndef LLVM_HEXAGON_HEXAGONFIXUPKINDS_H
11 #define LLVM_HEXAGON_HEXAGONFIXUPKINDS_H
12 
13 #include "llvm/MC/MCFixup.h"
14 
15 namespace llvm {
16 namespace Hexagon {
17 enum Fixups {
18   // Branch fixups for R_HEX_B{22,15,7}_PCREL.
19   fixup_Hexagon_B22_PCREL = FirstTargetFixupKind,
20   fixup_Hexagon_B15_PCREL,
21   fixup_Hexagon_B7_PCREL,
22   fixup_Hexagon_LO16,
23   fixup_Hexagon_HI16,
24   fixup_Hexagon_32,
25   fixup_Hexagon_16,
26   fixup_Hexagon_8,
27   fixup_Hexagon_GPREL16_0,
28   fixup_Hexagon_GPREL16_1,
29   fixup_Hexagon_GPREL16_2,
30   fixup_Hexagon_GPREL16_3,
31   fixup_Hexagon_HL16,
32   fixup_Hexagon_B13_PCREL,
33   fixup_Hexagon_B9_PCREL,
34   fixup_Hexagon_B32_PCREL_X,
35   fixup_Hexagon_32_6_X,
36   fixup_Hexagon_B22_PCREL_X,
37   fixup_Hexagon_B15_PCREL_X,
38   fixup_Hexagon_B13_PCREL_X,
39   fixup_Hexagon_B9_PCREL_X,
40   fixup_Hexagon_B7_PCREL_X,
41   fixup_Hexagon_16_X,
42   fixup_Hexagon_12_X,
43   fixup_Hexagon_11_X,
44   fixup_Hexagon_10_X,
45   fixup_Hexagon_9_X,
46   fixup_Hexagon_8_X,
47   fixup_Hexagon_7_X,
48   fixup_Hexagon_6_X,
49   fixup_Hexagon_32_PCREL,
50   fixup_Hexagon_COPY,
51   fixup_Hexagon_GLOB_DAT,
52   fixup_Hexagon_JMP_SLOT,
53   fixup_Hexagon_RELATIVE,
54   fixup_Hexagon_PLT_B22_PCREL,
55   fixup_Hexagon_GOTREL_LO16,
56   fixup_Hexagon_GOTREL_HI16,
57   fixup_Hexagon_GOTREL_32,
58   fixup_Hexagon_GOT_LO16,
59   fixup_Hexagon_GOT_HI16,
60   fixup_Hexagon_GOT_32,
61   fixup_Hexagon_GOT_16,
62   fixup_Hexagon_DTPMOD_32,
63   fixup_Hexagon_DTPREL_LO16,
64   fixup_Hexagon_DTPREL_HI16,
65   fixup_Hexagon_DTPREL_32,
66   fixup_Hexagon_DTPREL_16,
67   fixup_Hexagon_GD_PLT_B22_PCREL,
68   fixup_Hexagon_LD_PLT_B22_PCREL,
69   fixup_Hexagon_GD_GOT_LO16,
70   fixup_Hexagon_GD_GOT_HI16,
71   fixup_Hexagon_GD_GOT_32,
72   fixup_Hexagon_GD_GOT_16,
73   fixup_Hexagon_LD_GOT_LO16,
74   fixup_Hexagon_LD_GOT_HI16,
75   fixup_Hexagon_LD_GOT_32,
76   fixup_Hexagon_LD_GOT_16,
77   fixup_Hexagon_IE_LO16,
78   fixup_Hexagon_IE_HI16,
79   fixup_Hexagon_IE_32,
80   fixup_Hexagon_IE_16,
81   fixup_Hexagon_IE_GOT_LO16,
82   fixup_Hexagon_IE_GOT_HI16,
83   fixup_Hexagon_IE_GOT_32,
84   fixup_Hexagon_IE_GOT_16,
85   fixup_Hexagon_TPREL_LO16,
86   fixup_Hexagon_TPREL_HI16,
87   fixup_Hexagon_TPREL_32,
88   fixup_Hexagon_TPREL_16,
89   fixup_Hexagon_6_PCREL_X,
90   fixup_Hexagon_GOTREL_32_6_X,
91   fixup_Hexagon_GOTREL_16_X,
92   fixup_Hexagon_GOTREL_11_X,
93   fixup_Hexagon_GOT_32_6_X,
94   fixup_Hexagon_GOT_16_X,
95   fixup_Hexagon_GOT_11_X,
96   fixup_Hexagon_DTPREL_32_6_X,
97   fixup_Hexagon_DTPREL_16_X,
98   fixup_Hexagon_DTPREL_11_X,
99   fixup_Hexagon_GD_GOT_32_6_X,
100   fixup_Hexagon_GD_GOT_16_X,
101   fixup_Hexagon_GD_GOT_11_X,
102   fixup_Hexagon_LD_GOT_32_6_X,
103   fixup_Hexagon_LD_GOT_16_X,
104   fixup_Hexagon_LD_GOT_11_X,
105   fixup_Hexagon_IE_32_6_X,
106   fixup_Hexagon_IE_16_X,
107   fixup_Hexagon_IE_GOT_32_6_X,
108   fixup_Hexagon_IE_GOT_16_X,
109   fixup_Hexagon_IE_GOT_11_X,
110   fixup_Hexagon_TPREL_32_6_X,
111   fixup_Hexagon_TPREL_16_X,
112   fixup_Hexagon_TPREL_11_X,
113 
114   LastTargetFixupKind,
115   NumTargetFixupKinds = LastTargetFixupKind - FirstTargetFixupKind
116 };
117 enum FixupBitmaps : unsigned {
118   Word8 = 0xff,
119   Word16 = 0xffff,
120   Word32 = 0xffffffff,
121   Word32_LO = 0x00c03fff,
122   Word32_HL = 0x0, // Not Implemented
123   Word32_GP = 0x0, // Not Implemented
124   Word32_B7 = 0x00001f18,
125   Word32_B9 = 0x003000fe,
126   Word32_B13 = 0x00202ffe,
127   Word32_B15 = 0x00df20fe,
128   Word32_B22 = 0x01ff3ffe,
129   Word32_R6 = 0x000007e0,
130   Word32_U6 = 0x0,  // Not Implemented
131   Word32_U16 = 0x0, // Not Implemented
132   Word32_X26 = 0x0fff3fff
133 };
134 } // namespace Hexagon
135 } // namespace llvm
136 
137 #endif // LLVM_HEXAGON_HEXAGONFIXUPKINDS_H
138