RFR: 8264711: More runtime TRAPS cleanups

2021-04-05 Thread Harold Seigel
Please review this additional cleanup of use of TRAPS in hotspot runtime code. The changes were tested with Mach5 tiers 1-2 on Linux, Mac OS, and Windows and Mach5 tiers 3-5 on Linux x64. Thanks, Harold - Commit messages: - 8264711: More runtime TRAPS cleanups Changes: https://g

Re: RFR: 8264711: More runtime TRAPS cleanups

2021-04-05 Thread Lois Foltan
On Mon, 5 Apr 2021 17:57:13 GMT, Harold Seigel wrote: > Please review this additional cleanup of use of TRAPS in hotspot runtime > code. The changes were tested with Mach5 tiers 1-2 on Linux, Mac OS, and > Windows and Mach5 tiers 3-5 on Linux x64. > > Thanks, Harold Looks good Harold. One m

Re: RFR: 8264711: More runtime TRAPS cleanups

2021-04-05 Thread Patricio Chilano Mateo
On Mon, 5 Apr 2021 17:57:13 GMT, Harold Seigel wrote: > Please review this additional cleanup of use of TRAPS in hotspot runtime > code. The changes were tested with Mach5 tiers 1-2 on Linux, Mac OS, and > Windows and Mach5 tiers 3-5 on Linux x64. > > Thanks, Harold Hi Harold, I looked at t

Re: RFR: 8263565: NPE was thrown when sun.jvm.hotspot.rmi.serverNamePrefix was set

2021-04-05 Thread Alex Menkov
On Mon, 15 Mar 2021 02:01:12 GMT, Yasumasa Suenaga wrote: > NPE was thrown when I set server name prefix for debugd as following: > > $ jhsdb -J-Dsun.jvm.hotspot.rmi.serverNamePrefix=test debugd --pid 781 > Attaching to process ID 781 and starting RMI services, please wait... > Error attaching t

Re: RFR: 8264711: More runtime TRAPS cleanups [v2]

2021-04-05 Thread Harold Seigel
> Please review this additional cleanup of use of TRAPS in hotspot runtime > code. The changes were tested with Mach5 tiers 1-2 on Linux, Mac OS, and > Windows and Mach5 tiers 3-5 on Linux x64. > > Thanks, Harold Harold Seigel has updated the pull request incrementally with one additional com

Re: RFR: 8264711: More runtime TRAPS cleanups [v2]

2021-04-05 Thread Harold Seigel
On Mon, 5 Apr 2021 19:11:49 GMT, Patricio Chilano Mateo wrote: >> Harold Seigel has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Undo change to ObjectSynchronizer::jni_exit() > > Hi Harold, > > I looked at the changes to synchronization

Re: RFR: 8264686: ClhsdbTestConnectArgument.java should use SATestUtils::validateSADebugDPrivileges

2021-04-05 Thread Chris Plummer
On Mon, 5 Apr 2021 01:45:15 GMT, Yasumasa Suenaga wrote: > [JDK-8263670](https://bugs.openjdk.java.net/browse/JDK-8263670) has > introduced `SATestUtils::validateSADebugDPrivileges` to check privileges for > on OS X. > > https://github.com/openjdk/jdk/blob/a209ed01bafb7721d6b733d1c4bd3f1776463

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v2]

2021-04-05 Thread Chris Plummer
On Mon, 5 Apr 2021 00:27:35 GMT, Yasumasa Suenaga wrote: >> src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/SALauncher.java line 89: >> >>> 87: if (canConnectToRemote) { >>> 88: System.out.println(" or jhsdb " + mode + " >>> --connect debugserver"); >>> 89:

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v2]

2021-04-05 Thread Chris Plummer
On Mon, 5 Apr 2021 00:25:38 GMT, Yasumasa Suenaga wrote: >> `jhsdb debugd` will start RMI registry by default, but we want to prevent it >> due to port confliction in some cases. We can control it with >> `sun.jvm.hotspot.rmi.startRegistry` system property. However we have no way >> to set it

Re: *Address.hashCode ignore the upper 32 bits of a long value

2021-04-05 Thread Chris Plummer
[moving to serviceability-dev] Hi, I'm not sure if Address hashcodes are even used by SA, and if they are, I doubt this slightly improved hash would make a noticeable difference. However, if you want to pursue this change just to get started with making OpenJDK contributions, I'm ok with that

Re: RFR: 8264711: More runtime TRAPS cleanups [v2]

2021-04-05 Thread Patricio Chilano Mateo
On Mon, 5 Apr 2021 20:27:53 GMT, Harold Seigel wrote: >> Please review this additional cleanup of use of TRAPS in hotspot runtime >> code. The changes were tested with Mach5 tiers 1-2 on Linux, Mac OS, and >> Windows and Mach5 tiers 3-5 on Linux x64. >> >> Thanks, Harold > > Harold Seigel has

Re: RFR: 8264711: More runtime TRAPS cleanups [v2]

2021-04-05 Thread Patricio Chilano Mateo
On Mon, 5 Apr 2021 20:24:31 GMT, Harold Seigel wrote: > Thanks Lois and Patricio for reviewing the change! > I removed my bogus change to ObjectSynchronizer::jni_exit() which also made > calls consistent in jfrJavaSupport.cpp. > Harold Thanks Harold! Fix looks good. - PR: https://g

Re: RFR: 8264711: More runtime TRAPS cleanups [v2]

2021-04-05 Thread David Holmes
On Mon, 5 Apr 2021 20:27:53 GMT, Harold Seigel wrote: >> Please review this additional cleanup of use of TRAPS in hotspot runtime >> code. The changes were tested with Mach5 tiers 1-2 on Linux, Mac OS, and >> Windows and Mach5 tiers 3-5 on Linux x64. >> >> Thanks, Harold > > Harold Seigel has

Re: RFR: 8264711: More runtime TRAPS cleanups

2021-04-05 Thread David Holmes
On 6/04/2021 5:14 am, Patricio Chilano Mateo wrote: src/hotspot/share/prims/jni.cpp line 2738: 2736: 2737: Handle obj(THREAD, JNIHandles::resolve_non_null(jobj)); 2738: ObjectSynchronizer::jni_exit(THREAD->as_Java_thread(), obj()); Here we would return JNI_ERR if we throw IMSE from jni_ex

Integrated: 8264686: ClhsdbTestConnectArgument.java should use SATestUtils::validateSADebugDPrivileges

2021-04-05 Thread Yasumasa Suenaga
On Mon, 5 Apr 2021 01:45:15 GMT, Yasumasa Suenaga wrote: > [JDK-8263670](https://bugs.openjdk.java.net/browse/JDK-8263670) has > introduced `SATestUtils::validateSADebugDPrivileges` to check privileges for > on OS X. > > https://github.com/openjdk/jdk/blob/a209ed01bafb7721d6b733d1c4bd3f1776463

Integrated: 8263565: NPE was thrown when sun.jvm.hotspot.rmi.serverNamePrefix was set

2021-04-05 Thread Yasumasa Suenaga
On Mon, 15 Mar 2021 02:01:12 GMT, Yasumasa Suenaga wrote: > NPE was thrown when I set server name prefix for debugd as following: > > $ jhsdb -J-Dsun.jvm.hotspot.rmi.serverNamePrefix=test debugd --pid 781 > Attaching to process ID 781 and starting RMI services, please wait... > Error attaching t

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v3]

2021-04-05 Thread Yasumasa Suenaga
On Mon, 5 Apr 2021 20:57:34 GMT, Chris Plummer wrote: > On the other hand, maybe you could go with just the id@debugserver:1234 > example and leave the other 3 off. The syntax does clearly show the id and > port are optional. Agree, I left `id@debugserver:1234` only in new commit. ---

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v2]

2021-04-05 Thread Yasumasa Suenaga
On Mon, 5 Apr 2021 20:50:30 GMT, Chris Plummer wrote: >> Yasumasa Suenaga has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Fix comments > > test/hotspot/jtreg/serviceability/sa/sadebugd/DebugdRmidTest.java line 51: > >> 49: JDKTo

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v3]

2021-04-05 Thread Yasumasa Suenaga
> `jhsdb debugd` will start RMI registry by default, but we want to prevent it > due to port confliction in some cases. We can control it with > `sun.jvm.hotspot.rmi.startRegistry` system property. However we have no way > to set it excepting system property. jhsdb should provide the way to set

Integrated: 8264411: serviceability/jvmti/HeapMonitor tests intermittently fail due to large TLAB size

2021-04-05 Thread Hui Shi
On Tue, 30 Mar 2021 12:02:40 GMT, Hui Shi wrote: > …ue to large TLAB size > > serviceability/jvmti/HeapMonitor tests intermittently fail when using > PS/Serial GC, original test has implicit assumptions on TLAB size and depends > on allocate fix amount of objects to consume TLAB and trigger ob

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v2]

2021-04-05 Thread Chris Plummer
On Tue, 6 Apr 2021 00:56:08 GMT, Yasumasa Suenaga wrote: >> test/hotspot/jtreg/serviceability/sa/sadebugd/DebugdRmidTest.java line 51: >> >>> 49: JDKToolLauncher rmidLauncher = >>> JDKToolLauncher.createUsingTestJDK("rmid"); >>> 50: >>> rmidLauncher.addToolArg("-J-Dsun.rmi.acti

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v2]

2021-04-05 Thread Yasumasa Suenaga
On Tue, 6 Apr 2021 01:42:45 GMT, Chris Plummer wrote: >> They are needed. >> >> If we don't give `execPolicy=none`, we can see warning on console. >> SA code would run on rmid, so we need to add module. > > I was actually just referring to `--add-modules`, but github added a few > lines before

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v2]

2021-04-05 Thread Chris Plummer
On Tue, 6 Apr 2021 02:46:40 GMT, Yasumasa Suenaga wrote: >> I was actually just referring to `--add-modules`, but github added a few >> lines before the one I selected. >> >> I guess I'm not fully understanding what `rmid` is for in this context, and >> how it relates to the `rmiregistry` comm

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v2]

2021-04-05 Thread Yasumasa Suenaga
On Tue, 6 Apr 2021 03:16:29 GMT, Chris Plummer wrote: >> SA has RMI remote object, it will be handled in RMI registry. >> We can see following exception without `--add-modules`. >> >> $ jhsdb debugd --pid 40339 --disableregistry --hostname localhost >> --registryport 1098 >> Attaching to proces

Re: RFR: 8263636: Add --disableregistry option to jhsdb debugd [v2]

2021-04-05 Thread Chris Plummer
On Tue, 6 Apr 2021 03:32:25 GMT, Yasumasa Suenaga wrote: >> Both of the above are using `--disableregistry`. Is that what you meant to >> do? I would think that you would not want that on the first one. > > Sorry, the correct commands are as follows: > > * console 1 (start RMI registry) > *