[PATCH] D25096: [RS4GC] New pass to remove gc.relocates added by RS4GC
Anna Thomas via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 21 11:32:56 PDT 2016
anna marked 6 inline comments as done.
anna added inline comments.
Comment at: lib/Transforms/Utils/StripGCRelocates.cpp:60
+ // are removed by a following instcombine pass.
+ if (!isStatepoint(GCRel->getOperand(0)))
> Hm -- why is it okay for _instcombine_ to remove the relocates hanging off of landingpads? In `@test3`, I suspect _instcombine_ is removing these because they aren't used, if they had real uses the landingpad relocates would still be around.
> Also, if you avoid adding these landingpad gc relocates to the `GCRelocates` vector then instead of tracking `Changed`, you could just `return !GCRelocates.empty();`.
That's right. I've updated the comment as well, and avoid tracking `Changed`.
More information about the llvm-commits