From f9533fc728a1e13916eaff84c31993b885c21a73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maja=20K=C4=85dzio=C5=82ka?= Date: Tue, 7 Mar 2023 00:30:50 +0100 Subject: [PATCH] Don't preserve return stack pointer between interpreted words This isn't done by the expanded interpreter either, and not doing it lets me save 4 bytes. --- README.md | 4 ++-- boot.s | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index a946e66..d59efc8 100644 --- a/README.md +++ b/README.md @@ -153,8 +153,8 @@ Git or GitHub's web interface. This disparity is handled by two Python scripts: ## Free bytes -At this moment, not counting the `55 AA` signature at the end, **496** bytes are used, -leaving 14 bytes for any potential improvements. +At this moment, not counting the `55 AA` signature at the end, **492** bytes are used, +leaving 18 bytes for any potential improvements. Byte saving leaderboard: - Ilya Kurdyukov saved 24 bytes. Thanks! diff --git a/boot.s b/boot.s index dc8c642..d143091 100644 --- a/boot.s +++ b/boot.s @@ -174,7 +174,6 @@ STATE equ $+1 ; Execute the word .execute: -RetSP equ $+1 mov di, RS0 pop bx mov si, .return @@ -182,7 +181,6 @@ RetSP equ $+1 .return: dw .executed .executed: - mov [RetSP], di push bx jmp short InterpreterLoop