-
Notifications
You must be signed in to change notification settings - Fork 2
quek/chocoforth
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
LiSP の息抜きにちょっこと Forth でも作ってみる。 Direct threaded code 64bit Linux もとは jonesforth です。 http://annexia.org/forth (gdb) p/x *(long*)(var_latest)@10 $3 = {0x401188, 0x455552540420, 0xd7ff419090909090, 0x400828, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0} p *(char*)($rdi)@$rcx p/x *(char*)($rdi-24)@24 %rax Return value %rbx Callee saved %rcx 4th argument %rdx 3rd argument %rsi 2nd argument %rdi 1st argument %rbp Callee saved %rsp Stack pointer %r8 5th argument %r9 6th argument %r10 Callee saved %r11 Used for linking %r12 Unused for C %r13 Callee saved %r14 Callee saved %r15 Callee saved <<Direct Threaded Code>> mov r15, _ENTER _ENTER: PUSHRSP rsi pop rsi NEXT DOUBLE: nop nop nop nop nop call r15 .code: DUP PLUS EXIT DUP: mov rax, rsp push rax NEXT EXIT: POPRSP rsi NEXT <<Indirect Threaded Code>> DOUBLE: DOCOL ; codeword DUP PLUS EXIT DUP: DUP_code ; codeword DUP_code: mov rax, rsp push rax NEXT EXIT: EXIT_code ; codeword EXIT_code: POPRSP rsi NEXT DOCOL: PUSHRSP rsi add rax, CELLL mov rsi, rax NEXT
About
Forth: Direct threaded code, 64 bit Linux
Topics
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published