This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: [Bug optimization/15256] New: [tree-ssa] Optimize manual bitfield manipilation.
- From: Segher Boessenkool <segher at kernel dot crashing dot org>
- To: gcc-bugzilla at gcc dot gnu dot org
- Cc: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 18 May 2004 13:44:16 +0200
- Subject: Re: [Bug optimization/15256] New: [tree-ssa] Optimize manual bitfield manipilation.
- References: <20040503080351.15256.kazu@cs.umass.edu>
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).