Re: c/7661: gcc-3.0 optimization bug on debian GNULinux on x86 with very simple program
> >
> > Changed my mind. After a posting from Linus on dri-devel and a discussion
> > about integer overflow (undefined) in C the following came out:
>
> Is integer overflow behaviour really undefined? If yes (I want it to be yes
> :),
> then, of course, it's the programmer's fault, not the compiler's. If
> defined -
> then the compiler's. :(
>
Signed overflow is undefined per the ANSI C spec. Only unsinged overflow
has a defined behaviour. However, the unsigned case is not handled
properly on x86 either.
c.
Reply to: