This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: Strange error
- From: giacomo `giotti` mariani <giacomomariani at yahoo dot it>
- To: fortran at gcc dot gnu dot org
- Date: Tue, 28 Jul 2009 18:22:03 +0200
- Subject: Re: Strange error
Thank you very much for all your quick answers.
I've found my error: a matmul with an unallocated matrix (thank to the
corefile, reached thank to ulimit -c unlimited).
I've reproduced the error (which persist with gfortran 4.4.1.20090721 on
freebsd) in the next code:
$ cat prova.f90
module quelche
real (8), allocatable, dimension (:,:) :: a
end module quelche
program provaalooc
use quelche
real (8), dimension (2) :: v1,v2
v1=[1.0d0,2.0d0]
v2=matmul(a,v1)
write (*,*) v2
end program
which, compiled with:
$gfortran44 -ffpe-trap=invalid,overflow,zero,underflow -Wall -pedantic
-Wextra -Werror -Wtabs -Wno-unused -ffixed-line-length-132
-fbounds-check -O0 -g3 prova.f90 -o Prova
gives:
$./Prova
Assertion failed: (GFC_DESCRIPTOR_RANK (a) == 2 || GFC_DESCRIPTOR_RANK
(b) == 2), function matmul_r8, file
../.././..//gcc-4.3-20090419/libgfortran/generated/matmul_r8.c, line 96.
Abort (core dumped)
Is it a bug or the right behavior of the compiler?
Thank you very much
Giacomo
--
/_\ The ASCII Per comunicare in modo riservato:
\_/ Ribbon Campaign gpg --keyserver pool.sks-keyservers.net \
X Against HTML --recv-keys 20611EAD
/_\ Email!
----------------------------------------------------------------------
Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html