Initially used forking due to recommendations on cosmopolitan libc. It appears they're actively improving threading support, so will need to reassess if threads would be preferable to forking.
struct ths* opt_out_thread -- needn't be initialiized and is always clobbered except when it isn't specified, in which case, the thread is kind of detached and will (currently) just leak the stack / tls memory
Cosmopolitan Libc v2.1 now supports pthreads. That includes detached threads, which are currently automatically reclaimed on pthread_create entry or __cxa_finalize.
Initially used forking due to recommendations on cosmopolitan libc. It appears they're actively improving threading support, so will need to reassess if threads would be preferable to forking.
Might be a bit on this... I don't see a good way to have detached threads in cosmopolitan libc: https://justine.lol/cosmopolitan/documentation.html#_spawn
No point in just leaking memory.