]> gitweb.factorcode.org Git - factor.git/commitdiff
Primitives now pass vm ptr on 64bit x86
authorPhil Dawes <phil@phildawes.net>
Tue, 25 Aug 2009 05:59:26 +0000 (06:59 +0100)
committerPhil Dawes <phil@phildawes.net>
Wed, 16 Sep 2009 07:20:09 +0000 (08:20 +0100)
basis/cpu/x86/64/bootstrap.factor
vm/primitives.hpp

index 8b0d53cda56f52075097c96f21f70c3464efae21..28309e7d978106d16d64425a2ad13c4fa51ba138 100644 (file)
@@ -21,6 +21,9 @@ IN: bootstrap.x86
 : rex-length ( -- n ) 1 ;
 
 [
+    ! HACK: stash vm pointer above the ds stack
+    temp0 0 MOV rc-absolute-cell rt-vm jit-rel
+    ds-reg bootstrap-cell [+] temp0 MOV 
     ! load stack_chain
     temp0 0 MOV rc-absolute-cell rt-stack-chain jit-rel
     temp0 temp0 [] MOV
index 8e6c3b8f518dec1aafe2f9f46138b4b4c54deb96..5eefc19e016346a346bdd2372a8a123b0fcd6f56 100644 (file)
@@ -13,6 +13,7 @@ namespace factor
 
 extern const primitive_type primitives[];
 #define PRIMITIVE_OVERFLOW_GETVM() vm
+
 #define VM_PTR vm
 #define ASSERTVM() 
 }