fold-const.c
377 KB
-
re PR middle-end/24427 (missing optimization opportunity with binary operators) · 840992bd
PR middle-end/24427 * fold-const.c (fold_binary) <BIT_IOR_EXPR>: Transform (X&C1)|C2 into (X,C2) if C1 is a subset of the bits of C2. Transform (X&C1)|C2 into X|C2 if C1|C2 == ~0. Canonicalize (X&C1)|C2 as (X&(C1&~C2))|C2. <BIT_AND_EXPR>: Canonicalize (X|C1)&C2 as (X&C2)|(C1&C2). * gcc.dg/tree-ssa/andor-1.c: New test case. From-SVN: r110918
Roger Sayle committed