Anyone knowlegable about valgrind ? Was: Re: g77 and valgrind error?

Toon Moene toon@moene.indiv.nluug.nl
Fri Aug 6 20:57:00 GMT 2004


bvds@bvds.geneva.edu wrote:
> I am using valgrind on a g77 program and am getting
> some peculiar results:
> 
> Cccccccccccccccccccccccccccccccccccccccccc
>       program memty
>       integer i
>       i=360
>       call fsub(i)
>       end
> C
>       subroutine fsub(i)
>       integer i
>       double complex x(i,i)
>       x(i,i)=complex(0D0,0D0)
>       end
> Ccccccccccccccccccccccccccccccccccccccccc
> 
> Valgrind gives an error of the form:

I do not know anything about valgrind, but the Fortran code is perfectly 
OK.  It uses an automatic array x in subroutine fsub that is dimensioned 
using the dummy argument i, which is an extension of Fortran 77, but 
allowed in Fortran 90 and supported by g77.

I tried your code using g77-3.3.4 as supplied by Debian on their testing 
platform (up-to-date as of Sunday 1/8/2004) and it performs perfectly.

I'm afraid someone else has to help you here (that's why I changed the 
subject).

Cheers,

-- 
Toon Moene - mailto:toon@moene.indiv.nluug.nl - phoneto: +31 346 214290
Saturnushof 14, 3738 XG  Maartensdijk, The Netherlands
Maintainer, GNU Fortran 77: http://gcc.gnu.org/onlinedocs/g77_news.html
A maintainer of GNU Fortran 95: http://gcc.gnu.org/fortran/



More information about the Gcc-help mailing list