Comment

Comment by halayli

Segmented stacks will take much more space. One of the reasons I went with stack copy is because it allows me to create a million lthreads if I wanted without worrying about memory.

Lthread is in C, an environment where you control/manage your memory. Using slab allocators and high performance malloc like jemalloc, you can avoid allocating a lot of your variables on the stack and the stack copy will become minimal. In most of the production code I have running using lthread, stack copying is on the average of 300 bytes.

parent halayli 13 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton