[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-serviceability-dev
Subject:    Re: RFR: 8308762: Metaspace leak with Instrumentation.retransform [v4]
From:       Coleen Phillimore <coleenp () openjdk ! org>
Date:       2023-07-28 12:49:46
Message-ID: LuVK-eMt-g6iY5y1tdxAKbsinCoUGkoSR5NLy-5gj-E=.ce490669-3755-443f-bbff-5c347456828c () github ! com
[Download RAW message or body]

On Tue, 18 Jul 2023 16:48:55 GMT, Jean-Philippe Bempel <jpbempel@openjdk.org> wrote:

> > Fix a small leak in constant pool merging during retransformation of a class. If \
> > this class has a catch block with `Throwable`, the class `Throwable` is \
> > pre-resolved in the constant pool, while all the other classes are in a \
> > unresolved state. So the constant pool merging process was considering the entry \
> > with pre-resolved class as different compared to the destination and create a new \
> > entry. We now try to consider it as equal specially for Methodref/Fieldref.
> 
> Jean-Philippe Bempel has refreshed the contents of this pull request, and previous \
> commits have been removed. The incremental views will show differences compared to \
> the previous content of the PR. The pull request contains one new commit since the \
> last revision: 
> Revert resolved class to unresolved for comparison
> 
> remove is_unresolved_class_mismatch

src/hotspot/share/prims/jvmtiRedefineClasses.cpp line 1710:

> 1708:                                               *merge_cp_p, scratch_i)) {
> 1709:         // The mismatch in compare_entry_to() above is because of a
> 1710:         // resolved versus unresolved class entry at the same index

I'm sorry for the piecemeal review.   There's another comment that mentions this \
comment that should be removed.  It starts with this:

-      // The find_matching_entry() call above could fail to find a match

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/14780#discussion_r1277505986


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic