Hi all,
Just new to the forum, but I think it's great that these forums exist!
I'm running MAC OS X 10.6 on a macbook pro. I just installed gfortran version 4.8 (which was probably the latest one, because it was chosen by default) through the homebrew 'package manager' on this macbook. I used to have gfortran version 4.3 on my older computer and was able to compile. I compile using a make-file, and most dependencies (modules) of the main program compile without complication. The following module, however, gives me an error:
where the error is:
gfortran -c SRC/Timers.F90 -g -Wall -fbounds-check -fbacktrace -J./MOD -o OBJ/Timers.o
f951: internal compiler error: Illegal instruction
f951: internal compiler error: Abort trap
gfortran: internal compiler error: Abort trap (program f951)
make: *** [OBJ/Timers.o] Abort trap
After some checking it turns out the compiles stumbles over the following snippet:
Hence it seems like one is not allowed to use such floating point constructs in the code??
Anyone familiar with this problem? And how to fix it? Is there a flag I can set, such that it actually swallows this or do I need to change the code (and other modules/routines having similar constructs?).
Thanks in advance!
Cheers,
Kees
Just new to the forum, but I think it's great that these forums exist!
I'm running MAC OS X 10.6 on a macbook pro. I just installed gfortran version 4.8 (which was probably the latest one, because it was chosen by default) through the homebrew 'package manager' on this macbook. I used to have gfortran version 4.3 on my older computer and was able to compile. I compile using a make-file, and most dependencies (modules) of the main program compile without complication. The following module, however, gives me an error:
Code:
module timers
implicit none
public
integer, private :: time_array(8)
contains
!----------------------------------------------------------------
subroutine start_timer(time)
real :: time
call date_and_time(values=time_array)
!time = time_array(5)*3600. + time_array(6)*60. + time_array(7) + 0.001*time_array(8)
time=time_array(5)*3600+time_array(6)*60+time_array(7)+ 0.001*time_array(8)
write(0,*)time_array(5)
!write(0,*)time
end subroutine start_timer
!----------------------------------------------------------------
subroutine end_timer(ftime,stime)
real :: ftime,stime
call date_and_time(values=time_array)
!ftime = (-1.*stime+(time_array (5)*3600. + time_array(6)*60. + time_array(7) + 0.001*time_array(8)))
!write(0,*)ftime,stime
end subroutine end_timer
!----------------------------------------------------------------
end module timers
where the error is:
gfortran -c SRC/Timers.F90 -g -Wall -fbounds-check -fbacktrace -J./MOD -o OBJ/Timers.o
f951: internal compiler error: Illegal instruction
f951: internal compiler error: Abort trap
gfortran: internal compiler error: Abort trap (program f951)
make: *** [OBJ/Timers.o] Abort trap
After some checking it turns out the compiles stumbles over the following snippet:
Code:
0.001*time_array(8)
Hence it seems like one is not allowed to use such floating point constructs in the code??
Anyone familiar with this problem? And how to fix it? Is there a flag I can set, such that it actually swallows this or do I need to change the code (and other modules/routines having similar constructs?).
Thanks in advance!
Cheers,
Kees