[all-commits] [llvm/llvm-project] 419c6d: [mlir][LLVM] Verify too many indices in GEP verifi...
Markus Böck via All-commits
all-commits at lists.llvm.org
Wed Oct 25 02:38:40 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 419c6da3d763cc34b15aa66d4b6e7fed6031cedd
https://github.com/llvm/llvm-project/commit/419c6da3d763cc34b15aa66d4b6e7fed6031cedd
Author: Markus Böck <markus.boeck02 at gmail.com>
Date: 2023-10-25 (Wed, 25 Oct 2023)
Changed paths:
M mlir/lib/Dialect/LLVMIR/IR/LLVMDialect.cpp
M mlir/test/Dialect/LLVMIR/invalid.mlir
M mlir/test/Dialect/LLVMIR/mem2reg.mlir
M mlir/test/Dialect/LLVMIR/roundtrip-typed-pointers.mlir
M mlir/test/Dialect/LLVMIR/roundtrip.mlir
Log Message:
-----------
[mlir][LLVM] Verify too many indices in GEP verifier (#70174)
The current verifier stopped verification with a success value as soon
as a type was encountered that cannot be indexed into. The correct
behaviour in this case is to error out as there are too many indices for
the element type. Not doing so leads to bad user-experience as an
invalid GEP is likely to fail only later during LLVM IR translation.
This PR implements the correct verification behaviour. Some tests
upstream had to also be fixed as they were creating invalid GEPs.
Fixes https://github.com/llvm/llvm-project/issues/70168
More information about the All-commits
mailing list