[flang-commits] [PATCH] D139613: [flang] Lower intrinsics to HLFIR part 1

Jean Perier via Phabricator via flang-commits flang-commits at lists.llvm.org
Thu Dec 8 01:48:56 PST 2022


jeanPerier created this revision.
jeanPerier added a reviewer: clementval.
jeanPerier added a project: Flang.
Herald added subscribers: mehdi_amini, jdoerfert.
Herald added a reviewer: sscalpone.
Herald added a project: All.
jeanPerier requested review of this revision.

This patch adds support for lowering intrinsics that have no dynamic
optionality aspects to handle and that requires argument to be lowered
to value, addr, or box.

It uses the current intrinsic lowering framework that can be re-used in
HLFIR to start with. HLFIR operations for charater/transformational
intrinsics will be added as needed from an optimization point of view.
The current approach will still create temporary variables for their
value directly in lowering.

Later patch will still need to add:

- support for dynamically optional arguments
- inquires
- "moving" the in memory computation of character and transformational

intrinsics to hlfir.expr. This is not needed from a semantic point of
view, but will help optimizing and will probably be required inside
hlfir.elemental returning characters so that the returned element
type is an hlfir.expr and match the result type of later hlfir.apply.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D139613

Files:
  flang/lib/Lower/ConvertCall.cpp
  flang/lib/Optimizer/Builder/HLFIRTools.cpp
  flang/test/Lower/HLFIR/calls-f77.f90

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D139613.481199.patch
Type: text/x-patch
Size: 6708 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/flang-commits/attachments/20221208/b000f6cd/attachment.bin>


More information about the flang-commits mailing list