The compiler in the server VM now provides correct stack backtraces for all "cold" built-in exceptions. For performance purposes, when such an exception is thrown a few times, the method may be recompiled. After recompilation, the compiler may choose a faster tactic using preallocated exceptions that do not provide a stack trace. To disable completely the use of preallocated exceptions, use this new flag: -XX:-OmitStackTraceInFastThrow
[url]http://stackoverflow.com/questions/1142007/why-does-log4j-disable-stack-trace-after-lots-of-repetition-of-the-same-excepti[/url]
[url]http://java.sun.com/j2se/1.5.0/relnotes.html#hotspot[/url]
[url]http://stackoverflow.com/questions/1142007/why-does-log4j-disable-stack-trace-after-lots-of-repetition-of-the-same-excepti[/url]
[url]http://java.sun.com/j2se/1.5.0/relnotes.html#hotspot[/url]
本文介绍如何通过设置新的JVM标志-XX:-OmitStackTraceInFastThrow来完全禁用使用预分配异常,这些异常在多次抛出后为了性能而被编译器采用,但不提供堆栈跟踪。
4769

被折叠的 条评论
为什么被折叠?



