[PATCH] D79868: [DebugInfo] Correct debuginfo for post-ra hoist and sink in Machine LICM

Adrian Prantl via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 13 09:11:03 PDT 2020


aprantl added a comment.

Can you explain why the sunk instruction's location is considered incorrect? I would have naively assumed that for profiling particularly, you would want to retain the original location to ensure that it is counted.



================
Comment at: llvm/lib/CodeGen/MachineLICM.cpp:641
+  // experience and adversely affect the accuracy of profiling information.
+  MI->setDebugLoc(DebugLoc());
+
----------------
Can a DBG_VALUE ever be hoisted out of a loop? In that case this would delete the inline info from the intrinsic and attribute the inlined variable to the wrong function.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D79868/new/

https://reviews.llvm.org/D79868





More information about the llvm-commits mailing list