 : jit-save-context ( -- )
     4 vm-reg 0 LWZ
     1 4 0 STW
-    ds-reg vm-reg 8 STW
-    rs-reg vm-reg 12 STW ;
-
-: jit-load-context ( -- )
+    ds-reg 4 8 STW
+    rs-reg 4 12 STW ;
+
+: jit-restore-context ( -- )
     4 vm-reg 0 LWZ
-    ds-reg vm-reg 8 LWZ
-    rs-reg vm-reg 12 LWZ ;
+    ds-reg 4 8 LWZ
+    rs-reg 4 12 LWZ ;
 
 [
     0 3 LOAD32 rc-absolute-ppc-2/2 rt-literal jit-rel

[ [ SUBFO. ] "overflow_fixnum_subtract" jit-overflow ] \ fixnum- define-sub-primitive

[
    jit-save-context
    3 ds-reg 0 LWZ
    3 3 tag-bits get SRAWI
    4 ds-reg -4 LWZ
    ds-reg ds-reg 4 SUBI
    0 0 LI
    0 MTXER
    6 3 4 MULLWO.

    0 4 LOAD32 rc-absolute-ppc-2/2 rt-primitive jit-rel
    4 MTLR
    BLRL
    jit-restore-context
] jit-primitive jit-define

[ 0 BL rc-relative-ppc-3 rt-xt-pic jit-rel ] jit-word-call jit-define
