High Level Assembler for z/OS & z/VM & z/VSE. Language Reference (Version 1 Release 6) - page 22

 

  Главная      Manuals     High Level Assembler for z/OS & z/VM & z/VSE. Language Reference (Version 1 Release 6)

 

Search            copyright infringement  

 

 

 

 

 

 

 

 

 

 

 

Content      ..     20      21      22      23     ..

 

 

 

High Level Assembler for z/OS & z/VM & z/VSE. Language Reference (Version 1 Release 6) - page 22

 

 

►►
ACTR arithmetic_expression
►◄
sequence_symbol
sequence_symbol
Is a sequence symbol.
arithmetic_expression
Is an arithmetic expression used to set or reset a conditional assembly branch
counter.
A conditional assembly branch counter has a local scope; its value is decremented
by AGO and successful AIF instructions, and reassigned only by ACTR instructions
that appear within the same scope. Thus, the nesting of macros has no effect on the
setting of branch counters in other scopes. The assembler assigns a branch counter
for open code and for each macro definition. In the absence of an ACTR
instruction, a default value of 4096 is assigned.
Branch counter operations
Within the scope of a branch counter, the following occurs:
1. Each time an AGO or AIF branch is executed, the assembler checks the branch
counter for zero or a negative value.
2. If the count is not zero or negative, it is decremented by one.
3. If the count is zero or negative, the assembler takes one of two actions:
a. If it is processing instructions in open code, the assembler processes the
remainder of the instructions in the source module as comments. Errors
discovered in these instructions during previous passes are flagged.
b. If it is processing instructions inside a macro definition, the assembler
terminates the expansion of that macro definition and processes the next
sequential instruction after the calling macro instruction. If the macro
definition is called by an outer macro instruction, the assembler processes
the next sequential prototype instruction after the call; that is, it continues
processing at the next outer level of nested macros.
The assembler halves the ACTR counter value when it encounters serious syntax
errors in conditional assembly instructions.
ANOP instruction
You can specify a sequence symbol in the name field of an ANOP instruction, and
use the symbol as a label for branching purposes.
The ANOP instruction carries out no operation itself, but you can use it to allow
conditional assembly to resume assembly or conditional generation at an
instruction that does not have a sequence symbol in its name field. For example, if
you wanted to branch to a SETA, SETB, or SETC assignment instruction, which
requires a variable symbol in the name field, you can insert a labeled ANOP
instruction immediately before the assignment instruction. By branching to the
ANOP instruction with an AIF or AGO instruction, you are, in effect, branching to
the assignment instruction.
Chapter 9. How to write conditional assembly instructions
401
►► sequence_symbol ANOP
►◄
sequence_symbol
Is a sequence symbol.
No operation is carried out by an ANOP instruction. Instead, if a branch is taken
to the ANOP instruction, the assembler processes the next sequential instruction.
Example:
MACRO
&NAME
MOVE
&T,&F
LCLC
&TYPE
AIF
(T’&T EQ ’F’).FTYPE
Statement 1
&TYPE
SETC
’E’
Statement 2
.FTYPE
ANOP
Statement 3
&NAME
ST&TYPE
2,SAVEAREA
Statement 4
L&TYPE
2,&F
ST&TYPE
2,&T
L&TYPE
2,SAVEAREA
MEND
Statement 1 determines if the type attribute of the first macro instruction operand
is the letter F. If the type attribute is not the letter F, Statement 2 is the next
statement processed by the assembler. If the type attribute is the letter F, Statement
4 should be processed next. However, because there is a variable symbol (&NAME) in
the name field of Statement 4, the required sequence symbol (.FTYPE) cannot be
placed in the name field. Therefore, an ANOP instruction (Statement 3) must be
placed before Statement 4.
Then, if the type attribute of the first operand is the letter F, the next statement
processed by the assembler is the statement named by sequence symbol .FTYPE.
The value of &TYPE retains its initial null character value because the SETC
instruction is not processed. Because .FTYPE names an ANOP instruction, the next
statement processed by the assembler is Statement 4, the statement following the
ANOP instruction.
402
HLASM V1R6 Language Reference
Chapter 10. MHELP instruction
The MHELP instruction controls a set of trace and dump facilities. MHELP
statements can occur anywhere in open code or in macro definitions. MHELP
options remain in effect until superseded by another MHELP statement.
MHELP options
Options are selected by an absolute expression in the MHELP operand field.
►►
MHELP options
►◄
sequence_symbol
sequence_symbol
Is a sequence symbol.
options
Is the sum of the binary or decimal options. Here is a description of these
options:
MHELP B'1' or MHELP 1, Macro Call Trace:
This option provides a one-line trace listing for each macro call, giving the
name of the called macro, its nested depth, and its &SYSNDX value. The
trace is provided only upon entry into the macro. No trace is provided if
error conditions prevent entry into the macro.
MHELP B'10' or MHELP 2, Macro Branch Trace:
This option provides a one-line trace-listing for each AGO and AIF
conditional assembly branch within a macro. It gives the model statement
numbers of the “branched from” and the “branched to” statements, and
the name of the macro in which the branch occurs. This trace option is
suppressed for library macros.
MHELP B'100' or MHELP 4, Macro AIF Dump:
This option dumps undimensioned SET symbol values from the macro
dictionary immediately before each AIF statement that is encountered.
MHELP B'1000' or MHELP 8, Macro Exit Dump:
This option dumps undimensioned SET symbols from the macro dictionary
|
and records from the AINSERT buffer whenever an MEND or MEXIT
statement is encountered.
MHELP B'10000' or MHELP 16, Macro Entry Dump:
This option dumps parameter values from the macro dictionary
immediately after a macro call is processed.
MHELP B'100000' or MHELP 32, Global Suppression:
This option suppresses global SET symbols in two preceding options,
MHELP 4 and MHELP 8.
MHELP B'1000000' or MHELP 64, Macro Hex Dump:
This option, when used with the Macro AIF dump, the Macro Exit dump,
or the Macro Entry dump, dumps the parameter and SETC symbol values
403
in EBCDIC and hexadecimal formats. Only positional and keyword
parameters are dumped in hexadecimal; system parameters are dumped in
EBCDIC. The full value of SETC variables or parameters is dumped in
hexadecimal.
MHELP B'10000000' or MHELP 128, MHELP Suppression:
This option suppresses all currently active MHELP options.
MHELP Control on &SYSNDX:
The maximum value of the &SYSNDX system variable can be controlled by
the MHELP instruction. The limit is set by specifying a number in the
operand of the MHELP instruction that is not one of the MHELP codes
defined above, and is in the following number ranges:
v
256 to 65535
v Most numbers in the range 65792 to 9999999. Refer to “MHELP operand
mapping” for details.
When the &SYSNDX limit is reached, message ASMA013S ACTR counter
exceeded is issued, and the assembler in effect ignores all further macro
calls.
MHELP operand mapping
The MHELP operand field is mapped into a fullword. The predefined MHELP
codes correspond to the fourth byte of this fullword, while the &SYSNDX limit is
controlled by setting any bit in the third byte to 1. If all bits in the third byte are 0,
then the &SYSNDX limit is not set.
The bit settings for bytes 3 and 4 are shown in Table 62.
Table 62. &SYSNDX Control Bits
Byte
Description
Byte 3 - &SYSNDX control
1
Bit 0 = 1. Value=32768. Limit &SYSNDX to
32768.
.1
Bit 1 = 1. Value=16384. Limit &SYSNDX to
16384.
..1
Bit 2 = 1. Value=8192. Limit &SYSNDX to 8192.
...1
Bit 3 = 1. Value=4096. Limit &SYSNDX to 4096.
.... 1...
Bit 4 = 1. Value=2048. Limit &SYSNDX to 2048.
.... .1..
Bit 5 = 1. Value=1024. Limit &SYSNDX to 1024.
.... ..1.
Bit 6 = 1. Value=512. Limit &SYSNDX to 512.
.... ...1
Bit 7 = 1. Value=256. Limit &SYSNDX to 256.
404
HLASM V1R6 Language Reference
Table 62. &SYSNDX Control Bits (continued)
Byte
Description
Byte 4
1
Bit 0 = 1. Value=128. MHELP Suppression.
.1
Bit 1 = 1. Value=64. Macro Hex Dump.
..1
Bit 2 = 1. Value=32. Global Suppression.
...1
Bit 3 = 1. Value=16. Macro Entry Dump.
.... 1...
Bit 4 = 1. Value=8. Macro Exit Dump.
.... .1..
Bit 5 = 1. Value=4. Macro AIF Dump.
.... ..1.
Bit 6 = 1. Value=2. Macro Branch Trace.
.... ...1
Bit 7 = 1. Value=1. Macro Call Trace.
Note: You can use any combination of bit settings in any byte of the MHELP
fullword to set the limit, provided at least one bit in byte 3 is set. This explains
why not all values 65792 - 9999999 can be used to set the limit. For example, the
number 131123 does not set the &SYSNDX limit because none of the bits in byte 3
are set to 1.
Examples:
MHELP 256
Limit &SYSNDX to 256
MHELP 1
Trace macro calls
MHELP 65536
No effect. No bits in bytes 3,4
MHELP 65792
Limit &SYSNDX to 65792
See Figure 53 on page 406 for more examples.
Combining options
More than one MHELP option, including the limit for &SYSNDX, can be specified
at the same time by combining the option codes in one MHELP operand. For
example, call and branch traces can be invoked by:
MHELP B’11’
MHELP 2+1
MHELP 3
Substitution by variable symbols can also be used.
Chapter 10. MHELP instruction
405
┌────────────────────────┬───────────────────────────────────┬───────────────────────────────────┐
│ MHELP Instruction
MHELP Operand
MHELP Effect
├────────────────────────┼──────────┬────────────────────────┤
│ Decimal
Hexadecimal
├──────┬─────────┬───────┤
│ &SYSNDX │ MHELP │
├────────────────────────┼──────────┼──────┼─────────┼───────┼───────────────────────────────────┤
│ MHELP 4869
4869 │ 0000 │
13
05
│ Macro call trace and AIF dump;
│ &SYSNDX limited to 4869
├────────────────────────┼──────────┼──────┼─────────┼───────┼───────────────────────────────────┤
│ MHELP 65536
65536 │ 0001 │
00
00
│ No effect
├────────────────────────┼──────────┼──────┼─────────┼───────┼───────────────────────────────────┤
│ MHELP 16777232
│ 16777232 │ 0010 │
00
10
│ Macro entry dump
├────────────────────────┼──────────┼──────┼─────────┼───────┼───────────────────────────────────┤
│ MHELP 28678
28678 │ 0000 │
70
06
│ Macro branch trace and AIF dump;
│ &SYSNDX limited to 28678
├────────────────────────┼──────────┼──────┼─────────┼───────┼───────────────────────────────────┤
│ MHELP 256+1
257 │ 0000 │
01
01
│ Macro call trace;
│ &SYSNDX limited to 257
├────────────────────────┼──────────┼──────┼─────────┼───────┼───────────────────────────────────┤
│ MHELP B’11’
3 │ 0000 │
00
03
│ Macro call trace, and
│ macro branch trace
└────────────────────────┴──────────┴──────┴─────────┴───────┴───────────────────────────────────┘
Figure 53. MHELP control on &SYSNDX
406
HLASM V1R6 Language Reference
Appendix A. Assembler instructions
Table 63 summarizes the basic formats of assembler instructions, and Table 64 on
page 410 summarizes assembler statements.
Table 63. Assembler instructions
Operation
Entry
Name Entry
Operand Entry
ACONTROL
A sequence symbol or space
One or more operands, separated by
commas
ACTR
A sequence symbol or space
An arithmetic SETA expression
ADATA
A sequence symbol or space
One-to-four decimal, self-defining terms,
and one character string, separated by
commas.
AEJECT²
A sequence symbol or space
Taken as a remark
AGO
A sequence symbol or space
A sequence symbol
AIF
A sequence symbol or space
A logical expression enclosed in
parentheses, immediately followed by a
sequence symbol
AINSERT
A sequence symbol or space
A character string, followed by FRONT
or BACK
AMODE
Any symbol or space
24, 31, 64, ANY, or ANY31
ALIAS
A symbol
A character string or a hexadecimal
string
ANOP
A sequence symbol or space
Taken as a remark
AREAD²
Any SETC symbol
NOPRINT, NOSTMT, CLOCKB,
CLOCKD, or spaces
ASPACE
A sequence symbol or space
An absolute expression
CATTR (z/OS
A valid program object external
One or more attributes
and CMS)
class name
CCW
Any symbol or space
Four operands, separated by commas
CCW0
Any symbol or space
Four operands, separated by commas
CCW1
Any symbol or space
Four operands, separated by commas
CEJECT
A sequence symbol or space
An absolute expression or space
CNOP
Any symbol or space
Two absolute expressions, separated by
a comma
COM
Any symbol or space
Taken as a remark
COPY
A sequence symbol or space
An ordinary symbol, or, for open code
statements, a variable symbol
CSECT
Any symbol or space
Taken as a remark
CXD
Any symbol or space
Taken as a remark
DC
Any symbol or space
One or more operands, separated by
commas
DROP
A sequence symbol or space
One or more absolute expressions and
symbols, separated by commas, or space
407
Table 63. Assembler instructions (continued)
Operation
Entry
Name Entry
Operand Entry
DS
Any symbol or space
One or more operands, separated by
commas
DSECT
A symbol or space
Taken as a remark
DXD5
A symbol
One or more operands, separated by
commas
EJECT
A sequence symbol or space
Taken as a remark
END
A sequence symbol or space
A relocatable expression or space
ENTRY
A sequence symbol or space
One or more relocatable symbols,
separated by commas
EQU
A variable symbol or an ordinary
One to five operands, separated by
symbol
commas
EXITCTL
A sequence symbol or space
A character-string operand followed by
one to four decimal self-defining terms,
separated by commas
EXTRN
A sequence symbol or space
One or more relocatable symbols,
separated by commas
GBLA
A sequence symbol or space
One or more variable symbols that are
to be used as SET symbols, separated by
commas¹
GBLB
A sequence symbol or space
One or more variable symbols that are
to be used as SET symbols, separated by
commas¹
GBLC
A sequence symbol or space
One or more variable symbols that are
to be used as SET symbols, separated by
commas¹
ICTL
Space
One to three decimal self-defining terms,
separated by commas
ISEQ
A sequence symbol or space
Two decimal self-defining terms,
separated by a comma, or space
LCLA
A sequence symbol or space
One or more variable symbols that are
to be used as SET symbols, separated by
commas¹
LCLB
A sequence symbol or space
One or more variable symbols that are
to be used as SET symbols, separated by
commas¹
LCLC
A sequence symbol or space
One or more variable symbols separated
by commas¹
LOCTR
A variable or ordinary symbol
Space
LTORG
Any symbol or space
Taken as a remark
2,5
MACRO
Space
Taken as a remark
MEND2,5
A sequence symbol or space
Taken as a remark
MEXIT2,5
A sequence symbol or space
Taken as a remark
MHELP
A sequence symbol or space
Absolute expression, binary, or decimal
options
408
HLASM V1R6 Language Reference
Table 63. Assembler instructions (continued)
Operation
Entry
Name Entry
Operand Entry
MNOTE
A sequence symbol or space
A severity code, followed by a comma,
followed by a character string enclosed
in apostrophes. Double-byte characters
are permitted if the DBCS assembler
option is specified.
OPSYN
An ordinary symbol
A machine instruction mnemonic
or an operation code defined by
a previous macro definition or
OPSYN instruction
An operation code mnemonic
Space
ORG
A sequence symbol or space
A relocatable expression or space
POP
A sequence symbol or space
One or more operands, separated by
commas
PRINT
A sequence symbol or space
One or more operands, separated by
commas
PUNCH
A sequence symbol or space
A 1-to-80-character string enclosed in
apostrophes. Double-byte characters are
permitted if the DBCS assembler option
is specified.
PUSH
A sequence symbol or space
One or more operands, separated by
commas
REPRO
A sequence symbol or space
Taken as a remark
RMODE
Any symbol or space
24, 31, 64, or ANY
RSECT
Any symbol or space
Taken as a remark
SETA
A SETA symbol
An arithmetic expression
SETAF
A SETA symbol
An external function module, and the
arithmetic expressions it requires,
separated by commas
SETB
A SETB symbol
A 0 or a 1, or a logical expression
enclosed in parentheses
SETC
A SETC symbol
A type attribute, a character expression,
a substring notation, or a concatenation
of character expressions and substring
notations. Double-byte characters are
permitted if the DBCS assembler option
is specified.
SETCF
A SETC symbol
An external function module, and the
character expressions it requires,
separated by commas
SPACE
A sequence symbol or space
An absolute expression
START
Any symbol or space
An absolute expression or space
TITLE3,5
A 1-to-8-character string, a
A 1-to-100-character string enclosed in
variable symbol, a combination of
apostrophes. Double-byte characters are
character string or variable
permitted if the DBCS assembler option
symbol, a sequence symbol, or
is specified.
space
Appendix A. Assembler instructions
409
Table 63. Assembler instructions (continued)
Operation
Entry
Name Entry
Operand Entry
USING
A symbol or space
Either a single absolute or relocatable
expression or a pair of absolute or
relocatable expressions enclosed in
parentheses and followed by 1 to 16
absolute expressions, separated by
commas, or followed by a relocatable
expression
WXTRN
A sequence symbol or space
One or more relocatable symbols,
separated by commas
XATTR
An external symbol
One or more operands, separated by
(z/OS and
commas
CMS)
Notes:
1. SET symbols can be defined as subscripted SET symbols.
2. Can only be used as part of a macro definition.
3. See “TITLE instruction” on page 219 for a description of the name entry.
4. These instructions start a private section.
5. These instructions can be specified before the first executable control section.
Table 64. Assembler statements
Instruction Entry
Name Entry
Operand Entry
ModelStatements1 and 2
An ordinary symbol, variable
Any combination of characters
symbol, sequence symbol, or a
(including variable symbols)
combination of variable
symbols and other characters
that is equivalent to a symbol,
or space
Prototype Statement³
A symbolic parameter or space
Zero or more operands that
are symbolic parameters
(separated by commas), and
zero or more operands
(separated by commas) of the
form symbolic parameter,
equal sign, optional standard
value
Macro Instruction
An ordinary symbol, a variable
Zero or more positional
Statement³
symbol, or a combination of
operands (separated by
variable symbols and other
commas), and zero or more
characters that is equivalent to
keyword operands (separated
a symbol, any character string,
by commas) of the form
a sequence symbol or space
keyword, equal sign, value
Assembler Language
An ordinary symbol, a variable
Any combination of characters
Statement12
symbol, a sequence symbol, or
(including variable symbols)
a combination of variable
symbols and other characters
that is equivalent to a symbol,
or space
410
HLASM V1R6 Language Reference
Table 64. Assembler statements (continued)
Instruction Entry
Name Entry
Operand Entry
Notes:
1. Variable symbols can be used to generate assembler language mnemonic operation codes
(listed in Chapter 5, “Assembler instruction statements,” on page 99), except COPY,
ICTL, ISEQ, and REPRO. Variable symbols cannot be used in the name and operand
entries of COPY, ICTL, and ISEQ instructions, except for the COPY instruction in open
code, where a variable symbol is allowed for the operand entry.
2. No substitution is done for variables in the line following a REPRO statement.
3. Can only be used as part of a macro definition.
4. When the name field of a macro instruction contains a sequence symbol, the sequence
symbol is not passed as a name field parameter. It only has meaning as a possible
branch target for conditional assembly.
5. Variable symbols appearing in a macro instruction are replaced by their values before the
macro instruction is processed.
Appendix A. Assembler instructions
411
412
HLASM V1R6 Language Reference
Appendix B. Summary of constants
Table 65 and Table 66 on page 414 summarize the types of assembler constants.
Table 65. Summary of constants (part 1 of 2)
Implicit
Length
Length
Modifier
Constant
Type
(Bytes)
Alignment
Range
Specified By
Address
A
4
Fullword
.1 to 4¹
Any expression
Doubleword Address
AD
8
Doubleword
.1 to 8¹
Any expression
Binary
B
As needed
Byte
.1 to 256
Binary digits
Character
C
As needed
Byte
.1 to 256²
Characters
ASCII Character
CA
As needed
Byte
.1 to 256²
Characters
Unicode Character
CU
As needed
Byte
2 to 256³
Characters
Floating Point Hex
D
8
Doubleword
.1 to 8
Decimal digits
Floating Point Hex
DH
8
Doubleword
.12 to 8
Decimal digits
Floating Point Binary
DB
8
Doubleword
.12 to 8
Decimal digits
Floating Point Decimal
DD
8
Doubleword
8
Decimal digits
Floating Point Hex
E
4
Fullword
.1 to 8
Decimal digits
Floating Point Hex
EH
4
Fullword
.12 to 8
Decimal digits
Floating Point Binary
EB
4
Fullword
.9 to 8
Decimal digits
Floating Point Decimal
ED
4
Fullword
4
Decimal digits
Fixed Point
F
4
Fullword
.1 to 8
Decimal digits
Doubleword Fixed
FD
8
Doubleword
.1 to 8
Decimal digits
Point
Graphic (DBCS)
G
As needed
Byte
2 to 256³
DBCS characters
Fixed Point
H
2
Halfword
.1 to 8
Decimal digits
Length
J
4
Fullword
1 to 4
Class name or external DSECT name
Floating Point Hex
L
16
Doubleword
.1 to 16
Decimal digits
Floating Point Hex
LH
16
Doubleword
.12 to 16
Decimal digits
Floating Point Binary
LB
16
Doubleword
.16 to 16
Decimal digits
Floating Point Decimal
LD
16
Doubleword
16
Decimal digits
Floating Point Hex
LQ
16
Quadword
.1 to 16
Decimal digits
Decimal
P
As needed
Byte
.1 to 16
Decimal digits
Offset
Symbol naming a DXD, DSECT, or
Q
4
Fullword
1 to 4
part
QY
3
Halfword
3 only
Address
R
4
Fullword
3, 4
Symbol
Address
One absolute or relocatable expression,
S
2
Halfword
2 only
or two absolute expressions: exp(exp)
SY
3
Halfword
3 only
Address
V
4
Fullword
3, 4
Relocatable symbol
Hexadecimal
X
As needed
Byte
.1 to 256²
Hex digits
413
Table 65. Summary of constants (part 1 of 2) (continued)
Implicit
Length
Length
Modifier
Constant
Type
(Bytes)
Alignment Range
Specified By
Address
Y
2
Halfword
.1 to 2¹
Any expression
Decimal
Z
As needed Byte
.1 to 16
Decimal digits
Notes:
1. Bit length specification permitted with absolute expressions only; relocatable A-type constants, 2, 3, or 4 bytes
only; relocatable Y-type constants, 2 bytes only.
2. In a DS assembler instruction, C-and-X type constants can have length specification to 65535.
3. The length modifier must be a multiple of 2, and can be up to 65534 in a DS assembler instruction.
4. GOFF only.
Table 66. Summary of constants (part 2 of 2)
No. of
Constants
Range for
Range for
Constant
Type
per Operand
Exponents
Scale
Truncation or Padding Side
Address
A
Multiple
Left
Binary
B
Multiple
Left
Character
C
One
Right
ASCII Character
CA
One
Right
Unicode Character
CU
One
Right
Floating Point Hex
D
Multiple
-85 to +75
0 to 13
Right¹
Floating Point Hex
DH
Multiple
-231 to 231-1
0 to 13
Right¹
Floating Point Binary
DB
Multiple
-231 to 231-1
N/A
Right¹
Floating Point Decimal
DD
Multiple
-231 to 231-1
N/A
Floating Point Hex
E
Multiple
-85 to +75
0 to 5
Right¹
Floating Point Hex
EH
Multiple
-231 to 231-1
0 to 5
Right¹
Floating Point Binary
EB
Multiple
-231 to 231-1
N/A
Right¹
Floating Point Decimal
ED
Multiple
-231 to 231-1
N/A
Fixed Point
F
Multiple
-85 to +75
-187 to +346
Left¹
Graphic (DBCS)
G
One
Right
Fixed Point
H
Multiple
-85 to +15
-187 to +346
Left¹
Length
J
Multiple
Left¹
Floating Point Hex
L
Multiple
-85 to +75
0 to 27
Right¹
Floating Point Hex
LH
Multiple
-231 to 231-1
0 to 27
Right¹
Floating Point Binary
LB
Multiple
-231 to 231-1
N/A
Right¹
Floating Point Decimal
LD
Multiple
-231 to 231-1
N/A
Floating Point Hex
LQ
Multiple
-231 to 231-1
0 to 28
Right¹
Decimal
P
Multiple
Left
Offset
Q
Multiple
Left
Address
R
Multiple
Left
Address
S
Multiple
Address
V
Multiple
Left
414
HLASM V1R6 Language Reference
Table 66. Summary of constants (part 2 of 2) (continued)
No. of
Constants
Range for
Range for
Constant
Type per Operand Exponents Scale
Truncation or Padding Side
Hexadecimal
X
Multiple
Left
Address
Y
Multiple
Left
Decimal
Z
Multiple
Left
Notes:
1. Errors are flagged if significant bits are truncated or if the value specified cannot be contained in the implicit
length of the constant.
Appendix B. Summary of constants
415
416
HLASM V1R6 Language Reference
Appendix C. Macro and conditional assembly language
summary
This appendix summarizes the macro and conditional assembly language described
in Part 3 of this publication. Table 67 indicates which macro and conditional
assembly language elements can be used in the name and operand entries of each
statement. Table 69 on page 419 summarizes the expressions that can be used in
macro instruction statements. Table 71 on page 420 summarizes the attributes that
can be used in each expression. Table 72 on page 421 summarizes the variable
symbols that can be used in each expression. Table 73 on page 422 summarizes the
system variable symbols that can be used in each expression.
Table 67. Macro language elements (part 1)
Variable Symbols
Global-scope SET Symbols²
Local SET Symbols²
Symbolic
Sequence
Statement
Parameter
SETA
SETB
SETC
SETA
SETB
SETC
Symbol
MACRO
Prototype
Name
Statement
Operand
GBLA
Operand¹¹
Operand
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Name
GBLB
Operand¹¹
Operand¹¹
Operand
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Name
GBLC
Operand¹¹
Operand¹¹
Operand¹¹
Operand
Operand¹¹
Operand¹¹
Operand¹¹
Name
LCLA
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Operand
Operand¹¹
Operand¹¹
Name
LCLB
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Operand
Operand¹¹
Name
LCLC
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Operand¹¹
Operand
Name
Name
Model
Name
Name
Name
Name
Name
Name
Name
Statement
Operation
Operation
Operation
Operation
Operation
Operation
Operation
Operand
Operand
Operand
Operand
Operand
Operand
Operand
SETA
Name¹²
Name
Name¹²
Name¹²
Name
Name¹²
Name¹²
Operand³
Operand
Operand
Operand¹⁰
Operand
Operand
Operand¹⁰
SETAF
Name¹²
Name
Name¹²
Name¹⁰,¹²
Name
Name¹²
Name¹⁰,¹²
Operand³,¹³
Operand¹³
Operand,¹³
Operand¹³
Operand¹³
Operand,¹³
Operand¹³
SETB
Name¹²
Name¹²
Name
Name¹²
Name¹²
Name
Name¹²
Operand
Operand
Operand
Operand
Operand
Operand
Operand
SETC
Name¹²
Name¹²
Name¹²
Name
Name¹²
Name¹²
Name
Operand
Operand
Operand
Operand
Operand
Operand
Operand
Operand
SETCF
Name¹²
Name¹²
Name¹²
Name
Name¹²
Name¹²
Name
Operand¹³
Operand,¹³
Operand,¹³
Operand¹³
Operand,¹³
Operand,¹³
Operand¹³
ACTR
Operand³
Operand
Operand
Operand³
Operand
Operand
Operand³
Name
Name
AEJECT
AGO
Name
Operand
AIF
Operand
Operand
Operand
Operand
Operand
Operand
Operand
Name
Operand
Name
ANOP
AREAD
Name¹²
Name¹²
Name¹²
Name
Name¹²
Name¹²
Name
ASPACE
Operand³
Operand
Operand
Operand³
Operand
Operand
Operand³
Name
417
Table 67. Macro language elements (part 1) (continued)
Variable Symbols
Global-scope SET Symbols²
Local SET Symbols²
Symbolic
Sequence
Statement
Parameter
SETA
SETB
SETC
SETA
SETB
SETC
Symbol
Name
MEXIT
MNOTE
Operand
Operand
Operand
Operand
Operand
Operand
Operand
Name
Name
MEND
Name
Outer
Name
Name
Name
Name
Name
Name
Macro
Operand
Operand
Operand
Operand
Operand
Operand
Name
Inner
Name
Name
Name
Name
Name
Name
Name
Macro
Operand
Operand
Operand
Operand
Operand
Operand
Operand
Notes:
1. Variable symbols in macro instructions are replaced by their values before processing.
2. Depending upon their values, system variable symbols with global scope can be used in the same way as global SET symbols, and
system variable symbols with local scope can be used in the same way as local SET symbols.
3. Only if value is self-defining term.
4. Converted to arithmetic 0 or 1.
5. Only in character relations.
6. Only in arithmetic relations.
7. Only in arithmetic or character relations.
8. Converted to an unsigned number.
9. Converted to character 0 or 1.
10. Only if one to ten decimal digits, not greater than 2147483647.
11. Only in created SET symbols if value of parenthesized expression is an alphabetic character followed by 0 to 61 alphanumeric
characters.
12. Only in created SET symbols (as described above) and in subscripts (see SETA statement).
13. The first operand of a SETAF or SETCF instruction must be a character (SETC) expression containing or evaluating to an eight byte
module name.
Table 68. Macro language elements (part 2)
Attributes
Type
Operation
Statement
Length
Scale
Integer
Count
Number
Defined
Code
MACRO
Prototype
Statement
GBLA
GBLB
GBLC
LCLA
LCLB
LCLC
Model
Statement
SETA
Operand
Operand
Operand
Operand
Operand
Operand
SETAF
Operand¹³
Operand¹³
Operand¹³
Operand¹³
Operand¹³
SETB
Operand
Operand
Operand
Operand
Operand
Operand
Operand
Operand
SETC
Operand
Operand
SETCF
Operand¹³
ACTR
Operand
Operand
Operand
Operand
Operand
AEJECT
AGO
AIF
Operand
Operand
Operand
Operand
Operand
Operand
Operand
Operand
ANOP
AREAD
ASPACE
Operand
Operand
Operand
Operand
Operand
418
HLASM V1R6 Language Reference
Table 68. Macro language elements (part 2) (continued)
Attributes
Type
Operation
Statement
Length
Scale
Integer
Count
Number
Defined
Code
MEXIT
MNOTE
MEND
Outer
Macro
Notes:
1. Variable symbols in macro instructions are replaced by their values before processing.
2. Depending upon their values, system variable symbols with global scope can be used in the same way as global SET symbols, and
system variable symbols with local scope can be used in the same way as local SET symbols.
3. Only if value is self-defining term.
4. Converted to arithmetic 0 or 1.
5. Only in character relations.
6. Only in arithmetic relations.
7. Only in arithmetic or character relations.
8. Converted to an unsigned number.
9. Converted to character 0 or 1.
10. Only if one to ten decimal digits, not greater than 2147483647.
11. Only in created SET symbols if value of parenthesized expression is an alphabetic character followed by 0 to 61 alphanumeric
characters.
12. Only in created SET symbols (as described above) and in subscripts (see SETA statement).
13. The first operand of a SETAF or SETCF instruction must be a character (SETC) expression containing or evaluating to an eight byte
module name.
Table 69. Conditional assembly expressions
Arithmetic
Character
Logical
Expression
Expressions
Expressions
Expressions
Self-defining
Any combination of characters
A 0 or a 1 Absolute,
Can
terms Absolute,
(including double-byte
predefined ordinary
contain
predefined ordinary
characters, if the DBCS
symbols SETB
symbols Length, scale,
assembler option is specified)
symbols Arithmetic
integer, count, defined,
enclosed in apostrophes Any
relations Character
and number
variable symbol enclosed in
relations Arithmetic
attributes SETA and
apostrophes A concatenation of
value
SETB symbols SETC
variable symbols and other
symbols whose values
characters enclosed in
are a self-defining
apostrophes Built-in
term Symbolic
Functions A type or operation
parameters if the
code attribute
corresponding operand
reference Substrings
is a self-defining
term Built-in
Functions &SYSDATC
&SYSLIST(n) if the
corresponding operand
is a self-defining
term &SYSLIST (n,m) if
the corresponding
operand is a
self-defining
term &SYSOPT_DBCS,
&SYSOPT_RENT, and
&SYSOPT_XOBJECT
&SYSM_HSEV and
&SYSM_SEV
&SYSNDX, &SYSNEST,
and &SYSSTMT
Operations
+, - (unary and binary),
Concatenation, with a period (.),
AND, OR, NOT,
*, and /; Parentheses
or by juxtaposition; substrings
XOR Parentheses
permitted
permitted
Range of values
-2³¹ to +2³¹-1
0 through 4064 characters
0 (false) or 1 (true)
Appendix C. Macro and conditional assembly language summary
419
Table 69. Conditional assembly expressions (continued)
Arithmetic
Character
Logical
Expression
Expressions
Expressions
Expressions
Used in
SETA
SETC operands Character
SETB operands AIF
operands Arithmetic
relations Created SET symbols
operands Created SET
relations Created SET
symbols
symbols Subscripted
SET symbols &SYSLIST
subscripts Substring
notation Sublist notation
Built-in functions fall into the following categories:
Table 70. Built-in functions
Value Type
Functions
Arithmetic
AND, B2A, C2A, D2A, DCLEN, FIND, INDEX, NOT, OR, SLA, SLL,
SRA, SRL, X2A, XOR
Logical
AND, AND NOT, ISBIN, ISDEC, ISHEX, ISSYM, NOT, OR, OR
NOT, XOR, XOR NOT
Character
A2B, A2C, A2D, A2X, B2C, B2D, B2X, BYTE, C2B, C2D, C2X, D2B,
D2C, D2X, DCVAL, DEQUOTE, DOUBLE, LOWER, SIGNED,
UPPER, X2B, X2C, X2D
Table 71. Attributes
Can be used only if
Attribute
Notation
Can be used with:
Type Attribute is:
Can be used in:
Type
T'
Ordinary symbols
Any value
SETC expressions
defined in open code;
symbolic parameters
Character relations
inside macro
definitions;
&SYSLIST(n),
&SYSLIST(n,m) inside
macro definitions;
SET symbols; all
system variable
symbols
Length
L'
Ordinary symbols
Any value except M, N, O,
SETA and ordinary
defined in open code;
T, U
arithmetic
symbolic parameters
expressions
inside macro
definitions;
&SYSLIST(n), and
&SYSLIST(n,m) inside
macro definitions
Scale
S'
Ordinary symbols
H,F,G,D,E,L,K,P, and Z
SETA and ordinary
defined in open code;
arithmetic
symbolic parameters
expressions
inside macro
definitions;
&SYSLIST(n), and
&SYSLIST(n,m) inside
macro definitions
420
HLASM V1R6 Language Reference

 

 

 

 

 

 

 

Content      ..     20      21      22      23     ..