Gentoo Archives: gentoo-amd64

From: Frank Peters <frank.peters@×××××××.net>
To: gentoo-amd64@l.g.o
Subject: Re: [gentoo-amd64] Re: GCC-4.5.2 Has Serious Problems
Date: Fri, 01 Jul 2011 00:05:43
In Reply to: [gentoo-amd64] Re: GCC-4.5.2 Has Serious Problems by Nikos Chantziaras
On Fri, 01 Jul 2011 02:44:36 +0300
Nikos Chantziaras <realnc@×××××.de> wrote:

> > > > Your code is buggy, because you're breaking C's aliasing rules. You are > > not allowed to use a different pointer type to dereference a variable of > > a different type. Doing so results in undefined behavior. >
Well, the error occurs only within the loop structure. If I manually "unroll" the loop using the same pointers there is no error when compiled with "O2." IOW, the problem is how the loop is optimized under -O2. Frank Peters


Subject Author
[gentoo-amd64] Re: GCC-4.5.2 Has Serious Problems Nikos Chantziaras <realnc@×××××.de>