!258 8233280 Remove GCLockerInvokesConcurrent relative logic for G1

From: @kuenking111
Reviewed-by: @jvmboy
Signed-off-by: @jvmboy
This commit is contained in:
openeuler-ci-bot 2021-12-10 04:15:36 +00:00 committed by Gitee
commit 85b49acf10
2 changed files with 58 additions and 1 deletions

View File

@ -0,0 +1,52 @@
From cf0e0f39908c8de21d69139e1144c2ad131c1140 Mon Sep 17 00:00:00 2001
From: mashoubing <mashoubing1@huawei.com>
Date: Sun, 26 Sep 2021 17:30:48 +0800
Subject: [PATCH 2/4] 8233280: Remove GCLockerInvokesConcurrent relative logic
for G1
---
.../src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp | 4 ----
.../src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp | 5 ++---
2 files changed, 2 insertions(+), 7 deletions(-)
diff --git a/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp b/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp
index 4f45bba52..060531901 100644
--- a/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp
+++ b/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp
@@ -2394,7 +2394,6 @@ bool G1CollectedHeap::is_user_requested_concurrent_full_gc(GCCause::Cause cause
bool G1CollectedHeap::should_do_concurrent_full_gc(GCCause::Cause cause) {
switch (cause) {
- case GCCause::_gc_locker: return GCLockerInvokesConcurrent;
case GCCause::_g1_humongous_allocation: return true;
case GCCause::_g1_periodic_collection: return true;
default: return is_user_requested_concurrent_full_gc(cause);
@@ -2583,9 +2582,6 @@ void G1CollectedHeap::collect(GCCause::Cause cause) {
gclog_or_tty->print_cr("Periodic GC is denied and not try !");
return;
}
- if (GC_locker::is_active_and_needs_gc()) {
- GC_locker::stall_until_clear();
- }
}
}
} else if (GC_locker::should_discard(cause, gc_count_before)) {
diff --git a/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp b/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp
index d83e6cb65..3225967b3 100644
--- a/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp
+++ b/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp
@@ -354,9 +354,8 @@ private:
// It decides whether an explicit GC should start a concurrent cycle
// instead of doing a STW GC. Currently, a concurrent cycle is
// explicitly started if:
- // (a) cause == _gc_locker and +GCLockerInvokesConcurrent, or
- // (b) cause == _java_lang_system_gc and +ExplicitGCInvokesConcurrent.
- // (c) cause == _g1_humongous_allocation
+ // (a) cause == _java_lang_system_gc and +ExplicitGCInvokesConcurrent.
+ // (b) cause == _g1_humongous_allocation
bool should_do_concurrent_full_gc(GCCause::Cause cause);
// Keeps track of how many "old marking cycles" (i.e., Full GCs or
--
2.22.0

View File

@ -916,7 +916,7 @@ Provides: java-%{javaver}-%{origin}-accessibility%{?1} = %{epoch}:%{version}-%{r
Name: java-%{javaver}-%{origin}
Version: %{javaver}.%{updatever}.%{buildver}
Release: 2
Release: 3
# java-1.5.0-ibm from jpackage.org set Epoch to 1 for unknown reasons
# and this change was brought into RHEL-4. java-1.5.0-ibm packages
# also included the epoch in their virtual provides. This created a
@ -1117,6 +1117,7 @@ Patch219: G1Uncommit-Introduce-G1PeriodGCNotRetry-control-whet.patch
Patch220: JDK-debug-version-crash-when-using-AppCDS.patch
Patch221: 8183543-Aarch64-C2-compilation-often-fails-with-fail--last.patch
Patch222: 8273111-Default-timezone-should-return-zone-ID-if-locatiome-is-valid-but-not-canonicalization-on-linux.patch
Patch223: 8233280-Remove-GCLockerInvokesConcurrent-relative-logic-for-G1.patch
# 8u312
@ -1584,6 +1585,7 @@ pushd %{top_level_dir_name}
%patch220 -p1
%patch221 -p1
%patch222 -p1
%patch223 -p1
popd
# System library fixes
@ -2201,6 +2203,9 @@ require "copy_jdk_configs.lua"
%endif
%changelog
* Fri Dec 10 2021 kuenking111 <wangkun49@huawei.com> - 1:1.8.0.312-b07.3
- add 8233280-Remove-GCLockerInvokesConcurrent-relative-logic-for-G1.patch
* Fri Dec 10 2021 kuenking111 <wangkun49@huawei.com> - 1:1.8.0.312-b07.2
- add 8273111-Default-timezone-should-return-zone-ID-if-locatiome-is-valid-but-not-canonicalization-on-linux.patch