1 //===- SkeletonRegisterInfo.h - Skeleton Register Information Impl -*- C++ -*-==//
3 // The LLVM Compiler Infrastructure
5 // This file was developed by the LLVM research group and is distributed under
6 // the University of Illinois Open Source License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 // This file contains the Skeleton implementation of the MRegisterInfo class.
12 //===----------------------------------------------------------------------===//
14 #ifndef SKELETON_REGISTERINFO_H
15 #define SKELETON_REGISTERINFO_H
17 #include "llvm/Target/MRegisterInfo.h"
18 #include "SkeletonGenRegisterInfo.h.inc"
23 struct SkeletonRegisterInfo : public SkeletonGenRegisterInfo {
24 SkeletonRegisterInfo();
25 const TargetRegisterClass* getRegClassForType(const Type* Ty) const;
27 // See MRegisterInfo.h for information on these methods.
28 int storeRegToStackSlot(MachineBasicBlock &MBB,
29 MachineBasicBlock::iterator MBBI,
30 unsigned SrcReg, int FrameIndex) const;
32 int loadRegFromStackSlot(MachineBasicBlock &MBB,
33 MachineBasicBlock::iterator MBBI,
34 unsigned DestReg, int FrameIndex) const;
36 int copyRegToReg(MachineBasicBlock &MBB, MachineBasicBlock::iterator MBBI,
37 unsigned DestReg, unsigned SrcReg,
38 const TargetRegisterClass *RC) const;
40 void eliminateCallFramePseudoInstr(MachineFunction &MF,
41 MachineBasicBlock &MBB,
42 MachineBasicBlock::iterator I) const;
44 void eliminateFrameIndex(MachineBasicBlock::iterator II) const;
46 void processFunctionBeforeFrameFinalized(MachineFunction &MF) const;
48 void emitPrologue(MachineFunction &MF) const;
49 void emitEpilogue(MachineFunction &MF, MachineBasicBlock &MBB) const;
51 } // end namespace llvm