Skip to content

Commit 1292677

Browse files
vzakhariIanWood1
authored andcommitted
Reland [flang] Generalized simplification of HLFIR reduction ops. (llvm#136071) (llvm#136246)
This change generalizes SumAsElemental inlining in SimplifyHLFIRIntrinsics pass so that it can be applied to ALL, ANY, COUNT, MAXLOC, MAXVAL, MINLOC, MINVAL, SUM. This change makes the special handling of the reduction operations in OptimizedBufferization redundant: once HLFIR operations are inlined, the hlfir.elemental inlining should do the rest of the job.
1 parent 54e8f56 commit 1292677

16 files changed

+2233
-2002
lines changed

flang/lib/Optimizer/HLFIR/Transforms/OptimizedBufferization.cpp

Lines changed: 0 additions & 465 deletions
Large diffs are not rendered by default.

flang/lib/Optimizer/HLFIR/Transforms/SimplifyHLFIRIntrinsics.cpp

Lines changed: 864 additions & 200 deletions
Large diffs are not rendered by default.

flang/test/HLFIR/all-elemental.fir

Lines changed: 0 additions & 91 deletions
This file was deleted.

flang/test/HLFIR/any-elemental.fir

Lines changed: 0 additions & 190 deletions
This file was deleted.

0 commit comments

Comments
 (0)