LLD already has a mechanism for caching creation of DWARCContext:
llvm::call_once(initDwarfLine, [this]() { initializeDwarf(); }); Though it is not used in all places. I need that patch for implementing "Remove obsolete debug info" feature (D74169). But this caching mechanism is useful by itself, and I think it would be good to use it without connection to "Remove obsolete debug info" feature. So this patch changes inplace creation of DWARFContext with its cached version. Depends on D74308 Reviewed By: ruiu Differential Revision: https://reviews.llvm.org/D74773
Loading
Please register or sign in to comment