(Re)allocation of allocatable arrays on assignment - F2003

Paul Richard Thomas paul.richard.thomas@gmail.com
Sat Oct 23 18:45:00 GMT 2010


Hi Dominique,

Thanks!  It's already fixed - as you surmised by fixing the problem
with the test.

I am just now running the Polyhedron suite with the patch in place.

Cheers

Paul

On Sat, Oct 23, 2010 at 3:51 PM, Dominique Dhumieres <dominiq@lps.ens.fr> wrote:
> Paul,
>
> Withe the latest patch, rnflow.f90 gives an ICE: reduced test
>
> subroutine evlrnf (nclsm)
> implicit none
> integer, intent (in)            :: nclsm
> real, allocatable, dimension (:,:) :: dtrsft
> real, allocatable, dimension (:)   :: vwrk1t
> allocate (dtrsft (1:nclsm,1:nclsm))
> dtrsft = 0.0
> allocate (vwrk1t (1:nclsm))
>   vwrk1t = dtrsft (nclsm, 1:nclsm)
> deallocate (dtrsft)
> deallocate (vwrk1t)
> end subroutine evlrnf
>
> [macbook] lin/test% gfc -c evlrnf_red.f90
> evlrnf_red.f90: In function 'evlrnf':
> evlrnf_red.f90:9:0: internal compiler error: in fold_binary_loc, at fold-const.c:9411
>
> This is the same location than the ICE I see after removing the comment
> in your test.
>
> Also with -O2 and above valgrind complains with the executable for the
> original test:
>
> ==13063== Conditional jump or move depends on uninitialised value(s)
> ==13063==    at 0x100001AA9: MAIN__ (in ./a.out)
>
> Otherwise the failures reported previously have been fixed.
>
> Thanks,
>
> Dominique
>



-- 
The knack of flying is learning how to throw yourself at the ground and miss.
       --Hitchhikers Guide to the Galaxy



More information about the Fortran mailing list