1218885Sdim//===-- Thumb1FrameLowering.h - Thumb1-specific frame info stuff --*- C++ -*-=// 2218885Sdim// 3218885Sdim// The LLVM Compiler Infrastructure 4218885Sdim// 5218885Sdim// This file is distributed under the University of Illinois Open Source 6218885Sdim// License. See LICENSE.TXT for details. 7218885Sdim// 8218885Sdim//===----------------------------------------------------------------------===// 9218885Sdim// 10218885Sdim// 11218885Sdim// 12218885Sdim//===----------------------------------------------------------------------===// 13218885Sdim 14218885Sdim#ifndef __THUMB_FRAMEINFO_H_ 15221345Sdim#define __THUMB_FRAMEINFO_H_ 16218885Sdim 17218885Sdim#include "ARM.h" 18218885Sdim#include "ARMFrameLowering.h" 19218885Sdim#include "ARMSubtarget.h" 20218885Sdim#include "Thumb1InstrInfo.h" 21218885Sdim#include "Thumb1RegisterInfo.h" 22218885Sdim#include "llvm/Target/TargetFrameLowering.h" 23218885Sdim 24218885Sdimnamespace llvm { 25218885Sdim class ARMSubtarget; 26218885Sdim 27218885Sdimclass Thumb1FrameLowering : public ARMFrameLowering { 28218885Sdimpublic: 29218885Sdim explicit Thumb1FrameLowering(const ARMSubtarget &sti) 30218885Sdim : ARMFrameLowering(sti) { 31218885Sdim } 32218885Sdim 33218885Sdim /// emitProlog/emitEpilog - These methods insert prolog and epilog code into 34218885Sdim /// the function. 35218885Sdim void emitPrologue(MachineFunction &MF) const; 36218885Sdim void emitEpilogue(MachineFunction &MF, MachineBasicBlock &MBB) const; 37218885Sdim 38218885Sdim bool spillCalleeSavedRegisters(MachineBasicBlock &MBB, 39218885Sdim MachineBasicBlock::iterator MI, 40218885Sdim const std::vector<CalleeSavedInfo> &CSI, 41218885Sdim const TargetRegisterInfo *TRI) const; 42218885Sdim bool restoreCalleeSavedRegisters(MachineBasicBlock &MBB, 43218885Sdim MachineBasicBlock::iterator MI, 44218885Sdim const std::vector<CalleeSavedInfo> &CSI, 45218885Sdim const TargetRegisterInfo *TRI) const; 46218885Sdim 47218885Sdim bool hasReservedCallFrame(const MachineFunction &MF) const; 48249423Sdim 49249423Sdim void eliminateCallFramePseudoInstr(MachineFunction &MF, 50249423Sdim MachineBasicBlock &MBB, 51249423Sdim MachineBasicBlock::iterator MI) const; 52218885Sdim}; 53218885Sdim 54218885Sdim} // End llvm namespace 55218885Sdim 56218885Sdim#endif 57