17#ifndef FORTRAN_LOWER_CONVERTEXPRTOHLFIR_H
18#define FORTRAN_LOWER_CONVERTEXPRTOHLFIR_H
20#include "flang/Lower/StatementContext.h"
21#include "flang/Lower/Support/Utils.h"
22#include "flang/Optimizer/Builder/FIRBuilder.h"
23#include "flang/Optimizer/Builder/HLFIRTools.h"
24#include "flang/Optimizer/Dialect/FIRDialect.h"
39hlfir::EntityWithAttributes
40convertExprToHLFIR(mlir::Location loc, Fortran::lower::AbstractConverter &,
41 const Fortran::lower::SomeExpr &, Fortran::lower::SymMap &,
42 Fortran::lower::StatementContext &);
44inline fir::ExtendedValue translateToExtendedValue(
45 mlir::Location loc, fir::FirOpBuilder &builder, hlfir::Entity entity,
46 Fortran::lower::StatementContext &context,
bool contiguityHint =
false) {
47 auto [exv, exvCleanup] =
48 hlfir::translateToExtendedValue(loc, builder, entity, contiguityHint);
57 Fortran::lower::AbstractConverter &,
58 const Fortran::lower::SomeExpr &,
59 Fortran::lower::SymMap &,
60 Fortran::lower::StatementContext &);
61fir::ExtendedValue convertToBox(mlir::Location loc,
62 Fortran::lower::AbstractConverter &,
64 Fortran::lower::StatementContext &,
65 mlir::Type fortranType);
93 Fortran::lower::AbstractConverter &,
94 const Fortran::lower::SomeExpr &,
95 Fortran::lower::SymMap &,
96 Fortran::lower::StatementContext &);
97fir::ExtendedValue convertToAddress(mlir::Location loc,
98 Fortran::lower::AbstractConverter &,
100 Fortran::lower::StatementContext &,
101 mlir::Type fortranType);
105 Fortran::lower::AbstractConverter &,
106 const Fortran::lower::SomeExpr &,
107 Fortran::lower::SymMap &,
108 Fortran::lower::StatementContext &);
109fir::ExtendedValue convertToValue(mlir::Location loc,
110 Fortran::lower::AbstractConverter &,
111 hlfir::Entity entity,
112 Fortran::lower::StatementContext &);
114fir::ExtendedValue convertDataRefToValue(mlir::Location loc,
115 Fortran::lower::AbstractConverter &,
116 const Fortran::evaluate::DataRef &,
117 Fortran::lower::SymMap &,
118 Fortran::lower::StatementContext &);
125 const Fortran::lower::SomeExpr &,
126 Fortran::lower::SymMap &);
136 mlir::Location loc, Fortran::lower::AbstractConverter &,
137 const Fortran::lower::SomeExpr &, Fortran::lower::SymMap &,
138 Fortran::lower::StatementContext &);
145 mlir::Location loc, Fortran::lower::AbstractConverter &converter,
146 const Fortran::lower::SomeExpr &expr, Fortran::lower::SymMap &symMap,
147 Fortran::lower::StatementContext &stmtCtx);
Definition AbstractConverter.h:85
void attachCleanup(CleanupFunction cuf)
Append a cleanup function to the "list" of cleanup functions.
Definition StatementContext.h:69
Definition SymbolMap.h:146
Definition ParserActions.h:24
hlfir::Entity genVectorSubscriptedDesignatorFirstElementAddress(mlir::Location loc, Fortran::lower::AbstractConverter &converter, const Fortran::lower::SomeExpr &expr, Fortran::lower::SymMap &symMap, Fortran::lower::StatementContext &stmtCtx)
Definition ConvertExprToHLFIR.cpp:2176
fir::MutableBoxValue convertExprToMutableBox(mlir::Location loc, Fortran::lower::AbstractConverter &, const Fortran::lower::SomeExpr &, Fortran::lower::SymMap &)
Definition ConvertExprToHLFIR.cpp:2150
fir::ExtendedValue convertExprToAddress(mlir::Location loc, Fortran::lower::AbstractConverter &, const Fortran::lower::SomeExpr &, Fortran::lower::SymMap &, Fortran::lower::StatementContext &)
Definition ConvertExprToHLFIR.cpp:2112
hlfir::ElementalAddrOp convertVectorSubscriptedExprToElementalAddr(mlir::Location loc, Fortran::lower::AbstractConverter &, const Fortran::lower::SomeExpr &, Fortran::lower::SymMap &, Fortran::lower::StatementContext &)
Definition ConvertExprToHLFIR.cpp:2168
fir::ExtendedValue convertExprToValue(mlir::Location loc, Fortran::lower::AbstractConverter &, const Fortran::lower::SomeExpr &, Fortran::lower::SymMap &, Fortran::lower::StatementContext &)
Lower an evaluate::Expr to a fir::ExtendedValue value.
Definition ConvertExprToHLFIR.cpp:2132
fir::ExtendedValue convertExprToBox(mlir::Location loc, Fortran::lower::AbstractConverter &, const Fortran::lower::SomeExpr &, Fortran::lower::SymMap &, Fortran::lower::StatementContext &)
Definition ConvertExprToHLFIR.cpp:2090
Definition AbstractConverter.h:29