Trailing-Edge
-
PDP-10 Archives
-
decuslib10-04
-
43,50325/savreg.mac
There are no other files named savreg.mac in the archive.
; File: SAVREG.MAC
;
; This work was supported by the Advanced Research
; Projects Agency of the Office of the Secretary of
; Defense (F44620-73-C-0074) and is monitored by the
; Air Force Office of Scientific Research.
.TITLE SAVREG
.CSECT SAVR.C
; The BLISS-11 out-of-line routines to save and restore register contents.
;
; 30-Nov-73 P. Knueven
;
; The routine $SAVn is called at the beginning of a routine
; which modifies the contents of registers 1 thru n. The calling
; sequence is the following:
; JSR R1,$SAVn
;
R0=%0
R1=%1
R2=%2
R3=%3
R4=%4
R5=%5
SP=%6
PC=%7
.GLOBL $SAV2,$SAV3
.GLOBL $SAV4,$SAV5
$SAV2: MOV R2,-(SP)
MOV R1,-(SP)
MOV 4(SP),R1
JSR PC,@(SP)+
BR RE2
$SAV3: MOV R2,-(SP)
MOV R3,-(SP)
MOV R1,-(SP)
MOV 6(SP),R1
JSR PC,@(SP)+
BR RE3
$SAV4: MOV R2,-(SP)
MOV R3,-(SP)
MOV R4,-(SP)
MOV R1,-(SP)
MOV 8.(SP),R1
JSR PC,@(SP)+
BR RE4
$SAV5: MOV R2,-(SP)
MOV R3,-(SP)
MOV R4,-(SP)
MOV R5,-(SP)
MOV R1,-(SP)
MOV 10.(SP),R1
JSR PC,@(SP)+
MOV (SP)+,R5
RE4: MOV (SP)+,R4
RE3: MOV (SP)+,R3
RE2: MOV (SP)+,R2
MOV (SP)+,R1
RTS PC
.END