Re: RFR: 8319589: Attach from root to a user java process not supported in Mac

2025-06-17 Thread Andrey Turbanov
On Mon, 16 Jun 2025 09:46:11 GMT, Sergey Chernyshev wrote: > Hi all, > > I would like to propose a fix for JDK-8319589. This will allow jcmd and jps > running as root to get the complete list of JVMs running by all users, and to > attach from root to non-root JVMs. Previously, JDK-8197387 int

Re: RFR: 8357995: Use "stdin.encoding" for reading System.in with InputStreamReader/Scanner [core] [v4]

2025-06-05 Thread Andrey Turbanov
On Tue, 3 Jun 2025 07:55:06 GMT, Volkan Yazici wrote: >> Passes the `Charset` read from the `stdin.encoding` system property while >> creating `InputStreamReader` or `Scanner` instances for `System.in`. >> >> `stdin.encoding` is a recently added property for Java 25 in >> [JDK-8350703](https:/

Re: RFR: 8357172: Extend try block in nsk/jdi tests to capture exceptions thrown by Debuggee.classByName()

2025-05-27 Thread Andrey Turbanov
On Tue, 20 May 2025 20:10:20 GMT, Chris Plummer wrote: > Extend try block to cover debuggee.classByname() call. I would suggest > disabling whitespace diffs when doing the review. It makes code movement and > deletions more obvious. > > There are a number of places where I removed a try/catch

Re: RFR: 8356870: HotSpotDiagnosticMXBean.dumpThreads and jcmd Thread.dump_to_file updates [v2]

2025-05-26 Thread Andrey Turbanov
On Sun, 25 May 2025 06:21:05 GMT, Alan Bateman wrote: >> Updates the thread dump generated by HotSpotDiagnosticMXBean.dumpThreads and >> jcmd Thread.dump_to_file to include thread state and lock information. Also >> update the HotSpotDiagnosticMXBean.dumpThreads API description to link to a >>

Re: RFR: 8356693: AOT assembly phase fails with -javaagent

2025-05-13 Thread Andrey Turbanov
On Sun, 11 May 2025 04:57:44 GMT, Ioi Lam wrote: > https://openjdk.org/jeps/483 mentions: > >> To enjoy the benefits of the AOT cache generated during a training run, the >> training run and all subsequent runs must be essentially similar. [...] All >> runs must not use JVMTI agents that can a

Re: RFR: 8351002: com/sun/management/OperatingSystemMXBean cpuLoad tests fail intermittently

2025-03-24 Thread Andrey Turbanov
On Mon, 24 Mar 2025 10:13:34 GMT, Kevin Walls wrote: > These tests have always silently permitted a -1 return value from > OperatingSystemMXBean CPU time methods. > > They need to be stricter, but occasionally Windows 2019 returns a -1 for the > first few calls of these methods. This seems to

Re: RFR: 8229012: When single stepping, the debug agent can cause the thread to remain in interpreter mode after single stepping completes [v3]

2025-01-25 Thread Andrey Turbanov
On Fri, 24 Jan 2025 20:09:31 GMT, Chris Plummer wrote: >> When doing a STEP_OVER, the debug agent does a NotifyFramePop() on the >> current frame as a safety net. After the STEP_OVER completes, the >> NotifyFramePop() is usually still in place. This keeps the thread in >> interp_only mode, wh

Re: RFR: 8344562: Remove security manager dependency from module jdk.jdi

2024-11-19 Thread Andrey Turbanov
On Tue, 19 Nov 2024 18:29:33 GMT, Brian Burkhalter wrote: > Trivial removal of the use of the `SecurityManager` from a single class. src/jdk.jdi/share/classes/com/sun/tools/jdi/VirtualMachineManagerImpl.java line 65: > 63: SecurityManager sm = System.getSecurityManager(); > 64:

Re: RFR: 8344177: Remove SecurityManager and related calls from java.management [v3]

2024-11-19 Thread Andrey Turbanov
On Mon, 18 Nov 2024 17:08:21 GMT, Kevin Walls wrote: >> Remove redundant SecurityManager, AccessController references >> (following on from JDK-8338411: Implement JEP 486: Permanently Disable the >> Security Manager). > > Kevin Walls has updated the pull request incrementally with one additional

Re: RFR: 8343741: SA jstack --mixed should print information about VM locks [v6]

2024-11-19 Thread Andrey Turbanov
On Mon, 18 Nov 2024 20:56:27 GMT, Leonid Mesnik wrote: >> Hi >> Could you please review the the fix that add locks information into SA jhsdb >> stack --mixed output. >> >> Here is the motivation for this rfe and explanation why I add it into SA now. >> >> The information about current owners o

Re: RFR: 8343984: Fix Unsafe address overflow [v7]

2024-11-12 Thread Andrey Turbanov
On Tue, 12 Nov 2024 16:30:12 GMT, Shaojin Wen wrote: >> In the JDK code, there are some places that may cause Unsafe offset >> overflow. The probability of occurrence is low, but if it occurs, it will >> cause JVM crash. > > Shaojin Wen has updated the pull request incrementally with one additi

Re: RFR: 8338383: Implement JEP 491: Synchronize Virtual Threads without Pinning

2024-11-06 Thread Andrey Turbanov
On Thu, 17 Oct 2024 14:28:30 GMT, Patricio Chilano Mateo wrote: > This is the implementation of JEP 491: Synchronize Virtual Threads without > Pinning. See [JEP 491](https://bugs.openjdk.org/browse/JDK-8337395) for > further details. > > In order to make the code review easier the changes hav

Re: RFR: 8331497: Implement JEP 483: Ahead-of-Time Class Loading & Linking [v4]

2024-10-28 Thread Andrey Turbanov
On Thu, 24 Oct 2024 03:01:54 GMT, Ioi Lam wrote: >> This is an implementation of [JEP 483: Ahead-of-Time Class Loading & >> Linking](https://openjdk.org/jeps/483). >> >> >> Note: this is a combined PR of the following individual PRs >> - https://github.com/openjdk/jdk/pull/20516 >> - https

Re: RFR: 8338383: Implementation of Synchronize Virtual Threads without Pinning

2024-10-21 Thread Andrey Turbanov
On Thu, 17 Oct 2024 14:28:30 GMT, Patricio Chilano Mateo wrote: > This is the implementation of JEP 491: Synchronize Virtual Threads without > Pinning. See [JEP 491](https://bugs.openjdk.org/browse/JDK-8337395) for > further details. > > In order to make the code review easier the changes hav

Re: RFR: 8341927: Remove hardcoded SunJCE provider

2024-10-21 Thread Andrey Turbanov
On Wed, 16 Oct 2024 18:47:44 GMT, Matthew Donovan wrote: > In this PR, I removed hard-coded security providers and replaced them with a > system property, test.provider.name. If the property is not specified, the > provider originally used in the test is used: > > Cipher c = Cipher.getInstance

Re: RFR: 8341436: containers/docker/TestJcmdWithSideCar.java takes needlessly long to run [v3]

2024-10-16 Thread Andrey Turbanov
On Mon, 7 Oct 2024 19:37:51 GMT, Sebastian Lövdahl wrote: >> The fix is twofold. >> >> 1. Stop the main container after an iteration is done. The main container is >> started with its runtime defined as 120 seconds, which means that each >> iteration takes 120 seconds. In reality, one iteratio

Re: RFR: 8339307: jhsdb jstack could not trace FFM upcall frame [v3]

2024-09-02 Thread Andrey Turbanov
On Sat, 31 Aug 2024 09:34:09 GMT, Yasumasa Suenaga wrote: >> I attempted to check stack trace in the core generated by [SEGV example in >> upcall](https://github.com/YaSuenag/garakuta/blob/841452d9176dab1ddbb552009c180530eb81190b/NativeSEGV/ffm/upcall/src/main/java/com/yasuenag/garakuta/nativese

Re: RFR: 8204681: Option to include timestamp in hprof filename

2024-08-27 Thread Andrey Turbanov
On Tue, 13 Aug 2024 15:07:17 GMT, Sonia Zaldana Calles wrote: > Hi all, > > This PR addresses [8204681](https://bugs.openjdk.org/browse/JDK-8204681) > enabling support for timestamp expansion in filenames specified in > `-XX:HeapDumpPath` using `%t`. > > As mentioned in this comments for t

Re: RFR: 8337517: Redacted Heap Dumps

2024-08-01 Thread Andrey Turbanov
On Wed, 31 Jul 2024 19:10:41 GMT, Henry Lin wrote: > Adds a command line option `-redact` to `jcmd`, `redact` to `jmap` and > `-XX:+HeapDumpRedacted` enabling redacted heap dumps. When enabled, the > output binary heap dump has zeroes written out in place of the original > primitive values in

Re: RFR: 8315884: New Object to ObjectMonitor mapping [v9]

2024-07-19 Thread Andrey Turbanov
On Mon, 15 Jul 2024 00:50:30 GMT, Axel Boldt-Christmas wrote: >> When inflating a monitor the `ObjectMonitor*` is written directly over the >> `markWord` and any overwritten data is displaced into a displaced >> `markWord`. This is problematic for concurrent GCs which needs extra care or >> l

Re: RFR: 8336254: Virtual thread implementation + test updates

2024-07-19 Thread Andrey Turbanov
On Thu, 11 Jul 2024 17:30:21 GMT, Alan Bateman wrote: > Bringover some of the changes accumulated in the loom repo to the main line, > most of these changes are test updates and have been baking in the loom repo > for several months. The motive is partly to reduce the large set of changes > th

Re: RFR: 8072701: resume001 failed due to ERROR: timeout for waiting for a BreakpintEvent [v3]

2024-07-15 Thread Andrey Turbanov
On Thu, 11 Jul 2024 22:36:05 GMT, Chris Plummer wrote: >> The test hits a breakpoint on thread2 with SUSPEND_EVENT_THREAD policy, so >> only thread2 is suspended. It then does a vm.suspend(), which suspends all >> threads and bumps the suspendCount of thread2 up to 2. It then does an >> eventS

Re: RFR: 8330846: Add stacks of mounted virtual threads to the HotSpot thread dump [v4]

2024-06-03 Thread Andrey Turbanov
On Mon, 3 Jun 2024 08:30:15 GMT, Inigo Mediavilla Saiz wrote: >> Print the stack traces of mounted virtual threads when calling `jcmd >> Thread.print`. > > Inigo Mediavilla Saiz has updated the pull request incrementally with one > additional commit since the last revision: > > Add missing

Re: RFR: 8330534: Update nsk/jdwp tests to use driver instead of othervm

2024-04-22 Thread Andrey Turbanov
On Wed, 17 Apr 2024 20:19:49 GMT, Leonid Mesnik wrote: > The jdwp tests use debugger and debugee. There is no goal to execute debugger > part with all VM flags, they are needed to be used with debugee VM only. > The change is all tests is to don't use System.exit() and use 'driver' > instead of

Re: RFR: JDK-8327474 Review use of java.io.tmpdir in jdk tests [v3]

2024-03-26 Thread Andrey Turbanov
On Thu, 21 Mar 2024 17:13:46 GMT, Bill Huang wrote: >> This task addresses an essential aspect of our testing infrastructure: the >> proper handling and cleanup of temporary files and socket files created >> during test execution. The motivation behind these changes is to prevent the >> accumu

Re: RFR: 8324066: "clhsdb jstack" should not by default scan for j.u.c locks because it can be very slow [v2]

2024-01-27 Thread Andrey Turbanov
On Thu, 18 Jan 2024 16:19:38 GMT, Chris Plummer wrote: >> I noticed that "clhsdb jstack" seemed to hang when I attached to process >> with a somewhat large heap. It had taken over 10 minutes when I finally >> decided to have a look at the SA process (using bin/jstack), which came up >> with th

Re: RFR: 8318682: SA decoding of scalar replaced objects is broken [v3]

2024-01-14 Thread Andrey Turbanov
On Mon, 15 Jan 2024 05:37:02 GMT, Tom Rodriguez wrote: >> The changes for JDK-8287061 didn't update the SA decoding logic and there >> are other places where the decoding has gotten out of sync with HotSpot. >> Some of them can't be tested because they are part of JVMCI but I've added a >> di

Re: RFR: JDK-8310066: Improve test coverage for JVMTI GetThreadState on carrier and mounted vthread

2023-06-26 Thread Andrey Turbanov
On Fri, 23 Jun 2023 01:57:56 GMT, Alex Menkov wrote: > This is follow-up JDK-8307153/JDK-8309612 (JVMTI GetThreadState on carrier > should return STATE_WAITING) > New test tests GetThreadState for different thread states. > The test detected a bug in the implementation, new issue is created: >

Re: RFR: 8306446: java/lang/management/ThreadMXBean/Locks.java transient failures

2023-06-21 Thread Andrey Turbanov
On Thu, 15 Jun 2023 20:34:53 GMT, Kevin Walls wrote: > This test iterates an array of ThreadInfos in a few places (e.g. in the > method doCheck()), and needs to tolerate and ignore nulls, in case a thread > finishes and the test hits an NPE. > > There are other calls like "TM.getThreadInfo(tid

Re: RFR: 8308237: add JDWP and JDI virtual thread support for ThreadReference.PopFrames [v4]

2023-05-22 Thread Andrey Turbanov
On Mon, 22 May 2023 06:35:47 GMT, Chris Plummer wrote: >> This is a follow-on to >> [JDK-8308000](https://bugs.openjdk.org/browse/JDK-8308000) which adds JVMTI >> PopFrames support for virtual thread. For JDWP and JDI this is mostly a spec >> update, although JDI needs minor changes to properl

Re: RFR: 8308400: add ForceEarlyReturn support for virtual threads [v2]

2023-05-22 Thread Andrey Turbanov
On Sat, 20 May 2023 00:21:04 GMT, Serguei Spitsyn wrote: >> This enhancement adds ForceEarlyReturnXXX support for virtual threads. The >> spec defines minimal support that the JVMTI ForceEarlyReturnXXX can be used >> for a virtual thread suspended an an event. >> Actually, the ForceEarlyReturnX

Re: RFR: 8307478: Implementation of Prepare to Restrict The Dynamic Loading of Agents

2023-05-14 Thread Andrey Turbanov
On Wed, 10 May 2023 11:12:49 GMT, Alan Bateman wrote: > This is the implementation for JEP 451. There are two parts to this: > > 1. A multi-line warning is printed when a JVM TI or Java agent is loaded into > a running VM. For JVM TI, the message is printed to stderr from > JvmtiAgent::load. F

Re: RFR: 8307058: Implementation of Generational ZGC [v6]

2023-05-04 Thread Andrey Turbanov
On Thu, 4 May 2023 11:44:14 GMT, Stefan Karlsson wrote: >> Hi all, >> >> Please review the implementation of Generational ZGC, which can be turned on >> by adding -XX:+ZGenerational in addition to using -XX:+UseZGC. Generational >> ZGC is a major rewrite of the non-generational ZGC version tha

Re: RFR: 8306471: Add virtual threads support to JDWP ThreadReference.Stop and JDI ThreadReference.stop()

2023-04-25 Thread Andrey Turbanov
On Wed, 19 Apr 2023 23:40:56 GMT, Chris Plummer wrote: > Note this PR depends on the #13546 PR for the following: > > [JDK-8306434](https://bugs.openjdk.org/browse/JDK-8306434): add support of > virtual threads to JVMTI StopThread > > So it can't be finalized and push until after JDK-8306434 i

Re: RFR: 8304919: Implementation of Virtual Threads [v3]

2023-03-29 Thread Andrey Turbanov
On Wed, 29 Mar 2023 07:31:40 GMT, Alan Bateman wrote: >> JEP 444 proposes to make virtual threads a permanent feature in Java 21. The >> APIs that were preview APIs in Java 19/20 are changed to permanent and their >> `@since`/equivalent are changed to 21 (as per the guidance in JEP 12). The >>

Re: RFR: 8301995: Move invokedynamic resolution information out of ConstantPoolCacheEntry [v6]

2023-03-17 Thread Andrey Turbanov
On Wed, 15 Mar 2023 18:45:00 GMT, Matias Saavedra Silva wrote: >> The current structure used to store the resolution information for >> invokedynamic, ConstantPoolCacheEntry, is difficult to interpret due to its >> ambigious fields f1 and f2. This structure can hold information for fields, >>

Re: RFR: 8292818: replace 96-bit representation for field metadata with variable-sized streams [v6]

2023-03-17 Thread Andrey Turbanov
On Fri, 17 Mar 2023 13:51:05 GMT, Frederic Parain wrote: >> Please review this change re-implementing the FieldInfo data structure. >> >> The FieldInfo array is an old data structure storing fields metadata. It has >> poor extension capabilities, a complex management code because of lack of >>

Re: RFR: 8294977: Convert test/jdk/java tests from ASM library to Classfile API [v5]

2023-03-17 Thread Andrey Turbanov
On Thu, 16 Mar 2023 15:34:58 GMT, Chen Liang wrote: >> Summaries: >> 1. A few recommendations about updating the constant API is made at >> https://mail.openjdk.org/pipermail/classfile-api-dev/2023-March/000233.html >> and I may update this patch shall the API changes be integrated before >> 2.

Integrated: 8303690: Prefer ArrayList to LinkedList in com.sun.jmx.mbeanserver.Introspector

2023-03-07 Thread Andrey Turbanov
The message from this sender included one or more files which could not be scanned for virus detection; do not open these files unless you are certain of the sender's intent. -- On Thu, 2 Mar 2023 20:16:35 GMT, Andrey Tur

RFR: 8303690: Prefer ArrayList to LinkedList in com.sun.jmx.mbeanserver.Introspector

2023-03-06 Thread Andrey Turbanov
`LinkedList` is used as value in `com.sun.jmx.mbeanserver.Introspector.SimpleIntrospector#cache` It's created, filled (with `add`) and then iterated. No removes from the head or something like this. `ArrayList` should be preferred as more efficient and widely used collection. Also I've done some

Integrated: 8303267: Prefer ArrayList to LinkedList in ConcurrentLocksPrinter

2023-03-02 Thread Andrey Turbanov
On Mon, 27 Feb 2023 12:54:24 GMT, Andrey Turbanov wrote: > LinkedList is used as value in > `sun.jvm.hotspot.runtime.ConcurrentLocksPrinter#locksMap` Map. > There is only add/iterator calls on this lists. No removes from the head or > something like this. Not sure why LinkedList w

RFR: 8303267: Prefer ArrayList to LinkedList in ConcurrentLocksPrinter

2023-02-27 Thread Andrey Turbanov
LinkedList is used as value in `sun.jvm.hotspot.runtime.ConcurrentLocksPrinter#locksMap` Map. There is only add/iterator calls on this lists. No removes from the head or something like this. Not sure why LinkedList was used, but ArrayList should be preferred as more efficient and widely used col

Re: RFR: 8299518: HotSpotVirtualMachine shared code across different platforms [v4]

2023-01-09 Thread Andrey Turbanov
On Mon, 9 Jan 2023 03:29:04 GMT, Yi Yang wrote: >> harmless refactor to share code across different platforms of >> VirtualMachineImpl: >> 1. Shared code to process command response after requesting a command >> execution >> 2. Read functionality in SocketInputStream can be reused > > Yi Yang h

Integrated: 8298090: Use String.join() instead of manual loop in DescriptorSupport.toString

2022-12-11 Thread Andrey Turbanov
On Wed, 2 Nov 2022 21:30:51 GMT, Andrey Turbanov wrote: > There is opportunity to use String.join in DescriptorSupport.toString > implementation. Result code is much shorter and clearer. This pull request has now been integrated. Changeset: d646e32b Author:Andrey Turbano

Re: RFR: 8298073: gc/metaspace/CompressedClassSpaceSizeInJmapHeap.java causes test task timeout on macosx

2022-12-08 Thread Andrey Turbanov
On Thu, 8 Dec 2022 03:06:31 GMT, Chris Plummer wrote: > This fixes two separate CRs: > > [JDK-8241293](https://bugs.openjdk.org/browse/JDK-8241293) > CompressedClassSpaceSizeInJmapHeap.java time out after 8 minutes > [JDK-8298073](https://bugs.openjdk.org/browse/JDK-8298073) > gc/metaspace/Com

RFR: 8298090: Use String.join() instead of manual loop in DescriptorSupport.toString

2022-12-05 Thread Andrey Turbanov
There is opportunity to use String.join in DescriptorSupport.toString implementation. Result code is much shorter and clearer. - Commit messages: - [PATCH] Use String.join() instead of manual loop in DescriptorSupport Changes: https://git.openjdk.org/jdk/pull/10960/files Webrev: h

Re: RFR: 8294241: Deprecate URL public constructors

2022-10-27 Thread Andrey Turbanov
On Wed, 26 Oct 2022 16:00:56 GMT, Daniel Fuchs wrote: > Deprecate URL constructors. Developers are encouraged to use `java.net.URI` > to parse or construct any URL. > > The `java.net.URL` class does not itself encode or decode any URL components > according to the escaping mechanism defined in

Re: RFR: 8286212: Cgroup v1 initialization causes NPE on some systems [v3]

2022-10-10 Thread Andrey Turbanov
On Wed, 18 May 2022 18:14:52 GMT, Severin Gehwolf wrote: >> Please review this change to the cgroup v1 subsystem which makes it more >> resilient on some of the stranger systems. Unfortunately, I wasn't able to >> re-create a similar system as the reporter. The idea of using the longest >> sub

Re: RFR: 8288387: GetLocalXXX/SetLocalXXX spec should require suspending target thread [v2]

2022-10-10 Thread Andrey Turbanov
On Thu, 6 Oct 2022 17:31:00 GMT, Serguei Spitsyn wrote: >> The spec of JVM TI GetLocalXXX/SetLocalXXX functions is updated to require >> the target thread to be suspended. If not suspended then the >> JVMTI_ERROR_THREAD_NOT_SUSPENDED error code is returned by the >> implementation. >> >> The

Re: RFR: 8289711: Add container configuration data to mbeans [v10]

2022-09-29 Thread Andrey Turbanov
On Wed, 10 Aug 2022 02:10:25 GMT, xpbob wrote: >> Container configuration information is useful for troubleshooting >> problems,Exposing information in MBeans is ideal for monitoring, jConsole, >> and other scenarios. >> Results the following >> ![图片](https://user-images.githubusercontent.com/7

Integrated: 8293879: Remove unnecessary castings in jdk.hotspot.agent

2022-09-19 Thread Andrey Turbanov
On Thu, 15 Sep 2022 20:49:14 GMT, Andrey Turbanov wrote: > Redundant castings make code harder to read. > Found them by IntelliJ IDEA. > I tried to choose only casts which are definitely safe to remove. > Most generification was done in > [JDK-8241618](https://bugs.openjdk

Re: RFR: 8293879: Remove unnecessary castings in jdk.hotspot.agent

2022-09-19 Thread Andrey Turbanov
On Thu, 15 Sep 2022 20:49:14 GMT, Andrey Turbanov wrote: > Redundant castings make code harder to read. > Found them by IntelliJ IDEA. > I tried to choose only casts which are definitely safe to remove. > Most generification was done in > [JDK-8241618](https://bugs.openjdk

Re: RFR: 8293879: Remove unnecessary castings in jdk.hotspot.agent

2022-09-16 Thread Andrey Turbanov
On Thu, 15 Sep 2022 22:27:25 GMT, Chris Plummer wrote: >> Redundant castings make code harder to read. >> Found them by IntelliJ IDEA. >> I tried to choose only casts which are definitely safe to remove. >> Most generification was done in >> [JDK-8241618](https://bugs.openjdk.org/browse/JDK-8241

RFR: 8293879: Remove unnecessary castings in jdk.hotspot.agent

2022-09-15 Thread Andrey Turbanov
Redundant castings make code harder to read. Found them by IntelliJ IDEA. I tried to choose only casts which are definitely safe to remove. Most generification was done in [JDK-8241618](https://bugs.openjdk.org/browse/JDK-8241618), but casts weren't removed. - Commit messages: - [P

Integrated: 8293647: Avoid unnecessary boxing in jdk.hotspot.agent

2022-09-13 Thread Andrey Turbanov
On Mon, 12 Sep 2022 12:35:30 GMT, Andrey Turbanov wrote: > Usages of methods `Integer.valueOf`, `Boolean.valueOf`, `Long.valueOf` often > can be simplified by using their pair methods > `parseInt`/`parseBoolean`/`parseLong`. This pull request has now been integrated. Changeset:

RFR: 8293647: Avoid unnecessary boxing in jdk.hotspot.agent

2022-09-12 Thread Andrey Turbanov
Usages of methods `Integer.valueOf`, `Boolean.valueOf`, `Long.valueOf` often can be simplified by using their pair methods `parseInt`/`parseBoolean`/`parseLong`. - Commit messages: - 8293647: Avoid unnecessary boxing in jdk.hotspot.agent - [PATCH] Avoid unnecessary boxing in jdk.h

Integrated: 8293432: Use diamond operator in java.management

2022-09-08 Thread Andrey Turbanov
On Mon, 5 Sep 2022 19:56:44 GMT, Andrey Turbanov wrote: > The diamond operator was introduced in Java 7. We can take advantage of this > language feature to make code easier to read. > Tested on Linux release x64. `make test TEST="jdk/java/lang/management > jdk/javax/managemen

Re: RFR: 8293432: Use diamond operator in java.management

2022-09-08 Thread Andrey Turbanov
On Mon, 5 Sep 2022 19:56:44 GMT, Andrey Turbanov wrote: > The diamond operator was introduced in Java 7. We can take advantage of this > language feature to make code easier to read. > Tested on Linux release x64. `make test TEST="jdk/java/lang/management > jdk/javax/managemen

Re: RFR: 8293432: Use diamond operator in java.management

2022-09-06 Thread Andrey Turbanov
On Mon, 5 Sep 2022 19:56:44 GMT, Andrey Turbanov wrote: > The diamond operator was introduced in Java 7. We can take advantage of this > language feature to make code easier to read. > Tested on Linux release x64. `make test TEST="jdk/java/lang/management > jdk/javax/managemen

RFR: 8293432: Use diamond operator in java.management

2022-09-06 Thread Andrey Turbanov
The diamond operator was introduced in Java 7. We can take advantage of this language feature to make code easier to read. Tested on Linux release x64. `make test TEST="jdk/java/lang/management jdk/javax/management jdk/com/sun/jmx jdk/sun/management"` Test summary ==

Integrated: 8292350: Use static methods for hashCode/toString primitives

2022-08-20 Thread Andrey Turbanov
On Wed, 10 Aug 2022 08:01:41 GMT, Andrey Turbanov wrote: > It's a bit shorter and clearer. This pull request has now been integrated. Changeset: 37c0a136 Author: Andrey Turbanov URL: https://git.openjdk.org/jdk/commit/37c0a13647e74fd02823a3f621e986f96904b933 Stats: 8 li

RFR: 8292350: Use static methods for hashCode/toString primitives

2022-08-15 Thread Andrey Turbanov
It's a bit shorter and clearer. - Commit messages: - [PATCH] Use static methods for hashCode/toString primitives Changes: https://git.openjdk.org/jdk/pull/9816/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=9816&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8292350

Integrated: 8289126: Cleanup unnecessary null comparison before instanceof check in jdk.hotspot.agent

2022-06-27 Thread Andrey Turbanov
On Fri, 24 Jun 2022 09:19:33 GMT, Andrey Turbanov wrote: > Update code checks both non-null and instance of a class in jdk.hotspot.agent > module classes. > The checks and explicit casts could also be replaced with pattern matching > for the instanceof operator. > > For exam

Re: RFR: 8289126: Cleanup unnecessary null comparison before instanceof check in jdk.hotspot.agent

2022-06-24 Thread Andrey Turbanov
On Fri, 24 Jun 2022 18:15:26 GMT, Chris Plummer wrote: >I noticed you have 3 tier1 JDI tests timing out on all platforms. I don't see >this in another PR I just reviewed. I know you didn't change JDI, but am >wondering why this is happening in your PR. See [JDK-8289129](https://bugs.openjdk.o

RFR: 8289126: Cleanup unnecessary null comparison before instanceof check in jdk.hotspot.agent

2022-06-24 Thread Andrey Turbanov
Update code checks both non-null and instance of a class in jdk.hotspot.agent module classes. The checks and explicit casts could also be replaced with pattern matching for the instanceof operator. For example, the following code: Object node = tree.getLastSelectedPathComponent();