From cb52f5dd0200f66ba6e6b4a3b1db0da6f60cdf9e Mon Sep 17 00:00:00 2001 From: Rose Hogenson Date: Sat, 27 Aug 2022 20:23:23 -0700 Subject: Use reg 255 for swapping. I wanted to use the top reg, for some reason I thought at the time that 127 was the biggest 8-bit number. Obviously it's 255. --- lib/csc/codegen-test.csc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/csc/codegen-test.csc') diff --git a/lib/csc/codegen-test.csc b/lib/csc/codegen-test.csc index 29d1da5..752f250 100644 --- a/lib/csc/codegen-test.csc +++ b/lib/csc/codegen-test.csc @@ -92,9 +92,9 @@ (mov (local 2) (const 1)) (jmp (label 1)) (label 1) - (mov (local 127) (local 1)) + (mov (local 255) (local 1)) (mov (local 1) (local 2)) - (mov (local 2) (local 127)) + (mov (local 2) (local 255)) (mov (local 3) (const 0)) (jmp (label 2)) (label 2) -- cgit v1.3.1