[PATCH] D122163: [StripDeadDebugInfo] Drop dead CUs
Alexey Bader via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 4 05:41:52 PDT 2022
bader marked 4 inline comments as done.
bader added a comment.
@aprantl, sorry for the delay. I'd like to finish this patch on behalf of @mlychkov.
I've applied all your suggestions. Please, take a look.
================
Comment at: llvm/lib/Transforms/IPO/StripSymbols.cpp:300
+collectCUsWithScope(const DIScope *Scope, std::set<DICompileUnit *> &LiveCUs,
+ SmallPtrSet<const DIScope *, 32> &VisitedScopes) {
+ if (!Scope)
----------------
aprantl wrote:
> This is highly subjective, but to me, 32 seems a bit large for a smallptrset. Did you base that number on any performance measurements?
I reduced 32 -> 8, but I haven't done any performance measurements, so let me know if it sounds reasonable to you.
================
Comment at: llvm/lib/Transforms/IPO/StripSymbols.cpp:338
- LiveGVs.insert(DIG);
-
// Make sure we only visit each global variable only once.
----------------
aprantl wrote:
> This change seems to be unrelated to the above change, and it might be better to discuss it in a separate review. Is this going to drop //all// constant globals?
I removed this part of the patch, so let discuss it in a separate review.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D122163/new/
https://reviews.llvm.org/D122163
More information about the llvm-commits
mailing list