NEW 152367
BitXor(Comparison, 1) where canBeInternal(Comparison) should be generated as an inverted comparison
https://bugs.webkit.org/show_bug.cgi?id=152367
Summary BitXor(Comparison, 1) where canBeInternal(Comparison) should be generated as ...
Filip Pizlo
Reported 2015-12-16 16:23:33 PST
This is relevant for float comparisons. Some of them will start as something like: Equal(EqualOrUnordered(left, right), 0) Then we will canonicalize this to: BitXor(EqualOrUnordered(left, right), 1) But then the code generator will emit the BitXor separately, so we'll have some nasty code to perform the comparison followed by a xor. That's goofy. Note that this problem goes away if we also do branch fusion. For example both of these are fine: Branch(BitXor(EqualOrUnordered(left, right), 1)) Check(BitXor(EqualOrUnordered(left, right), 1)) We won't see the Branch case because of strength reduction, but we will see the Check case, and that's OK - we'll chew through the BitXor.
Attachments
Note You need to log in before you can comment on or make changes to this bug.