[PATCH] D64595: [Debuginfo][SROA] Need to handle dbg.value in SROA pass.

Jeremy Morse via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 16 07:01:55 PDT 2019


jmorse added a comment.

Sorry for the long delay --

> AFAIU your previous recommendation to avoid converting dbg.declare in instcombiner as well as similar recommendation done by @rnk - they both based on the fact that dbg.addr solution is not fully implemented yet. For SROA case it means : there should not be dbg.value pointing into an alloca. There should be dbg.addr pointing to alloca. Code which do dbg.declare lowering in instcombiner is just temporarily solution until dbg.addr is properly implemented.

That sounds about right -- using dbg.addr would avoid having to think about what's in the DIExpression, and is subject to flow control so would mix well with dbg.value's for the same variable. Alas, I don't know what kind of state dbg.addr is in :o

> Thus, for the current moment I think to implement your original suggestion with avoiding dbg.declare lowering in instcombiner for aggregates.

I think it's worth exploring; at the very least, seeing what the other debug-info reviewers think of that path would be good.


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

https://reviews.llvm.org/D64595





More information about the llvm-commits mailing list