1 //===- MipsSEFrameLowering.h - Mips32/64 frame lowering ---------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
12 //===----------------------------------------------------------------------===//
14 #ifndef LLVM_LIB_TARGET_MIPS_MIPSSEFRAMELOWERING_H
15 #define LLVM_LIB_TARGET_MIPS_MIPSSEFRAMELOWERING_H
17 #include "MipsFrameLowering.h"
18 #include "llvm/CodeGen/MachineBasicBlock.h"
23 class MipsSEFrameLowering : public MipsFrameLowering {
25 explicit MipsSEFrameLowering(const MipsSubtarget &STI);
27 /// emitProlog/emitEpilog - These methods insert prolog and epilog code into
29 void emitPrologue(MachineFunction &MF, MachineBasicBlock &MBB) const override;
30 void emitEpilogue(MachineFunction &MF, MachineBasicBlock &MBB) const override;
32 int getFrameIndexReference(const MachineFunction &MF, int FI,
33 unsigned &FrameReg) const override;
35 bool spillCalleeSavedRegisters(MachineBasicBlock &MBB,
36 MachineBasicBlock::iterator MI,
37 const std::vector<CalleeSavedInfo> &CSI,
38 const TargetRegisterInfo *TRI) const override;
40 bool hasReservedCallFrame(const MachineFunction &MF) const override;
42 void determineCalleeSaves(MachineFunction &MF, BitVector &SavedRegs,
43 RegScavenger *RS) const override;
44 unsigned ehDataReg(unsigned I) const;
47 void emitInterruptEpilogueStub(MachineFunction &MF,
48 MachineBasicBlock &MBB) const;
49 void emitInterruptPrologueStub(MachineFunction &MF,
50 MachineBasicBlock &MBB) const;
53 } // end namespace llvm
55 #endif // LLVM_LIB_TARGET_MIPS_MIPSSEFRAMELOWERING_H