DO-loop and WRITE strange behaviour

Paul Thomas paulthomas2@wanadoo.fr
Sun Jul 3 20:11:00 GMT 2005


I see very much the same as you, Pedro, using Redhat 9/ GNU Fortran 95 
(GCC 4.1.0 20050703 (experimental)).  4.0 is the same.

I do not see a gap but, rather, a large number of nulls up to line 631, 
whereupon the rest is printed correctly.  Strangely with formatted io, 
the correct output starts at 684.

 gfortran]# /gcc-4.1/bin/gfortran -v simple.f90
Driving: /gcc-4.1/bin/gfortran -v simple.f90 -lgfortranbegin -lgfortran 
-lm -shared-libgcc
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with: ../gcc/configure --prefix=/gcc-4.1 
--enable-languages=c,f95 --with-gmp=/usr/local --with-mpfr=/usr/local : 
(reconfigured) ../gcc/configure --prefix=/gcc-4.1 --with-gmp=/usr/local 
--with-mpfr=/usr/local --enable-languages=c,f95 --no-create --no-recursion
Thread model: posix
gcc version 4.1.0 20050703 (experimental)
 /gcc-4.1/libexec/gcc/i686-pc-linux-gnu/4.1.0/f951 simple.f90 -quiet 
-dumpbase simple.f90 -mtune=pentiumpro -auxbase simple -version -o 
/tmp/ccrXkhhO.s
GNU F95 version 4.1.0 20050703 (experimental) (i686-pc-linux-gnu)
        compiled by GNU C version 4.1.0 20050703 (experimental).
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
 as -V -Qy -o /tmp/ccWXqK9v.o /tmp/ccrXkhhO.s
GNU assembler version 2.13.90.0.18 (i386-redhat-linux) using BFD version 
2.13.90.0.18 20030206
 /gcc-4.1/libexec/gcc/i686-pc-linux-gnu/4.1.0/collect2 --eh-frame-hdr -m 
elf_i386 -dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o 
/usr/lib/crti.o /gcc-4.1/lib/gcc/i686-pc-linux-gnu/4.1.0/crtbegin.o 
-L/gcc-4.1/lib/gcc/i686-pc-linux-gnu/4.1.0 
-L/gcc-4.1/lib/gcc/i686-pc-linux-gnu/4.1.0/../../.. /tmp/ccWXqK9v.o 
-lgfortranbegin -lgfortran -lm -lgcc_s -lgcc -lc -lgcc_s -lgcc 
/gcc-4.1/lib/gcc/i686-pc-linux-gnu/4.1.0/crtend.o /usr/lib/crtn.o

Is it possible that Pedro and I are doing something wrong in our 
environments?  I have taken a look at everything that I can think of and 
cannot see the problem.

Paul T




More information about the Fortran mailing list