1*0b57cec5SDimitry Andric //===- ARCRegisterInfo.h - ARC Register Information Impl --------*- C++ -*-===// 2*0b57cec5SDimitry Andric // 3*0b57cec5SDimitry Andric // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4*0b57cec5SDimitry Andric // See https://llvm.org/LICENSE.txt for license information. 5*0b57cec5SDimitry Andric // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6*0b57cec5SDimitry Andric // 7*0b57cec5SDimitry Andric //===----------------------------------------------------------------------===// 8*0b57cec5SDimitry Andric // 9*0b57cec5SDimitry Andric // This file contains the ARC implementation of the MRegisterInfo class. 10*0b57cec5SDimitry Andric // 11*0b57cec5SDimitry Andric //===----------------------------------------------------------------------===// 12*0b57cec5SDimitry Andric 13*0b57cec5SDimitry Andric #ifndef LLVM_LIB_TARGET_ARC_ARCREGISTERINFO_H 14*0b57cec5SDimitry Andric #define LLVM_LIB_TARGET_ARC_ARCREGISTERINFO_H 15*0b57cec5SDimitry Andric 16*0b57cec5SDimitry Andric #include "llvm/CodeGen/TargetRegisterInfo.h" 17*0b57cec5SDimitry Andric 18*0b57cec5SDimitry Andric #define GET_REGINFO_HEADER 19*0b57cec5SDimitry Andric #include "ARCGenRegisterInfo.inc" 20*0b57cec5SDimitry Andric 21*0b57cec5SDimitry Andric namespace llvm { 22*0b57cec5SDimitry Andric 23*0b57cec5SDimitry Andric class TargetInstrInfo; 24*0b57cec5SDimitry Andric 25*0b57cec5SDimitry Andric struct ARCRegisterInfo : public ARCGenRegisterInfo { 26*0b57cec5SDimitry Andric public: 27*0b57cec5SDimitry Andric ARCRegisterInfo(); 28*0b57cec5SDimitry Andric 29*0b57cec5SDimitry Andric /// Code Generation virtual methods... 30*0b57cec5SDimitry Andric 31*0b57cec5SDimitry Andric const MCPhysReg *getCalleeSavedRegs(const MachineFunction *MF) const override; 32*0b57cec5SDimitry Andric 33*0b57cec5SDimitry Andric BitVector getReservedRegs(const MachineFunction &MF) const override; 34*0b57cec5SDimitry Andric 35*0b57cec5SDimitry Andric bool requiresRegisterScavenging(const MachineFunction &MF) const override; 36*0b57cec5SDimitry Andric 37*0b57cec5SDimitry Andric bool trackLivenessAfterRegAlloc(const MachineFunction &MF) const override; 38*0b57cec5SDimitry Andric 39*0b57cec5SDimitry Andric bool useFPForScavengingIndex(const MachineFunction &MF) const override; 40*0b57cec5SDimitry Andric 41*0b57cec5SDimitry Andric void eliminateFrameIndex(MachineBasicBlock::iterator II, int SPAdj, 42*0b57cec5SDimitry Andric unsigned FIOperandNum, 43*0b57cec5SDimitry Andric RegScavenger *RS = nullptr) const override; 44*0b57cec5SDimitry Andric 45*0b57cec5SDimitry Andric const uint32_t *getCallPreservedMask(const MachineFunction &MF, 46*0b57cec5SDimitry Andric CallingConv::ID CC) const override; 47*0b57cec5SDimitry Andric 48*0b57cec5SDimitry Andric // Debug information queries. 49*0b57cec5SDimitry Andric Register getFrameRegister(const MachineFunction &MF) const override; 50*0b57cec5SDimitry Andric 51*0b57cec5SDimitry Andric //! Return whether to emit frame moves 52*0b57cec5SDimitry Andric static bool needsFrameMoves(const MachineFunction &MF); 53*0b57cec5SDimitry Andric }; 54*0b57cec5SDimitry Andric 55*0b57cec5SDimitry Andric } // end namespace llvm 56*0b57cec5SDimitry Andric 57*0b57cec5SDimitry Andric #endif // LLVM_LIB_TARGET_ARC_ARCREGISTERINFO_H 58