Why does gfortran not work?

The current versions of gfortran do not work with FoX, the XML library that is included in the distribution. The reason appears to be some compiler bug. gfortran does compile FoX, but causes an error at runtime.

According to Tobias Burnus

It should work with
GCC 4.5.0 20091029 (experimental) [trunk revision 153706]
or later. At least on my x86-64-linux (openSUSE 11.2rc1) all examples
now work and comparing the result with g95 shows the same output (except
for the last digits).

I have compiled with -O3 -ffast-math -march=native -flto (Note
-ffast-math should be only used with care for production runs.)

There were two issues, which are now solved:

a) As written before, there was a GCC 4.4/4.5 regression with regards
to zero-sized arrays in TRANSFER which caused a crash.

b) When invoking pointer-returning generic functions to directly pass
the pointer argument without using an explicit pointer assignment in
between, the wrong pointer address was used as actual argument.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License