Changeset 10815
 Timestamp:
 Sep 21, 2008, 5:26:41 AM (11 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

trunk/source/level0/X86/X8632/x8632hash.lisp
r10731 r10815 6 6 ;;; This should stay in LAP so that it's fast 7 7 ;;; Equivalent to cl:mod when both args are positive fixnums 8 9 ;;; We have to use edx:eax for the dividend, so we can't avoid10 ;;; having to do the markasimm/markasnode dance here. This11 ;;; may have performance implications.12 8 (defx8632lapfunction fastmod ((number arg_y) (divisor arg_z)) 13 (markasimm temp1) ;aka edx 14 (let ((imm1 temp1)) 15 (xorl (% imm1) (% imm1)) 16 (mov (% number) (% imm0)) 17 (div (% divisor)) 18 (mov (% imm1) (% arg_z))) 19 (markasnode temp1) 9 (xorl (% edx) (% edx)) ;aka temp1 10 (mov (% number) (% imm0)) 11 (div (% divisor)) ;boxed remainder goes into edx/temp1 12 (mov (% edx) (% arg_z)) 20 13 (singlevaluereturn)) 21 14
Note: See TracChangeset
for help on using the changeset viewer.