> I have a problem using the shift operator, maybe a bug (ok, a bug or i'm > wrong about shift operator)
You are wrong about the shift operator. This is a bug in your code, not a gcc bug. Shift operators are only defined for non-negative shifts counts less than the size of the value being shifted. This is a practical necessity because hardware varies greatly on how it treats out of range shifts. Paul