mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-25 16:24:23 +00:00
Target: Fix build breakage.
No functional change intended. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@218497 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -99,7 +99,7 @@ public:
|
|||||||
virtual const TargetSubtargetInfo *getSubtargetImpl() const {
|
virtual const TargetSubtargetInfo *getSubtargetImpl() const {
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
virtual const TargetSubtargetInfo *getSubtargetImpl(const Function *) const {
|
virtual const TargetSubtargetInfo *getSubtargetImpl(const Function &) const {
|
||||||
return getSubtargetImpl();
|
return getSubtargetImpl();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -85,7 +85,7 @@ MipselTargetMachine(const Target &T, StringRef TT,
|
|||||||
: MipsTargetMachine(T, TT, CPU, FS, Options, RM, CM, OL, true) {}
|
: MipsTargetMachine(T, TT, CPU, FS, Options, RM, CM, OL, true) {}
|
||||||
|
|
||||||
const MipsSubtarget *
|
const MipsSubtarget *
|
||||||
MipsTargetMachine::getSubtargetImpl(const Function &F) const override {
|
MipsTargetMachine::getSubtargetImpl(const Function &F) const {
|
||||||
AttributeSet FnAttrs = F.getAttributes();
|
AttributeSet FnAttrs = F.getAttributes();
|
||||||
Attribute CPUAttr =
|
Attribute CPUAttr =
|
||||||
FnAttrs.getAttribute(AttributeSet::FunctionIndex, "target-cpu");
|
FnAttrs.getAttribute(AttributeSet::FunctionIndex, "target-cpu");
|
||||||
@ -124,7 +124,7 @@ MipsTargetMachine::getSubtargetImpl(const Function &F) const override {
|
|||||||
void MipsTargetMachine::resetSubtarget(MachineFunction *MF) {
|
void MipsTargetMachine::resetSubtarget(MachineFunction *MF) {
|
||||||
DEBUG(dbgs() << "resetSubtarget\n");
|
DEBUG(dbgs() << "resetSubtarget\n");
|
||||||
|
|
||||||
Subtarget = const_cast<MipsSubtarget*>(getSubtargetImpl(MF->getFunction()));
|
Subtarget = const_cast<MipsSubtarget *>(getSubtargetImpl(*MF->getFunction()));
|
||||||
MF->setSubtarget(Subtarget);
|
MF->setSubtarget(Subtarget);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user