LLVM  13.0.0git
PPCMCTargetDesc.cpp
Go to the documentation of this file.
1 //===-- PPCMCTargetDesc.cpp - PowerPC Target Descriptions -----------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file provides PowerPC specific target descriptions.
10 //
11 //===----------------------------------------------------------------------===//
12 
16 #include "PPCELFStreamer.h"
17 #include "PPCTargetStreamer.h"
19 #include "llvm/ADT/SmallPtrSet.h"
20 #include "llvm/ADT/StringRef.h"
21 #include "llvm/ADT/Triple.h"
22 #include "llvm/BinaryFormat/ELF.h"
23 #include "llvm/MC/MCAsmBackend.h"
24 #include "llvm/MC/MCAssembler.h"
25 #include "llvm/MC/MCCodeEmitter.h"
26 #include "llvm/MC/MCContext.h"
27 #include "llvm/MC/MCDwarf.h"
28 #include "llvm/MC/MCELFStreamer.h"
29 #include "llvm/MC/MCExpr.h"
30 #include "llvm/MC/MCInstrInfo.h"
31 #include "llvm/MC/MCObjectWriter.h"
32 #include "llvm/MC/MCRegisterInfo.h"
33 #include "llvm/MC/MCSectionXCOFF.h"
34 #include "llvm/MC/MCStreamer.h"
36 #include "llvm/MC/MCSymbol.h"
37 #include "llvm/MC/MCSymbolELF.h"
38 #include "llvm/MC/MCSymbolXCOFF.h"
39 #include "llvm/Support/Casting.h"
40 #include "llvm/Support/CodeGen.h"
45 
46 using namespace llvm;
47 
48 #define GET_INSTRINFO_MC_DESC
49 #include "PPCGenInstrInfo.inc"
50 
51 #define GET_SUBTARGETINFO_MC_DESC
52 #include "PPCGenSubtargetInfo.inc"
53 
54 #define GET_REGINFO_MC_DESC
55 #include "PPCGenRegisterInfo.inc"
56 
58 
59 // Pin the vtable to this file.
61 
63  MCInstrInfo *X = new MCInstrInfo();
64  InitPPCMCInstrInfo(X);
65  return X;
66 }
67 
69  bool isPPC64 =
70  (TT.getArch() == Triple::ppc64 || TT.getArch() == Triple::ppc64le);
71  unsigned Flavour = isPPC64 ? 0 : 1;
72  unsigned RA = isPPC64 ? PPC::LR8 : PPC::LR;
73 
75  InitPPCMCRegisterInfo(X, RA, Flavour, Flavour);
76  return X;
77 }
78 
80  StringRef CPU, StringRef FS) {
81  // Set some default feature to MC layer.
82  std::string FullFS = std::string(FS);
83 
84  if (TT.isOSAIX()) {
85  if (!FullFS.empty())
86  FullFS = "+aix," + FullFS;
87  else
88  FullFS = "+aix";
89  }
90 
91  return createPPCMCSubtargetInfoImpl(TT, CPU, /*TuneCPU*/ CPU, FullFS);
92 }
93 
95  const Triple &TheTriple,
96  const MCTargetOptions &Options) {
97  bool isPPC64 = (TheTriple.getArch() == Triple::ppc64 ||
98  TheTriple.getArch() == Triple::ppc64le);
99 
100  MCAsmInfo *MAI;
101  if (TheTriple.isOSBinFormatXCOFF())
102  MAI = new PPCXCOFFMCAsmInfo(isPPC64, TheTriple);
103  else
104  MAI = new PPCELFMCAsmInfo(isPPC64, TheTriple);
105 
106  // Initial state of the frame pointer is R1.
107  unsigned Reg = isPPC64 ? PPC::X1 : PPC::R1;
108  MCCFIInstruction Inst =
109  MCCFIInstruction::cfiDefCfa(nullptr, MRI.getDwarfRegNum(Reg, true), 0);
110  MAI->addInitialFrameState(Inst);
111 
112  return MAI;
113 }
114 
116  std::unique_ptr<MCAsmBackend> &&MAB,
117  std::unique_ptr<MCObjectWriter> &&OW,
118  std::unique_ptr<MCCodeEmitter> &&Emitter,
119  bool RelaxAll) {
121  std::move(Emitter));
122 }
123 
124 namespace {
125 
126 class PPCTargetAsmStreamer : public PPCTargetStreamer {
128 
129 public:
130  PPCTargetAsmStreamer(MCStreamer &S, formatted_raw_ostream &OS)
131  : PPCTargetStreamer(S), OS(OS) {}
132 
133  void emitTCEntry(const MCSymbol &S,
135  if (const MCSymbolXCOFF *XSym = dyn_cast<MCSymbolXCOFF>(&S)) {
136  MCSymbolXCOFF *TCSym =
137  cast<MCSectionXCOFF>(Streamer.getCurrentSectionOnly())
138  ->getQualNameSymbol();
139  // If the variant kind is TLSGD the entry represents the region handle for
140  // the symbol, we prefix the name with a dot and we add the @m
141  // relocation specifier.
142  if (Kind == MCSymbolRefExpr::VariantKind::VK_PPC_TLSGD)
143  OS << "\t.tc ." << TCSym->getName() << "," << XSym->getName() << "@m\n";
144  else
145  OS << "\t.tc " << TCSym->getName() << "," << XSym->getName() << '\n';
146 
147  if (TCSym->hasRename())
148  Streamer.emitXCOFFRenameDirective(TCSym, TCSym->getSymbolTableName());
149  return;
150  }
151 
152  OS << "\t.tc " << S.getName() << "[TC]," << S.getName() << '\n';
153  }
154 
155  void emitMachine(StringRef CPU) override {
156  OS << "\t.machine " << CPU << '\n';
157  }
158 
159  void emitAbiVersion(int AbiVersion) override {
160  OS << "\t.abiversion " << AbiVersion << '\n';
161  }
162 
163  void emitLocalEntry(MCSymbolELF *S, const MCExpr *LocalOffset) override {
164  const MCAsmInfo *MAI = Streamer.getContext().getAsmInfo();
165 
166  OS << "\t.localentry\t";
167  S->print(OS, MAI);
168  OS << ", ";
169  LocalOffset->print(OS, MAI);
170  OS << '\n';
171  }
172 };
173 
174 class PPCTargetELFStreamer : public PPCTargetStreamer {
175 public:
176  PPCTargetELFStreamer(MCStreamer &S) : PPCTargetStreamer(S) {}
177 
178  MCELFStreamer &getStreamer() {
179  return static_cast<MCELFStreamer &>(Streamer);
180  }
181 
182  void emitTCEntry(const MCSymbol &S,
184  // Creates a R_PPC64_TOC relocation
185  Streamer.emitValueToAlignment(8);
186  Streamer.emitSymbolValue(&S, 8);
187  }
188 
189  void emitMachine(StringRef CPU) override {
190  // FIXME: Is there anything to do in here or does this directive only
191  // limit the parser?
192  }
193 
194  void emitAbiVersion(int AbiVersion) override {
195  MCAssembler &MCA = getStreamer().getAssembler();
196  unsigned Flags = MCA.getELFHeaderEFlags();
197  Flags &= ~ELF::EF_PPC64_ABI;
198  Flags |= (AbiVersion & ELF::EF_PPC64_ABI);
199  MCA.setELFHeaderEFlags(Flags);
200  }
201 
202  void emitLocalEntry(MCSymbolELF *S, const MCExpr *LocalOffset) override {
203  MCAssembler &MCA = getStreamer().getAssembler();
204 
205  // encodePPC64LocalEntryOffset will report an error if it cannot
206  // encode LocalOffset.
207  unsigned Encoded = encodePPC64LocalEntryOffset(LocalOffset);
208 
209  unsigned Other = S->getOther();
211  Other |= Encoded;
212  S->setOther(Other);
213 
214  // For GAS compatibility, unless we already saw a .abiversion directive,
215  // set e_flags to indicate ELFv2 ABI.
216  unsigned Flags = MCA.getELFHeaderEFlags();
217  if ((Flags & ELF::EF_PPC64_ABI) == 0)
218  MCA.setELFHeaderEFlags(Flags | 2);
219  }
220 
221  void emitAssignment(MCSymbol *S, const MCExpr *Value) override {
222  auto *Symbol = cast<MCSymbolELF>(S);
223 
224  // When encoding an assignment to set symbol A to symbol B, also copy
225  // the st_other bits encoding the local entry point offset.
226  if (copyLocalEntry(Symbol, Value))
227  UpdateOther.insert(Symbol);
228  else
229  UpdateOther.erase(Symbol);
230  }
231 
232  void finish() override {
233  for (auto *Sym : UpdateOther)
234  if (Sym->isVariable())
235  copyLocalEntry(Sym, Sym->getVariableValue());
236 
237  // Clear the set of symbols that needs to be updated so the streamer can
238  // be reused without issues.
239  UpdateOther.clear();
240  }
241 
242 private:
243  SmallPtrSet<MCSymbolELF *, 32> UpdateOther;
244 
245  bool copyLocalEntry(MCSymbolELF *D, const MCExpr *S) {
246  auto *Ref = dyn_cast<const MCSymbolRefExpr>(S);
247  if (!Ref)
248  return false;
249  const auto &RhsSym = cast<MCSymbolELF>(Ref->getSymbol());
250  unsigned Other = D->getOther();
252  Other |= RhsSym.getOther() & ELF::STO_PPC64_LOCAL_MASK;
253  D->setOther(Other);
254  return true;
255  }
256 
257  unsigned encodePPC64LocalEntryOffset(const MCExpr *LocalOffset) {
258  MCAssembler &MCA = getStreamer().getAssembler();
259  int64_t Offset;
260  if (!LocalOffset->evaluateAsAbsolute(Offset, MCA))
262  LocalOffset->getLoc(), ".localentry expression must be absolute.");
263 
264  switch (Offset) {
265  default:
267  LocalOffset->getLoc(),
268  ".localentry expression is not a valid power of 2.");
269  case 0:
270  return 0;
271  case 1:
272  return 1 << ELF::STO_PPC64_LOCAL_BIT;
273  case 4:
274  case 8:
275  case 16:
276  case 32:
277  case 64:
278  return (int)Log2(Offset) << (int)ELF::STO_PPC64_LOCAL_BIT;
279  }
280  }
281 };
282 
283 class PPCTargetMachOStreamer : public PPCTargetStreamer {
284 public:
285  PPCTargetMachOStreamer(MCStreamer &S) : PPCTargetStreamer(S) {}
286 
287  void emitTCEntry(const MCSymbol &S,
289  llvm_unreachable("Unknown pseudo-op: .tc");
290  }
291 
292  void emitMachine(StringRef CPU) override {
293  // FIXME: We should update the CPUType, CPUSubType in the Object file if
294  // the new values are different from the defaults.
295  }
296 
297  void emitAbiVersion(int AbiVersion) override {
298  llvm_unreachable("Unknown pseudo-op: .abiversion");
299  }
300 
301  void emitLocalEntry(MCSymbolELF *S, const MCExpr *LocalOffset) override {
302  llvm_unreachable("Unknown pseudo-op: .localentry");
303  }
304 };
305 
306 class PPCTargetXCOFFStreamer : public PPCTargetStreamer {
307 public:
308  PPCTargetXCOFFStreamer(MCStreamer &S) : PPCTargetStreamer(S) {}
309 
310  void emitTCEntry(const MCSymbol &S,
312  const MCAsmInfo *MAI = Streamer.getContext().getAsmInfo();
313  const unsigned PointerSize = MAI->getCodePointerSize();
314  Streamer.emitValueToAlignment(PointerSize);
315  Streamer.emitSymbolValue(&S, PointerSize);
316  }
317 
318  void emitMachine(StringRef CPU) override {
319  llvm_unreachable("Machine pseudo-ops are invalid for XCOFF.");
320  }
321 
322  void emitAbiVersion(int AbiVersion) override {
323  llvm_unreachable("ABI-version pseudo-ops are invalid for XCOFF.");
324  }
325 
326  void emitLocalEntry(MCSymbolELF *S, const MCExpr *LocalOffset) override {
327  llvm_unreachable("Local-entry pseudo-ops are invalid for XCOFF.");
328  }
329 };
330 
331 } // end anonymous namespace
332 
335  MCInstPrinter *InstPrint,
336  bool isVerboseAsm) {
337  return new PPCTargetAsmStreamer(S, OS);
338 }
339 
340 static MCTargetStreamer *
342  const Triple &TT = STI.getTargetTriple();
343  if (TT.isOSBinFormatELF())
344  return new PPCTargetELFStreamer(S);
345  if (TT.isOSBinFormatXCOFF())
346  return new PPCTargetXCOFFStreamer(S);
347  return new PPCTargetMachOStreamer(S);
348 }
349 
351  unsigned SyntaxVariant,
352  const MCAsmInfo &MAI,
353  const MCInstrInfo &MII,
354  const MCRegisterInfo &MRI) {
355  return new PPCInstPrinter(MAI, MII, MRI, T);
356 }
357 
361  // Register the MC asm info.
363 
364  // Register the MC instruction info.
366 
367  // Register the MC register info.
369 
370  // Register the MC subtarget info.
372 
373  // Register the MC Code Emitter
375 
376  // Register the asm backend.
378 
379  // Register the elf streamer.
381 
382  // Register the object target streamer.
385 
386  // Register the asm target streamer.
388 
389  // Register the MCInstPrinter.
391  }
392 }
llvm::EngineKind::Kind
Kind
Definition: ExecutionEngine.h:524
llvm::MCAssembler::getELFHeaderEFlags
unsigned getELFHeaderEFlags() const
ELF e_header flags.
Definition: MCAssembler.h:262
llvm::PPCXCOFFMCAsmInfo
Definition: PPCMCAsmInfo.h:29
MCDwarf.h
llvm
Definition: AllocatorList.h:23
Reg
unsigned Reg
Definition: MachineSink.cpp:1566
llvm::MCSymbol
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
Definition: MCSymbol.h:41
llvm::ELF::STO_PPC64_LOCAL_MASK
@ STO_PPC64_LOCAL_MASK
Definition: ELF.h:405
PPCELFStreamer.h
llvm::MCContext
Context object for machine code objects.
Definition: MCContext.h:71
StringRef.h
llvm::MCSymbolXCOFF::getSymbolTableName
StringRef getSymbolTableName() const
Definition: MCSymbolXCOFF.h:61
MCCodeEmitter.h
llvm::Target
Target - Wrapper for Target specific information.
Definition: TargetRegistry.h:124
llvm::MCAsmInfo
This class is intended to be used as a base class for asm properties and features specific to the tar...
Definition: MCAsmInfo.h:56
ErrorHandling.h
llvm::TargetRegistry::RegisterAsmTargetStreamer
static void RegisterAsmTargetStreamer(Target &T, Target::AsmTargetStreamerCtorTy Fn)
Definition: TargetRegistry.h:876
llvm::PPCTargetStreamer::~PPCTargetStreamer
~PPCTargetStreamer() override
llvm::Triple
Triple - Helper class for working with autoconf configuration names.
Definition: Triple.h:45
MCAssembler.h
llvm::Triple::isOSBinFormatXCOFF
bool isOSBinFormatXCOFF() const
Tests whether the OS uses the XCOFF binary format.
Definition: Triple.h:655
llvm::MCAsmInfo::getCodePointerSize
unsigned getCodePointerSize() const
Get the code pointer size in bytes.
Definition: MCAsmInfo.h:471
T
#define T
Definition: Mips16ISelLowering.cpp:341
Offset
uint64_t Offset
Definition: ELFObjHandler.cpp:81
llvm::SmallPtrSet
SmallPtrSet - This class implements a set which is optimized for holding SmallSize or less elements.
Definition: SmallPtrSet.h:449
llvm::createPPCMCCodeEmitter
MCCodeEmitter * createPPCMCCodeEmitter(const MCInstrInfo &MCII, const MCRegisterInfo &MRI, MCContext &Ctx)
Definition: PPCMCCodeEmitter.cpp:36
PPCMCAsmInfo.h
PPCMCTargetDesc.h
llvm::TargetRegistry::RegisterMCInstPrinter
static void RegisterMCInstPrinter(Target &T, Target::MCInstPrinterCtorTy Fn)
RegisterMCInstPrinter - Register a MCInstPrinter implementation for the given target.
Definition: TargetRegistry.h:838
MCELFStreamer.h
llvm::MCSymbolELF
Definition: MCSymbolELF.h:14
Context
LLVMContext & Context
Definition: NVVMIntrRange.cpp:66
PPCInstPrinter.h
FormattedStream.h
llvm::getThePPC64LETarget
Target & getThePPC64LETarget()
Definition: PowerPCTargetInfo.cpp:25
llvm::MCStreamer
Streaming machine code generation interface.
Definition: MCStreamer.h:197
ELF.h
llvm::MCELFStreamer
Definition: MCELFStreamer.h:23
MCAsmBackend.h
llvm::ModRefInfo::Ref
@ Ref
The access may reference the value stored in memory.
llvm::X86AS::FS
@ FS
Definition: X86.h:183
llvm::PPCELFMCAsmInfo
Definition: PPCMCAsmInfo.h:22
llvm::MCAssembler::getContext
MCContext & getContext() const
Definition: MCAssembler.h:292
llvm::PPCInstPrinter
Definition: PPCInstPrinter.h:21
C
(vector float) vec_cmpeq(*A, *B) C
Definition: README_ALTIVEC.txt:86
createPPCMCInstrInfo
static MCInstrInfo * createPPCMCInstrInfo()
Definition: PPCMCTargetDesc.cpp:62
llvm::Log2
unsigned Log2(Align A)
Returns the log2 of the alignment.
Definition: Alignment.h:217
int
Clang compiles this i1 i64 store i64 i64 store i64 i64 store i64 i64 store i64 align Which gets codegen d xmm0 movaps rbp movaps rbp movaps rbp movaps rbp rbp rbp rbp rbp It would be better to have movq s of instead of the movaps s LLVM produces ret int
Definition: README.txt:536
llvm::MCSubtargetInfo::getTargetTriple
const Triple & getTargetTriple() const
Definition: MCSubtargetInfo.h:107
MCSymbolELF.h
MCContext.h
MCInstrInfo.h
MCSymbol.h
llvm::MCSymbolXCOFF::hasRename
bool hasRename() const
Definition: MCSymbolXCOFF.h:57
llvm::Triple::ppc64
@ ppc64
Definition: Triple.h:69
MCSubtargetInfo.h
llvm::MCTargetStreamer
Target specific streamer interface.
Definition: MCStreamer.h:91
SmallPtrSet.h
llvm::MCSymbol::getName
StringRef getName() const
getName - Get the symbol name.
Definition: MCSymbol.h:197
llvm::Triple::getArch
ArchType getArch() const
getArch - Get the parsed architecture type of this triple.
Definition: Triple.h:307
llvm::MCContext::reportFatalError
LLVM_ATTRIBUTE_NORETURN void reportFatalError(SMLoc L, const Twine &Msg)
Definition: MCContext.cpp:936
MCSectionXCOFF.h
llvm::RegisterMCAsmInfoFn
RegisterMCAsmInfoFn - Helper template for registering a target assembly info implementation.
Definition: TargetRegistry.h:973
llvm::MCCFIInstruction
Definition: MCDwarf.h:441
X
static GCMetadataPrinterRegistry::Add< ErlangGCPrinter > X("erlang", "erlang-compatible garbage collector")
llvm::MCELFStreamer::emitValueToAlignment
void emitValueToAlignment(unsigned, int64_t, unsigned, unsigned) override
Emit some number of copies of Value until the byte alignment ByteAlignment is reached.
Definition: MCELFStreamer.cpp:363
createPPCMCStreamer
static MCStreamer * createPPCMCStreamer(const Triple &T, MCContext &Context, std::unique_ptr< MCAsmBackend > &&MAB, std::unique_ptr< MCObjectWriter > &&OW, std::unique_ptr< MCCodeEmitter > &&Emitter, bool RelaxAll)
Definition: PPCMCTargetDesc.cpp:115
createObjectTargetStreamer
static MCTargetStreamer * createObjectTargetStreamer(MCStreamer &S, const MCSubtargetInfo &STI)
Definition: PPCMCTargetDesc.cpp:341
llvm::Triple::ppc64le
@ ppc64le
Definition: Triple.h:70
createPPCMCInstPrinter
static MCInstPrinter * createPPCMCInstPrinter(const Triple &T, unsigned SyntaxVariant, const MCAsmInfo &MAI, const MCInstrInfo &MII, const MCRegisterInfo &MRI)
Definition: PPCMCTargetDesc.cpp:350
llvm::MCAssembler
Definition: MCAssembler.h:60
llvm::TargetRegistry::RegisterMCAsmBackend
static void RegisterMCAsmBackend(Target &T, Target::MCAsmBackendCtorTy Fn)
RegisterMCAsmBackend - Register a MCAsmBackend implementation for the given target.
Definition: TargetRegistry.h:785
llvm::MCSymbolRefExpr::VariantKind
VariantKind
Definition: MCExpr.h:194
D
static GCRegistry::Add< StatepointGC > D("statepoint-example", "an example strategy for statepoint")
createPPCMCSubtargetInfo
static MCSubtargetInfo * createPPCMCSubtargetInfo(const Triple &TT, StringRef CPU, StringRef FS)
Definition: PPCMCTargetDesc.cpp:79
llvm::MCInstPrinter
This is an instance of a target assembly language printer that converts an MCInst to valid target ass...
Definition: MCInstPrinter.h:43
LLVM_EXTERNAL_VISIBILITY
#define LLVM_EXTERNAL_VISIBILITY
Definition: Compiler.h:132
move
compiles ldr LCPI1_0 ldr ldr mov lsr tst moveq r1 ldr LCPI1_1 and r0 bx lr It would be better to do something like to fold the shift into the conditional move
Definition: README.txt:546
MCSymbolXCOFF.h
PowerPCTargetInfo.h
llvm::TargetRegistry::RegisterObjectTargetStreamer
static void RegisterObjectTargetStreamer(Target &T, Target::ObjectTargetStreamerCtorTy Fn)
Definition: TargetRegistry.h:882
MCRegisterInfo.h
llvm::MCAssembler::setELFHeaderEFlags
void setELFHeaderEFlags(unsigned Flags)
Definition: MCAssembler.h:263
llvm::formatted_raw_ostream
formatted_raw_ostream - A raw_ostream that wraps another one and keeps track of line and column posit...
Definition: FormattedStream.h:30
llvm::MCCFIInstruction::cfiDefCfa
static MCCFIInstruction cfiDefCfa(MCSymbol *L, unsigned Register, int Offset)
.cfi_def_cfa defines a rule for computing CFA as: take address from Register and add Offset to it.
Definition: MCDwarf.h:488
llvm::MCAsmInfo::addInitialFrameState
void addInitialFrameState(const MCCFIInstruction &Inst)
Definition: MCAsmInfo.cpp:81
RA
SI optimize exec mask operations pre RA
Definition: SIOptimizeExecMaskingPreRA.cpp:71
llvm::TargetRegistry::RegisterMCSubtargetInfo
static void RegisterMCSubtargetInfo(Target &T, Target::MCSubtargetInfoCtorFnTy Fn)
RegisterMCSubtargetInfo - Register a MCSubtargetInfo implementation for the given target.
Definition: TargetRegistry.h:758
llvm::MCTargetOptions
Definition: MCTargetOptions.h:36
Triple.h
llvm::createPPCELFStreamer
MCELFStreamer * createPPCELFStreamer(MCContext &Context, std::unique_ptr< MCAsmBackend > MAB, std::unique_ptr< MCObjectWriter > OW, std::unique_ptr< MCCodeEmitter > Emitter)
Definition: PPCELFStreamer.cpp:224
llvm::StringRef
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:57
llvm_unreachable
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
Definition: ErrorHandling.h:136
S
add sub stmia L5 ldr r0 bl L_printf $stub Instead of a and a wouldn t it be better to do three moves *Return an aggregate type is even return S
Definition: README.txt:210
llvm::MCRegisterInfo
MCRegisterInfo base class - We assume that the target defines a static array of MCRegisterDesc object...
Definition: MCRegisterInfo.h:135
llvm::PPCTargetStreamer::PPCTargetStreamer
PPCTargetStreamer(MCStreamer &S)
Definition: PPCMCTargetDesc.cpp:57
MRI
unsigned const MachineRegisterInfo * MRI
Definition: AArch64AdvSIMDScalarPass.cpp:105
llvm::getThePPC64Target
Target & getThePPC64Target()
Definition: PowerPCTargetInfo.cpp:21
MCObjectWriter.h
llvm::TargetRegistry::RegisterMCInstrInfo
static void RegisterMCInstrInfo(Target &T, Target::MCInstrInfoCtorFnTy Fn)
RegisterMCInstrInfo - Register a MCInstrInfo implementation for the given target.
Definition: TargetRegistry.h:725
llvm::TargetRegistry::RegisterMCCodeEmitter
static void RegisterMCCodeEmitter(Target &T, Target::MCCodeEmitterCtorTy Fn)
RegisterMCCodeEmitter - Register a MCCodeEmitter implementation for the given target.
Definition: TargetRegistry.h:851
llvm::MCInstrInfo
Interface to description of machine instruction set.
Definition: MCInstrInfo.h:25
llvm::TargetRegistry::RegisterMCRegInfo
static void RegisterMCRegInfo(Target &T, Target::MCRegInfoCtorFnTy Fn)
RegisterMCRegInfo - Register a MCRegisterInfo implementation for the given target.
Definition: TargetRegistry.h:745
llvm::TargetRegistry::RegisterELFStreamer
static void RegisterELFStreamer(Target &T, Target::ELFStreamerCtorTy Fn)
Definition: TargetRegistry.h:863
Casting.h
LLVMInitializePowerPCTargetMC
LLVM_EXTERNAL_VISIBILITY void LLVMInitializePowerPCTargetMC()
Definition: PPCMCTargetDesc.cpp:358
PPCTargetStreamer.h
llvm::getThePPC32LETarget
Target & getThePPC32LETarget()
Definition: PowerPCTargetInfo.cpp:17
llvm::ARMBuildAttrs::Symbol
@ Symbol
Definition: ARMBuildAttributes.h:79
createPPCMCRegisterInfo
static MCRegisterInfo * createPPCMCRegisterInfo(const Triple &TT)
Definition: PPCMCTargetDesc.cpp:68
CodeGen.h
createPPCMCAsmInfo
static MCAsmInfo * createPPCMCAsmInfo(const MCRegisterInfo &MRI, const Triple &TheTriple, const MCTargetOptions &Options)
Definition: PPCMCTargetDesc.cpp:94
llvm::MCExpr::print
void print(raw_ostream &OS, const MCAsmInfo *MAI, bool InParens=false) const
Definition: MCExpr.cpp:42
llvm::MCSymbolXCOFF
Definition: MCSymbolXCOFF.h:20
llvm::createPPCAsmBackend
MCAsmBackend * createPPCAsmBackend(const Target &T, const MCSubtargetInfo &STI, const MCRegisterInfo &MRI, const MCTargetOptions &Options)
Definition: PPCAsmBackend.cpp:271
MCStreamer.h
createAsmTargetStreamer
static MCTargetStreamer * createAsmTargetStreamer(MCStreamer &S, formatted_raw_ostream &OS, MCInstPrinter *InstPrint, bool isVerboseAsm)
Definition: PPCMCTargetDesc.cpp:333
raw_ostream.h
TargetRegistry.h
MCExpr.h
llvm::PPCTargetStreamer
Definition: PPCTargetStreamer.h:21
llvm::MCSubtargetInfo
Generic base class for all target subtargets.
Definition: MCSubtargetInfo.h:75
llvm::Value
LLVM Value Representation.
Definition: Value.h:75
llvm::MCExpr
Base class for the full range of assembler expressions which are needed for parsing.
Definition: MCExpr.h:35
llvm::ELF::EF_PPC64_ABI
@ EF_PPC64_ABI
Definition: ELF.h:399
llvm::ELF::STO_PPC64_LOCAL_BIT
@ STO_PPC64_LOCAL_BIT
Definition: ELF.h:404
Other
Optional< std::vector< StOtherPiece > > Other
Definition: ELFYAML.cpp:1163
llvm::MCExpr::getLoc
SMLoc getLoc() const
Definition: MCExpr.h:82
llvm::getThePPC32Target
Target & getThePPC32Target()
Definition: PowerPCTargetInfo.cpp:13