[PATCH] D87302: [IRSim][IROutliner] Adding DebugInfo handling for IR outlined functions.

David Blaikie via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 10 12:08:03 PDT 2021


dblaikie added a comment.

Does the outliner only run for commoning code, or can it run on a single function (for hot/cold reasons, or anything else)?

BUt yeah, in the commoning case, DWARF (& LLVM IR) have no way to represent this situation and dropping the location is the best tool we have at the moment. It's discussed here: https://llvm.org/docs/HowToUpdateDebugInfo.html#when-to-drop-an-instruction-location



================
Comment at: llvm/lib/Transforms/IPO/IROutliner.cpp:383
       Group.OutlinedFunctionType, GlobalValue::InternalLinkage,
       "outlined_ir_func_" + std::to_string(FunctionNameSuffix), M);
 
----------------
Side note: This seems surprising to me - do any other passes create functions with plain names like this? I'd expect anything being created would use something like the C++ reserved identifier namespace (double leading underscore or leading underscore and uppercase).


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

https://reviews.llvm.org/D87302



More information about the llvm-commits mailing list