IBM
Contents Index Previous Next



SDL Cross-References


The Analyzer has the ability to produce listings of SDL entities and references to these definitions. In one file, all definitions of entities in an SDL system will be gathered, along with cross references to these entities. Entities mainly used to indicate structure (such as system, block, substructure, process, procedure, and service), as well as entities defining objects (such as signals, variables and sorts) will be considered as definitions.

The file, which is described further below, is a plain text file.

Note:

The SDL Suite has support for graphical presentation of a cross-reference file, using an SDL-like graphical notation. To achieve this, you can use the Index Viewer. See The SDL Index Viewer.

Definitions and Cross References Files

The file name will be <unitname>.xrf for the cross references file, where <unitname> is the name of the SDL unit selected for analysis. Alternatively, the file name is to be supplied by the user when running the Analyzer from the Organizer.

If an SDL system is selected for analysis, all definitions and cross references are generated; while if case of a non-SDL system unit, definitions and cross references in the following units are generated:

The following entities will be part of the files:

ACTIVE

ATLEAST

BLOCK

BLOCK SUBSTRUCTURE

CHANNEL

CHANNEL SUBSTRUCTURE

CONNECTION

CONTINUOUS SIGNAL

CREATE

DCL

DECISION

ENABLING CONDITION

EXPORT

EXPORTED_PROCEDURE

FORMAL PARAMETER

FPAR

GATE

GENERATOR

IMPORT

IMPORTED

IMPORTED VARIABLE

IN-CONNECTOR

INHERITS

INPUT

INSTANTIATION

JOIN

LITERAL

NEWTYPE

NEXTSTATE

NUMBER OF INSTANCES

OPERATOR

OUT-CONNECTOR

OUTPUT

PACKAGE_INTERFACE

PROCEDURE

PROCEDURE CALL

PROCEDURE PARAMETERS

PROCESS

PROCESS PARAMETERS

REMOTE PROCEDURE

REMOTE VARIABLE

RESET

SAVE

SERVICE

SET

SIGNAL

SIGNAL ROUTE

SIGNALLIST

SIGNALROUTE

SIGNALSET

SORT

STATE

STATE_LIST

SYNONYM

SYNTYPE

SYSTEM

TASK

TIMER

TRANSITION OPTION

USE

VARIABLE

VIEW

VIEWED


Note:

No cross references will be generated for the predefined data types (INTEGER, NATURAL, CHARACTER, CHARSTRING, BOOLEAN, REAL, TIME, DURATION, PID) or for the predefined generators (ARRAY, STRING, POWERSET) as well as LITERALS and OPERATORS that are not part of the list above.

Syntax of Files

For each definition of any kind mentioned above the following information is generated:

ScopeLevel EntityType EntityName Reference

Explanation

For each entity used to indicate structure (system, block, substructure, process, procedure, service) there is a header consisting of three additional lines, which should be considered as a comment to increase the readability.

Example 348 : Reference in Analyzer Error

2  SIGNAL Bump \
SDTREF(SDL,/usr/tom/demongame.ssy(1),122(40,30),3)

Order of Definitions

The definitions are generated in pre-order (prefix walk in the tree formed by the definitions). This means that an entity is always followed by the entities defined within the entity. It also means that an entity at level N is defined in the first entity at level N-1 found when scanning upwards in the file.

Cross References

For each place where an entity is used, information about that cross reference is generated:

Example 349 : Cross References

4  DCL Count \
#SDTREF(SDL,/usr/tom/game.spr(1),179(80,10),2)
     TASK \
#SDTREF(SDL,/usr/tom/game.spr(1),137(30,40),1)
     OUTPUT \
#SDTREF(SDL,/usr/tom/game.spr(1),128(80,55),2)

Cross references consist of a keyword, describing where the reference was found, and the SDL reference. In Example 349, the variable Count is referenced in a task symbol and in an output. All cross references for an entity are placed immediately after the line for the definition.

Note:

Entities used to indicate structure can also have cross references (procedure call, process create).


http://www.ibm.com/rational
Contents Index Previous Next