[PATCH] D21299: [Codegen Prepare] Swap commutative binops before splitting branch condition.
Balaram Makam via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 13 09:43:48 PDT 2016
bmakam created this revision.
bmakam added reviewers: jmolloy, majnemer, rengolin, t.p.northover, mcrosier.
bmakam added a subscriber: llvm-commits.
Herald added a subscriber: mcrosier.
We generically canonicalize commutative binary operation nodes so that if
only one operand is a constant, it will be on the RHS. However, if both
operands are comparisons against constants, it is good to move the most
likely taken condition to the RHS if the binary operation is Instruction::And
and move the less likely taken condition to the RHS if the binary operation
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 4890 bytes
Desc: not available
More information about the llvm-commits