[Bug optimization/15256] New: [tree-ssa] Optimize manual bitfield manipilation.

Segher Boessenkool segher@kernel.crashing.org
Tue May 18 22:56:00 GMT 2004


The generic rule is

X | (Y ^ Z) == (X | Y) ^ Z      if X & (Y ^ Z) == 0

(because then it is just X ^ Y ^ Z -- dunno if you want to go
that far -- but that sure would be nice).

Segher

(everything should be canonicalized to (n)ands (and maybe xors)...
or == doubt == wrong).



More information about the Gcc-bugs mailing list