• Aucun résultat trouvé

Generation of Relocatable Output (ROR$) Purpose:

Dans le document Volume 4 System Utility Programs (Page 101-105)

I IOF I BEC

2.5.8. Relocatilble Output Routine (ROR)

2.5.8.2. Generation of Relocatable Output (ROR$) Purpose:

Formats relocatable items and outputs text to the relocatable element.

Format:

L,U AO,item addr LMJ X 11 ,ROR$

error return normal return Parameters:

item addr - Address of item.

Description:

UPDATE LEVEL

2-90

PAGE

ROR is called for every text word (e.g., instruction or data word) to be inserted in the relocatable element. For each call the user will furnish the text word and its relocation information in an item.

The minimum length of the item is three words; however, it may be larger. Any relocation of a text word, other than a simple relocation of the right address under the same location counter that applies to the text word, must be handled through special relocation items. Any number of special relocation items may be appended to the item. The ROR item format is shown in Table 2-14.

o

n

1

2

f

~d~

n-1

Word 0 n

r

Tsble 2- 14. ROR Item

I

not used

I

I

I

r

•.

text word

I

zero

I

Ic

I

address

special items

~-j /"

special items

item length, including any special relocation items

bits 16 and 17 of a left address field plus ten sign bits, or twelve sign bits for a left half-word field.

bits 16 and 17 of a right address field plus ten sign bits, or twelve sign bits for a right half-word field.

4144.41

L

SPERRY UNIVAC 1100 Series Executive 2-91

~~_____ _ ________ S_y~s_t_e_m __ U_t_il_it~y_P_r_o~g~r_a_m_s ______________________ ~u_~_A_n __ ~ __ l ____ ~M_G_E ____ _

Word '1

text word Word

:l

f bit 32

=

1, right address (bits 0-15) relocatable bit 33 = 1, left address (bits 18-34) relocatable.

Ic contains the location counter the text word is under and by which relocation specified by f takes place. May be overridden by a type 013 special item.

address address of the text word.

Words

3,

4, etc:. may contain special relocation items.

The Location Counter Relocation Item, type 011, format is:

35 30 24 18 12 0

~_1 -1--1

_011

--L-1_--L.-. 1

_ r

--.J..I _ _

IC

_I

This itEtm is used when relocation by a location counter other than the one specified in 53 of word 2 is de!sired.

the left margin of the field of relocation (a bit number in the range 0-35)

r the right margin of the field of relocation (a bit number in the range 0-35, with r less

~han or equal to I)

Ic iocation counter number; a signed 12 bit integer. The starting address of the location counter is added if Ic is positive or subtracteti if Ic is negative.

The External Reference Item (two words), type 012, format is:

35 30 24 18 12

o

~

2 sequence number of the external reference in the preamble 012 I r signs This it.em is used when relocation by the value of an externally defined symbol is desired.

r

the left margin of the field of relocation the right margin of the field of relocation

12 bits of all zeros or ones, depending on whether the external reference is to be added or subtracted, respectively.

4144.41 UP-HUMIER

SPERRY UNIVAC 1100 Serle. Executive System Utility Programs

The Large Location Counter Item, type 013, format is:

35 30 24

01 013 not used

UPDATE LEVEL

12

Ie

If this special item is used, it must be the first special item appended to the item.

2-92 PAGE

o

This item overrides the Ie in word 2 of the item. This allows location counters greater than 63.

Ie - location counter number the text is to be under.

ROR formats the text words and the relocation information into blocks and outputs the blocks to the relocatable element. Blocks contain one or more word groups. Word groups represent text words that are allocated to sequential memory cells. Each word group consists of two separate parts; the relocation information and the text words themselves.

The relocation information for the word groups starts at the beginning of the block and the text words are at the end of the block. Word groups for relocatable information format is:

35

o

relocation information for first word group relocation information for second word group

~~ /' ~~ /'

text words for second word group text words for first word group

The text words are in the inverse order in which they are allocated to memory cells.

The relocation information for any word group is a stream of bits. The length of the stream is variable.

The first bit of a stream is always the left-most bit of a word.

4144.41

I

SPERRY UNIVAC 1100 Serle. executive 2-93

~~~~

______________________

S~y_s_te_m

____

U_tl_'li_tY~P_r_o_g_ra_m

___ s ________________________

~u_~_A_n_~

___ L _____

~'_A_G_E

____ _

The str.eam of bits contain both fixed and variable length fields, the format is:

36 33 17 8 6

o

1

°

addr wc L gc

gc

I

bit stream

Bits 34-35 an indicator which signals a new word group

addr a fixed field containing the relative starting address of the first text word in the group.

we:

L gc

a fixed field containing the number of text words in the word group.

a fixed field indicating which location counter to use.

an optional variable length field indicating a location counter. If L is 3 then this field is present. The field length is the K-bit count.

The rest of the bit stream is variable length and contains the relocation bits for the text words.

The error return is taken when:

1. an 1/0 error occurs, A 1 will contain the status or

2. an internal inconsistency occurred in AOA, A 1 will be zero.

2.5.8.3:. End Relocatable Output Routine (EROR$)

PurpOSEt:

Termineltes AOA after the last text word has been processed.

Format:

L AO,(transfer addr,transfer addr Ic) LMJ X 11 ,EAOA$

error return normal return NOTE:

If no tnJnsfer location is specified (element may be a subroutine) then AO must be negative.

Parameters:

Tn1lnsfer adldr is the location of the first instruction to be executed in the main program.

Tri1lnsfer adldr Ie is the location counter to which the address applies.

4144.41

UP-NUMBEA

Description:

SPERRY UNIVAC 1100 Serie. Executive

System Utility Programs UPDATE LEVel

2-94

PAGE

EROR outputs the last block built by ROR and generates a transfer image. The transfer image is a special word group.

The EROR format is:

35 33 17 8 6

o

1 1 transfer address zero L gc

gc

I

EROR always generates a separate block for the word group:

The error return is taken when an I/O error occurs. The status is returned in A 1.

2.5.8.4. Table Write Subroutine (TBLWR$)

Dans le document Volume 4 System Utility Programs (Page 101-105)