LLVM: lib/Target/Sparc/SparcSubtarget.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9
10
11
12
13#ifndef LLVM_LIB_TARGET_SPARC_SPARCSUBTARGET_H
14#define LLVM_LIB_TARGET_SPARC_SPARCSUBTARGET_H
15
24
25#define GET_SUBTARGETINFO_HEADER
26#include "SparcGenSubtargetInfo.inc"
27
28namespace llvm {
29class StringRef;
30
32
33
35
36 virtual void anchor();
37
38#define GET_SUBTARGETINFO_MACRO(ATTRIBUTE, DEFAULT, GETTER) \
39 bool ATTRIBUTE = DEFAULT;
40#include "SparcGenSubtargetInfo.inc"
41
42 SparcInstrInfo InstrInfo;
43 SparcTargetLowering TLInfo;
44 std::unique_ptr TSInfo;
45 SparcFrameLowering FrameLowering;
46
47public:
48 SparcSubtarget(const StringRef &CPU, const StringRef &TuneCPU,
49 const StringRef &FS, const TargetMachine &TM);
50
52
55 return &FrameLowering;
56 }
58 return &InstrInfo.getRegisterInfo();
59 }
63
65
67
69
70#define GET_SUBTARGETINFO_MACRO(ATTRIBUTE, DEFAULT, GETTER) \
71 bool GETTER() const { return ATTRIBUTE; }
72#include "SparcGenSubtargetInfo.inc"
73
74
75
80
81
82
84 return is64Bit() ? 2047 : 0;
85 }
86
88 return ReserveRegister[PhysReg];
89 }
90
91
92
93
95};
96
97}
98
99#endif
Analysis containing CSE Info
static bool is64Bit(const char *name)
Tracks which library functions to use for a particular subtarget.
Targets can subclass this to parameterize the SelectionDAG lowering and instruction selection process...
const SparcRegisterInfo * getRegisterInfo() const override
Definition SparcSubtarget.h:57
int64_t getStackPointerBias() const
The 64-bit ABI uses biased stack and frame pointers, so the stack frame of the current function is th...
Definition SparcSubtarget.h:83
void initLibcallLoweringInfo(LibcallLoweringInfo &Info) const override
const SparcTargetLowering * getTargetLowering() const override
Definition SparcSubtarget.h:60
~SparcSubtarget() override
int getAdjustedFrameSize(int stackSize) const
Given a actual stack size as determined by FrameInfo, this function returns adjusted framesize which ...
bool enableMachineScheduler() const override
const TargetFrameLowering * getFrameLowering() const override
Definition SparcSubtarget.h:54
SparcSubtarget(const StringRef &CPU, const StringRef &TuneCPU, const StringRef &FS, const TargetMachine &TM)
void ParseSubtargetFeatures(StringRef CPU, StringRef TuneCPU, StringRef FS)
ParseSubtargetFeatures - Parses features string setting specified subtarget options.
SparcSubtarget & initializeSubtargetDependencies(StringRef CPU, StringRef TuneCPU, StringRef FS)
bool isRegisterReserved(MCPhysReg PhysReg) const
Definition SparcSubtarget.h:87
const SparcInstrInfo * getInstrInfo() const override
Definition SparcSubtarget.h:53
const SelectionDAGTargetInfo * getSelectionDAGInfo() const override
StringRef - Represent a constant reference to a string, i.e.
Information about stack frame layout on the target.
This is an optimization pass for GlobalISel generic memory operations.
uint16_t MCPhysReg
An unsigned integer type large enough to represent all physical registers, but not necessarily virtua...