Browse files

	Alpha build fix
	... write a slightly more general PREPARE-ARGUMENT function for
		modular arithmetic;
	... as discussed on #lisp IRC 2003-09-24, post-0.8.4 we can optimize
		common cases on platforms where register width and
		bignum-element-width are the same.
  • Loading branch information...
csrhodes committed Sep 24, 2003
1 parent 603a4ab commit 89823a09e0dd2869f7fea351d887f75e70548ea7
Showing with 2 additions and 4 deletions.
  1. +1 −3 src/code/numbers.lisp
  2. +1 −1 version.lisp-expr
@@ -1358,15 +1358,13 @@
(collect ((forms))
(flet ((definition (name lambda-list width pattern)
- (assert (sb!xc:subtypep `(unsigned-byte ,width)
- 'bignum-element-type))
`(defun ,name ,lambda-list
(flet ((prepare-argument (x)
(declare (integer x))
(etypecase x
((unsigned-byte ,width) x)
(fixnum (logand x ,pattern))
- (bignum (logand (%bignum-ref x 0) ,pattern)))))
+ (bignum (logand x ,pattern)))))
(,name ,@(loop for arg in lambda-list
collect `(prepare-argument ,arg)))))))
(loop for infos being each hash-value of sb!c::*modular-funs*
@@ -17,4 +17,4 @@
;;; checkins which aren't released. (And occasionally for internal
;;; versions, especially for internal versions off the main CVS
;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)

0 comments on commit 89823a0

Please sign in to comment.