Paul,
I am again getting a warning message about inconsistent common block lengths, when using FTN95 ver 5.30 and SLINK ver 1.42. A typical warning is:-
WARNING - Common block 'JUNK/' was previously defined in object file C:\ceasap_review\ceasap_2009\elinpt.obj as size 432 but is now defined as size 688 (C:\ceasap_review\ceasap_2009\beam.obj)
I had previously overcome this warning, by declaring an equivalent variable that was the maximum length used for this common and also declaring the common block in the main program.
A typical declaration looks like:- COMMON /JUNK / TELOAD(9,6) REAL*8 DUMJNK(750), TELOAD EQUIVALENCE ( DUMJNK, TELOAD )
The variable DUMJNK implies the common block is 6,000 bytes long. The number of variables in the common /JUNK/ varies quite a lot; a hang over from small memory days where JUNK was a pool of shared memory for many parts of the program.
It now appears that :-
- the equivalence is not being used to define the common block length, and also
- the initial declaration in the main program module is not being used in SLINK.
This appears to be happening as:-
- variable DUMJNK is not referenced elsewhere in each subroutine and
- in the main program, the variables in the common block are not otherwise referenced.
Is this a cosmetic regression or more serious ?
Implied in the fortran standard is that common blocks are not considered static, and can be undefined if the program goes outside the extent of where the common is defined. Hence there was the need to define all common in the program module. Is this assumption being threatened by the common appearing to not be defined in the program module ?
It does not appear to be happening to the length of other COMMON declarations where trailing variables declared in common blocks are not referenced in the subroutine, only the variable that is used via EQUIVALENCE, to fudge the defined length of the common.
John