Go to the documentation of this file.
40 X(
"erlang",
"erlang-compatible garbage collector");
45 unsigned IntPtrSize =
M.getDataLayout().getPointerSize();
52 for (GCModuleInfo::FuncInfoVec::iterator FI =
Info.funcinfo_begin(),
92 AP.
emitInt16(MD.getFrameSize() / IntPtrSize);
95 unsigned RegisteredArgs = IntPtrSize == 4 ? 5 : 6;
96 unsigned StackArity = MD.getFunction().arg_size() > RegisteredArgs
97 ? MD.getFunction().arg_size() - RegisteredArgs
108 LE = MD.live_end(PI);
111 OS.
AddComment(
"stack index (offset / wordsize)");
112 AP.
emitInt16(LI->StackOffset / IntPtrSize);
static StringRef getName(Value *V)
This is an optimization pass for GlobalISel generic memory operations.
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
We currently emits eax Perhaps this is what we really should generate is Is imull three or four cycles eax eax The current instruction priority is based on pattern complexity The former is more complex because it folds a load so the latter will not be emitted Perhaps we should use AddedComplexity to give LEA32r a higher priority We should always try to match LEA first since the LEA matching code does some estimate to determine whether the match is profitable if we care more about code then imull is better It s two bytes shorter than movl leal On a Pentium M
This currently compiles esp xmm0 movsd esp eax eax esp ret We should use not the dag combiner This is because dagcombine2 needs to be able to see through the X86ISD::Wrapper which DAGCombine can t really do The code for turning x load into a single vector load is target independent and should be moved to the dag combiner The code for turning x load into a vector load can only handle a direct load from a global or a direct load from the stack It should be generalized to handle any load from P
Garbage collection metadata for a single function.
std::vector< GCPoint >::iterator iterator
const std::string & getName() const
Return the name of the GC strategy.
void emitAlignment(Align Alignment, const GlobalObject *GV=nullptr, unsigned MaxBytesToEmit=0) const
Emit an alignment directive to the specified power of two boundary.
GCStrategy & getStrategy()
getStrategy - Return the GC strategy for the function.
MCContext & getContext() const
Streaming machine code generation interface.
std::vector< GCRoot >::const_iterator live_iterator
std::unique_ptr< MCStreamer > OutStreamer
This is the MCStreamer object for the file we are generating.
virtual void switchSection(MCSection *Section, const MCExpr *Subsection=nullptr)
Set the current section where code is being emitted to Section.
MCSectionELF * getELFSection(const Twine &Section, unsigned Type, unsigned Flags)
Analysis containing CSE Info
static GCMetadataPrinterRegistry::Add< ErlangGCPrinter > X("erlang", "erlang-compatible garbage collector")
void emitLabelPlusOffset(const MCSymbol *Label, uint64_t Offset, unsigned Size, bool IsSectionRelative=false) const
Emit something like ".long Label+Offset" where the size in bytes of the directive is specified by Siz...
A Module instance is used to store all the information related to an LLVM module.
This class is intended to be used as a driving class for all asm writers.
const TargetLoweringObjectFile & getObjFileLowering() const
Return information about object file lowering.
GCPoint - Metadata for a collector-safe point in machine code.
void linkErlangGCPrinter()
Creates an erlang-compatible metadata printer.
A static registration template.
An analysis pass which caches information about the entire Module.
void emitInt16(int Value) const
Emit a short directive and value.
virtual void AddComment(const Twine &T, bool EOL=true)
Add a textual comment.