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


Duplicate literals

HLASM Language Reference
SC26-4940-06

If you specify duplicate literals within the part of the source module that is controlled by an LTORG instruction, only one literal constant is assembled into the pertinent literal pool. This also applies to literals assembled into the literal pool at the end of the first or only control section of a source module that contains no LTORG instructions.

Literals are duplicates only if their specifications are identical, not if the object code assembled happens to be identical.

When two literals specifying identical A-type, Y-type or S-type address constants contain a reference to the value of the location counter (*), both literals are assembled into the literal pool. This is because the value of the location counter might be different in the two literals. Even if the location counter value is the same for both, they are still both assembled into the literal pool.

The following examples show how the assembler stores pairs of literals, if the placement of each pair is controlled by the same LTORG statement.
=X'F0'          Both are
=C'0'           stored

=XL3'0'         Both are
=HL3'0'         stored

=A(*+4)         Both are
=A(*+4)         stored

=X'FFFF'        Identical,
=X'FFFF'        only one copy is stored

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014