[llvm] [LiveDebugVariables] Fix a DBG_VALUE reordering issue (PR #111124)
David Stenberg via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 7 04:59:36 PDT 2024
dstenb wrote:
> > This looks good with a question inline and nit, thanks for finding!
> > Technically this patch can have some quadratic behaviour, because if there are multiple DBG_VALUEs being inserted in the same place, we'll repeatedly skip over the ones we've already inserted. See the large comment above this hunk: I believe Facebook/Meta hit some serious compile-times because of that and installed a cache of insertion points at the start of blocks. I don't believe DBG_VALUEs cluster inside basic blocks to the same extent that they do at the start of blocks so this patch is /probably/ fine -- if you can see an obvious way to avoid skipping over previously-inserted DBG_VALUEs then that'd be great, but I don't think it should block the patch.
>
> I'll look further into that. I think I still have access to http://llvm-compile-time-tracker.com, so I should be hopefully able to run some performance measurements on this.
Results: http://llvm-compile-time-tracker.com/compare.php?from=736c163523d7c6281513c120e7d85a6337c4501b&to=142397c089bc9775cd04763c70634196cdf2a7cf&stat=instructions%3Au.
The parent commit is a patch which disables instruction referencing mode (as the profiling is done on x86-64). I did not see any outliers there. However, I don't know how those builds compare to Facebook/Meta builds.
https://github.com/llvm/llvm-project/pull/111124
More information about the llvm-commits
mailing list