From 8c0c0b0dad6a7ddf2b3075db2285dce8130ef2d0 Mon Sep 17 00:00:00 2001 From: zinc Date: Thu, 15 Oct 2026 14:25:01 +0330 Subject: actors: micro workers map a copy-on-write snapshot too; inherited input is only the unread bytes; worker stacks 4 MB --- src/core/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/core') diff --git a/src/core/core.c b/src/core/core.c index 77c4a99..648f54a 100644 --- a/src/core/core.c +++ b/src/core/core.c @@ -7688,7 +7688,7 @@ static Cell context_start(Cell entry, Cell channel) { memcpy(context->callback_snapshot, ffi_cb, sizeof ffi_cb); memcpy(context->symbol_snapshot, ffi_sym, sizeof ffi_sym); memcpy(context->library_snapshot, ffi_lib, sizeof ffi_lib); context->ffi_symbols = ffi_nsym; context->ffi_libraries = ffi_nlib; context->ffi_libm = ffi_tried_libm; #endif - pthread_attr_init(&attributes); pthread_attr_setstacksize(&attributes, 16u << 20); + pthread_attr_init(&attributes); pthread_attr_setstacksize(&attributes, 4u << 20); /* the vm keeps its own stacks in vm memory; 4 MB of address space covers the deepest native recursion (jit compile, o3) */ i = pthread_create(&context->thread, &attributes, context_worker, context); pthread_attr_destroy(&attributes); if (i) goto failed; context->parent_channel.next = context_channels; context_channels = &context->parent_channel; -- cgit v1.2.3