This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/38913] Fortran does not set TYPE_CANONICAL properly



------- Comment #14 from rguenth at gcc dot gnu dot org  2009-06-28 20:43 -------
Another one, reduced from function_module_1.f90:

module M1

INTEGER p

CONTAINS
subroutine AA ()
   implicit NONE
   p = 1
end subroutine
end module

program P1
  USE M1
  implicit none
  p = 0
  call AA ()
  if (p /= 1) call abort
end

where the issue is that p is not properly unified in the use in P1 and AA.
After inlining we see:

p1 ()
{
  integer(kind=4)D.3 p.0D.1516;

<bb 2>:
  pD.1514 = 0;
  pD.1509 = 1;
  p.0D.1516_1 = pD.1514;
  if (p.0D.1516_1 != 1)

so we store to / read from different variables.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38913


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]