COMMON requires 4 bytes of padding at start

Janus Weil jaydub66@googlemail.com
Thu Sep 11 11:02:00 GMT 2008


Hi all,

when compiling old F77 code with gfortran, i get lots of warnings of the type:

Warning: COMMON 'foo' at (1) requires 4 bytes of padding at start

A simple test case which triggers this is the following:

implicit none
integer(kind=4) :: n
real(kind=8) :: p
common /foo/ n,p
end

Now I have two questions:

1) Should I take this warning seriously (i.e. does it have any
consequences) or can I simply ignore it?

2) If I choose to ignore it, is there a way to suppress the warning
(without suppressing other warnings)? The trouble for me is that it
shows up *always* (even without -Wall), and the only way I found to
suppress it is to use -w.

Cheers,
Janus



More information about the Fortran mailing list