[PATCH] D60913: [GVN+LICM] Use line 0 locations for better crash attribution

Vedant Kumar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 4 16:14:26 PDT 2020


vsk added a comment.

In D60913#2191469 <https://reviews.llvm.org/D60913#2191469>, @dblaikie wrote:

> Using zero on non-call locations might bloat the line table a fair bit. May be better to let those locations get flow-on from whatever other instructions are around?
>
> At least that, I think, is the current policy of "merge debug locations", is it not?

The current policy recommends using a merged debug location here (ref <https://llvm.org/docs/HowToUpdateDebugInfo.html#when-to-merge-instruction-locations>), but that's not the same as not setting a debug location. The recommendation is to use the `applyMergedLocation` API. If there's a cheap way to keep track of the scopes of the instructions replaced by 'NewInsts', that would be a good fit here.

> Perhaps we need a similar utility that can be kept in the same place (as merge debug locations)/enforce the same policy for hoisted locations.

Sorry, I don't follow. Is this some enforcement mechanism for debug location update rules?


Repository:
  rL LLVM

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

https://reviews.llvm.org/D60913



More information about the llvm-commits mailing list