[flang-commits] [PATCH] D134476: [flang] Allow "non-expandable" scalars in single-element contexts
Peter Klausler via Phabricator via flang-commits
flang-commits at lists.llvm.org
Thu Sep 22 13:52:55 PDT 2022
klausler created this revision.
klausler added a reviewer: jeanPerier.
klausler added a project: Flang.
Herald added a subscriber: jdoerfert.
Herald added a reviewer: sscalpone.
Herald added a project: All.
klausler requested review of this revision.
When a scalar expression is not expandable -- i.e., it would have to be
evaluated once and saved in a temporary to avoid changing the semantics
of the program if it were to be evaluated more than once -- it affects
some aspects of folding and expression semantics. In cases where
scalar expansion would not cause multiple evaluations due to the shape
of the result having but a single element, however, these "non-expandable"
scalar expressions can be safely allowed.
https://reviews.llvm.org/D134476
Files:
flang/include/flang/Evaluate/characteristics.h
flang/include/flang/Evaluate/shape.h
flang/include/flang/Evaluate/tools.h
flang/lib/Evaluate/fold-implementation.h
flang/lib/Evaluate/shape.cpp
flang/lib/Semantics/expression.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D134476.462285.patch
Type: text/x-patch
Size: 5796 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/flang-commits/attachments/20220922/0923f8c6/attachment.bin>
More information about the flang-commits
mailing list