mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
Move callee-saved regs spills / reloads to TFI
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120228 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -14,10 +14,13 @@
|
||||
#ifndef LLVM_TARGET_TARGETFRAMEINFO_H
|
||||
#define LLVM_TARGET_TARGETFRAMEINFO_H
|
||||
|
||||
#include "llvm/CodeGen/MachineBasicBlock.h"
|
||||
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
namespace llvm {
|
||||
class CalleeSavedInfo;
|
||||
class MachineFunction;
|
||||
class MachineBasicBlock;
|
||||
class MachineMove;
|
||||
@@ -108,6 +111,28 @@ public:
|
||||
virtual void emitEpilogue(MachineFunction &MF,
|
||||
MachineBasicBlock &MBB) const = 0;
|
||||
|
||||
/// spillCalleeSavedRegisters - Issues instruction(s) to spill all callee
|
||||
/// saved registers and returns true if it isn't possible / profitable to do
|
||||
/// so by issuing a series of store instructions via
|
||||
/// storeRegToStackSlot(). Returns false otherwise.
|
||||
virtual bool spillCalleeSavedRegisters(MachineBasicBlock &MBB,
|
||||
MachineBasicBlock::iterator MI,
|
||||
const std::vector<CalleeSavedInfo> &CSI,
|
||||
const TargetRegisterInfo *TRI) const {
|
||||
return false;
|
||||
}
|
||||
|
||||
/// restoreCalleeSavedRegisters - Issues instruction(s) to restore all callee
|
||||
/// saved registers and returns true if it isn't possible / profitable to do
|
||||
/// so by issuing a series of load instructions via loadRegToStackSlot().
|
||||
/// Returns false otherwise.
|
||||
virtual bool restoreCalleeSavedRegisters(MachineBasicBlock &MBB,
|
||||
MachineBasicBlock::iterator MI,
|
||||
const std::vector<CalleeSavedInfo> &CSI,
|
||||
const TargetRegisterInfo *TRI) const {
|
||||
return false;
|
||||
}
|
||||
|
||||
/// hasFP - Return true if the specified function should have a dedicated
|
||||
/// frame pointer register. For most targets this is true only if the function
|
||||
/// has variable sized allocas or if frame pointer elimination is disabled.
|
||||
|
@@ -19,7 +19,6 @@
|
||||
|
||||
namespace llvm {
|
||||
|
||||
class CalleeSavedInfo;
|
||||
class InstrItineraryData;
|
||||
class LiveVariables;
|
||||
class MCAsmInfo;
|
||||
@@ -375,29 +374,7 @@ public:
|
||||
const TargetRegisterInfo *TRI) const {
|
||||
assert(0 && "Target didn't implement TargetInstrInfo::loadRegFromStackSlot!");
|
||||
}
|
||||
|
||||
/// spillCalleeSavedRegisters - Issues instruction(s) to spill all callee
|
||||
/// saved registers and returns true if it isn't possible / profitable to do
|
||||
/// so by issuing a series of store instructions via
|
||||
/// storeRegToStackSlot(). Returns false otherwise.
|
||||
virtual bool spillCalleeSavedRegisters(MachineBasicBlock &MBB,
|
||||
MachineBasicBlock::iterator MI,
|
||||
const std::vector<CalleeSavedInfo> &CSI,
|
||||
const TargetRegisterInfo *TRI) const {
|
||||
return false;
|
||||
}
|
||||
|
||||
/// restoreCalleeSavedRegisters - Issues instruction(s) to restore all callee
|
||||
/// saved registers and returns true if it isn't possible / profitable to do
|
||||
/// so by issuing a series of load instructions via loadRegToStackSlot().
|
||||
/// Returns false otherwise.
|
||||
virtual bool restoreCalleeSavedRegisters(MachineBasicBlock &MBB,
|
||||
MachineBasicBlock::iterator MI,
|
||||
const std::vector<CalleeSavedInfo> &CSI,
|
||||
const TargetRegisterInfo *TRI) const {
|
||||
return false;
|
||||
}
|
||||
|
||||
/// emitFrameIndexDebugValue - Emit a target-dependent form of
|
||||
/// DBG_VALUE encoding the address of a frame index. Addresses would
|
||||
/// normally be lowered the same way as other addresses on the target,
|
||||
|
Reference in New Issue
Block a user