39% speed increase from optimizer!

This commit is contained in:
SpookyDervish
2025-09-09 18:03:58 +10:00
parent ab207d982c
commit e137cb88ae
3 changed files with 16 additions and 9 deletions

BIN
out

Binary file not shown.

15
out.asm
View File

@@ -5,11 +5,14 @@ section .text
global _start
_start:
push 0
mov rax, 1000
cmp rax, [rsp + 0]
setg al
movzx rax, al
push rax
push 1
.loop:
mov rax, [rsp + 8]
add rax, 1
mov QWORD [rsp + 8], rax
mov rax, 100000000
cmp rax, [rsp + 8]
jg .loop
mov rax, 60
mov rdi, [rsp + 0]
mov rdi, 0
syscall

View File

@@ -1,3 +1,7 @@
set &var 0
greater 1000 $var &cond
end $cond
set &counter 0
set &cond 1
@loop
add $counter 1 &counter
greater 100000000 $counter &cond
if $cond %loop
end 0