LLVM  14.0.0git
MSP430FrameLowering.h
Go to the documentation of this file.
1 //==- MSP430FrameLowering.h - Define frame lowering for MSP430 --*- 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 //
10 //
11 //===----------------------------------------------------------------------===//
12 
13 #ifndef LLVM_LIB_TARGET_MSP430_MSP430FRAMELOWERING_H
14 #define LLVM_LIB_TARGET_MSP430_MSP430FRAMELOWERING_H
15 
16 #include "MSP430.h"
18 
19 namespace llvm {
21 protected:
22 
23 public:
26  Align(2)) {}
27 
28  /// emitProlog/emitEpilog - These methods insert prolog and epilog code into
29  /// the function.
30  void emitPrologue(MachineFunction &MF, MachineBasicBlock &MBB) const override;
31  void emitEpilogue(MachineFunction &MF, MachineBasicBlock &MBB) const override;
32 
35  MachineBasicBlock::iterator I) const override;
36 
40  const TargetRegisterInfo *TRI) const override;
41  bool
45  const TargetRegisterInfo *TRI) const override;
46 
47  bool hasFP(const MachineFunction &MF) const override;
48  bool hasReservedCallFrame(const MachineFunction &MF) const override;
50  RegScavenger *RS = nullptr) const override;
51 };
52 
53 } // End llvm namespace
54 
55 #endif
MI
IRTranslator LLVM IR MI
Definition: IRTranslator.cpp:103
llvm
---------------------— PointerInfo ------------------------------------—
Definition: AllocatorList.h:23
llvm::MSP430FrameLowering
Definition: MSP430FrameLowering.h:20
TargetFrameLowering.h
llvm::MSP430FrameLowering::emitPrologue
void emitPrologue(MachineFunction &MF, MachineBasicBlock &MBB) const override
emitProlog/emitEpilog - These methods insert prolog and epilog code into the function.
Definition: MSP430FrameLowering.cpp:40
llvm::TargetFrameLowering
Information about stack frame layout on the target.
Definition: TargetFrameLowering.h:43
llvm::TargetRegisterInfo
TargetRegisterInfo base class - We assume that the target defines a static array of TargetRegisterDes...
Definition: TargetRegisterInfo.h:233
TRI
unsigned const TargetRegisterInfo * TRI
Definition: MachineSink.cpp:1567
llvm::MutableArrayRef
MutableArrayRef - Represent a mutable reference to an array (0 or more elements consecutively in memo...
Definition: ArrayRef.h:307
llvm::MSP430FrameLowering::eliminateCallFramePseudoInstr
MachineBasicBlock::iterator eliminateCallFramePseudoInstr(MachineFunction &MF, MachineBasicBlock &MBB, MachineBasicBlock::iterator I) const override
This method is called during prolog/epilog code insertion to eliminate call frame setup and destroy p...
Definition: MSP430FrameLowering.cpp:220
llvm::Align
This struct is a compact representation of a valid (non-zero power of two) alignment.
Definition: Alignment.h:39
llvm::MachineBasicBlock
Definition: MachineBasicBlock.h:95
llvm::MSP430FrameLowering::emitEpilogue
void emitEpilogue(MachineFunction &MF, MachineBasicBlock &MBB) const override
Definition: MSP430FrameLowering.cpp:105
I
#define I(x, y, z)
Definition: MD5.cpp:59
llvm::RegScavenger
Definition: RegisterScavenging.h:34
llvm::MSP430FrameLowering::restoreCalleeSavedRegisters
bool restoreCalleeSavedRegisters(MachineBasicBlock &MBB, MachineBasicBlock::iterator MI, MutableArrayRef< CalleeSavedInfo > CSI, const TargetRegisterInfo *TRI) const override
restoreCalleeSavedRegisters - Issues instruction(s) to restore all callee saved registers and returns...
Definition: MSP430FrameLowering.cpp:202
llvm::MachineFunction
Definition: MachineFunction.h:230
llvm::ArrayRef
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
Definition: APInt.h:32
MSP430.h
llvm::MSP430FrameLowering::MSP430FrameLowering
MSP430FrameLowering()
Definition: MSP430FrameLowering.h:24
MBB
MachineBasicBlock & MBB
Definition: AArch64SLSHardening.cpp:74
llvm::MSP430FrameLowering::hasFP
bool hasFP(const MachineFunction &MF) const override
hasFP - Return true if the specified function should have a dedicated frame pointer register.
Definition: MSP430FrameLowering.cpp:28
llvm::MSP430FrameLowering::spillCalleeSavedRegisters
bool spillCalleeSavedRegisters(MachineBasicBlock &MBB, MachineBasicBlock::iterator MI, ArrayRef< CalleeSavedInfo > CSI, const TargetRegisterInfo *TRI) const override
spillCalleeSavedRegisters - Issues instruction(s) to spill all callee saved registers and returns tru...
Definition: MSP430FrameLowering.cpp:178
llvm::TargetFrameLowering::StackGrowsDown
@ StackGrowsDown
Definition: TargetFrameLowering.h:47
llvm::MSP430FrameLowering::hasReservedCallFrame
bool hasReservedCallFrame(const MachineFunction &MF) const override
hasReservedCallFrame - Under normal circumstances, when a frame pointer is not required,...
Definition: MSP430FrameLowering.cpp:36
llvm::MachineInstrBundleIterator< MachineInstr >
llvm::MSP430FrameLowering::processFunctionBeforeFrameFinalized
void processFunctionBeforeFrameFinalized(MachineFunction &MF, RegScavenger *RS=nullptr) const override
processFunctionBeforeFrameFinalized - This method is called immediately before the specified function...
Definition: MSP430FrameLowering.cpp:283