FLANG
Fortran::lower::CalleeInterface Class Reference

#include <flang/Lower/CallInterface.h>

Inheritance diagram for Fortran::lower::CalleeInterface:
Fortran::lower::CallInterface< CalleeInterface >

Public Member Functions

 CalleeInterface (Fortran::lower::pft::FunctionLikeUnit &f, Fortran::lower::AbstractConverter &c)
bool hasAlternateReturns () const
std::string getMangledName () const
mlir::Location getCalleeLocation () const
Fortran::evaluate::characteristics::Procedure characterize () const
bool isMainProgram () const
Fortran::lower::pft::FunctionLikeUnitgetCallDescription () const
bool isIndirectCall () const
bool requireDispatchCall () const
const Fortran::semantics::SymbolgetProcedureSymbol () const
mlir::func::FuncOp addEntryBlockAndMapArguments ()
bool hasHostAssociated () const
mlir::Type getHostAssociatedTy () const
mlir::Value getHostAssociatedTuple () const
Public Member Functions inherited from Fortran::lower::CallInterface< CalleeInterface >
mlir::func::FuncOp getFuncOp () const
std::size_t getNumFIRArguments () const
 Number of MLIR inputs/outputs of the created FuncOp.
std::size_t getNumFIRResults () const
llvm::SmallVector< mlir::Type > getResultType () const
 Return the MLIR output types.
llvm::ArrayRef< PassedEntity > getPassedArguments () const
std::optional< PassedEntity > getPassedResult () const
mlir::FunctionType genFunctionType ()
 Returns the mlir function type.
void determineInterface (bool isImplicit, const Fortran::evaluate::characteristics::Procedure &)
bool callerAllocateResult () const
 Does the caller need to allocate storage for the result ?
bool mustPassResult () const
 Is the Fortran result passed as an extra MLIR argument ?
bool mustSaveResult () const
 Must the MLIR result be saved with a fir.save_result ?
bool canBeCalledViaImplicitInterface () const
 Can the associated procedure be called via an implicit interface?
fir::FortranProcedureFlagsEnumAttr getProcedureAttrs (mlir::MLIRContext *) const

Additional Inherited Members

Public Types inherited from Fortran::lower::CallInterface< CalleeInterface >
enum  PassEntityBy
 Enum the different ways an entity can be passed-by.
enum  Property
using FortranEntity
using FirValue
Protected Member Functions inherited from Fortran::lower::CallInterface< CalleeInterface >
 CallInterface (Fortran::lower::AbstractConverter &c)
CalleeInterfaceside ()
 CRTP handle.
void declare ()
void mapPassedEntities ()
void mapBackInputToPassedEntity (const FirPlaceHolder &, FirValue)
Protected Attributes inherited from Fortran::lower::CallInterface< CalleeInterface >
llvm::SmallVector< FirPlaceHolder > outputs
llvm::SmallVector< FirPlaceHolder > inputs
mlir::func::FuncOp func
llvm::SmallVector< PassedEntity > passedArguments
std::optional< PassedEntity > passedResult
bool saveResult
Fortran::lower::AbstractConverterconverter
std::optional< Fortran::evaluate::characteristics::Procedurecharacteristic

Detailed Description

CalleeInterface only provides the helpers needed by CallInterface to abstract the specificities of the callee side.

Member Function Documentation

◆ addEntryBlockAndMapArguments()

mlir::func::FuncOp Fortran::lower::CalleeInterface::addEntryBlockAndMapArguments ( )

Add mlir::func::FuncOp entry block and map fir block arguments to Fortran dummy argument symbols.

◆ getProcedureSymbol()

const Fortran::semantics::Symbol * Fortran::lower::CalleeInterface::getProcedureSymbol ( ) const

Return the procedure symbol if this is a call to a user defined procedure.

◆ isIndirectCall()

bool Fortran::lower::CalleeInterface::isIndirectCall ( ) const
inline

On the callee side it does not matter whether the procedure is called through pointers or not.

◆ requireDispatchCall()

bool Fortran::lower::CalleeInterface::requireDispatchCall ( ) const
inline

On the callee side it does not matter whether the procedure is called through dynamic dispatch or not.


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