Google
 

Trailing-Edge - PDP-10 Archives - ap-c796e-sb - formsc.unv
There are 3 other files named formsc.unv in the archive. Click here to see a list.
x,@P M3  n
	ENTRY	F LT.A
	SIXBIT	/F@LT.A/
FLT.A:
`IFE CPU-KA10,<
	HLRE	A+1,A	;COP Y THE HI HALT OF @A TO LOW A+1
	`HLL	A,A+1	;FILL	 UPPER PART OF A	  WITH THE SIGH
		@FSC	A,233	;FLOAT	` THE LOW HALT OF 
THE INTEGER
	SKI
 PGE	A	;FOR NEGAT
@IVE NUMBERS
	AOJ
`E	A+1,FLT.XT	;CHANGE HIGH PART TO  2'S COMPLEMENT
@	FSC	A+1,255	;FL`OAT THE HIGH PART

	FADR	A,A+1	;
 COMBINE THE TWO P
@ARTS
>
IFE CPU-
`KI10,<
	FLTR	A,HE HARDW
>
FLT.XT:	PETURNPANT NUMBER
3]S@  $
	ENTRY	I@FX.A
	SIXBIT	/I`FX.A/
IFX.A:
IFE CPU-KA10,<
	 MULI	A,400		;SEP@ERATE THE FRACTIO`N AND EXPONENT
	EXCH	A,A+1		;PU T PARTICAL RESULT@ IN A
	JUMPGE	`A+1,IFX.XT	;JUMP IF POSITIVE
	TRC 	A+1,-1	;NEGATE @THE EXPONENT
	MO`VNS	A		;POSITIVE FRACTION
IFX.XT :	ASH	A,-243(A+@1)	;USE EXPONENT `AS INDEX
	SKIPGE	A+1		;SKIP IF P OSITIVE
	MOVNS	@A		;NEGATE THE RE`SULT
>
IFE CPU-KI10,<
	FIX	A, A
>
	POPJ	P,		;@RETRURN A=FIXED NUMBER
Y@S@P >}{woP