[Bug tree-optimization/38826] points-to result wrong for reads from call-clobbered vars
rguenth at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Tue Jan 13 12:35:00 GMT 2009
------- Comment #1 from rguenth at gcc dot gnu dot org 2009-01-13 12:34 -------
It is interesting to see how taking the address of &s.q makes it a pointer
variable. The fundamental issue seems to be that eliminating non-pointers
and their edges conflicts with field-sensitive analysis.
Consider
struct S { int *p; int *q; };
void foo (struct S **);
int *bar (int b)
{
struct S s;
struct S *p = &s;
foo (&p);
return s.q;
}
to see that just generating extra ADDRESSOF constraints for call arguments
will not fix the issue.
Not only we will need to avoid eliminating non-pointers / edges if any of a
variables sub-field has got a proper pointer label, unifying them (they
still have pointer label 0) is also wrong.
Danny, any idea where/how to fix this?
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dberlin at gcc dot gnu dot
| |org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38826
More information about the Gcc-bugs
mailing list