ruiu added a comment. Do you really need this much change? I expected something smaller than this. I mean, I thought what we need to do is to just pass a list of symbols which LTO should keep. https://reviews.llvm.org/D33621