9 Commits

Author SHA1 Message Date
IgorCielniak
e2159bbca2 added memset_bytes, fixed some stack comments, fixed splitby_char and finally implemented splitby_str so splitby if now fully functional 2026-03-20 21:09:44 +01:00
igor
cda34e61bd added some functions to the stdlib 2026-03-18 15:27:01 +01:00
igor
2a1ae2f774 compiler: add -O0/-O2 flags, -v 1..4, whole-word JIT, lazy init, auto-inline control
- Add -O0 (no opts) and -O2 (no opts + no checks) CLI flags
- Add -v 1..4 verbosity: timing, per-function stats, debug dump, optimization diffs
- Whole-word JIT: compile Definition bodies to native x86-64 for CT VM
- Lazy CTMemory/JIT/ctype init (defer ctypes until first CT execution)
- Stack-effect comment parsing for stack-checks
- Peephole rules refactored to module-level dicts with O(1) lookup
- _emitted_start short-circuit (O(1) vs O(n) scan)
- Add --no-auto-inline to disable auto-inlining of small asm bodies
- Fix --ct-run-main to execute after linking (prevent SIGSEGV)
- Stdlib: small optimizations like swap + drop -> nip
2026-03-09 14:04:45 +01:00
IgorCielniak
2f5b1f40b1 added a function to convert the buildt in array to a dynamic array 2026-02-10 11:31:39 +01:00
IgorCielniak
5fb36ac9bc standardized the system of stack effect comments and updated/corrected the existing comments in stdlib and added some that were lacking 2026-02-05 21:36:03 +01:00
IgorCielniak
5ea020100e implemented realloc as well as a bunch of fixes and some small changes like changing the order of arguments for !, making alloc drop etc. 2026-02-02 15:51:58 +01:00
IgorCielniak
77594f45f4 rewritten 'sh' inside nob.sl from asm to l2 code, renamed strcpy to memcpy and put it in mem.sl 2026-01-11 19:26:39 +01:00
IgorCielniak
b9098d9893 changed the way that functions are defined 2026-01-08 15:28:10 +01:00
IgorCielniak
d4dc6ceef5 small refactor and cleanup 2026-01-08 13:15:27 +01:00