66//
77// ===----------------------------------------------------------------------===//
88
9- #include " MCTargetDesc/SystemZMCExpr .h"
9+ #include " MCTargetDesc/SystemZMCAsmInfo .h"
1010#include " MCTargetDesc/SystemZMCFixups.h"
1111#include " MCTargetDesc/SystemZMCTargetDesc.h"
1212#include " llvm/BinaryFormat/ELF.h"
@@ -103,14 +103,14 @@ unsigned SystemZELFObjectWriter::getRelocType(const MCFixup &Fixup,
103103 bool IsPCRel) const {
104104 SMLoc Loc = Fixup.getLoc ();
105105 unsigned Kind = Fixup.getKind ();
106- auto Specifier = SystemZMCExpr ::Specifier (Target.getSpecifier ());
106+ auto Specifier = SystemZ ::Specifier (Target.getSpecifier ());
107107 switch (Specifier) {
108- case SystemZMCExpr::VK_INDNTPOFF :
109- case SystemZMCExpr::VK_NTPOFF :
110- case SystemZMCExpr::VK_TLSGD :
111- case SystemZMCExpr::VK_TLSLD :
112- case SystemZMCExpr::VK_TLSLDM :
113- case SystemZMCExpr::VK_DTPOFF :
108+ case SystemZ::S_INDNTPOFF :
109+ case SystemZ::S_NTPOFF :
110+ case SystemZ::S_TLSGD :
111+ case SystemZ::S_TLSLD :
112+ case SystemZ::S_TLSLDM :
113+ case SystemZ::S_DTPOFF :
114114 if (auto *SA = Target.getAddSym ())
115115 cast<MCSymbolELF>(SA)->setType (ELF::STT_TLS);
116116 break ;
@@ -119,12 +119,12 @@ unsigned SystemZELFObjectWriter::getRelocType(const MCFixup &Fixup,
119119 }
120120
121121 switch (Specifier) {
122- case SystemZMCExpr::VK_None :
122+ case SystemZ::S_None :
123123 if (IsPCRel)
124124 return getPCRelReloc (Loc, Kind);
125125 return getAbsoluteReloc (Loc, Kind);
126126
127- case SystemZMCExpr::VK_NTPOFF :
127+ case SystemZ::S_NTPOFF :
128128 assert (!IsPCRel && " NTPOFF shouldn't be PC-relative" );
129129 switch (Kind) {
130130 case FK_Data_4:
@@ -135,14 +135,14 @@ unsigned SystemZELFObjectWriter::getRelocType(const MCFixup &Fixup,
135135 reportError (Loc, " Unsupported thread-local address (local-exec)" );
136136 return 0 ;
137137
138- case SystemZMCExpr::VK_INDNTPOFF :
138+ case SystemZ::S_INDNTPOFF :
139139 if (IsPCRel && Kind == SystemZ::FK_390_PC32DBL)
140140 return ELF::R_390_TLS_IEENT;
141141 reportError (Loc,
142142 " Only PC-relative INDNTPOFF accesses are supported for now" );
143143 return 0 ;
144144
145- case SystemZMCExpr::VK_DTPOFF :
145+ case SystemZ::S_DTPOFF :
146146 assert (!IsPCRel && " DTPOFF shouldn't be PC-relative" );
147147 switch (Kind) {
148148 case FK_Data_4:
@@ -153,7 +153,7 @@ unsigned SystemZELFObjectWriter::getRelocType(const MCFixup &Fixup,
153153 reportError (Loc, " Unsupported thread-local address (local-dynamic)" );
154154 return 0 ;
155155
156- case SystemZMCExpr::VK_TLSLDM :
156+ case SystemZ::S_TLSLDM :
157157 assert (!IsPCRel && " TLSLDM shouldn't be PC-relative" );
158158 switch (Kind) {
159159 case FK_Data_4:
@@ -166,7 +166,7 @@ unsigned SystemZELFObjectWriter::getRelocType(const MCFixup &Fixup,
166166 reportError (Loc, " Unsupported thread-local address (local-dynamic)" );
167167 return 0 ;
168168
169- case SystemZMCExpr::VK_TLSGD :
169+ case SystemZ::S_TLSGD :
170170 assert (!IsPCRel && " TLSGD shouldn't be PC-relative" );
171171 switch (Kind) {
172172 case FK_Data_4:
@@ -179,14 +179,14 @@ unsigned SystemZELFObjectWriter::getRelocType(const MCFixup &Fixup,
179179 reportError (Loc, " Unsupported thread-local address (general-dynamic)" );
180180 return 0 ;
181181
182- case SystemZMCExpr::VK_GOT :
183- case SystemZMCExpr::VK_GOTENT :
182+ case SystemZ::S_GOT :
183+ case SystemZ::S_GOTENT :
184184 if (IsPCRel && Kind == SystemZ::FK_390_PC32DBL)
185185 return ELF::R_390_GOTENT;
186186 reportError (Loc, " Only PC-relative GOT accesses are supported for now" );
187187 return 0 ;
188188
189- case SystemZMCExpr::VK_PLT :
189+ case SystemZ::S_PLT :
190190 assert (IsPCRel && " @PLT shouldn't be PC-relative" );
191191 switch (Kind) {
192192 case SystemZ::FK_390_PC12DBL:
@@ -209,8 +209,8 @@ unsigned SystemZELFObjectWriter::getRelocType(const MCFixup &Fixup,
209209bool SystemZELFObjectWriter::needsRelocateWithSymbol (const MCValue &V,
210210 unsigned Type) const {
211211 switch (V.getSpecifier ()) {
212- case SystemZMCExpr::VK_GOT :
213- case SystemZMCExpr::VK_PLT :
212+ case SystemZ::S_GOT :
213+ case SystemZ::S_PLT :
214214 return true ;
215215 default :
216216 return false ;
0 commit comments