gfortran bug?

Steve Kargl sgk@troutmask.apl.washington.edu
Wed Dec 6 21:14:00 GMT 2006


On Wed, Dec 06, 2006 at 09:55:04PM +0100, Daniel Franke wrote:
> On Wednesday 06 December 2006 21:24, Ray Nachlinger wrote:
> $> gfortran-svn -g -Wall ray.f90 && ./a.out
>  T T T T T
>  T T T T T
>  T T T T T
> Segmentation fault

The output is probably going to OS dependent (big vs. little
endian) and compiler dependent.

>   call repeat(.true., len_l, n,   l(1))

The first 2 bytes of the internal representation of .true.
do not need to be the same as the last 2 bytes.  .true.
can be any of the 2**32 bit patterns.

There are other problems such as the above (with consideration
of call by reference) provides the address for the scalar .true.,
which is 4 bytes.  The repeat routine is doing 10 assignments
of 2 bytes each that start with the address of .true..  The
following 16 bytes can be garbage.

__ 
Steve



More information about the Fortran mailing list