HLASM Language Reference
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Address constant—V

HLASM Language Reference
SC26-4940-06

The V-type constant reserves storage for the address of a location in a control section that is defined in another source module. Use the V-type address constant only to branch to an external address, because link-time processing might cause the branch to be indirect (for example, an assisted linkage in an overlay module). That is, the resolved address in a V-type address constant might not contain the address of the referenced symbol. In contrast, to refer to external data, use an A-type address constant whose nominal value specifies an external symbol identified by an EXTRN instruction.

Because you specify a symbol in a V-type address constant, the assembler assumes that it is an external symbol. A value of zero is assembled into the space reserved for the V-type constant; the correct relocated value of the address is inserted into this space by the linkage editor before your object program is loaded.

The symbol specified (see  1  in Table 1) in the nominal value subfield does not constitute a definition of the symbol for the source module in which the V-type address constant appears.

The symbol specified in a V-type constant must not represent external data in an overlay program.

Table 1. V address constants
Subfield Value Example Result
1. Duplication factor Allowed    
2. Type V    
3. Type Extension D    
4. Program type Allowed    

5. Modifiers
   Implicit length:
   (length modifier
   not present)

 
V-type: 4 bytes
VD-type: 8 bytes

VL4(ExtSym)  

   Alignment:
   (Length modifier
   not present)

V-type: Fullword
VD-type: Doubleword

   
Range for length:

V-type: 4 or 3 only
VD-type: 3, 4, or 8
(no bit length)

   
Range for scale: Not allowed    
Range for exponent: Not allowed    

6. Nominal value
   Represented by:

 
A single external
symbol

 
DC  V(MODA)  1 
DC  V(EXTADR)  1 

 
Enclosed by: Parentheses    
Exponent allowed: No    

   Number of values
   per operand:

Multiple    
Padding: None    

   Truncation of
   assembled value:

Not applicable    
In the following example, 12 bytes are reserved, because there are three symbols. The value of each assembled constant is zero until the program is link-edited.
VCONST   DC              V(SORT,MERGE,CALC)
z/OS only: To specify a list of conditional external symbols to be resolved by the Binder, the following syntax is used:
VCONST DC V(FUNCA:FUNCB:FUNCC)
The Binder will attempt to resolve the external reference to FUNCA. If FUNCA is not available, the Binder attempts to resolve the reference to FUNCB. If FUNCB is not available, FUNCC. Finally, if FUNCC is not available, the external references are flagged as unresolved.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014