Skip to content

Instantly share code, notes, and snippets.

@JohnArchieMckown
Created November 30, 2015 13:18
Show Gist options
  • Save JohnArchieMckown/b95ee10fb8ce593d7304 to your computer and use it in GitHub Desktop.
Save JohnArchieMckown/b95ee10fb8ce593d7304 to your computer and use it in GitHub Desktop.
z/OS HLASM macro which has the "proper" register equates for the General Purpose and Address Registers.
MACRO
&LBL REGS
AIF (D'R0).MEND
R0 EQU 0,,,,GR
R1 EQU 1,,,,GR
R2 EQU 2,,,,GR
R3 EQU 3,,,,GR
R4 EQU 4,,,,GR
R5 EQU 5,,,,GR
R6 EQU 6,,,,GR
R7 EQU 7,,,,GR
R8 EQU 8,,,,GR
R9 EQU 9,,,,GR
R10 EQU 10,,,,GR
R11 EQU 11,,,,GR
R12 EQU 12,,,,GR
R13 EQU 13,,,,GR
R14 EQU 14,,,,GR
R15 EQU 15,,,,GR
R0_64 EQU 0,,,,GR64
R1_64 EQU 1,,,,GR64
R2_64 EQU 2,,,,GR64
R3_64 EQU 3,,,,GR64
R4_64 EQU 4,,,,GR64
R5_64 EQU 5,,,,GR64
R6_64 EQU 6,,,,GR64
R7_64 EQU 7,,,,GR64
R8_64 EQU 8,,,,GR64
R9_64 EQU 9,,,,GR64
R10_64 EQU 10,,,,GR64
R11_64 EQU 11,,,,GR64
R12_64 EQU 12,,,,GR64
R13_64 EQU 13,,,,GR64
R14_64 EQU 14,,,,GR64
R15_64 EQU 15,,,,GR64
R0_32 EQU 0,,,,GR32
R1_32 EQU 1,,,,GR32
R2_32 EQU 2,,,,GR32
R3_32 EQU 3,,,,GR32
R4_32 EQU 4,,,,GR32
R5_32 EQU 5,,,,GR32
R6_32 EQU 6,,,,GR32
R7_32 EQU 7,,,,GR32
R8_32 EQU 8,,,,GR32
R9_32 EQU 9,,,,GR32
R10_32 EQU 10,,,,GR32
R11_32 EQU 11,,,,GR32
R12_32 EQU 12,,,,GR32
R13_32 EQU 13,,,,GR32
R14_32 EQU 14,,,,GR32
R15_32 EQU 15,,,,GR32
AR0 EQU 0,,,,AR
AR1 EQU 1,,,,AR
AR2 EQU 2,,,,AR
AR3 EQU 3,,,,AR
AR4 EQU 4,,,,AR
AR5 EQU 5,,,,AR
AR6 EQU 6,,,,AR
AR7 EQU 7,,,,AR
AR8 EQU 8,,,,AR
AR9 EQU 9,,,,AR
AR10 EQU 10,,,,AR
AR11 EQU 11,,,,AR
AR12 EQU 12,,,,AR
AR13 EQU 13,,,,AR
AR14 EQU 14,,,,AR
AR15 EQU 15,,,,AR
.MEND ANOP
MEND
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment