[flang][lowering] Add support for lowering of the `{l|u}bound` intrinsics
authorAndrzej Warzynski <andrzej.warzynski@arm.com>
Thu, 17 Mar 2022 17:11:35 +0000 (17:11 +0000)
committerAndrzej Warzynski <andrzej.warzynski@arm.com>
Fri, 18 Mar 2022 10:16:54 +0000 (10:16 +0000)
commitff3e75f7390e387f8134bacd9c862475a08d3348
tree4cc4f4f2678f05be686b4c97b04fefdd8a01f2f0
parent74992f4a5bb79e2084abdef406ef2e5aa2024368
[flang][lowering] Add support for lowering of the `{l|u}bound` intrinsics

This patch adds support for lowering of the `{l|u}bound` intrinsics from
Fortran to the FIR dialect of MLIR. Note that `ubound` is already
supported, but the test was missing (added here).

This is part of the upstreaming effort from the `fir-dev` branch in [1].

[1] https://github.com/flang-compiler/f18-llvm-project

Differential Revision: https://reviews.llvm.org/D121926

Co-authored-by: Jean Perier <jperier@nvidia.com>
Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
Co-authored-by: Peter Steinfeld <psteinfeld@nvidia.com>
flang/lib/Lower/IntrinsicCall.cpp
flang/test/Lower/Intrinsics/lbound.f90 [new file with mode: 0644]
flang/test/Lower/Intrinsics/ubound.f90 [new file with mode: 0644]