Fixes for Franz Lisp tahoe version

Peter S. Housel housel at ea.ecn.purdue.edu
Fri Jul 8 01:58:08 AEST 1988


	Those running the Purdue port of Franz Lisp Opus 38.92 for the tahoe
architecture should probably apply the following patches. The first fixes
errors in compiled programs using the (\\ ...) function, and the second
affects all programs that do division with bignums.

	Both of these should be fixed on the new BSD 4.3-Tahoe distribution.

	The first patch is for /usr/src/ucb/lisp/liszt/fixnum.l:

*** fixnum.l	Sun Dec 14 15:38:54 1986
--- /hogs/housel/fixnum.l	Thu Jul  7 10:42:43 1988
***************
*** 527,537 ****
  				  (setq rop2 '(0 r0))))
  		(if (eq opcode 'ediv)
  		    then (if (not simpleop1)
! 			     then (e-move rop1 #+for-vax 'r2 #+for-tahoe 'r1)
! 			    			 ; need quad
! 				  #+for-vax (e-write4 'ashq '$-32 'r1 'r1)
! 				  #+for-tahoe (e-write2 'clrl 'r0)
! 				  (setq rop1 #+for-vax 'r1 #+for-tahoe 'r0))
  				  				; word div.
  			 (e-write5 'ediv rop2 rop1 'r0 'r5)
  		    else (e-write4 opcode rop2 rop1 'r5))
--- 527,541 ----
  				  (setq rop2 '(0 r0))))
  		(if (eq opcode 'ediv)
  		    then (if (not simpleop1)
! 			     then #+for-vax (progn (e-move rop1 'r2) ;need quad
! 						(e-write4 'ashq '$-32 'r1 'r1))
! 			          #+for-tahoe (let ((x (d-genlab)))
! 						(e-write2 'clrl 'r2)
! 						(e-move rop1 'r3)
! 						(e-write2 'jgeq x)
! 						(e-write3 'mnegl '($ 1) 'r2)
! 						(e-writel x))
! 				  (setq rop1 #+for-vax 'r1 #+for-tahoe 'r2))
  				  				; word div.
  			 (e-write5 'ediv rop2 rop1 'r0 'r5)
  		    else (e-write4 opcode rop2 rop1 'r5))

	The second is for /usr/src/ucb/lisp/franz/tahoe/calqhat.s:

*** calqhat.s	Fri Nov 14 10:00:47 1986
--- /hogs/housel/calqhat.s	Thu Jul  7 10:41:53 1988
***************
*** 18,25 ****
  	emul	r0,4(r10),$0,r2		# qhat*v[2] into r3,r2
  	emul	r1,$0x40000000,8(r11),r8 #rhat*b + u[j+2] into r9,r8
  	# give up if r3,r2 <= r9,r8, otherwise iterate
! 	subl2	r8,r2			# perform r3,r2 - r9,r8
! 	sbwc	r9,r3
  	bleq	L103			# give up if negative or equal
  	decl	r0			# otherwise, qhat = qhat - 1
  	addl2	(r10),r1		# since dec'ed qhat, inc rhat by v[1]
--- 18,26 ----
  	emul	r0,4(r10),$0,r2		# qhat*v[2] into r3,r2
  	emul	r1,$0x40000000,8(r11),r8 #rhat*b + u[j+2] into r9,r8
  	# give up if r3,r2 <= r9,r8, otherwise iterate
! 	addl2	$0,r2			# explicitly clear carry.
! 	sbwc	r9,r3			# perform r3,r2 - r9,r8
! 	sbwc	r8,r2
  	bleq	L103			# give up if negative or equal
  	decl	r0			# otherwise, qhat = qhat - 1
  	addl2	(r10),r1		# since dec'ed qhat, inc rhat by v[1]



More information about the Comp.sys.tahoe mailing list