summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--quine.asm33
1 files changed, 25 insertions, 8 deletions
diff --git a/quine.asm b/quine.asm
index 9e5da26..cf6076d 100644
--- a/quine.asm
+++ b/quine.asm
@@ -2053,23 +2053,40 @@ cold_start:
 
   ; This was "roll3".
   dq litstring, "3roll", early_create, early_self_codeword, early_here, fetch
-  ; TODO
-  dq lit, 8, packalign, early_here_store
+  dq rax, pop_reg64
+  dq rbx, pop_reg64
+  dq rcx, pop_reg64
+  dq rbx, push_reg64
+  dq rax, push_reg64
+  dq rcx, push_reg64
+  dq pack_next, lit, 8, packalign, early_here_store
 
   ; This was "unroll3".
   dq litstring, "3unroll", early_create, early_self_codeword, early_here
   dq fetch
-  ; TODO
-  dq lit, 8, packalign, early_here_store
+  dq rax, pop_reg64
+  dq rbx, pop_reg64
+  dq rcx, pop_reg64
+  dq rax, push_reg64
+  dq rcx, push_reg64
+  dq rbx, push_reg64
+  dq pack_next, lit, 8, packalign, early_here_store
 
   dq litstring, "dup", early_create, early_self_codeword, early_here, fetch
-  ; TODO
-  dq lit, 8, packalign, early_here_store
+  dq rax, pop_reg64
+  dq rax, push_reg64
+  dq rax, push_reg64
+  dq pack_next, lit, 8, packalign, early_here_store
 
   ; This was "dup2".
   dq litstring, "2dup", early_create, early_self_codeword, early_here, fetch
-  ; TODO
-  dq lit, 8, packalign, early_here_store
+  dq rax, pop_reg64
+  dq rbx, pop_reg64
+  dq rbx, push_reg64
+  dq rax, push_reg64
+  dq rbx, push_reg64
+  dq rax, push_reg64
+  dq pack_next, lit, 8, packalign, early_here_store
 
   ; This was "add".
   dq litstring, "+", early_create, early_self_codeword, early_here, fetch