[PATCH] D140906: [DebugInfo] Replace UndefValue with PoisonValue in AssignmentTrackingAnalysis
Scott Linder via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 3 15:10:27 PST 2023
scott.linder added a comment.
Code LGTM, thank you! One small request is to move some comments around and update `llvm/docs/AssignmentTracking.md` to reflect the change.
Something like:
The first three parameters look and behave like an llvm.dbg.value. ID is a reference to a store (see next section). Address is the destination address of the store and it is modified by AddressExpression. An empty/undef/poison Address represents <...>.
================
Comment at: llvm/include/llvm/IR/IntrinsicInst.h:451
void setValue(Value *V);
+ bool isAddressKillLocation();
/// \name Casting methods
----------------
I vote for a short doc comment mentioning that this is the only correct way to ask a `DbgAssignIntrinsic` whether it "kills" the address-based location.
================
Comment at: llvm/lib/CodeGen/AssignmentTrackingAnalysis.cpp:1478
+ if (DAI.isAddressKillLocation()) {
// Address may be undef to indicate that although the store does take
// place, this part of the original store has been elided.
----------------
Somewhat stale reference to `undef` directly here. Could the comment just be folded into a general one on `isAddressKillLocation` itself?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D140906/new/
https://reviews.llvm.org/D140906
More information about the llvm-commits
mailing list