[Bug middle-end/46488] [4.5 regression] server/core_filters.c from apache httpd 2.2.17 miscompiled at -O3

jorton at redhat dot com gcc-bugzilla@gcc.gnu.org
Mon Nov 29 12:10:00 GMT 2010


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46488

--- Comment #21 from Joe Orton <jorton at redhat dot com> 2010-11-29 11:38:44 UTC ---
Thanks for the explanation.

(In reply to comment #20)
> > Why specifically does this result in an C99 aliasing violation anyway?  The
> > pointers to which this macro evaluates are never dereferenced, only compared
> > for equality.
> 
> I think they are dereferenced by the macro APR_RING_{NEXT,PREV} in some cases.

The pointers are constructed explicitly to never be dereferenced, only compared
for equality; if a dereference exists it would be a bug, but I don't see one.

In the absence of such a smoking gun, can an C99 aliasing issue occur merely in
handling pointer equivalence?



More information about the Gcc-bugs mailing list