FORCHECK can analyse separate program units, a set of program units and an entire program. FORCHECK first analyses the individual program units. Then it constructs a call-tree and a module dependency tree. Subsequently the consistency of the set of analysed program units or the entire program is verified. Below you can read what FORCHECK actually does in each of these analyses phases.
During the program-unit analysis Forcheck verifies the syntax as precisely as possible during static analysis. FORCHECK:
- performs full syntax and type-checking
- flags unused, unreferenced and undefined objects
- verifies constructs
- indicates truncation and loss of precision
- compares argument lists
- verifies EQUIVALENCE lists and accounts for the definition status
- detects extension of common blocks through EQUIVALENCE
- validates compliance to the Fortran standard in effect
- flags depricated and obsolescent syntax
- supports many Fortran extensions of all popular compilers
- no limit to the number of source lines or subprograms
Forcheck signals more programming flaws than most compilers do, such as unreferenced items, illegal usage of data types, undefined variables, loss of precision, transfer of control into a construct. When applying the "rigorous" option Forcheck additionally warns for potentially dangerous and less portable constructs. You can tune Forcheck to accept specific Fortran extensions.
FORCHECK can create a call tree of all referenced subprograms. Modules containing unsaved public data and unsaved common blocks which are not declared in the main program or in the root of its referencing program units are reported. Possible recursive references are flagged.
Global program analysis
In the global program analysis FORCHECK verifies the references of all subprograms with its argument lists, common blocks, modules and include files.
- Verification of subprogram references
FORCHECK verifies the consistency of the references to subroutines and functions for subprogram type and function characteristics.
- Verification of argument lists
Besides inspection of the number of arguments and argument characteristics, Forcheck finds out, if possible, if an argument is an input, output or input/output argument. You're informed if an actual argument is a constant, expression, do-loop variable, or occurs more than once in the actual argument list, while a new value is assigned to the dummy argument in the subprogram. Forcheck also detects if the actual array or character datum is shorter than the dummy. Moreover, if a dummy argument is apparently an input argument, the actual argument must have been defined.
- Detection of recursive I/O and recursive subprogram references
FORCHECK detects recursive I/O attemps and recursive subprogram references.
- Consistency of common blocks
The consistency of common blocks is verified for data type and length. If the number or characteristics of the objects in the various occurrences of a common block differ, you will be informed. When analyzing the entire program Forcheck flags unreferenced and undefined common-block objects.
- Verification of public module variables and types
When analyzing the entire program Forcheck flags unreferenced, undefined, not allocated and not associated public module variables and unused types.
- Consistent usage of include files
FORCHECK verifies if common blocks are consistently included from the same include files.
During the global program analysis FORCHECK can compose global cross-reference listings of all global items. This includes subprograms, common blocks, modules, include files, i/o units. Even individual common-block objects, public module variables and types can be cross-referenced.
|previous page||top page|