diff options
Diffstat (limited to 'src/main/cpp/blaze.cc')
-rw-r--r-- | src/main/cpp/blaze.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/main/cpp/blaze.cc b/src/main/cpp/blaze.cc index 5813619b68..739dc20ff8 100644 --- a/src/main/cpp/blaze.cc +++ b/src/main/cpp/blaze.cc @@ -420,8 +420,12 @@ static vector<string> GetArgumentArray( // TODO(b/109998449): only assume JDK >= 9 for embedded JDKs if (!globals->options->GetEmbeddedJavabase().empty()) { - // quiet warnings from com.google.protobuf.UnsafeUtil, + // In JDK9 we have seen a slow down when using the default G1 collector + // and thus switch back to parallel gc. + result.push_back("-XX:+UseParallelOldGC"); // see: https://github.com/google/protobuf/issues/3781 + + // quiet warnings from com.google.protobuf.UnsafeUtil, result.push_back("--add-opens=java.base/java.nio=ALL-UNNAMED"); } |