This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: tree level aliasing and call clobber
- From: Daniel Berlin <dberlin at dberlin dot org>
- To: Andrew Pinski <pinskia at physics dot uc dot edu>
- Cc: gcc mailing list <gcc at gcc dot gnu dot org>
- Date: Sat, 24 Dec 2005 16:53:32 -0500
- Subject: Re: tree level aliasing and call clobber
- References: <b63b810eda2d6e703872dbfa4145177b@physics.uc.edu>
On Sat, 2005-12-24 at 16:20 -0500, Andrew Pinski wrote:
> I noticed that if I try not to mark a variable as escaping, we don't
> get the function
> call to have V_MAY_DEF for that variable.
Which is correct.
>
> For an example in this Fortran code:
> function i()
> INTEGER :: i
> INTEGER :: t
> call f(t)
> t = 2;
> call g()
> if (t .ne. 2) then
> call abort ()
> end if
> i = t
> end function
>
>
> t cannot escape from the function as the variable is not marked as a
> TARGET.
> Is there a way to mark the function call for f as clobbering t but not
> escaping?
These two statements make no sense together.
Something that cannot escape the function is, by definition, not
clobbered by any calls.