It's limited by the size of the temporary stack during exec, and platform-specific. The smallest seems to be 100 4k pages (less space for argv and Tos, I suppose). Newer variants of the system raise that to the size of the stack segment (eg, 16 Mbytes), which is still platform-specific. In fact, glancing at sysproc.c, I'm not sure why it's limited to TSTKSIZ given it goes on to allocate a much bigger segment to put them in, but even if that could easily be removed, currently that is the limit.