jvm-arguments

How to get VM arguments from inside of Java application?

烈酒焚心 提交于 2019-11-26 01:39:27
问题 I need to check if some option that can be passed to JVM is explicitly set or has its default value. To be more specific: I need to create one specific thread with higher native stack size than the default one, but in case the user wants to take care of such things by himself by specifying the -Xss option I want to create all threads with default stack size (which will be specified by user in -Xss option). I\'ve checked classes like java.lang.System and java.lang.Runtime , but these aren\'t

Java stack overflow error - how to increase the stack size in Eclipse?

大憨熊 提交于 2019-11-26 00:47:57
问题 I am running a program that I\'ve written in Java in Eclipse. The program has a very deep level of recursion for very large inputs. For smaller inputs the program runs fine however when large inputs are given, I get the following error: Exception in thread \"main\" java.lang.StackOverflowError Can this be solved by increasing the Java stack size and if so, how do I do this in Eclipse? Update: @Jon Skeet The code is traversing a parse tree recursively in order to build up a datastructure. So,