Mercurial > hg > truffle
diff src/share/vm/runtime/arguments.cpp @ 12259:ae3e68933caf
Merge
author | adlertz |
---|---|
date | Tue, 17 Sep 2013 05:30:19 -0700 |
parents | bb57d48691f5 01b268b3080a |
children | da051ce490eb |
line wrap: on
line diff
--- a/src/share/vm/runtime/arguments.cpp Thu Sep 12 09:10:14 2013 +0200 +++ b/src/share/vm/runtime/arguments.cpp Tue Sep 17 05:30:19 2013 -0700 @@ -3326,6 +3326,33 @@ return shared_archive_path; } +#ifndef PRODUCT +// Determine whether LogVMOutput should be implicitly turned on. +static bool use_vm_log() { + if (LogCompilation || !FLAG_IS_DEFAULT(LogFile) || + PrintCompilation || PrintInlining || PrintDependencies || PrintNativeNMethods || + PrintDebugInfo || PrintRelocations || PrintNMethods || PrintExceptionHandlers || + PrintAssembly || TraceDeoptimization || TraceDependencies || + (VerifyDependencies && FLAG_IS_CMDLINE(VerifyDependencies))) { + return true; + } + +#ifdef COMPILER1 + if (PrintC1Statistics) { + return true; + } +#endif // COMPILER1 + +#ifdef COMPILER2 + if (PrintOptoAssembly || PrintOptoStatistics) { + return true; + } +#endif // COMPILER2 + + return false; +} +#endif // PRODUCT + // Parse entry point called from JNI_CreateJavaVM jint Arguments::parse(const JavaVMInitArgs* args) { @@ -3617,7 +3644,13 @@ NmethodSweepFraction = 1; } } -#endif + + if (!LogVMOutput && FLAG_IS_DEFAULT(LogVMOutput)) { + if (use_vm_log()) { + LogVMOutput = true; + } + } +#endif // PRODUCT if (PrintCommandLineFlags) { CommandLineFlags::printSetFlags(tty);