RFR (XS): 8234608: [TESTBUG] Memory leak in gc/g1/unloading/libdefine.cpp
Thomas Schatzl
thomas.schatzl at oracle.com
Tue Jan 28 14:23:52 UTC 2020
Hi Ian/Man,
On 28.01.20 04:13, Man Cao wrote:
> Hi all,
>
> Could anyone review this small patch contributed by my colleague Ian Rogers
> (irogers at google.com)?
> Bug: https://bugs.openjdk.java.net/browse/JDK-8234608
> Webrev: https://cr.openjdk.java.net/~manc/8234608/webrev.00/
>
> -Man
>
the change looks good - but the test testing this is broken. In fact,
the tests doing the redefinition via JVMTI do not even run at all. This
may be why the error that has been "fixed" in this change about passing
the byte stream to the RedefineClass method has never been noticed before.
I did some hacking to enable redefinition in the tests, and then
immediately had to fix the JNI method name, which once more indicates
that the appropriate tests were never run... :(
My changes are available at
http://cr.openjdk.java.net/~tschatzl/8234608/webrev/ ; however the
test(s) fail at the RedefineClasses call (with and without your patch) with
[...]vmTestbase/gc/g1/unloading/libdefine.cpp: Failed to call
RedefineClasses():
the function returned error 60
For more info about this error see the JVMTI spec
which means
JVMTI_ERROR_INVALID_CLASS_FORMAT (60)
A new class file is malformed (the VM would return a
ClassFormatError).
I have no further clue about what's wrong here. Maybe you are
interested/have time to investigate more but I need to give up for today
at least. Otherwise it's probably best to just add some links to the CR
for somebody else to continue.
Thanks,
Thomas
More information about the hotspot-gc-dev
mailing list