8279016: JFR Leak Profiler is broken with Shenandoah
Reviewed-by: egahlin, rkennke, mgronlun, wkemper
This commit is contained in:
parent
6811a11e27
commit
0be7118b2f
@ -856,6 +856,10 @@ define SetupRunJtregTestBody
|
|||||||
JTREG_AUTO_PROBLEM_LISTS += ProblemList-zgc.txt
|
JTREG_AUTO_PROBLEM_LISTS += ProblemList-zgc.txt
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifneq ($$(findstring -XX:+UseShenandoahGC, $$(JTREG_ALL_OPTIONS)), )
|
||||||
|
JTREG_AUTO_PROBLEM_LISTS += ProblemList-shenandoah.txt
|
||||||
|
endif
|
||||||
|
|
||||||
ifneq ($$(JTREG_EXTRA_PROBLEM_LISTS), )
|
ifneq ($$(JTREG_EXTRA_PROBLEM_LISTS), )
|
||||||
# Accept both absolute paths as well as relative to the current test root.
|
# Accept both absolute paths as well as relative to the current test root.
|
||||||
$1_JTREG_BASIC_OPTIONS += $$(addprefix $$(JTREG_PROBLEM_LIST_PREFIX), $$(wildcard \
|
$1_JTREG_BASIC_OPTIONS += $$(addprefix $$(JTREG_PROBLEM_LIST_PREFIX), $$(wildcard \
|
||||||
|
@ -34,6 +34,15 @@
|
|||||||
#include "runtime/javaThread.inline.hpp"
|
#include "runtime/javaThread.inline.hpp"
|
||||||
#include "runtime/vmThread.hpp"
|
#include "runtime/vmThread.hpp"
|
||||||
|
|
||||||
|
bool LeakProfiler::is_supported() {
|
||||||
|
if (UseShenandoahGC) {
|
||||||
|
// Leak Profiler uses mark words in the ways that might interfere
|
||||||
|
// with concurrent GC uses of them. This affects Shenandoah.
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
bool LeakProfiler::is_running() {
|
bool LeakProfiler::is_running() {
|
||||||
return ObjectSampler::is_created();
|
return ObjectSampler::is_created();
|
||||||
}
|
}
|
||||||
@ -48,6 +57,12 @@ bool LeakProfiler::start(int sample_count) {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Exit cleanly if not supported
|
||||||
|
if (!is_supported()) {
|
||||||
|
log_trace(jfr, system)("Object sampling is not supported");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
assert(!is_running(), "invariant");
|
assert(!is_running(), "invariant");
|
||||||
assert(sample_count > 0, "invariant");
|
assert(sample_count > 0, "invariant");
|
||||||
|
|
||||||
|
@ -35,6 +35,7 @@ class LeakProfiler : public AllStatic {
|
|||||||
static bool start(int sample_count);
|
static bool start(int sample_count);
|
||||||
static bool stop();
|
static bool stop();
|
||||||
static bool is_running();
|
static bool is_running();
|
||||||
|
static bool is_supported();
|
||||||
|
|
||||||
static void emit_events(int64_t cutoff_ticks, bool emit_all, bool skip_bfs);
|
static void emit_events(int64_t cutoff_ticks, bool emit_all, bool skip_bfs);
|
||||||
static void sample(HeapWord* object, size_t size, JavaThread* thread);
|
static void sample(HeapWord* object, size_t size, JavaThread* thread);
|
||||||
|
60
test/jdk/ProblemList-shenandoah.txt
Normal file
60
test/jdk/ProblemList-shenandoah.txt
Normal file
@ -0,0 +1,60 @@
|
|||||||
|
#
|
||||||
|
# Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
|
||||||
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
|
#
|
||||||
|
# This code is free software; you can redistribute it and/or modify it
|
||||||
|
# under the terms of the GNU General Public License version 2 only, as
|
||||||
|
# published by the Free Software Foundation.
|
||||||
|
#
|
||||||
|
# This code is distributed in the hope that it will be useful, but WITHOUT
|
||||||
|
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
|
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||||
|
# version 2 for more details (a copy is included in the LICENSE file that
|
||||||
|
# accompanied this code).
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License version
|
||||||
|
# 2 along with this work; if not, write to the Free Software Foundation,
|
||||||
|
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
#
|
||||||
|
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||||
|
# or visit www.oracle.com if you need additional information or have any
|
||||||
|
# questions.
|
||||||
|
#
|
||||||
|
|
||||||
|
#############################################################################
|
||||||
|
#
|
||||||
|
# List of quarantined tests for testing with Shenandoah.
|
||||||
|
#
|
||||||
|
#############################################################################
|
||||||
|
|
||||||
|
# Quiet all LeakProfiler tests
|
||||||
|
|
||||||
|
jdk/jfr/api/consumer/TestRecordingFileWrite.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestAllocationTime.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestArrayInformation.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestCircularReference.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestClassLoaderLeak.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestFieldInformation.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestG1.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestHeapDeep.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestHeapShallow.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestLargeRootSet.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestLastKnownHeapUsage.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestListenerLeak.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestMetadataRetention.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestObjectAge.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestObjectDescription.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestObjectSize.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestParallel.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestReferenceChainLimit.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestSanityDefault.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestSerial.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestShenandoah.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestThreadLocalLeak.java 8342951 generic-all
|
||||||
|
jdk/jfr/event/oldobject/TestZ.java 8342951 generic-all
|
||||||
|
jdk/jfr/jcmd/TestJcmdDump.java 8342951 generic-all
|
||||||
|
jdk/jfr/jcmd/TestJcmdDumpPathToGCRoots.java 8342951 generic-all
|
||||||
|
jdk/jfr/jcmd/TestJcmdStartPathToGCRoots.java 8342951 generic-all
|
||||||
|
jdk/jfr/jvm/TestWaste.java 8342951 generic-all
|
||||||
|
jdk/jfr/startupargs/TestOldObjectQueueSize.java 8342951 generic-all
|
||||||
|
|
Loading…
Reference in New Issue
Block a user