diff options
Diffstat (limited to 'src/user/lib/thread.S')
-rw-r--r-- | src/user/lib/thread.S | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/user/lib/thread.S b/src/user/lib/thread.S new file mode 100644 index 0000000..3cd3500 --- /dev/null +++ b/src/user/lib/thread.S @@ -0,0 +1,8 @@ +.section .text +.global chstack +.type chstack, @function +// _Noreturn void chstack(void *arg, void (*fn)(void*), void *esp); +chstack: + mov %rdx, %rsp + call *%rsi + jmp 0 // "exit" |