Changeset 7987 for branches/ia32/level-0/X86/X8632/x8632-bignum.lisp
- Timestamp:
- Jan 3, 2008, 1:58:49 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ia32/level-0/X86/X8632/x8632-bignum.lisp
r7963 r7987 7 7 ;;; and return multiple values. 8 8 ;;; 9 ;;; XXX -- figure out how we're going to handle multiple-values...10 9 (defx8632lapfunction %bignum-ref ((bignum arg_y) (i arg_z)) 11 (movl (% esp) (% temp0)) 10 (movl (% esp) (% temp0)) ;.SPvalues wants return addr in temp0 12 11 (movzwl (@ (+ 2 x8632::misc-data-offset) (% bignum) (% i)) (% imm0)) 13 12 (box-fixnum imm0 temp1) … … 224 223 (box-fixnum temp0 high) 225 224 (mark-as-node temp0) 225 (movl (% esp) (% temp0)) 226 226 (push (% high)) 227 227 (push (% low)) 228 (movl (% esp) (% temp0))229 228 (jmp-subprim .SPvalues)) 230 229 … … 252 251 (shll ($ 16) (% imm0)) 253 252 (orl (% imm0) (% temp1)) 254 (cmpl ($ '1) ( @ borrow (% esp)));CF = 1 if borrow is 0 else CF = 0253 (cmpl ($ '1) (% borrow)) ;CF = 1 if borrow is 0 else CF = 0 255 254 (sbbl (% temp0) (% temp1)) 256 255 (movl ($ 1) (% imm0)) … … 259 258 (movzwl (% temp1.w) (% imm0)) 260 259 (box-fixnum imm0 imm0) 260 (popl (% arg_y)) ;return address 261 (addl ($ '5) (% esp)) ;discard reserved frame & stack args 262 (pushl (% arg_y)) 261 263 (push (% imm0)) ;high 262 264 (sarl ($ 16) (% temp1)) … … 267 269 (push (% arg_z)) ;borrow 268 270 (set-nargs 3) 269 (popl (@ 16 (% esp))) ;relocate return addr 270 (addl ($ '4) (% esp)) ;discard args, part of saved frame 271 (movl (% esp) (% temp0)) 271 (leal (@ '3 (% esp)) (% temp0)) 272 272 (jmp-subprim .SPvalues)) 273 273 … … 391 391 (defx8632lapfunction %add-the-carry ((high 4) #|(ra 0)|# (low arg_y) (c arg_z)) 392 392 (mark-as-imm temp0) 393 (unbox-fixnum low imm0) 394 (movl (@ high (% esp)) (% temp0)) 395 (shll ($ (- 16 x8632::fixnumshift)) (% temp0)) 396 (orl (% imm0) (% temp0)) 397 (unbox-fixnum c imm0) 398 (addl (% imm0) (% temp0)) 399 (movzwl (% temp0.w) (% imm0)) 400 (box-fixnum imm0 temp1) 401 (sarl ($ 16) (% temp0)) 402 (box-fixnum temp0 temp0) 403 (push (% temp0)) ;high 404 (push (% temp1)) ;low 393 (let ((imm1 temp0) 394 (imm1.w temp0.w)) 395 (pop (% temp1)) 396 (popl (% imm1)) ;high 397 (discard-reserved-frame) 398 (push (% temp1)) 399 (shll ($ (- 16 x8632::fixnumshift)) (% temp0)) 400 (unbox-fixnum low imm0) 401 (orl (% imm0) (% imm1)) 402 (unbox-fixnum c imm0) 403 (addl (% imm0) (% imm1)) 404 (movzwl (% imm1.w) (% imm0)) 405 (box-fixnum imm0 temp1) 406 (sarl ($ 16) (% imm1)) 407 (shll ($ x8632::fixnumshift) (% imm1)) 408 (push (% imm1)) ;high 409 (push (% temp1))) ;low 410 (mark-as-node temp0) 405 411 (set-nargs 2) 406 (mark-as-node temp0) 407 (movl (% esp) (% temp0)) 412 (leal (@ '2 (% esp)) (% temp0)) 408 413 (jmp-subprim .SPvalues)) 409 414
Note: See TracChangeset
for help on using the changeset viewer.