[PATCH] D51618: [dsymutil] Reduce peak memory usage for the single threaded execution.
Jonas Devlieghere via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 5 11:04:43 PDT 2018
JDevlieghere marked 2 inline comments as done.
JDevlieghere added inline comments.
================
Comment at: llvm/tools/dsymutil/DwarfLinker.cpp:2552-2554
+ if (LinkContext.RelocMgr.hasValidRelocs() || LLVM_UNLIKELY(Options.Update))
+ DIECloner(*this, LinkContext.RelocMgr, DIEAlloc, LinkContext.CompileUnits,
+ Options)
----------------
friss wrote:
> Is that just a reformatting? Can you remove it from the patch if so?
This is the result of moving this code out of the loop and having one level less of indentation.
================
Comment at: llvm/tools/dsymutil/DwarfLinker.cpp:2622-2625
+ for (unsigned i = 0, e = NumObjects; i != e; ++i) {
+ AnalyzeLambda(i);
+ CloneLambda(i);
+ }
----------------
friss wrote:
> This loop doesn't have the LinkContext.Objectfile check which was in CloneLambda before and is in CloneAll. Would it be cleaner to pass a LinkContext to the lambdas and leave the logic there?
That check was moved into the `AnalyzeLambda` so it still happens, unless you're talking about something else?
https://reviews.llvm.org/D51618
More information about the llvm-commits
mailing list