Commit graph

14 commits

Author SHA1 Message Date
Daniel Kochmański
f4a0e6ee36 modules: [4/n] introduce ecl_module_bignum 2026-03-15 09:46:45 +01:00
Daniel Kochmański
79c56803b5 modules: [1/n] introduce ecl_module_gc
We also remove conditionalization for garbage collector inclusion in autotools.
When we propose an alternative gc, then we may decide to put them back, or to
add necessary ifdef statements directly in files.

Moreover untangle c-stack from the gc code and assign the stack base with a
rough guess only when it is not initialized yet (GC will always fill it).

Finally remove a kludge from ecl_adopt_cpu and disable colleciton until the cpu
is fully initialized.
2026-03-15 09:46:37 +01:00
Daniel Kochmański
df66f26cb6 modules: [0/n] introduce a new structure ecl_module in the system
This will allow us to decouple forward system initialization from the early
process code.
2026-03-15 09:46:31 +01:00
Daniel Kochmański
d6c0be95a9 nucleus: [2/n] move processing unit managament to nucleus 2026-03-13 19:23:06 +01:00
Daniel Kochmański
46b05d88b8 nucleus: [1/n] move processing unit managament to nucleus 2026-03-13 19:23:06 +01:00
Daniel Kochmański
1802d96b91 core: split cl_core_struct in two structure cl_core and ecl_core
ecl_core contains early global environment that is meant to be shared by all
runtimes, while cl_core contains an environment relevant to common lisp.
2026-03-13 19:23:05 +01:00
Daniel Kochmański
b93b2a6486 core: move defacto constants from cl_core structure to global space 2026-03-13 19:23:05 +01:00
Daniel Kochmański
7db0a89f42 stacks: use a manual allocator for stacks
Objects have a well defind extent so there is no need to rely on GC for
them. This change allows us to move stack initialization before garbage
collector is introduced into the system (or even without any GC).
2025-05-26 08:37:06 +02:00
Daniel Kochmański
1b058f0e3a stacks: manually allocate bindings table
This commit removes initial bindings array from the process and allocates it
only in the bds stack. To make fields in the structure less confusing we rename
initial_bindings slot to inherit_bindings_p.

On observable behavior change is that bindings are inherited when the process is
enabled, not when it is created. That was not specified in documentation so it
should be fine to change this behavior. Moreover it makes more sense from the
programmer perspective -- we want to inherit bindings of the process that starts
our thread, not the one that creates it.
2025-05-26 08:36:03 +02:00
Daniel Kochmański
9687a1d33a stacks: move frames stack to a separate structure 2025-05-26 07:43:41 +02:00
Daniel Kochmański
8f00f3494a stacks: rename thread_local_bindings{,_size} to tl_bindings{,_size}
This is strictly cosmetic change.
2025-05-26 07:43:41 +02:00
Daniel Kochmański
f365ebe079 stacks: move the binding stack to a separate structure 2025-05-26 07:43:41 +02:00
Daniel Kochmański
62c8f3f714 threads: get rid of an annoying warning stemming from xopen
We've defined _XOPEN_SOURCE 600 but glibc defines it as 700 or more.
2025-05-13 14:18:10 +02:00
Daniel Kochmański
0f4e9b1e17 core: factor out process managament from thread managament
This is a preliminary step towards coroutines and for switching global env in
single-threaded builds.
2025-03-31 20:44:46 +02:00
Renamed from src/c/threads/process.d (Browse further)