[x86] fix assert with horizontal math + broadcast of vector (PR43402)
[llvm-core.git] / lib / Target / MSP430 / MSP430FrameLowering.h
blob33ce3c70a2a3b030086265f363ae205ce787c719
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 //
11 //===----------------------------------------------------------------------===//
13 #ifndef LLVM_LIB_TARGET_MSP430_MSP430FRAMELOWERING_H
14 #define LLVM_LIB_TARGET_MSP430_MSP430FRAMELOWERING_H
16 #include "MSP430.h"
17 #include "llvm/CodeGen/TargetFrameLowering.h"
19 namespace llvm {
20 class MSP430FrameLowering : public TargetFrameLowering {
21 protected:
23 public:
24 explicit MSP430FrameLowering()
25 : TargetFrameLowering(TargetFrameLowering::StackGrowsDown, 2, -2, 2) {}
27 /// emitProlog/emitEpilog - These methods insert prolog and epilog code into
28 /// the function.
29 void emitPrologue(MachineFunction &MF, MachineBasicBlock &MBB) const override;
30 void emitEpilogue(MachineFunction &MF, MachineBasicBlock &MBB) const override;
32 MachineBasicBlock::iterator
33 eliminateCallFramePseudoInstr(MachineFunction &MF, MachineBasicBlock &MBB,
34 MachineBasicBlock::iterator I) const override;
36 bool spillCalleeSavedRegisters(MachineBasicBlock &MBB,
37 MachineBasicBlock::iterator MI,
38 const std::vector<CalleeSavedInfo> &CSI,
39 const TargetRegisterInfo *TRI) const override;
40 bool restoreCalleeSavedRegisters(MachineBasicBlock &MBB,
41 MachineBasicBlock::iterator MI,
42 std::vector<CalleeSavedInfo> &CSI,
43 const TargetRegisterInfo *TRI) const override;
45 bool hasFP(const MachineFunction &MF) const override;
46 bool hasReservedCallFrame(const MachineFunction &MF) const override;
47 void processFunctionBeforeFrameFinalized(MachineFunction &MF,
48 RegScavenger *RS = nullptr) const override;
51 } // End llvm namespace
53 #endif