What does “ulimit -s unlimited” do?

后端 未结 3 1684
遇见更好的自我
遇见更好的自我 2020-12-02 15:08

There are understandably many related questions on stack allocation

What and where are the stack and heap?

Why is there a limit on the stack size?

Si

3条回答
  •  长情又很酷
    2020-12-02 16:00

    ulimit -s unlimited lets the stack grow unlimited.

    This may prevent your program from crashing if you write programs by recursion, especially if your programs are not tail recursive (compilers can "optimize" those), and the depth of recursion is large.

提交回复
热议问题