Re: RFR: 8343610: InOutPathTest jpackage test produces invalid app image on macOS

2024-11-05 Thread Matthias Baesken
On Tue, 5 Nov 2024 22:42:13 GMT, Alexey Semenyuk wrote: > can you try this fix in your environment? Sure, I added the patch to our build/test queue . - PR Comment: https://git.openjdk.org/jdk/pull/21909#issuecomment-2458923465

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

2024-11-05 Thread Ioi Lam
On Wed, 6 Nov 2024 04:52:56 GMT, David Holmes wrote: > > I've been using AOT in class names and aot in function/variable names. I > > think that's consistent with HotSpot convention. > > As an acronym I think AOT in capitals should be preferred even in > function/variable names. I searched fo

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

2024-11-05 Thread Axel Boldt-Christmas
On Wed, 6 Nov 2024 00:08:16 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

Re: RFR: 8339783: Implement JEP 479: Remove the Windows 32-bit x86 Port [v30]

2024-11-05 Thread David Holmes
On Wed, 6 Nov 2024 01:44:48 GMT, Alex Menkov wrote: > On ARM and x64 processors, __stdcall is accepted and ignored by the compiler; @alexmenkov and @TheShermanTanker , I stand corrected and my apologies to @magicus . - PR Comment: https://git.openjdk.org/jdk/pull/21744#issuecommen

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

2024-11-05 Thread David Holmes
On Wed, 6 Nov 2024 00:08:16 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

Re: RFR: 8342650: Move getChars to DecimalDigits [v3]

2024-11-05 Thread Shaojin Wen
> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to > reduce duplication > > 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 > 2. Putting these two methods into DecimalDigits can avoid the need to expose > them in JavaLangAccess > 3. Eliminate d

Re: RFR: 8342650: Move getChars to DecimalDigits [v2]

2024-11-05 Thread Shaojin Wen
On Wed, 6 Nov 2024 01:44:38 GMT, Chen Liang wrote: >> Shaojin Wen has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains 11 additional >> commits since

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

2024-11-05 Thread David Holmes
On Tue, 5 Nov 2024 01:10:37 GMT, Ioi Lam wrote: > I've been using AOT in class names and aot in function/variable names. I > think that's consistent with HotSpot convention. As an acronym I think AOT in capitals should be preferred even in function/variable names. > In logging, I've been usi

Re: RFR: 8339783: Implement JEP 479: Remove the Windows 32-bit x86 Port [v30]

2024-11-05 Thread Julian Waters
On Wed, 6 Nov 2024 01:44:48 GMT, Alex Menkov wrote: > I think you may be throwing the baby out with the bath water when it comes to > `__stdcall`. It may be that 32-bit requires `__stdcall` but I don't see > anything that states `__stdcall` is ONLY for 32-bit! To my knowledge the only thing __

Re: RFR: 8342650: Move getChars to DecimalDigits [v2]

2024-11-05 Thread Chen Liang
On Tue, 5 Nov 2024 15:47:00 GMT, Shaojin Wen wrote: >> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to >> reduce duplication >> >> 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 >> 2. Putting these two methods into DecimalDigits can avoid th

Re: RFR: 8339783: Implement JEP 479: Remove the Windows 32-bit x86 Port [v30]

2024-11-05 Thread Alex Menkov
On Wed, 6 Nov 2024 00:58:10 GMT, David Holmes wrote: > I think you may be throwing the baby out with the bath water when it comes to > `__stdcall`. It may be that 32-bit requires `__stdcall` but I don't see > anything that states `__stdcall` is ONLY for 32-bit! https://learn.microsoft.com/en-u

Re: RFR: 8339783: Implement JEP 479: Remove the Windows 32-bit x86 Port [v30]

2024-11-05 Thread David Holmes
On Mon, 4 Nov 2024 20:42:59 GMT, Magnus Ihse Bursie wrote: >> This is the implementation of [JEP 479: _Remove the Windows 32-bit x86 >> Port_](https://openjdk.org/jeps/479). >> >> This is the summary of JEP 479: >>> Remove the source code and build support for the Windows 32-bit x86 port. >>>

RFR: 8343650: Reuse StringLatin1::putCharsAt and StringUTF16::putCharsAt

2024-11-05 Thread Shaojin Wen
Reuse the optimized putCharsAt method of StringLatin1 and StringUTF16 in PR #19626 to simplify the code, eliminate boundary checks, and improve performance - Commit messages: - use StringLatin1::putCharsAt and StringUTF16::putCharsAt Changes: https://git.openjdk.org/jdk/pull/21907/

Re: RFR: 8310996: Add JFR event for connect operations [v4]

2024-11-05 Thread Tim Prinzing
> Adds a JFR event for socket connect operations. > > Existing tests TestSocketEvents and TestSocketChannelEvents modified to also > check for connect events. Tim Prinzing has updated the pull request incrementally with one additional commit since the last revision: suggested changes --

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

2024-11-05 Thread Patricio Chilano Mateo
On Tue, 5 Nov 2024 14:35:11 GMT, Axel Boldt-Christmas wrote: >> Patricio Chilano Mateo has updated the pull request incrementally with five >> additional commits since the last revision: >> >> - Add oopDesc::has_klass_gap() check >> - Rename waitTimeout/set_waitTimeout accessors >> - Revert

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

2024-11-05 Thread Patricio Chilano Mateo
> 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 have been split into the > following initial 4 commits: > > - Change

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

2024-11-05 Thread Patricio Chilano Mateo
On Tue, 5 Nov 2024 23:58:39 GMT, Patricio Chilano Mateo wrote: >> src/hotspot/share/runtime/objectMonitor.cpp line 1643: >> >>> 1641: // actual callee (see nmethod::preserve_callee_argument_oops()). >>> 1642: ThreadOnMonitorWaitedEvent tmwe(current); >>> 1643: JvmtiExport::vth

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

2024-11-05 Thread Patricio Chilano Mateo
On Tue, 5 Nov 2024 11:35:29 GMT, Serguei Spitsyn wrote: > Is this posted after the VirtualThreadMount extension event posted? > It's posted before. We post the mount event at the end of thaw only if we are able to acquire the monitor: https://github.com/openjdk/jdk/blob/124efa0a6b8d05909e10005

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

2024-11-05 Thread Patricio Chilano Mateo
On Tue, 5 Nov 2024 23:50:29 GMT, Patricio Chilano Mateo wrote: >> src/hotspot/share/runtime/continuation.cpp line 134: >> >>> 132: return true; >>> 133: } >>> 134: #endif // INCLUDE_JVMTI >> >> Could you, please, consider the simplification below? >> >> >> #if INCLUDE_JVMTI >> // return tr

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

2024-11-05 Thread Patricio Chilano Mateo
On Mon, 4 Nov 2024 20:55:07 GMT, Serguei Spitsyn wrote: >> Patricio Chilano Mateo has updated the pull request incrementally with three >> additional commits since the last revision: >> >> - Update comment block in objectMonitor.cpp >> - Fix issue with unmounted virtual thread when dumping he

Re: RFR: 8328821: Map.of() derived view collection mutators should throw UnsupportedOperationException [v7]

2024-11-05 Thread Liam Miller-Cushon
On Tue, 9 Jul 2024 23:17:47 GMT, Liam Miller-Cushon wrote: >> This change overrides mutator methods in the implementation returned by >> `Map.of().entrySet()` to throw `UnsupportedOperationException`. > > Liam Miller-Cushon has updated the pull request incrementally with one > additional commit

Re: RFR: 8343610: InOutPathTest jpackage test produces invalid app image on macOS

2024-11-05 Thread Alexander Matveev
On Tue, 5 Nov 2024 16:08:20 GMT, Alexey Semenyuk wrote: > - fix `JPackageCommand.excludeAppLayoutAsserts()`; > - fix `InOutPath` test case that will make jpackage produce an invalid app > image on macOS. Looks good. - Marked as reviewed by almatvee (Reviewer). PR Review: https://

Re: RFR: 8343610: InOutPathTest jpackage test produces invalid app image on macOS

2024-11-05 Thread Alexey Semenyuk
On Tue, 5 Nov 2024 16:08:20 GMT, Alexey Semenyuk wrote: > - fix `JPackageCommand.excludeAppLayoutAsserts()`; > - fix `InOutPath` test case that will make jpackage produce an invalid app > image on macOS. @MBaesken can you try this fix in your environment? - PR Comment: https://git

Re: RFR: 8343610: InOutPathTest jpackage test produces invalid app image on macOS

2024-11-05 Thread Alexey Semenyuk
On Tue, 5 Nov 2024 16:08:20 GMT, Alexey Semenyuk wrote: > - fix `JPackageCommand.excludeAppLayoutAsserts()`; > - fix `InOutPath` test case that will make jpackage produce an invalid app > image on macOS. @sashamatveev ptal - PR Comment: https://git.openjdk.org/jdk/pull/21909#issue

RFR: 8343610: InOutPathTest jpackage test produces invalid app image on macOS

2024-11-05 Thread Alexey Semenyuk
- fix `JPackageCommand.excludeAppLayoutAsserts()`; - fix `InOutPath` test case that will make jpackage produce an invalid app image on macOS. - Commit messages: - Better wording of the comment - One more try to make it work on OSX - Bugfix for the case when `--app-content` is set

Re: RFR: 8343071: Broken anchors to restricted method page and some redundant ids

2024-11-05 Thread Nizar Benalla
On Fri, 1 Nov 2024 17:19:00 GMT, Nizar Benalla wrote: > Can I get a review for this patch that brings the last changes to fix broken > anchors in the source code. > > The links updated in this patch can be grouped into 3 sections, they were > minor so I grouped them into one PR. > > 1- Move s

Integrated: 8343071: Broken anchors to restricted method page and some redundant ids

2024-11-05 Thread Nizar Benalla
On Fri, 1 Nov 2024 17:19:00 GMT, Nizar Benalla wrote: > Can I get a review for this patch that brings the last changes to fix broken > anchors in the source code. > > The links updated in this patch can be grouped into 3 sections, they were > minor so I grouped them into one PR. > > 1- Move s

Re: RFR: 8338411: Implement JEP 486: Permanently Disable the Security Manager [v8]

2024-11-05 Thread Sean Mullan
On Tue, 5 Nov 2024 18:58:22 GMT, Sean Mullan wrote: >> This is the implementation of JEP 486: Permanently Disable the Security >> Manager. See [JEP 486](https://openjdk.org/jeps/486) for more details. The >> [CSR](https://bugs.openjdk.org/browse/JDK-8338412) describes in detail the >> main cha

RFR: 8343286: Missing unchecked cast warning in polymorphic method call

2024-11-05 Thread Vicente Romero
Javac is not issuing a mandated unchecked cast warning for code like: import java.lang.invoke.VarHandle; class VarHandleCast { VarHandle vh; V method(Object obj) { return (V)vh.getAndSet(this, obj); } } according to the spec the return type inferred for this method poly

Re: RFR: 8311302: Implement JEP 493: Linking Run-Time Images without JMODs [v44]

2024-11-05 Thread Severin Gehwolf
On Tue, 5 Nov 2024 19:39:08 GMT, Severin Gehwolf wrote: >> Please review this patch which adds a jlink mode to the JDK which doesn't >> need the packaged modules being present. A.k.a run-time image based jlink. >> Fundamentally this patch adds an option to use `jlink` even though your JDK >> i

Re: RFR: 8311302: Implement JEP 493: Linking Run-Time Images without JMODs [v44]

2024-11-05 Thread Severin Gehwolf
> Please review this patch which adds a jlink mode to the JDK which doesn't > need the packaged modules being present. A.k.a run-time image based jlink. > Fundamentally this patch adds an option to use `jlink` even though your JDK > install might not come with the packaged modules (directory `jm

Re: RFR: 8337279: Optimize format instant [v10]

2024-11-05 Thread Shaojin Wen
> By removing the redundant code logic in > DateTimeFormatterBuilder$InstantPrinterParser#formatTo, the codeSize can be > reduced and the performance can be improved. Shaojin Wen has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the

Re: RFR: 8317542: Specjvm::xml have scalability issue for high vCPU numbers

2024-11-05 Thread Vladimir Ivanov
On Thu, 31 Oct 2024 21:33:11 GMT, Vladimir Ivanov wrote: > The synchronization block may be substituted by the 'volatile' variable > smaller synchronization block. > It reduce the total blocking time for the specjvm2008::xml.validation > workload and improve the reported score. > Scores for the

Re: RFR: 8338411: Implement JEP 486: Permanently Disable the Security Manager [v6]

2024-11-05 Thread Sean Mullan
On Sun, 3 Nov 2024 12:33:05 GMT, Alan Bateman wrote: >> Right - this paragraph - lines 1620-1625 (old file) / 1362-1367 (new file) >> is no longer relevant and should be removed too. Thanks for spotting that. > > Removed in jep486 branch in sandbox so will get picked up when PR is > refreshed.

Re: RFR: 8343064: ClassFormatError: Illegal class name from InnerClassLambdaMetafactory [v2]

2024-11-05 Thread Chen Liang
> After the ClassFile API migration, when serializable lambdas are requested > for hidden class callers, illegal class name is generated for the > serialization methods, which previously had legal yet unusable class names, > as hidden classes cannot be described by a `CONSTANT_Class_info`. > >

Re: RFR: 8343064: ClassFormatError: Illegal class name from InnerClassLambdaMetafactory

2024-11-05 Thread Chen Liang
On Tue, 5 Nov 2024 18:29:52 GMT, Chen Liang wrote: > After the ClassFile API migration, when serializable lambdas are requested > for hidden class callers, illegal class name is generated for the > serialization methods, which previously had legal yet unusable class names, > as hidden classes

Re: RFR: 8338411: Implement JEP 486: Permanently Disable the Security Manager [v8]

2024-11-05 Thread Sean Mullan
> This is the implementation of JEP 486: Permanently Disable the Security > Manager. See [JEP 486](https://openjdk.org/jeps/486) for more details. The > [CSR](https://bugs.openjdk.org/browse/JDK-8338412) describes in detail the > main changes in the JEP and also includes an apidiff of the specif

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Quan Anh Mai
On Tue, 5 Nov 2024 14:07:12 GMT, Quan Anh Mai wrote: >> Hi, >> >> This patch makes `MemorySessionImpl.state` a `Stable` field so that liveness >> check of non-closeable scopes such as the global scope can be elided. >> >> Currently, the `state` field is overloaded with 2 responsibilities, to a

Re: RFR: 8343064: ClassFormatError: Illegal class name from InnerClassLambdaMetafactory

2024-11-05 Thread Alan Bateman
On Tue, 5 Nov 2024 18:29:52 GMT, Chen Liang wrote: > After the ClassFile API migration, when serializable lambdas are requested > for hidden class callers, illegal class name is generated for the > serialization methods, which previously had legal yet unusable class names, > as hidden classes

Re: RFR: 8343064: ClassFormatError: Illegal class name from InnerClassLambdaMetafactory

2024-11-05 Thread Abdelhak Zaaim
On Tue, 5 Nov 2024 18:29:52 GMT, Chen Liang wrote: > After the ClassFile API migration, when serializable lambdas are requested > for hidden class callers, illegal class name is generated for the > serialization methods, which previously had legal yet unusable class names, > as hidden classes

RFR: 8343064: ClassFormatError: Illegal class name from InnerClassLambdaMetafactory

2024-11-05 Thread Chen Liang
After the ClassFile API migration, when serializable lambdas are requested for hidden class callers, illegal class name is generated for the serialization methods, which previously had legal yet unusable class names, as hidden classes cannot be described by a `CONSTANT_Class_info`. This patch r

Re: RFR: 8338411: Implement JEP 486: Permanently Disable the Security Manager [v7]

2024-11-05 Thread Sean Mullan
> This is the implementation of JEP 486: Permanently Disable the Security > Manager. See [JEP 486](https://openjdk.org/jeps/486) for more details. The > [CSR](https://bugs.openjdk.org/browse/JDK-8338412) describes in detail the > main changes in the JEP and also includes an apidiff of the specif

Re: RFR: 8342936: Enhance java.io.IO with parameter-less println() and readln() [v3]

2024-11-05 Thread Naoto Sato
On Tue, 29 Oct 2024 08:13:22 GMT, Jan Lahoda wrote: >> This PR is simply adding parameter-less `java.io.IO.{println(),readln()}`, >> with the (hopefully) obvious semantics, plus the corresponding wiring to >> make those work. This may become part of JEP 495: >> https://openjdk.org/jeps/495 > >

Re: Allowing apps to force sun.jnu.encoding = "UTF-8" on Windows

2024-11-05 Thread Naoto Sato
Hi Fabian, On 11/5/24 12:52 AM, Fabian Meumertzheim wrote: On Mon, Nov 4, 2024 at 8:46 PM Naoto Sato wrote: I am afraid that the risk that would be involved in configuring sun.jnu.encoding exceeds the benefit it would bring, as the encoding is so baked in the basis of the Windows Java runtime.

Re: RFR: 8337143: (fc, fs) Move filesystem-related native objects from libnio to libjava [v8]

2024-11-05 Thread Brian Burkhalter
On Fri, 13 Sep 2024 20:41:27 GMT, Brian Burkhalter wrote: >> This proposed change would move the native objects required for NIO file >> interaction from the libnio native library to the libjava native library on >> Linux, macOS, and Windows. > > Brian Burkhalter has updated the pull request in

Re: RFR: 8311302: Implement JEP 493: Linking Run-Time Images without JMODs [v42]

2024-11-05 Thread Severin Gehwolf
On Fri, 1 Nov 2024 18:03:16 GMT, Mandy Chung wrote: > I expect that the jmodless tests will first build an image (say `image1`) > using jlink `--generate-linkable-runtime` option and then verify > `image1/bin/jlink` that links from the run-time image. I don't see > `--generate-linkable-runtime

Re: RFR: 8343071: Broken anchors to restricted method page and some redundant ids

2024-11-05 Thread Iris Clark
On Fri, 1 Nov 2024 17:19:00 GMT, Nizar Benalla wrote: > Can I get a review for this patch that brings the last changes to fix broken > anchors in the source code. > > The links updated in this patch can be grouped into 3 sections, they were > minor so I grouped them into one PR. > > 1- Move s

Re: RFR: 8310996: Add JFR event for connect operations [v3]

2024-11-05 Thread Alan Bateman
On Tue, 5 Nov 2024 16:48:14 GMT, Tim Prinzing wrote: >> Adds a JFR event for socket connect operations. >> >> Existing tests TestSocketEvents and TestSocketChannelEvents modified to also >> check for connect events. > > Tim Prinzing has updated the pull request incrementally with one additional

Re: RFR: 8311302: Implement JEP 493: Linking Run-Time Images without JMODs [v43]

2024-11-05 Thread Severin Gehwolf
> Please review this patch which adds a jlink mode to the JDK which doesn't > need the packaged modules being present. A.k.a run-time image based jlink. > Fundamentally this patch adds an option to use `jlink` even though your JDK > install might not come with the packaged modules (directory `jm

Integrated: 8341903: Implementation of Scoped Values (Fourth Preview)

2024-11-05 Thread Andrew Haley
On Thu, 10 Oct 2024 16:16:51 GMT, Andrew Haley wrote: > The fourth preview of scoped values. This pull request has now been integrated. Changeset: 3fab8e37 Author:Andrew Haley URL: https://git.openjdk.org/jdk/commit/3fab8e37bbebbb3930108b2015efe488b1fa1e97 Stats: 161 lines in 7

Re: RFR: 8339783: Implement JEP 479: Remove the Windows 32-bit x86 Port [v30]

2024-11-05 Thread Kim Barrett
On Mon, 4 Nov 2024 20:42:59 GMT, Magnus Ihse Bursie wrote: >> This is the implementation of [JEP 479: _Remove the Windows 32-bit x86 >> Port_](https://openjdk.org/jeps/479). >> >> This is the summary of JEP 479: >>> Remove the source code and build support for the Windows 32-bit x86 port. >>>

Integrated: 8332744: [REDO] 'internal proprietary API' diagnostics if --system is configured to an earlier JDK version

2024-11-05 Thread Liam Miller-Cushon
On Fri, 24 May 2024 15:32:09 GMT, Liam Miller-Cushon wrote: > This change fixes a bug preventing javac from emitting > 'compiler.warn.sun.proprietary' diagnostics if `--system` is set to a > non-default value. The diagnostics are currently emitted for values of > `--release`, and for the defau

Re: RFR: 8311302: Implement JEP 493: Linking Run-Time Images without JMODs [v42]

2024-11-05 Thread Severin Gehwolf
On Thu, 31 Oct 2024 23:20:30 GMT, Mandy Chung wrote: > `test/jdk/tools/jlink/JmodLess` can be renamed to `linkableRuntimeImage` or a > name consistent with the JEP. Renamed to `runtimeImage`. As it's in the `jlink` folder already it's implied that it's the link from run-time image then. > tes

Re: RFR: 8310996: Add JFR event for connect operations [v3]

2024-11-05 Thread Tim Prinzing
> Adds a JFR event for socket connect operations. > > Existing tests TestSocketEvents and TestSocketChannelEvents modified to also > check for connect events. Tim Prinzing has updated the pull request incrementally with one additional commit since the last revision: improved exception names

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v8]

2024-11-05 Thread Jorn Vernee
On Tue, 5 Nov 2024 14:24:20 GMT, Per Minborg wrote: >>> What happens here if an element is already aligned, and `padding.byteSize() >>> == element.byteAlignment()`? e.g. >>> `MemoryLayout.structLayout(MemoryLayout.paddingLayout(4), >>> ValueLayout.JAVA_INT)`? >> >> This is an error that exist

Re: RFR: 8329251: Print custom truststore/ keystore name [v8]

2024-11-05 Thread Sean Coffey
On Tue, 5 Nov 2024 04:54:15 GMT, Prasadrao Koppula wrote: >> Using SharedSecrets, I attempted to expose FileInputStream::path >> information. After implementing the fix, I validated the startup performance >> tests. Observed no consistent pattern of performance drops or gains, can >> disregard

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Quan Anh Mai
On Tue, 5 Nov 2024 15:31:11 GMT, Maurizio Cimadamore wrote: >> Okay, fair enough. > > Using two blocking queues might also be possible: > * at the start of each iteration a thread does a `get` on its own queue > * at the end of each iteration, a thread does a put on the other thread's > queue >

Re: RFR: 8342650: Move getChars to DecimalDigits [v2]

2024-11-05 Thread Shaojin Wen
> Move getChars methods of StringLatin1 and StringUTF16 to DecimalDigits to > reduce duplication > > 1. HexDigits and OctalDigits also include getCharsLatin1 and getCharsUTF16 > 2. Putting these two methods into DecimalDigits can avoid the need to expose > them in JavaLangAccess > 3. Eliminate d

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Quan Anh Mai
On Tue, 5 Nov 2024 15:29:22 GMT, Per Minborg wrote: >> Quan Anh Mai has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - copyright year >> - address reviews > > In `SharedSession`, would it not be necessary to override `isClosable()` so >

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Maurizio Cimadamore
On Tue, 5 Nov 2024 15:13:29 GMT, Jorn Vernee wrote: >> I'm afraid that it would be too expensive compared to a spinlock, and the >> scheduler might not wake up the threads soon enough to make a meaningful >> race, greatly reducing the effectiveness of the test. > > Okay, fair enough. Using two

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Per Minborg
On Tue, 5 Nov 2024 14:07:12 GMT, Quan Anh Mai wrote: >> Hi, >> >> This patch makes `MemorySessionImpl.state` a `Stable` field so that liveness >> check of non-closeable scopes such as the global scope can be elided. >> >> Currently, the `state` field is overloaded with 2 responsibilities, to a

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Jorn Vernee
On Tue, 5 Nov 2024 14:49:09 GMT, Quan Anh Mai wrote: >> test/jdk/java/foreign/TestMemorySession.java line 374: >> >>> 372: Thread.onSpinWait(); >>> 373: k = lock.get(); >>> 374: } >> >> I think the right primitive here is a `CyclicBarrier`

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Jorn Vernee
On Tue, 5 Nov 2024 14:07:12 GMT, Quan Anh Mai wrote: >> Hi, >> >> This patch makes `MemorySessionImpl.state` a `Stable` field so that liveness >> check of non-closeable scopes such as the global scope can be elided. >> >> Currently, the `state` field is overloaded with 2 responsibilities, to a

Re: RFR: 8332744: [REDO] 'internal proprietary API' diagnostics if --system is configured to an earlier JDK version [v4]

2024-11-05 Thread Vicente Romero
On Mon, 4 Nov 2024 22:23:50 GMT, Liam Miller-Cushon wrote: >> This change fixes a bug preventing javac from emitting >> 'compiler.warn.sun.proprietary' diagnostics if `--system` is set to a >> non-default value. The diagnostics are currently emitted for values of >> `--release`, and for the de

Re: RFR: 8332744: [REDO] 'internal proprietary API' diagnostics if --system is configured to an earlier JDK version [v3]

2024-11-05 Thread Vicente Romero
On Tue, 5 Nov 2024 01:03:14 GMT, Liam Miller-Cushon wrote: >> lgtm > > @vicente-romero-oracle could you please take another look? > > I was preparing to integrate this, and the latest merge includes one new > benchmark that requires another update: > https://github.com/openjdk/jdk/pull/19397/c

Integrated: 8333893: Optimization for StringBuilder append boolean & null

2024-11-05 Thread Shaojin Wen
On Mon, 10 Jun 2024 12:12:58 GMT, Shaojin Wen wrote: > After PR https://github.com/openjdk/jdk/pull/16245, C2 optimizes stores into > primitive arrays by combining values ​​into larger stores. > > This PR rewrites the code of appendNull and append(boolean) methods so that > these two methods c

Re: RFR: 8333893: Optimization for StringBuilder append boolean & null [v20]

2024-11-05 Thread Shaojin Wen
On Fri, 18 Oct 2024 21:56:53 GMT, Shaojin Wen wrote: >> After PR https://github.com/openjdk/jdk/pull/16245, C2 optimizes stores into >> primitive arrays by combining values ​​into larger stores. >> >> This PR rewrites the code of appendNull and append(boolean) methods so that >> these two meth

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v10]

2024-11-05 Thread Jorn Vernee
On Tue, 5 Nov 2024 14:25:21 GMT, Per Minborg wrote: >> test/jdk/java/foreign/TestLinker.java line 188: >> >>> 186: assertEquals(e.getMessage(), >>> 187: "The padding layout x2 was preceded by another >>> padding layout x1 in [b1x1x2i4]"); >>> 188: } >> >

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v8]

2024-11-05 Thread Per Minborg
On Mon, 4 Nov 2024 12:15:53 GMT, Jorn Vernee wrote: > Also, don't we already check the alignment before when calling > `checkMemberOffset`? Why is it checked again here? Good catch. - PR Review Comment: https://git.openjdk.org/jdk/pull/21041#discussion_r1829425363

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v12]

2024-11-05 Thread Per Minborg
> This PR prevents sequence layout with padding to be used with the Linker. Per Minborg has updated the pull request incrementally with one additional commit since the last revision: Remove redundant check - Changes: - all: https://git.openjdk.org/jdk/pull/21041/files - new:

Re: RFR: 8339783: Implement JEP 479: Remove the Windows 32-bit x86 Port [v30]

2024-11-05 Thread Magnus Ihse Bursie
On Mon, 4 Nov 2024 20:42:59 GMT, Magnus Ihse Bursie wrote: >> This is the implementation of [JEP 479: _Remove the Windows 32-bit x86 >> Port_](https://openjdk.org/jeps/479). >> >> This is the summary of JEP 479: >>> Remove the source code and build support for the Windows 32-bit x86 port. >>>

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Quan Anh Mai
On Tue, 5 Nov 2024 14:43:29 GMT, Jorn Vernee wrote: >> Quan Anh Mai has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - copyright year >> - address reviews > > test/jdk/java/foreign/TestMemorySession.java line 374: > >> 372:

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

2024-11-05 Thread Patricio Chilano Mateo
On Tue, 5 Nov 2024 08:19:34 GMT, Alan Bateman wrote: >> src/hotspot/share/jfr/metadata/metadata.xml line 160: >> >>> 158: >>> 159: >>> 160: >> >> Previously, the event was in the "Java Application" category. I think that >> was a better fit because it meant it was visualized in the sa

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Jorn Vernee
On Tue, 5 Nov 2024 14:07:12 GMT, Quan Anh Mai wrote: >> Hi, >> >> This patch makes `MemorySessionImpl.state` a `Stable` field so that liveness >> check of non-closeable scopes such as the global scope can be elided. >> >> Currently, the `state` field is overloaded with 2 responsibilities, to a

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

2024-11-05 Thread Patricio Chilano Mateo
On Tue, 5 Nov 2024 06:30:55 GMT, Fei Yang wrote: >> Great, thanks Dean. I removed `possibly_adjust_frame()` and the related code. >> @RealFYang I made the equivalent change for riscv, could you verify it's >> okay? > > @pchilano : Hi, Great to see `possibly_adjust_frame()` go away. Nice cleanup!

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v11]

2024-11-05 Thread Per Minborg
> This PR prevents sequence layout with padding to be used with the Linker. Per Minborg has updated the pull request incrementally with two additional commits since the last revision: - Rephrase doc - Improve language - Changes: - all: https://git.openjdk.org/jdk/pull/21041/fil

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

2024-11-05 Thread Axel Boldt-Christmas
On Tue, 5 Nov 2024 01:40:15 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

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

2024-11-05 Thread Patricio Chilano Mateo
On Tue, 5 Nov 2024 01:47:29 GMT, Patricio Chilano Mateo wrote: >> Patricio Chilano Mateo has updated the pull request incrementally with five >> additional commits since the last revision: >> >> - Add oopDesc::has_klass_gap() check >> - Rename waitTimeout/set_waitTimeout accessors >> - Reve

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

2024-11-05 Thread Patricio Chilano Mateo
On Tue, 5 Nov 2024 07:51:05 GMT, Erik Gahlin wrote: >> Patricio Chilano Mateo has updated the pull request incrementally with five >> additional commits since the last revision: >> >> - Add oopDesc::has_klass_gap() check >> - Rename waitTimeout/set_waitTimeout accessors >> - Revert suggestio

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

2024-11-05 Thread Patricio Chilano Mateo
> 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 have been split into the > following initial 4 commits: > > - Change

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v8]

2024-11-05 Thread Per Minborg
On Tue, 5 Nov 2024 14:12:42 GMT, Per Minborg wrote: >> Also, don't we already check the alignment before when calling >> `checkMemberOffset`? Why is it checked again here? > >> Also, don't we already check the alignment before when calling >> `checkMemberOffset`? Why is it checked again here? >

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v10]

2024-11-05 Thread Per Minborg
On Tue, 5 Nov 2024 14:15:24 GMT, Jorn Vernee wrote: >> Per Minborg has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Add checks of exception messages > > test/jdk/java/foreign/TestLinker.java line 188: > >> 186: assertEquals(e

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v8]

2024-11-05 Thread Per Minborg
On Tue, 5 Nov 2024 14:20:32 GMT, Per Minborg wrote: >>> Also, don't we already check the alignment before when calling >>> `checkMemberOffset`? Why is it checked again here? >> >> Good catch. > >> What happens here if an element is already aligned, and `padding.byteSize() >> == element.byteAli

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v4]

2024-11-05 Thread Quan Anh Mai
On Fri, 1 Nov 2024 02:44:15 GMT, Quan Anh Mai wrote: >> Hi, >> >> This patch makes `MemorySessionImpl.state` a `Stable` field so that liveness >> check of non-closeable scopes such as the global scope can be elided. >> >> Currently, the `state` field is overloaded with 2 responsibilities, to a

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v10]

2024-11-05 Thread Jorn Vernee
On Tue, 5 Nov 2024 13:51:13 GMT, Per Minborg wrote: >> This PR prevents sequence layout with padding to be used with the Linker. > > Per Minborg has updated the pull request incrementally with one additional > commit since the last revision: > > Add checks of exception messages test/jdk/java

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v5]

2024-11-05 Thread Quan Anh Mai
> Hi, > > This patch makes `MemorySessionImpl.state` a `Stable` field so that liveness > check of non-closeable scopes such as the global scope can be elided. > > Currently, the `state` field is overloaded with 2 responsibilities, to act as > a communication device between `close` and `checkVal

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v4]

2024-11-05 Thread Quan Anh Mai
On Mon, 4 Nov 2024 19:08:49 GMT, Jorn Vernee wrote: >> `checkValidStateRaw` synchronizes with `justClose` using handshakes so an >> opaque or higher load is only needed in `sharedSessionAlreadyClosed`. A >> `getOpaque` would probably be adequate. But I believe there is no formal >> restriction

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v10]

2024-11-05 Thread Per Minborg
> This PR prevents sequence layout with padding to be used with the Linker. Per Minborg has updated the pull request incrementally with one additional commit since the last revision: Add checks of exception messages - Changes: - all: https://git.openjdk.org/jdk/pull/21041/files

Integrated: 8343314: Move common properties from jpackage jtreg test declarations to TEST.properties file

2024-11-05 Thread Alexey Semenyuk
On Wed, 30 Oct 2024 19:07:54 GMT, Alexey Semenyuk wrote: > Clean up of jpackage jtreg test declarations: > - remove "@modules java.base/jdk.internal.util"; > - remove `--add-opens` from @run; > - replace "@library ../../../../helpers" and > "@library ../helpers" with "@library > /test/jdk/to

Re: RFR: 8333893: Optimization for StringBuilder append boolean & null [v20]

2024-11-05 Thread Emanuel Peter
On Fri, 18 Oct 2024 21:56:53 GMT, Shaojin Wen wrote: >> After PR https://github.com/openjdk/jdk/pull/16245, C2 optimizes stores into >> primitive arrays by combining values ​​into larger stores. >> >> This PR rewrites the code of appendNull and append(boolean) methods so that >> these two meth

Re: RFR: 8340205: Native linker allows MemoryLayout consisting of only PaddingLayout [v9]

2024-11-05 Thread Per Minborg
> This PR prevents sequence layout with padding to be used with the Linker. Per Minborg has updated the pull request incrementally with seven additional commits since the last revision: - Update test/jdk/java/foreign/TestLinker.java Co-authored-by: Jorn Vernee - Update src/java.base/s

Re: Request for Comments: Adding bulk-read method "CharSequence.getChars(int srcBegin, int srcEnd, char[] dst, int dstBegin)"

2024-11-05 Thread Chen Liang
Thanks Markus, let's continue the API discussion here. I indeed believe that allowing to batch-copy to an array is a good idea. The JDK CharSequence can provide a safe "ranged copy from source into destination" functionality. However, users must be aware that there may be malicious CharSequence i

RFR: 8342380: Implement JEP draft: Warn about use of Memory-Access Methods in `sun.misc.Unsafe`

2024-11-05 Thread Alan Bateman
Change default value of the command line option --sun-misc-unsafe-memory-access from "allow" to "warn". - Commit messages: - Update test - Merge branch 'master' into JDK-8342380 - Update usage/man page - Initial commit Changes: https://git.openjdk.org/jdk/pull/21762/files Webr

Integrated: 8343547: Restore accidentally removed annotations in LambdaForm from ClassFile API port

2024-11-05 Thread Chen Liang
On Mon, 4 Nov 2024 15:47:46 GMT, Chen Liang wrote: > These two annotations are found to be lost during the ClassFile API port of > LambdaForm generation. I seem not able to reproduce the master issue in a > current build but could reproduce before when the change is first made. > Anyways thi

Re: RFR: 8343071: Broken anchors to restricted method page and some redundant ids

2024-11-05 Thread Maurizio Cimadamore
On Fri, 1 Nov 2024 17:19:00 GMT, Nizar Benalla wrote: > Can I get a review for this patch that brings the last changes to fix broken > anchors in the source code. > > The links updated in this patch can be grouped into 3 sections, they were > minor so I grouped them into one PR. > > 1- Move s

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

2024-11-05 Thread Serguei Spitsyn
On Tue, 5 Nov 2024 01:40:15 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

Re: RFR: 8342936: Enhance java.io.IO with parameter-less println() and readln() [v3]

2024-11-05 Thread Jan Lahoda
On Tue, 5 Nov 2024 09:48:29 GMT, vulinh64 wrote: > My question (please don't bash me, I am new): Any chance we can set the > encoding of console? I tested on Java 23 (Windows) and the encoding is > `windows-1252` so it will not display unicode characters correctly. I believe that after https:/

Re: RFR: 8342936: Enhance java.io.IO with parameter-less println() and readln() [v3]

2024-11-05 Thread vulinh64
On Tue, 29 Oct 2024 08:13:22 GMT, Jan Lahoda wrote: >> This PR is simply adding parameter-less `java.io.IO.{println(),readln()}`, >> with the (hopefully) obvious semantics, plus the corresponding wiring to >> make those work. This may become part of JEP 495: >> https://openjdk.org/jeps/495 > >

Re: Allowing apps to force sun.jnu.encoding = "UTF-8" on Windows

2024-11-05 Thread Fabian Meumertzheim
On Mon, Nov 4, 2024 at 8:46 PM Naoto Sato wrote: > I am afraid that the risk that would be involved in configuring > sun.jnu.encoding exceeds the benefit it would bring, as the encoding is > so baked in the basis of the Windows Java runtime. Since Microsoft > itself now recommends users choose UTF

Re: RFR: 8343394: Make MemorySessionImpl.state a stable field [v4]

2024-11-05 Thread Per Minborg
On Mon, 4 Nov 2024 21:57:39 GMT, ExE Boss wrote: >> Doesn't using `setOpaque` mean that another thread may see the update to >> `state` before the update to `acquireCount`? i.e. the scope of a memory >> segment may appear closed, but the segment would still be passable to a >> downcall? > > `a

  1   2   >