Increase Stack Size on Windows (GCC)
IIRC, In GCC you can provide the --stack,[bytes] parameter to ld.
E.g.
gcc -Wl,--stack,16777216 -o file.exe file.c
To have a stack of 16MiB, I think that the default size is 8MiB.
There are two stack sizes in Windows. The initially commited size, and the total reserved size. You can set both with a STACKSIZE statement in a .def file.