LLVM 23.0.0git
XtensaRegisterInfo.h
Go to the documentation of this file.
1//===-- XtensaRegisterInfo.h - Xtensa Register Information Impl -*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// This file contains the Xtensa implementation of the TargetRegisterInfo class.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef LLVM_LIB_TARGET_XTENSA_XTENSAREGISTERINFO_H
14#define LLVM_LIB_TARGET_XTENSA_XTENSAREGISTERINFO_H
15
16#include "Xtensa.h"
18
19#define GET_REGINFO_HEADER
20#include "XtensaGenRegisterInfo.inc"
21
22namespace llvm {
23class MCRegisterClass;
24using TargetRegisterClass = MCRegisterClass;
25class XtensaInstrInfo;
26class XtensaSubtarget;
27
29public:
31
33
34 bool requiresRegisterScavenging(const MachineFunction &MF) const override {
35 return true;
36 }
37
38 bool requiresFrameIndexScavenging(const MachineFunction &MF) const override {
39 return true;
40 }
41
42 bool trackLivenessAfterRegAlloc(const MachineFunction &) const override {
43 return true;
44 }
45
46 const uint16_t *
47 getCalleeSavedRegs(const MachineFunction *MF = 0) const override;
49 CallingConv::ID) const override;
50 BitVector getReservedRegs(const MachineFunction &MF) const override;
51
53 unsigned FIOperandNum,
54 RegScavenger *RS = nullptr) const override;
55
56 Register getFrameRegister(const MachineFunction &MF) const override;
57};
58
59} // end namespace llvm
60
61#endif // LLVM_LIB_TARGET_XTENSA_REGISTERINFO_H
IRTranslator LLVM IR MI
MachineInstrBundleIterator< MachineInstr > iterator
Wrapper class representing virtual and physical registers.
Definition Register.h:20
XtensaRegisterInfo(const XtensaSubtarget &STI)
const uint16_t * getCalleeSavedRegs(const MachineFunction *MF=0) const override
bool requiresFrameIndexScavenging(const MachineFunction &MF) const override
bool trackLivenessAfterRegAlloc(const MachineFunction &) const override
bool eliminateFrameIndex(MachineBasicBlock::iterator MI, int SPAdj, unsigned FIOperandNum, RegScavenger *RS=nullptr) const override
const XtensaSubtarget & Subtarget
const uint32_t * getCallPreservedMask(const MachineFunction &MF, CallingConv::ID) const override
Register getFrameRegister(const MachineFunction &MF) const override
BitVector getReservedRegs(const MachineFunction &MF) const override
bool requiresRegisterScavenging(const MachineFunction &MF) const override
unsigned ID
LLVM IR allows to use arbitrary numbers as calling convention identifiers.
Definition CallingConv.h:24
This is an optimization pass for GlobalISel generic memory operations.
MCRegisterClass TargetRegisterClass
Definition FastISel.h:58