GCC not (optimally) exploiting restrict pointers?
Joe Buck
Joe.Buck@synopsys.COM
Wed Dec 15 17:54:00 GMT 2004
On Wed, Dec 15, 2004 at 05:10:14PM -0000, Dave Korn wrote:
> > From: gcc-owner On Behalf Of Richard Guenther
> > So, the value in *a has to be accessed through a exclusively and
> > cannot be accessed through b, regardless of any type qualifiers
> > present on b or not.
>
> .... unless of course b was derived from a in the function that calls foo(),
> perhaps?
Nope. The whole point of restrict is that you're making a promise to the
compiler that an optimization is safe. If you lie, you lose.
More information about the Gcc
mailing list