a****r 发帖数: 71 | 1 跑matlab做DFS,recursion limit可以设到800,再大就直接crash了,请教怎么能调大
点,看到有人可以设到上万。 | k**********g 发帖数: 989 | 2
http://superuser.com/questions/340239/how-to-increase-stack-siz
Also, try to identify where the stack limit overflow is caused by the C/C++
code or Java code, because their stack limits and usage patterns are
completely different. C/C++ code use the OS thread stack directly; Managed
languages such as .NET (C#) and Java had their own abstractions over OS
thread.
MATLAB itself is implemented using a mixture of C/C++ and Java.
For Java code, increase both the Java stack size and the Java heap size. http://stackoverflow.com/questions/4967885/jvm-option-xss-what-does-it-do-exactly
Finally, usage of the stack can be reduced by allocating variables on the
heap instead, i.e. using malloc or new instead of local variables.
【在 a****r 的大作中提到】 : 跑matlab做DFS,recursion limit可以设到800,再大就直接crash了,请教怎么能调大 : 点,看到有人可以设到上万。
|
|