logoalt Hacker News

stickfigure • yesterday at 8:15 PM • 1 reply • view on HN

I don't see why this is problematic. Stack is just memory, you can allocate it by incrementing a pointer. Any amount you want, really.

Apache modules worked like this (still do, presumably). Each request has a stack; allocations bump the stack pointer; when a request is finished, the stack pointer is reset. Incredibly efficient as long as you don't need to keep memory longer than a single request.

Looks like in Goose, each scope acts like an apache "request".


Replies

abcd_f • yesterday at 8:27 PM

In Windows, by default, thread's stack is capped at 1MB. Main thread gets more but that's somewhat off the point.

➕ show 2 replies