aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp
diff options
context:
space:
mode:
authorJean Perier <jperier@nvidia.com>2022-03-25 18:01:50 +0100
committerJean Perier <jperier@nvidia.com>2022-03-25 18:05:54 +0100
commit5bc9ee1b780656c6d7f27c4ca657c5a7815311c1 (patch)
treef11706cb08b73e40445853cd26fe6ddbdaba6c67 /llvm/lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp
parentec858f02015c32c683852fe72761a2e610dc5785 (diff)
downloadllvm-5bc9ee1b780656c6d7f27c4ca657c5a7815311c1.zip
llvm-5bc9ee1b780656c6d7f27c4ca657c5a7815311c1.tar.gz
llvm-5bc9ee1b780656c6d7f27c4ca657c5a7815311c1.tar.bz2
[flang][lowering] Handle zero extent case in LBOUND
Follow up of https://reviews.llvm.org/D121488. Ensure lower bounds are `1` when the related dimension extent is zero. Note that lower bounds from descriptors are now guaranteed to fulfill this property after the runtime/codegen patches. Also fixes explicit shape array extent lowering when instantiating variables to deal with negative extent cases (issue found while testing LBOUND edge case). This notably caused allocation crashes when dealing with automatic arrays with reversed bounds or negative size specification expression. The standard specifies that the extent of such arrays is zero. This change has some ripple effect in the current lit tests. Add move two helpers as part of this change: - Add a helper to tell if a fir::ExtendedValue describes an assumed size array (last dimension extent is unknown to the compiler, both at compile time and runtime). - Move and share getIntIfConstant from Character.cpp so that it can be used elsewhere (NFC). Differential Revision: https://reviews.llvm.org/D122467
Diffstat (limited to 'llvm/lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp')
0 files changed, 0 insertions, 0 deletions