]> gitweb.factorcode.org Git - factor.git/commitdiff
cpu: cleanups
authorSlava Pestov <slava@shill.local>
Sat, 26 Sep 2009 02:47:05 +0000 (21:47 -0500)
committerSlava Pestov <slava@shill.local>
Sat, 26 Sep 2009 02:47:05 +0000 (21:47 -0500)
basis/cpu/ppc/ppc.factor
basis/cpu/x86/32/32.factor
basis/cpu/x86/64/64.factor

index eabac51db59aa4e91449a39c40ce57bb14bee72a..bcd52206a0caeebab86cdea25e96fa91b5e60db1 100644 (file)
@@ -510,7 +510,7 @@ M:: ppc %save-gc-root ( gc-root register -- )
 M:: ppc %load-gc-root ( gc-root register -- )
     register 1 gc-root gc-root@ LWZ ;
 
-M:: ppc %call-gc ( gc-root-count -- )
+M:: ppc %call-gc ( gc-root-count temp -- )
     3 1 gc-root-base local@ ADDI
     gc-root-count 4 LI
     "inline_gc" f %alien-invoke ;
index 84294b491207a776ff147299c472107f5d943968..5f6c0d469698f977ea84df95347c744ff0326c62 100755 (executable)
@@ -314,15 +314,15 @@ M: x86.32 %callback-return ( n -- )
         [ drop 0 ]
     } cond RET ;
 
-M:: x86.32 %call-gc ( gc-root-count temp1 -- )
-    ! USE: prettyprint "PHIL" pprint temp1 pprint temp2 pprint
-    temp1 gc-root-base param@ LEA
+M:: x86.32 %call-gc ( gc-root-count temp -- )
+    temp gc-root-base param@ LEA
     12 [
-        0 PUSH rc-absolute-cell rt-vm rel-fixup ! push the vm ptr as an argument
+        ! Pass the VM ptr as the third parameter
+        0 PUSH rc-absolute-cell rt-vm rel-fixup
         ! Pass number of roots as second parameter
         gc-root-count PUSH 
         ! Pass pointer to start of GC roots as first parameter
-        temp1 PUSH 
+        temp PUSH 
         ! Call GC
         "inline_gc" f %alien-invoke
     ] with-aligned-stack ;
index dfe537baa37521f11a8f2cdeabc7f0ad4a04e4a6..562563039e6d87a8329450a5500ce3e296fd5078 100644 (file)
@@ -235,12 +235,12 @@ M:: x86.64 %binary-float-function ( dst src1 src2 func -- )
     func f %alien-invoke
     dst float-function-return ;
 
-M:: x86.64 %call-gc ( gc-root-count temp1 -- )
+M:: x86.64 %call-gc ( gc-root-count temp -- )
     ! Pass pointer to start of GC roots as first parameter
     param-reg-1 gc-root-base param@ LEA
     ! Pass number of roots as second parameter
     param-reg-2 gc-root-count MOV
-    ! Pass vm as third parameter
+    ! Pass VM ptr as third parameter
     param-reg-3 %mov-vm-ptr
     ! Call GC
     "inline_gc" f %alien-invoke ;