FLANG

Public Types | Public Member Functions | Protected Member Functions | List of all members
Fortran::lower::ComplexExprHelper Class Reference

Helper to facilitate lowering of COMPLEX manipulations in FIR. More...

`#include <flang/Lower/ComplexExpr.h>`

## Public Types
enum | Part { Real = 0, Imag = 1 }

## Public Member Functions
| ComplexExprHelper (FirOpBuilder &builder, mlir::Location loc)
| ComplexExprHelper (const ComplexExprHelper &)=delete
mlir::Type | getComplexPartType (mlir::Value cplx)
| Type helper. Determine the type. Do not create MLIR operations.
mlir::Type | getComplexPartType (mlir::Type complexType)
mlir::Value | createComplex (fir::KindTy kind, mlir::Value real, mlir::Value imag)
| Complex operation creation helper. They create MLIR operations.
mlir::Value | createComplex (mlir::Type complexType, mlir::Value real, mlir::Value imag)
| Create a complex value.
mlir::Value | extractComplexPart (mlir::Value cplx, bool isImagPart)
std::pair< mlir::Value, mlir::Value > | extractParts (mlir::Value cplx)
| Returns (Real, Imag) pair of `cplx`.
mlir::Value | insertComplexPart (mlir::Value cplx, mlir::Value part, bool isImagPart)
mlir::Value | createComplexCompare (mlir::Value cplx1, mlir::Value cplx2, bool eq)

## Protected Member Functions
template<Part partId>
mlir::Value | extract (mlir::Value cplx)
template<Part partId>
mlir::Value | insert (mlir::Value cplx, mlir::Value part)
template<Part partId>
mlir::Value | createPartId ()

## Detailed Description

Helper to facilitate lowering of COMPLEX manipulations in FIR.

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

- include/flang/Lower/ComplexExpr.h
- lib/Lower/ComplexExpr.cpp