Invokes with deopt states on them must have unique landingpads
for gc.relocate placement (see RewriteStatepointsForGC.cpp)
Disable landingpad merging for invokes with deopt states in SimplifyCFG,
to avoid need of undoing this optimization later.
Differential D119266
[SimplifyCFG] Do not merge landingpads for invokes with deopt state. dantrushin on Feb 8 2022, 10:55 AM. Authored by
Details
Invokes with deopt states on them must have unique landingpads Disable landingpad merging for invokes with deopt states in SimplifyCFG,
Diff Detail
Unit Tests
Event TimelineComment Actions I'm not sure i understand why this is required. Going through all the invokes
Comment Actions I want to avoid doing optimization which I will undo later.
Comment Actions Hot take: then the deopt is simply misdesigned. More realistically, then we need to add the opposite transform into simplifycfg. Comment Actions Reading through the review, I see what look like two related issues.
I'd also think this would be really easy to do in RS4GC as we already have all the utilities for splitting edges. Assuming there's not a deeper semantic issue I'm missing on first glance, I'd strongly prefer fixing RS4GC.
Comment Actions RS4GC knows how to split edges. so it can do it. As for opt blowup I mentioned, it is not infinite loop, but an IR produced by repeatable application of above simplifyCFG + LoopSimplify. |
Why is only the first predecessor checked?