aboutsummaryrefslogtreecommitdiff
path: root/include/io.s
diff options
context:
space:
mode:
authorMirek Kratochvil <exa.exa@gmail.com>2023-11-01 18:25:26 +0100
committerMirek Kratochvil <exa.exa@gmail.com>2023-11-01 18:25:26 +0100
commit1909e97d4615045e707710a2aaeae8bf702a8355 (patch)
treeacba7fd278ef27dbdb749f936b38a812a056176a /include/io.s
parent32d71ef9f25b4cebb2ae95b4f528bbc02f62ea31 (diff)
parent970ffb4684dbd88bd54e909820bbc5a66a87b18d (diff)
downloaduskel-1909e97d4615045e707710a2aaeae8bf702a8355.tar.gz
uskel-1909e97d4615045e707710a2aaeae8bf702a8355.tar.bz2
Merge branch 'gc-attempt-1'
Diffstat (limited to 'include/io.s')
-rw-r--r--include/io.s4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/io.s b/include/io.s
index 205f144..29a63c9 100644
--- a/include/io.s
+++ b/include/io.s
@@ -4,11 +4,13 @@ _io_s_file:
# | int | -> cont
.thunkcode print
+ needs_alloc $040
thunkto %rsi, $print_fini, $2, %rbp, %rsi
enter 020(%rbp)
# arg -> | ret | cont |
.thunkcode print_fini
+ needs_alloc $0110 #64 bit characters + 8 backup
mov 010(%rsi), %rax
# make a string
@@ -24,7 +26,7 @@ _io_s_file:
shr $1, %rax
jnz print_fini_loop
- mov $0, %rdi #stdin
+ mov $1, %rdi #stdout
mov %rsp, %rdx
sub %r15, %rdx #size
mov %r15, %rsi #buf