------- Comment #3 from mikael dot morin at tele2 dot fr 2008-10-17 12:39 ------- I'm at r141174. But I don't think it is one particular revision. I have seen this for a couple of weeks now. I thought it would be reverted soon. Now, I'm not sure it is a gcc bug. I have the feeling that my system is somehow broken, but I can't figure out where.
Here are the details: $ /usr/local/bin/gfortran -v Utilisation des specs internes. Target: x86_64-unknown-linux-gnu Configuré avec: ../src/configure --enable-languages=fortran --disable-multilib Modèle de thread: posix gcc version 4.4.0 20081016 (experimental) (GCC) $ /usr/local/bin/gcc -O0 -g -c value_4.c $ /usr/local/bin/gfortran -ff2c -w -O0 -g value_4.o value_4.f90 -o value_4 $ ./value_4 zsh: segmentation fault ./value_4 (gdb) bt #0 __muldc3 (a=8, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1834 #1 0x00007fb8c55fb351 in __muldc3 (a=8, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #2 0x00007fb8c55fb351 in __muldc3 (a=8, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #3 0x00007fb8c55fb351 in __muldc3 (a=8, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #4 0x00007fb8c55fb351 in __muldc3 (a=-1, b=2, c=4, d=0) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #5 0x00000000004007f7 in c_to_c__ (retval=0x7fffce012220, c1=0 + 0 * I, c2=0x7fffce012228) at value_4.c:48 #6 0x000000000040092d in value_4 () at value_4.f90:39 #7 0x00000000004009e0 in main (argc=1, argv=0x7fffce012338) at ../../../src/libgfortran/fmain.c:21 #8 0x00007fb8c52a6146 in __libc_start_main () from /lib/libc.so.6 #9 0x0000000000400659 in _start () this is not fortran-related, reduced-testcase: #include <complex.h> int main () { complex float u = __muldc3 (1, 2, 3, 4); return 0; } (gdb) bt #0 __muldc3 (a=10, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1834 #1 0x0000000000400cc1 in __muldc3 (a=10, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #2 0x0000000000400cc1 in __muldc3 (a=10, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #3 0x0000000000400cc1 in __muldc3 (a=10, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #4 0x0000000000400cc1 in __muldc3 (a=10, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #5 0x0000000000400cc1 in __muldc3 (a=10, b=0, c=0, d=1) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #6 0x0000000000400cc1 in __muldc3 (a=1, b=2, c=3, d=4) at ../../../src/libgcc/../gcc/libgcc2.c:1889 #7 0x00000000004004a1 in main () at value_4_f90.c:4 I looked at the offending line, but seen nothing wrong though I have never been playing with C complex. In fact the code looks like directly taken from the C99 standard, so I bet it's correct. I will see if I can find a working revision. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37850