[all-commits] [llvm/llvm-project] 4f551b: [IndVarSimplify] Add safety check for getTruncateE...
Anshil Gandhi via All-commits
all-commits at lists.llvm.org
Wed Feb 11 02:09:03 PST 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 4f551b55aeb316cd2d8f8f911908ea5bd4ced16b
https://github.com/llvm/llvm-project/commit/4f551b55aeb316cd2d8f8f911908ea5bd4ced16b
Author: Anshil Gandhi <95053726+gandhi56 at users.noreply.github.com>
Date: 2026-02-11 (Wed, 11 Feb 2026)
Changed paths:
M llvm/lib/Transforms/Scalar/IndVarSimplify.cpp
A llvm/test/Transforms/IndVarSimplify/scev-update-loop-opt.ll
Log Message:
-----------
[IndVarSimplify] Add safety check for getTruncateExpr in genLoopLimit (#172234)
getTruncateExpr may not always return a SCEVAddRecExpr when truncating
loop bounds. Add a check to verify the result type before casting, and
bail out of the transformation if the cast would be invalid.
This prevents potential crashes from invalid casts when dealing with
complex loop bounds.
Co-authored by Michael Rowan
Resolves [#153090](https://github.com/llvm/llvm-project/issues/153090)
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list