Go to the documentation of this file.
33 #define DEBUG_TYPE "m68k-subtarget"
35 #define GET_SUBTARGETINFO_TARGET_DESC
36 #define GET_SUBTARGETINFO_CTOR
37 #include "M68kGenSubtargetInfo.inc"
43 if (CPU.
empty() || CPU ==
"generic") {
49 void M68kSubtarget::anchor() {}
55 FrameLowering(*
this,
this->getStackAlignment()), TLInfo(
TM, *
this),
251 auto *
F = dyn_cast_or_null<Function>(GV);
252 if (
F &&
F->hasFnAttribute(Attribute::NonLazyBind)) {
bool isPositionIndependent() const
This is an optimization pass for GlobalISel generic memory operations.
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
bool abiUsesSoftFloat() const
Triple - Helper class for working with autoconf configuration names.
const RegisterBankInfo * getRegBankInfo() const override
@ MO_PLT
On a symbol operand this indicates that the immediate is offset to the PLT entry of symbol name from ...
@ EK_BlockAddress
EK_BlockAddress - Each entry is a plain address of block, e.g.
@ MO_GOT
On a symbol operand this indicates that the immediate is the offset to the GOT entry for the symbol n...
const M68kTargetLowering * getTargetLowering() const override
const M68kRegisterInfo * getRegisterInfo() const override
@ MO_PC_RELATIVE_ADDRESS
On a symbol operand this indicates that the immediate is the pc-relative address of the symbol.
@ EK_Custom32
EK_Custom32 - Each entry is a 32-bit value that is custom lowered by the TargetLowering::LowerCustomJ...
const CallLowering * getCallLowering() const override
unsigned char classifyBlockAddressReference() const
Classify a blockaddress reference for the current subtarget according to how we should reference it i...
@ MO_GOTOFF
On a symbol operand this indicates that the immediate is the offset to the location of the symbol nam...
std::unique_ptr< RegisterBankInfo > RegBankInfo
@ EK_LabelDifference32
EK_LabelDifference32 - Each entry is the address of the block minus the address of the jump table.
bool isPositionIndependent() const
constexpr bool empty() const
empty - Check if the string is empty.
Holds all the information related to register banks.
Provides the logic to select generic machine instructions.
const M68kTargetMachine & TM
Module * getParent()
Get the module that this global value is contained inside of...
unsigned stackAlignment
The minimum alignment known to hold of the stack frame on entry to the function and which must be mai...
This class provides the information for the target register banks.
std::unique_ptr< InstructionSelector > InstSelector
A Module instance is used to store all the information related to an LLVM module.
@ MO_ABSOLUTE_ADDRESS
On a symbol operand this indicates that the immediate is the absolute address of the symbol.
StringRef - Represent a constant reference to a string, i.e.
Analysis the ScalarEvolution expression for r is this
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
const LegalizerInfo * getLegalizerInfo() const override
bool shouldAssumeDSOLocal(const Module &M, const GlobalValue *GV) const
unsigned char classifyGlobalFunctionReference(const GlobalValue *GV, const Module &M) const
Classify a global function reference for the current subtarget.
M68kSubtarget(const Triple &TT, StringRef CPU, StringRef FS, const M68kTargetMachine &_TM)
This constructor initializes the data members to match that of the specified triple.
unsigned char classifyLocalReference(const GlobalValue *GV) const
Classify a global variable reference for the current subtarget according to how we should reference i...
static StringRef selectM68kCPU(Triple TT, StringRef CPU)
Select the M68k CPU for the given triple and cpu name.
bool isLegalToCallImmediateAddr() const
Return true if the subtarget allows calls to immediate address.
This struct provides the information for the target register banks.
InstructionSelector * getInstructionSelector() const override
unsigned getJumpTableEncoding() const
InstructionSelector * createM68kInstructionSelector(const M68kTargetMachine &TM, const M68kSubtarget &Subtarget, const M68kRegisterBankInfo &RBI)
@ MO_GOTPCREL
On a symbol operand this indicates that the immediate is offset to the GOT entry for the symbol name ...
std::string str() const
str - Get the contents as an std::string.
const char LLVMTargetMachineRef TM
void ParseSubtargetFeatures(StringRef CPU, StringRef TuneCPU, StringRef FS)
Parses features string setting specified subtarget options.
CodeModel::Model getCodeModel() const
Returns the code model.
M68kSubtarget & initializeSubtargetDependencies(StringRef CPU, Triple TT, StringRef FS, const M68kTargetMachine &TM)
std::unique_ptr< CallLowering > CallLoweringInfo
bool atLeastM68020() const
unsigned char classifyExternalReference(const Module &M) const
Classify a external variable reference for the current subtarget according to how we should reference...
InstrItineraryData InstrItins
unsigned char classifyGlobalReference(const GlobalValue *GV, const Module &M) const
Classify a global variable reference for the current subtarget according to how we should reference i...