As reported by Dominique, http://gcc.gnu.org/ml/fortran/2007-11/msg00105.html Christopher D. Rickett replied: > (3) gfortran.dg/bind_c_coms.f90 which fails because of the warnings: > ld: warning alignment lost in merging tentative definition _f03_com2 > ld: warning alignment lost in merging tentative definition _mycom > ld: warning alignment lost in merging tentative definition _mycom2 > ld: warning alignment lost in merging tentative definition _singl i submitted a patch that fixes the alignment differences for bind(c) commons on OSX back in August (i think), but noone ever reviewed it * * * See the thread starting at http://gcc.gnu.org/ml/fortran/2007-08/msg00138.html and the patch at http://gcc.gnu.org/ml/fortran/2007-08/msg00142.html
I have applied the patch at http://gcc.gnu.org/ml/fortran/2007-08/msg00142.html and the warnings have disappeared without introducing any visible regression (Intel Darwin9.1).
This bug is really annoying, could someone test that the patch in http://gcc.gnu.org/ml/fortran/2007-08/msg00142.html does not break anything on other platforms? If it does not, could it be committed? TIA Dominique
Reviewed and OK. I will commit after regression testing completed.
Patch committed on trunk. 2007-11-23 Christopher D. Rickett <crickett@lanl.gov> * trans-common.c (build_common_decl): Fix the alignment for BIND(C) common blocks.