mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-29 22:52:18 +00:00
Move the R600 intrinsic support back to the target machine - there's
nothing subtarget dependent about the intrinsic support in any backend as far as I can tell. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@214738 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
981eb59138
commit
b88bbc0e9d
@ -83,7 +83,7 @@ AMDGPUSubtarget::AMDGPUSubtarget(StringRef TT, StringRef GPU, StringRef FS,
|
||||
FrameLowering(TargetFrameLowering::StackGrowsUp,
|
||||
64 * 16, // Maximum stack alignment (long16)
|
||||
0),
|
||||
IntrinsicInfo(), InstrItins(getInstrItineraryForCPU(GPU)) {
|
||||
InstrItins(getInstrItineraryForCPU(GPU)) {
|
||||
|
||||
if (getGeneration() <= AMDGPUSubtarget::NORTHERN_ISLANDS) {
|
||||
InstrInfo.reset(new R600InstrInfo(*this));
|
||||
|
@ -65,7 +65,6 @@ private:
|
||||
|
||||
const DataLayout DL;
|
||||
AMDGPUFrameLowering FrameLowering;
|
||||
AMDGPUIntrinsicInfo IntrinsicInfo;
|
||||
std::unique_ptr<AMDGPUTargetLowering> TLInfo;
|
||||
std::unique_ptr<AMDGPUInstrInfo> InstrInfo;
|
||||
InstrItineraryData InstrItins;
|
||||
@ -75,7 +74,6 @@ public:
|
||||
AMDGPUSubtarget &initializeSubtargetDependencies(StringRef GPU, StringRef FS);
|
||||
|
||||
const AMDGPUFrameLowering *getFrameLowering() const { return &FrameLowering; }
|
||||
const AMDGPUIntrinsicInfo *getIntrinsicInfo() const { return &IntrinsicInfo; }
|
||||
const AMDGPUInstrInfo *getInstrInfo() const { return InstrInfo.get(); }
|
||||
const AMDGPURegisterInfo *getRegisterInfo() const {
|
||||
return &InstrInfo->getRegisterInfo();
|
||||
|
@ -54,7 +54,7 @@ AMDGPUTargetMachine::AMDGPUTargetMachine(const Target &T, StringRef TT,
|
||||
CodeModel::Model CM,
|
||||
CodeGenOpt::Level OptLevel)
|
||||
: LLVMTargetMachine(T, TT, CPU, FS, Options, RM, CM, OptLevel),
|
||||
Subtarget(TT, CPU, FS, *this) {
|
||||
Subtarget(TT, CPU, FS, *this), IntrinsicInfo() {
|
||||
setRequiresStructuredCFG(true);
|
||||
initAsmInfo();
|
||||
}
|
||||
|
@ -25,8 +25,8 @@
|
||||
namespace llvm {
|
||||
|
||||
class AMDGPUTargetMachine : public LLVMTargetMachine {
|
||||
|
||||
AMDGPUSubtarget Subtarget;
|
||||
AMDGPUIntrinsicInfo IntrinsicInfo;
|
||||
|
||||
public:
|
||||
AMDGPUTargetMachine(const Target &T, StringRef TT, StringRef FS,
|
||||
@ -37,7 +37,7 @@ public:
|
||||
return getSubtargetImpl()->getFrameLowering();
|
||||
}
|
||||
const AMDGPUIntrinsicInfo *getIntrinsicInfo() const override {
|
||||
return getSubtargetImpl()->getIntrinsicInfo();
|
||||
return &IntrinsicInfo;
|
||||
}
|
||||
const AMDGPUInstrInfo *getInstrInfo() const override {
|
||||
return getSubtargetImpl()->getInstrInfo();
|
||||
|
Loading…
x
Reference in New Issue
Block a user