Trailing-Edge
-
PDP-10 Archives
-
decus_20tap3_198111
-
decus/20-0079/second.mac
There are no other files named second.mac in the archive.
TITLE SECOND - FORTRAN SUBROUTINE TO RETURN CPU 'RUNTIM' IN A REAL VARABLE
SUBTTL AUTHOR : A.GRAYSON 14-NOV-73
;
; CALLING SEQUENCE: REAL A
; CALL SECOND (A)
; RETURNS IN A THE FLOATING POINT CPU SECONDS USED BY THE JOB
;
; WORKS FOR BOTH F40 AND FORTRAN-10
; WORKS FOR 10U SEC. AND 60 CYCLE CLOCK ACCOUNTING
; WORKS ON KA10 AND KI10 CPUS
;
ENTRY SECOND
EXTERN CEXIT. , FLT.0
;
; DEFAULT ASSEMBLY IS 10U SEC. KI10
;
HPA=1 ; HIGH PRECISION ACCOUNTING IS SELECTED
; BY TURNING ON THE SIGN BIT IN THE CALLING
; AC AND IF THE MONITOR ACCOUNTING SUPPORTS
; THE DK10. 10 USEC INTERVALS ARE RETURNED
; NOT MILLISECONDS!
; KA=1 ; UNCOMMENT FOR KA10 CODE
;
; PREAMBLE FOR F40 AND FORTRAN-10 COMPATABILITY
;
SIXBIT /SECOND/
SECOND: CAIA
PUSH 17, CEXIT.
;
; SELECT HIGH PRECISION OR 60-CYCLE ACCOUNTING
;
;
IFDEF HPA, < MOVSI 0, 400000
>
IFNDEF HPA, < SETZ 0,
>
;
RUNTIM 0,
;
; FLOAT THE RUNTIM CORRECTLY. NOTE: FSC 0,233 FAILS WITH HPA=1
; IF JOB HAS ACCUMULATED MUCH RUNTIME.
;
IFDEF KA, < PUSHJ 17, FLT.0
>
IFNDEF KA, < FLTR 0,0
;
; THESE MAGIC NUMBERS ARE 100,000. AND 1,000. IN OCTAL.
;
IFDEF HPA, < FDVR 0, [221606500000]
>
IFNDEF HPA, < FDVRI 0, 212764
>
; RETURN DATA AND GO BACK
;
MOVEM 0, @(16)
POPJ 17,
END
>