This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/29145] unsafe use of restrict qualifier
- From: "djg at cray dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 26 Jan 2007 21:09:36 -0000
- Subject: [Bug tree-optimization/29145] unsafe use of restrict qualifier
- References: <bug-29145-12972@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #10 from djg at cray dot com 2007-01-26 21:09 -------
(In reply to comment #8)
> I'm testing this patch, that makes us more conservative, and concludes that two
> pointers don't overlap only if both are "based on" restricted pointers, with
> "based on" trivially implemented as the pointer used in the reference itself.
> In addition, we check that the declarations of both pointers are in the
> parameter list of the same function (to be safe w.r.t the scope of the pointer
> declarations). Looks like this should be safe enough?
One thing I can think of that this description misses is that the two pointers
must be based-on *different* restrict-qualified pointers, unless that case is
already handled elsewhere.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29145