LLVM  13.0.0git
Public Member Functions | List of all members
llvm::CallLowering::IncomingValueHandler Struct Reference

Base class for ValueHandlers used for arguments coming into the current function, or for return values received from a call. More...

#include "llvm/CodeGen/GlobalISel/CallLowering.h"

Inheritance diagram for llvm::CallLowering::IncomingValueHandler:
Inheritance graph
[legend]
Collaboration diagram for llvm::CallLowering::IncomingValueHandler:
Collaboration graph
[legend]

Public Member Functions

 IncomingValueHandler (MachineIRBuilder &MIRBuilder, MachineRegisterInfo &MRI)
 
Register buildExtensionHint (CCValAssign &VA, Register SrcReg, LLT NarrowTy)
 Insert G_ASSERT_ZEXT/G_ASSERT_SEXT or other hint instruction based on VA, returning the new register if a hint was inserted. More...
 
void assignValueToReg (Register ValVReg, Register PhysReg, CCValAssign &VA) override
 Provides a default implementation for argument handling. More...
 
- Public Member Functions inherited from llvm::CallLowering::ValueHandler
 ValueHandler (bool IsIncoming, MachineIRBuilder &MIRBuilder, MachineRegisterInfo &MRI)
 
virtual ~ValueHandler ()=default
 
bool isIncomingArgumentHandler () const
 Returns true if the handler is dealing with incoming arguments, i.e. More...
 
virtual Register getStackAddress (uint64_t Size, int64_t Offset, MachinePointerInfo &MPO, ISD::ArgFlagsTy Flags)=0
 Materialize a VReg containing the address of the specified stack-based object. More...
 
virtual uint64_t getStackValueStoreSize (const DataLayout &DL, const CCValAssign &VA) const
 Return the in-memory size to write for the argument at VA. More...
 
virtual void assignValueToAddress (Register ValVReg, Register Addr, uint64_t Size, MachinePointerInfo &MPO, CCValAssign &VA)=0
 The specified value has been assigned to a stack location. More...
 
virtual void assignValueToAddress (const ArgInfo &Arg, unsigned ValRegIndex, Register Addr, uint64_t Size, MachinePointerInfo &MPO, CCValAssign &VA)
 An overload which takes an ArgInfo if additional information about the arg is needed. More...
 
virtual unsigned assignCustomValue (const ArgInfo &Arg, ArrayRef< CCValAssign > VAs)
 Handle custom values, which may be passed into one or more of VAs. More...
 
void copyArgumentMemory (const ArgInfo &Arg, Register DstPtr, Register SrcPtr, const MachinePointerInfo &DstPtrInfo, Align DstAlign, const MachinePointerInfo &SrcPtrInfo, Align SrcAlign, uint64_t MemSize, CCValAssign &VA) const
 Do a memory copy of MemSize bytes from SrcPtr to DstPtr. More...
 
Register extendRegister (Register ValReg, CCValAssign &VA, unsigned MaxSizeBits=0)
 Extend a register to the location type given in VA, capped at extending to at most MaxSize bits. More...
 

Additional Inherited Members

- Public Attributes inherited from llvm::CallLowering::ValueHandler
MachineIRBuilderMIRBuilder
 
MachineRegisterInfoMRI
 
const bool IsIncomingArgumentHandler
 

Detailed Description

Base class for ValueHandlers used for arguments coming into the current function, or for return values received from a call.

Definition at line 301 of file CallLowering.h.

Constructor & Destructor Documentation

◆ IncomingValueHandler()

llvm::CallLowering::IncomingValueHandler::IncomingValueHandler ( MachineIRBuilder MIRBuilder,
MachineRegisterInfo MRI 
)
inline

Definition at line 302 of file CallLowering.h.

Member Function Documentation

◆ assignValueToReg()

void CallLowering::IncomingValueHandler::assignValueToReg ( Register  ValVReg,
Register  PhysReg,
CCValAssign VA 
)
overridevirtual

◆ buildExtensionHint()

Register CallLowering::IncomingValueHandler::buildExtensionHint ( CCValAssign VA,
Register  SrcReg,
LLT  NarrowTy 
)

Insert G_ASSERT_ZEXT/G_ASSERT_SEXT or other hint instruction based on VA, returning the new register if a hint was inserted.

Definition at line 1076 of file CallLowering.cpp.

References llvm::MachineIRBuilder::buildAssertSExt(), llvm::MachineIRBuilder::buildAssertZExt(), llvm::MachineRegisterInfo::cloneVirtualRegister(), llvm::CCValAssign::getLocInfo(), llvm::MachineInstrBuilder::getReg(), llvm::LLT::getScalarSizeInBits(), and MRI.


The documentation for this struct was generated from the following files: