[JumpThreading] Look through freeze in getPredicateAt() fold
This code is valid for any icmp, so we can safely look through a freeze when trying to find one. A caveat here is that replaceFoldableUses() may not end up replacing any uses in this case. It might make sense to use the freeze as the context instruction (rather than the terminator) if there is a freeze, to ensure that it always gets folded. This would require some changes to how replaceFoldedUses() works though, as it currently assumes that the value is valid at the end of the block.
Loading
Please sign in to comment