LLVM API Documentation

XCoreRegisterInfo.h
Go to the documentation of this file.
00001 //===-- XCoreRegisterInfo.h - XCore Register Information Impl ---*- C++ -*-===//
00002 //
00003 //                     The LLVM Compiler Infrastructure
00004 //
00005 // This file is distributed under the University of Illinois Open Source
00006 // License. See LICENSE.TXT for details.
00007 //
00008 //===----------------------------------------------------------------------===//
00009 //
00010 // This file contains the XCore implementation of the MRegisterInfo class.
00011 //
00012 //===----------------------------------------------------------------------===//
00013 
00014 #ifndef LLVM_LIB_TARGET_XCORE_XCOREREGISTERINFO_H
00015 #define LLVM_LIB_TARGET_XCORE_XCOREREGISTERINFO_H
00016 
00017 #include "llvm/Target/TargetRegisterInfo.h"
00018 
00019 #define GET_REGINFO_HEADER
00020 #include "XCoreGenRegisterInfo.inc"
00021 
00022 namespace llvm {
00023 
00024 class TargetInstrInfo;
00025 
00026 struct XCoreRegisterInfo : public XCoreGenRegisterInfo {
00027 public:
00028   XCoreRegisterInfo();
00029 
00030   /// Code Generation virtual methods...
00031 
00032   const MCPhysReg *
00033   getCalleeSavedRegs(const MachineFunction *MF =nullptr) const override;
00034 
00035   BitVector getReservedRegs(const MachineFunction &MF) const override;
00036   
00037   bool requiresRegisterScavenging(const MachineFunction &MF) const override;
00038 
00039   bool trackLivenessAfterRegAlloc(const MachineFunction &MF) const override;
00040 
00041   bool useFPForScavengingIndex(const MachineFunction &MF) const override;
00042 
00043   void eliminateFrameIndex(MachineBasicBlock::iterator II,
00044                            int SPAdj, unsigned FIOperandNum,
00045                            RegScavenger *RS = nullptr) const override;
00046 
00047   // Debug information queries.
00048   unsigned getFrameRegister(const MachineFunction &MF) const override;
00049 
00050   //! Return whether to emit frame moves
00051   static bool needsFrameMoves(const MachineFunction &MF);
00052 };
00053 
00054 } // end namespace llvm
00055 
00056 #endif