Google
 

Trailing-Edge - PDP-10 Archives - BB-4157F-BM_1983 - build/formsc.unv
There are 3 other files named formsc.unv in the archive. Click here to see a list.
x,5@P GWMYP I]YP I]YP Ii9P M3  uQ_c
	ENTRY	FupLT.A
	SIXBIT	/FvLT.A/
FLT.A:
v0IFE CPU-KA10,<
	vPHLRE	A+1,A	;COPvpY THE HI HALT OF wA TO LOW A+1
	w0HLL	A,A+1	;FILLwP UPPER PART OF Awp WITH THE SIGH
	xFSC	A,233	;FLOATx0 THE LOW HALT OF xPTHE INTEGER
	SKIxpPGE	A	;FOR NEGATyIVE NUMBERS
	AOJy0E	A+1,FLT.XT	;CHyPANGE HIGH PART TOyp 2'S COMPLEMENT
z	FSC	A+1,255	;FLz0OAT THE HIGH PARTzP
	FADR	A,A+1	;zpCOMBINE THE TWO P{ARTS
>
IFE CPU-{0KI10,<
	FLTR	A,{PA	;USE THE HARDW{pARE
>
FLT.XT:	P|OPJ	P,	;RETURN A|0=THE FLOATING POINT NUMBER
3]S@ |q`
	ENTRY	I}FX.A
	SIXBIT	/I}0FX.A/
IFX.A:
}PIFE CPU-KA10,<
	}pMULI	A,400		;SEP~ERATE THE FRACTIO~0N AND EXPONENT
	~PEXCH	A,A+1		;PU~pT PARTICAL RESULT IN A
	JUMPGE	0A+1,IFX.XT	;JUMP PIF POSITIVE
	TRCp	A+1,-1	;NEGATE THE EXPONENT
	MO0VNS	A		;POSITIVEP FRACTION
IFX.XTp:	ASH	A,-243(A+1)	;USE EXPONENT 0AS INDEX
	SKIPGEP	A+1		;SKIP IF PpOSITIVE
	MOVNS	A		;NEGATE THE RE0SULT
>
IFE CPU-PKI10,<
	FIX	A,pA
>
	POPJ	P,		;RETRURN A=FIXED NUMBER
S@P >}{woP