------- Comment #3 from jvdelisle at gcc dot gnu dot org  2008-10-07 04:25 
-------
With the following test program I created a file to read useing a write in
place of the read.

program testio
  implicit none
  integer      :: i, k
  real         :: x
  real(kind=8) :: y
  complex      :: c
  character(27) :: a
  integer, parameter :: n = 1000000
  x = 3.14159
  y = exp(1.0)
  c = complex(x,y)
  a = "abcdefghijklmnopqrstuvwxyz1"
  open(10,form="formatted")
  do i=1,n
    read(10, '(i10,1x,f7.5,1x,f12.10,1x,a27,1x,2f12.8)') k, x, y, a, c
  end do
  close(10, status="keep")
end program testio


With 4.4:

$ time ./a.out 

real    0m9.307s
user    0m9.238s
sys     0m0.063s

With 4.3:

$ time ./a.out 

real    0m8.167s
user    0m8.113s
sys     0m0.034s

That's about 13% slowdown in formatted reads.


-- 


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

Reply via email to