X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fassembly%2Fsparc%2Farith.lisp;h=d3b52d24a99ca38acce43ea753c46212af806548;hb=dfc9c3a9dde3ae21498ac1a184a6e56fd4e79eb0;hp=61278cc658e820ba798a3d41943970d490d131ec;hpb=4898ef32c639b1c7f4ee13a5ba566ce6debd03e6;p=sbcl.git diff --git a/src/assembly/sparc/arith.lisp b/src/assembly/sparc/arith.lisp index 61278cc..d3b52d2 100644 --- a/src/assembly/sparc/arith.lisp +++ b/src/assembly/sparc/arith.lisp @@ -171,31 +171,12 @@ (inst srl lo n-fixnum-tag-bits) (inst or lo temp) (inst sra hi n-fixnum-tag-bits) - ;; Allocate a BIGNUM for the result. - #+nil - (pseudo-atomic (:extra (pad-data-block (1+ bignum-digits-offset))) - (let ((one-word (gen-label))) - (inst or res alloc-tn other-pointer-lowtag) - ;; We start out assuming that we need one word. Is that correct? - (inst sra temp lo 31) - (inst xorcc temp hi) - (inst b :eq one-word) - (inst li temp (logior (ash 1 n-widetag-bits) bignum-widetag)) - ;; Nope, we need two, so allocate the addition space. - (inst add alloc-tn (- (pad-data-block (+ 2 bignum-digits-offset)) - (pad-data-block (1+ bignum-digits-offset)))) - (inst li temp (logior (ash 2 n-widetag-bits) bignum-widetag)) - (storew hi res (1+ bignum-digits-offset) other-pointer-lowtag) - (emit-label one-word) - (storew temp res 0 other-pointer-lowtag) - (storew lo res bignum-digits-offset other-pointer-lowtag))) ;; Always allocate 2 words for the bignum result, even if we only ;; need one. The copying GC will take care of the extra word if it ;; isn't needed. (with-fixed-allocation (res temp bignum-widetag (+ 2 bignum-digits-offset)) (let ((one-word (gen-label))) - (inst or res alloc-tn other-pointer-lowtag) ;; We start out assuming that we need one word. Is that correct? (inst sra temp lo 31) (inst xorcc temp hi) @@ -256,7 +237,7 @@ (inst mulscc temp zero-tn) (inst rdy res)))))) (frob unsigned-* "unsigned *" 40 unsigned-num unsigned-reg) - (frob signed-* "unsigned *" 41 signed-num signed-reg) + (frob signed-* "signed *" 41 signed-num signed-reg) (frob fixnum-* "fixnum *" 30 tagged-num any-reg))