forgot tolmac.zig lol

This commit is contained in:
veclav talica 2023-09-20 12:37:49 +05:00
parent a6fd0c8023
commit ec59936d42

20
src/tolmac.zig Normal file
View File

@ -0,0 +1,20 @@
// todo: Interpreter context as binary local variable.
// It would hold memory mappings, as well as error stack.
// todo: Define procedure call for user code.
// todo: Instruction set extensions, such as memory management schemes, non-exhaustive logging,
// exception mechanism, coroutines via yield/resume and etc.
// todo: Threading scheme.
// todo: Extension for native floating point stack ops.
// todo: Try using small code model with nopie/nopic binary.
// idea: Specialized opcodes that have side effects on read and write, such as
// zero-check on push/pop, or jump if condition bit met. This would create a lot
// of permutations tho, we might try to discover which code devices are most used.
// idea: 'JIT' could be done by simple op* compiled binary copying up until `jmpq *(%%rdi)`,
// with immediate operand prelude modified, which could be done procedurally.
pub const Word = u64;
pub const RecursionLimit = 1024;
pub usingnamespace @import("arch/x86-64.zig");