Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v7]

2022-08-31 Thread David Holmes
On Thu, 1 Sep 2022 06:42:06 GMT, Ioi Lam wrote: >> src/hotspot/share/classfile/protectionDomainCache.hpp line 33: >> >>> 31: >>> 32: // The ProtectionDomainCacheTable maps all >>> java.security.ProtectionDomain objects that are >>> 33: // registered by DictionaryEntry::add_protection_domain()

Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v7]

2022-08-31 Thread Ioi Lam
On Thu, 1 Sep 2022 04:12:32 GMT, David Holmes wrote: >> Coleen Phillimore has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Fix comments, add assert. > > src/hotspot/share/classfile/protectionDomainCache.hpp line 33: > >> 31: >> 32: // T

Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v7]

2022-08-31 Thread David Holmes
On Wed, 31 Aug 2022 12:39:08 GMT, Coleen Phillimore wrote: >> Please review this simple conversion for the ProtectionDomainCacheTable from >> Old Hashtable to ResourceHashtable. There are specific tests for this table >> in test/hotspot/jtreg/runtime/Dictionary and >> serviceability/dcmd/vm/D

Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v4]

2022-08-31 Thread David Holmes
On Wed, 31 Aug 2022 12:30:24 GMT, Coleen Phillimore wrote: >> I still can't decipher what this "map" actually holds. What does the unique >> WeakHandle actually refer to? > > WeakHandles are wrappers around a pointer to an oop that has been allocated > in OopStorage. We cannot hold oops direct

Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v7]

2022-08-31 Thread David Holmes
On Wed, 31 Aug 2022 12:39:08 GMT, Coleen Phillimore wrote: >> Please review this simple conversion for the ProtectionDomainCacheTable from >> Old Hashtable to ResourceHashtable. There are specific tests for this table >> in test/hotspot/jtreg/runtime/Dictionary and >> serviceability/dcmd/vm/D

Re: RFR: 8175382: clhsdb pmap should print the end addresses of the load modules

2022-08-31 Thread Yasumasa Suenaga
On Tue, 30 Aug 2022 23:04:18 GMT, Chris Plummer wrote: > The clhsdb 'pmap' command prints the start addresses and the sizes of the > various load modules. It would be more intuitive to have the end address > printed as the VM.dynlibs jcmd does. > > Before: > > 0x7f8839c38000 5920K /usr/l

RFR: 8293010: JDI ObjectReference/referringObjects/referringObjects001 fails assert(env->is_enabled(JVMTI_EVENT_OBJECT_FREE)) failed: checking

2022-08-31 Thread Serguei Spitsyn
The problem is that the following assert in the JvmtiExport::post_object_free is wrong: ` assert(env->is_enabled(JVMTI_EVENT_OBJECT_FREE), "checking");` Even though the condition was checked before, it can be changed later as it is racy by JVM TI design. It has to be replaced with the check:

Re: RFR: 7124710: interleaved RedefineClasses() and RetransformClasses() calls may have a problem [v2]

2022-08-31 Thread Alex Menkov
On Wed, 31 Aug 2022 00:01:29 GMT, Serguei Spitsyn wrote: >> Alex Menkov has updated the pull request incrementally with one additional >> commit since the last revision: >> >> updated comments > > src/hotspot/share/classfile/klassFactory.cpp line 135: > >> 133: if (state != NULL) { >> 13

Re: RFR: 7124710: interleaved RedefineClasses() and RetransformClasses() calls may have a problem [v2]

2022-08-31 Thread Alex Menkov
> The problem is RedefineClasses does not update cached_class_bytes, so > subsequent RetransformClasses gets obsolete class bytes (this are testcases > 3-6 from the new test) > > cached_class_bytes are set when an agent instruments the class from > ClassFileLoadHook. > After successful Redefine

Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v3]

2022-08-31 Thread Coleen Phillimore
On Wed, 31 Aug 2022 05:11:33 GMT, David Holmes wrote: >> I think you should add an assert that the `protection_domain.resolve()` >> never returns null, with a comment explaining why. > > I agree. In general if code is using WeakHandle's then I would expect to see > null checks. I added the com

Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v3]

2022-08-31 Thread Coleen Phillimore
On Wed, 31 Aug 2022 05:13:17 GMT, David Holmes wrote: >> This one (not the one I removed), is called by dictionary.cpp - the pd_set >> is a linked list of ProtectionDomainEntry, where we don't keep the >> WeakHandle alive when looking at the value. > > I don't understand your point. My point is

Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v7]

2022-08-31 Thread Coleen Phillimore
> Please review this simple conversion for the ProtectionDomainCacheTable from > Old Hashtable to ResourceHashtable. There are specific tests for this table > in test/hotspot/jtreg/runtime/Dictionary and > serviceability/dcmd/vm/DictionaryStatsTest.java. > Also tested with tier1-7. Coleen Phil

Re: RFR: 8292375: Convert ProtectionDomainCacheTable to ResourceHashtable [v4]

2022-08-31 Thread Coleen Phillimore
On Wed, 31 Aug 2022 05:15:22 GMT, David Holmes wrote: >> Okay, I added your comment. > > I still can't decipher what this "map" actually holds. What does the unique > WeakHandle actually refer to? WeakHandles are wrappers around a pointer to an oop that has been allocated in OopStorage. We ca

Re: RFR: 8283627: Outdated comment in MachineDescriptionTwosComplement.isLP64

2022-08-31 Thread Serguei Spitsyn
On Mon, 22 Aug 2022 15:06:31 GMT, Daniel Skantz wrote: > Update MachineDescriptionTwosComplement.java comment to indicate that LP64 > machines are no longer uncommon. This correction looks okay modulo comment from Chris about one more place. Thanks, Serguei - Marked as reviewed by

Re: RFR: 8175382: clhsdb pmap should print the end addresses of the load modules

2022-08-31 Thread Serguei Spitsyn
On Tue, 30 Aug 2022 23:04:18 GMT, Chris Plummer wrote: > The clhsdb 'pmap' command prints the start addresses and the sizes of the > various load modules. It would be more intuitive to have the end address > printed as the VM.dynlibs jcmd does. > > Before: > > 0x7f8839c38000 5920K /usr/l

Withdrawn: JDK-8292595: jdwp utf_util getWideString might leak memory

2022-08-31 Thread Matthias Baesken
On Thu, 18 Aug 2022 11:51:52 GMT, Matthias Baesken wrote: > There seems to be a case where utf_util.c getWideString might leak memory in > an early return. This pull request has been closed without being integrated. - PR: https://git.openjdk.org/jdk/pull/9918