MSP430RegisterInfo.h revision 249423
1234353Sdim//===-- MSP430RegisterInfo.h - MSP430 Register Information Impl -*- C++ -*-===//
2193323Sed//
3193323Sed//                     The LLVM Compiler Infrastructure
4193323Sed//
5193323Sed// This file is distributed under the University of Illinois Open Source
6193323Sed// License. See LICENSE.TXT for details.
7193323Sed//
8193323Sed//===----------------------------------------------------------------------===//
9193323Sed//
10193323Sed// This file contains the MSP430 implementation of the MRegisterInfo class.
11193323Sed//
12193323Sed//===----------------------------------------------------------------------===//
13193323Sed
14193323Sed#ifndef LLVM_TARGET_MSP430REGISTERINFO_H
15193323Sed#define LLVM_TARGET_MSP430REGISTERINFO_H
16193323Sed
17193323Sed#include "llvm/Target/TargetRegisterInfo.h"
18193323Sed
19224145Sdim#define GET_REGINFO_HEADER
20224145Sdim#include "MSP430GenRegisterInfo.inc"
21224145Sdim
22193323Sednamespace llvm {
23193323Sed
24193323Sedclass TargetInstrInfo;
25193323Sedclass MSP430TargetMachine;
26193323Sed
27193323Sedstruct MSP430RegisterInfo : public MSP430GenRegisterInfo {
28193323Sedprivate:
29193323Sed  MSP430TargetMachine &TM;
30193323Sed  const TargetInstrInfo &TII;
31193323Sed
32193323Sed  /// StackAlign - Default stack alignment.
33193323Sed  ///
34193323Sed  unsigned StackAlign;
35193323Sedpublic:
36193323Sed  MSP430RegisterInfo(MSP430TargetMachine &tm, const TargetInstrInfo &tii);
37193323Sed
38193323Sed  /// Code Generation virtual methods...
39234353Sdim  const uint16_t *getCalleeSavedRegs(const MachineFunction *MF = 0) const;
40193323Sed
41193323Sed  BitVector getReservedRegs(const MachineFunction &MF) const;
42239462Sdim  const TargetRegisterClass*
43239462Sdim  getPointerRegClass(const MachineFunction &MF, unsigned Kind = 0) const;
44193323Sed
45212904Sdim  void eliminateFrameIndex(MachineBasicBlock::iterator II,
46249423Sdim                           int SPAdj, unsigned FIOperandNum,
47249423Sdim                           RegScavenger *RS = NULL) const;
48193323Sed
49193323Sed  // Debug information queries.
50199481Srdivacky  unsigned getFrameRegister(const MachineFunction &MF) const;
51193323Sed};
52193323Sed
53193323Sed} // end namespace llvm
54193323Sed
55193323Sed#endif // LLVM_TARGET_MSP430REGISTERINFO_H
56