------- Comment #4 from burnus at gcc dot gnu dot org  2008-03-30 21:18 -------
> Not all. I gave two counter examples: pvf and ifort.

Well at least ifort 9.1, 10.0 and 10.1 on Linux do not use the f2c calling
convention. Neither does NAG f95. But I agree that _ vs __ and different
calling convention make things more difficult, which is why I'm glad that we
have BIND(C).
However, besides the problem you mentioned with unmodifiable libraries there is
the additional problem that many compilers do not support BIND(C), yet.

> gcc makes a difference between built in types and structs with respect to
> function return values (depends on the platform and the
> -fpcc-struct-return/-freg-struct-return switches).

Ugh, this explains why on PPC(?) the initial VALUE gfortran testsuite test
(which used a struct instead of _Complex on the C side) failed; on x86/x86-64
it worked. I thought it was only about alignment.


-- 


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

Reply via email to