LLVM 20.0.0git
|
#include "RISCVFrameLowering.h"
#include "RISCVMachineFunctionInfo.h"
#include "RISCVSubtarget.h"
#include "llvm/BinaryFormat/Dwarf.h"
#include "llvm/CodeGen/MachineFrameInfo.h"
#include "llvm/CodeGen/MachineFunction.h"
#include "llvm/CodeGen/MachineInstrBuilder.h"
#include "llvm/CodeGen/MachineRegisterInfo.h"
#include "llvm/CodeGen/RegisterScavenging.h"
#include "llvm/IR/DiagnosticInfo.h"
#include "llvm/MC/MCDwarf.h"
#include "llvm/Support/LEB128.h"
#include <algorithm>
Go to the source code of this file.
Variables | |
static const std::pair< MCPhysReg, int8_t > | FixedCSRFIMap [] |
|
static |
Definition at line 443 of file RISCVFrameLowering.cpp.
References llvm::SmallVectorImpl< T >::append(), llvm::encodeSLEB128(), llvm::encodeULEB128(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), and TRI.
Referenced by createDefCFAExpression(), and createDefCFAOffset().
|
static |
Definition at line 470 of file RISCVFrameLowering.cpp.
References llvm::SmallString< InternalLen >::append(), appendScalableVectorExpression(), assert(), llvm::MCCFIInstruction::createEscape(), llvm::encodeULEB128(), llvm::printReg(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), llvm::SmallVectorBase< Size_T >::size(), llvm::SmallString< InternalLen >::str(), and TRI.
|
static |
Definition at line 500 of file RISCVFrameLowering.cpp.
References llvm::SmallString< InternalLen >::append(), appendScalableVectorExpression(), assert(), llvm::MCCFIInstruction::createEscape(), llvm::encodeULEB128(), llvm::printReg(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), llvm::SmallVectorBase< Size_T >::size(), llvm::SmallString< InternalLen >::str(), and TRI.
|
static |
Definition at line 120 of file RISCVFrameLowering.cpp.
References llvm::MachineInstrBuilder::addCFIIndex(), llvm::MachineFunction::addFrameInst(), llvm::MachineInstrBuilder::addImm(), llvm::MachineInstrBuilder::addReg(), llvm::BuildMI(), llvm::MCCFIInstruction::createRestore(), llvm::RegState::Define, DL, llvm::MachineInstr::FrameDestroy, llvm::MachineFrameInfo::getCalleeSavedInfo(), llvm::MachineFunction::getFrameInfo(), llvm::MachineFunction::getFunction(), llvm::CalleeSavedInfo::getReg(), llvm::RISCVABI::getSCSPReg(), llvm::MachineFunction::getSubtarget(), llvm::Function::hasFnAttribute(), MBB, MI, llvm::none_of(), llvm::MachineInstrBuilder::setMIFlag(), llvm::MachineInstrBuilder::setMIFlags(), and TII.
Referenced by llvm::RISCVFrameLowering::emitEpilogue().
|
static |
Definition at line 58 of file RISCVFrameLowering.cpp.
References llvm::MachineInstrBuilder::addCFIIndex(), llvm::MachineFunction::addFrameInst(), llvm::MachineInstrBuilder::addImm(), llvm::MachineInstrBuilder::addReg(), assert(), llvm::BuildMI(), llvm::MCCFIInstruction::createEscape(), llvm::RegState::Define, DL, llvm::MachineInstr::FrameSetup, llvm::MachineFrameInfo::getCalleeSavedInfo(), llvm::MachineFunction::getFrameInfo(), llvm::MachineFunction::getFunction(), llvm::CalleeSavedInfo::getReg(), llvm::RISCVABI::getSCSPReg(), llvm::MachineFunction::getSubtarget(), llvm::Function::hasFnAttribute(), MBB, MI, llvm::none_of(), llvm::Offset, llvm::MachineInstrBuilder::setMIFlag(), TII, and TRI.
Referenced by llvm::RISCVFrameLowering::emitPrologue().
|
static |
Definition at line 1180 of file RISCVFrameLowering.cpp.
References llvm::MachineFunction::getSubtarget(), llvm::RISCVSubtarget::hasStdExtCOrZca(), MBB, MI, and TII.
|
static |
Definition at line 30 of file RISCVFrameLowering.cpp.
References llvm::RISCVABI::ABI_ILP32E, and llvm::RISCVABI::ABI_LP64E.
|
static |
Definition at line 376 of file RISCVFrameLowering.cpp.
|
static |
Definition at line 170 of file RISCVFrameLowering.cpp.
References llvm::MachineFunction::getInfo(), llvm::Register::id(), and llvm_unreachable.
Referenced by llvm::RISCVFrameLowering::assignCalleeSavedSpillSlots(), llvm::RISCVFrameLowering::emitPrologue(), getRestoreLibCallName(), and getSpillLibCallName().
|
static |
Definition at line 295 of file RISCVFrameLowering.cpp.
References assert(), llvm::find_if(), FixedCSRFIMap, llvm::Register::id(), and P.
Referenced by llvm::RISCVFrameLowering::assignCalleeSavedSpillSlots().
Definition at line 263 of file RISCVFrameLowering.cpp.
References llvm_unreachable, llvm::RISCVZC::RA, llvm::RISCVZC::RA_S0, llvm::RISCVZC::RA_S0_S1, llvm::RISCVZC::RA_S0_S11, llvm::RISCVZC::RA_S0_S2, llvm::RISCVZC::RA_S0_S3, llvm::RISCVZC::RA_S0_S4, llvm::RISCVZC::RA_S0_S5, llvm::RISCVZC::RA_S0_S6, llvm::RISCVZC::RA_S0_S7, llvm::RISCVZC::RA_S0_S8, and llvm::RISCVZC::RA_S0_S9.
Referenced by llvm::RISCVFrameLowering::assignCalleeSavedSpillSlots().
|
static |
Definition at line 236 of file RISCVFrameLowering.cpp.
References getLibCallID().
Referenced by llvm::RISCVFrameLowering::restoreCalleeSavedRegisters().
|
static |
Definition at line 397 of file RISCVFrameLowering.cpp.
References llvm::MachineFunction::getFrameInfo(), llvm::MachineFrameInfo::getStackID(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), and llvm::TargetStackID::ScalableVector.
Referenced by llvm::RISCVFrameLowering::emitPrologue(), llvm::RISCVFrameLowering::restoreCalleeSavedRegisters(), and llvm::RISCVFrameLowering::spillCalleeSavedRegisters().
|
static |
Definition at line 1117 of file RISCVFrameLowering.cpp.
References llvm::MachineFunction::getFrameInfo(), llvm::MachineFrameInfo::getStackID(), llvm::MachineFunction::getSubtarget(), llvm::RISCVSubtarget::hasVInstructions(), llvm::RISCV::isRVVSpill(), MBB, MI, and llvm::TargetStackID::ScalableVector.
Referenced by llvm::RISCVFrameLowering::processFunctionBeforeFrameFinalized().
|
static |
Definition at line 209 of file RISCVFrameLowering.cpp.
References getLibCallID().
Referenced by llvm::RISCVFrameLowering::spillCalleeSavedRegisters().
|
static |
Definition at line 379 of file RISCVFrameLowering.cpp.
Referenced by llvm::RISCVFrameLowering::emitEpilogue(), and llvm::RISCVFrameLowering::emitPrologue().
|
static |
Definition at line 382 of file RISCVFrameLowering.cpp.
References llvm::TargetStackID::Default, llvm::MachineFunction::getFrameInfo(), llvm::MachineFrameInfo::getStackID(), and llvm::SmallVectorTemplateBase< T, bool >::push_back().
Referenced by llvm::RISCVFrameLowering::emitEpilogue(), llvm::RISCVFrameLowering::emitPrologue(), llvm::RISCVFrameLowering::getFrameIndexReference(), llvm::RISCVFrameLowering::restoreCalleeSavedRegisters(), and llvm::RISCVFrameLowering::spillCalleeSavedRegisters().
|
static |
Definition at line 1161 of file RISCVFrameLowering.cpp.
References llvm::MachineFunction::getSubtarget().
Referenced by llvm::RISCVFrameLowering::hasReservedCallFrame(), and llvm::RISCVFrameLowering::processFunctionBeforeFrameFinalized().
Definition at line 47 of file RISCVFrameLowering.cpp.
Referenced by llvm::RISCVFrameLowering::assignCalleeSavedSpillSlots(), getMaxPushPopReg(), llvm::RISCVFrameLowering::restoreCalleeSavedRegisters(), and llvm::RISCVFrameLowering::spillCalleeSavedRegisters().