]> gitweb.factorcode.org Git - factor.git/commitdiff
Fix x86 typo
authorslava <slava@factorcode.org>
Sat, 29 Apr 2006 21:28:51 +0000 (21:28 +0000)
committerslava <slava@factorcode.org>
Sat, 29 Apr 2006 21:28:51 +0000 (21:28 +0000)
library/bootstrap/boot-stage1.factor
library/compiler/x86/architecture.factor

index 29f717929aabb4942535693a20b7ace33fe37a5c..05ffbba14b12df77d1646b60ebdab9c6e8639e2d 100644 (file)
@@ -283,7 +283,7 @@ vectors words ;
                     "/library/compiler/x86/assembler.factor"
                     "/library/compiler/x86/architecture.factor"
                     "/library/compiler/x86/alien.factor"
-                    "/library/compiler/x86/intrinsics.factor"
+                    "/library/compiler/x86/intrinsics.factor"
                 }
             ]
         } {
index 112f18e09ddc8f3d442bc471a396effb478515ed..d1f39683bee4feadfb89b69c5fd93e3cc588a274 100644 (file)
@@ -2,25 +2,25 @@
 ! See http://factorcode.org/license.txt for BSD license.
 IN: compiler
 USING: alien arrays assembler generic kernel kernel-internals
-math namespaces sequences words ;
+math memory namespaces sequences words ;
 
 ! x86 register assignments
 ! EAX, ECX, EDX vregs
 ! ESI datastack
 ! EBX callstack
 
+! AMD64 redefines these four
 : ds-reg ESI ; inline
 : cs-reg EBX ; inline
+: remainder-reg EDX ; inline
+: vregs { EAX ECX EDX } ; inline
+
 : reg-stack ( n reg -- op ) swap cells neg [+] ;
 
 M: ds-loc v>operand ds-loc-n ds-reg reg-stack ;
 
 M: cs-loc v>operand cs-loc-n cs-reg reg-stack ;
 
-: remainder-reg EDX ; inline
-
-: vregs { EAX ECX EDX } ; inline
-
 : %alien-invoke ( symbol dll -- )
     2dup dlsym CALL rel-relative rel-dlsym ;
 
@@ -44,8 +44,7 @@ M: float-regs fastcall-regs drop { } ;
 
 : prepare-division CDQ ; inline
 
-M: immediate load-literal ( dest literal -- )
-    address MOV ;
+M: immediate load-literal ( dest literal -- ) address MOV ;
 
 M: object load-literal ( dest literal -- )
     add-literal [] MOV rel-absolute-cell rel-address ;
@@ -59,8 +58,7 @@ M: object load-literal ( dest literal -- )
 
 : %jump-label ( label -- ) JMP ;
 
-: %jump-t ( label -- )
-    "flag" operand f v>operand CMP JNE ;
+: %jump-t ( label -- ) "flag" operand f v>operand CMP JNE ;
 
 : %dispatch ( -- )
     #! Compile a piece of code that jumps to an offset in a
@@ -87,7 +85,7 @@ M: object load-literal ( dest literal -- )
 
 : %replace ( vreg loc -- ) swap %peek ;
 
-: (%inc) 0 input cells dup 0 > [ ADD ] [ neg SUB ] if ;
+: (%inc) cells dup 0 > [ ADD ] [ neg SUB ] if ;
 
 : %inc-d ( n -- ) ds-reg (%inc) ;