[StripDeadDebugInfo] Drop dead CUs entirely
authorKeno Fischer <keno@alumni.harvard.edu>
Thu, 6 Apr 2017 19:26:22 +0000 (19:26 +0000)
committerKeno Fischer <keno@alumni.harvard.edu>
Thu, 6 Apr 2017 19:26:22 +0000 (19:26 +0000)
commitbacc64b5fae4b8716a6f0313927932182d0d815b
tree7fff6cf6f4e8284d2532e974fbc350e3b1f7c261
parentb122ed918195b46c2aa860c3cf9c6e7371ea03e8
[StripDeadDebugInfo] Drop dead CUs entirely

Summary:
Prior to this while it would delete the dead DIGlobalVariables, it would
leave dead DICompileUnits and everything referenced therefrom. For a bit
bitcode file with thousands of compile units those dead nodes easily
outnumbered the real ones. Clean that up.

Reviewed By: aprantl
Differential Revision: https://reviews.llvm.org/D31720

llvm-svn: 299692
llvm/lib/Transforms/IPO/StripSymbols.cpp
llvm/test/Transforms/StripSymbols/strip-dead-debug-info.ll