[Bug tree-optimization/38985] New: [4.2/4.3/4.4 Regression] missing constraints for pointers accessed directly via their address
Andrew Thomas Pinski
pinskia@gmail.com
Tue Jan 27 11:27:00 GMT 2009
Sent from my iPhone
On Jan 27, 2009, at 3:15 AM, "bonzini at gnu dot org" <gcc-bugzilla@gcc.gnu.org
> wrote:
> This testcase fails:
>
> /* { dg-do compile } */
> /* { dg-options "-O2 -fdump-tree-optimized" } */
>
> int f(int *p)
> {
> int a = *p;
> int *q = (int *)0xDEADBEE0;
> *q = 5;
> return *p == a;
> }
>
> /* { dg-final { scan-tree-dump-times " = \\\*p" 2 "optimized" } } */
> /* { dg-final { scan-tree-dump-not "return 1" "optimized" } } */
> /* { dg-final { cleanup-tree-dump "optimized" } } */
>
>
> Unlike PR38984 it does not require -fno-delete-null-pointer-checks.
Volatile addresses also don't have vops on them. As I mentioned in
the other bug. So this is also a bug for volatiles.
>
>
>
> --
> Summary: [4.2/4.3/4.4 Regression] missing constraints for
> pointers accessed directly via their address
> Product: gcc
> Version: 4.4.0
> Status: UNCONFIRMED
> Keywords: wrong-code
> Severity: normal
> Priority: P3
> Component: tree-optimization
> AssignedTo: unassigned at gcc dot gnu dot org
> ReportedBy: bonzini at gnu dot org
> OtherBugsDependingO 38984
> nThis:
>
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38985
>
More information about the Gcc-bugs
mailing list