[all-commits] [llvm/llvm-project] 0a69cd: [JumpThreading][DebugInfo] Propagate DebugLocs whe...
Stephen Tozer via All-commits
all-commits at lists.llvm.org
Wed Sep 10 09:29:14 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 0a69cd4e34e3a1a8a84a2b9fe8764a4b535a9e37
https://github.com/llvm/llvm-project/commit/0a69cd4e34e3a1a8a84a2b9fe8764a4b535a9e37
Author: Stephen Tozer <stephen.tozer at sony.com>
Date: 2025-09-10 (Wed, 10 Sep 2025)
Changed paths:
M llvm/lib/Transforms/Scalar/JumpThreading.cpp
A llvm/test/Transforms/JumpThreading/simplify-partially-redundant-load-debugloc.ll
Log Message:
-----------
[JumpThreading][DebugInfo] Propagate DebugLocs when simplifying loads (#157683)
In simplifyPartiallyRedundantLoad we may replace a load with a PHI of
available values in predecessor blocks. As part of this process, we may
need to cast those values, which we do by inserting a new cast at the
end of the predecessor. These cast instructions should take their debug
location from the load instruction, just as the PHI does; we make an
exception if the predecessor does not unconditionally branch to the
load's block, as in that case we are not guaranteed to reach the load
and must therefore drop its debug location.
Found using https://github.com/llvm/llvm-project/pull/107279.
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