Re: RFR: 8210549: Runtime.exec: in closeDescriptors(), use FD_CLOEXEC instead of close() [v4]

2025-06-16 Thread Thomas Stuefe
On Mon, 16 Jun 2025 18:32:15 GMT, Roger Riggs wrote: >> Thomas Stuefe has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains five commits: >> >> - Merge branch 'master' into >> JDK-8210549-Runtime-exec-in-closeDescriptors-use-FD_CLOEXE

Re: RFR: 8210549: Runtime.exec: in closeDescriptors(), use FD_CLOEXEC instead of close() [v4]

2025-06-16 Thread Thomas Stuefe
On Mon, 16 Jun 2025 18:32:15 GMT, Roger Riggs wrote: >> Thomas Stuefe has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains five commits: >> >> - Merge branch 'master' into >> JDK-8210549-Runtime-exec-in-closeDescriptors-use-FD_CLOEXE

Re: RFR: 8210549: Runtime.exec: in closeDescriptors(), use FD_CLOEXEC instead of close() [v5]

2025-06-16 Thread Thomas Stuefe
> Hi, please consider the following patch. > > This patch replaces the existing close-file-descriptors-logic we follow > before exec'ing a target binary: instead of explicitly closing the file > descriptors, we mark them as CLOEXEC. That simplifies the logic: it gets rid > of the awkward tiptoe

RFR: 8359735: [Ubuntu 25.10] java/lang/ProcessBuilder/Basic.java, java/lang/ProcessHandle/InfoTest.java fail due to rust-coreutils

2025-06-16 Thread Vladimir Petko
To accommodate systems like Ubuntu 25.10 that use Rust coreutils, this PR updates tests that previously assumed BusyBox was the only environment to use symlinks for core utilities. Changes: - `java/lang/ProcessBuilder/Basic.java`: The test is updated to simply verify that `/bin/true `and `/bi

Re: RFR: 8191963: Path.equals() and File.equals() return true for two different files on Windows

2025-06-16 Thread Xueming Shen
On Thu, 12 Jun 2025 21:12:53 GMT, Brian Burkhalter wrote: > Replace logic in `java.io.WinNTFileSystems.compare(File,File)` with that from > `sun.nio.fs.WindowsPath.compareTo(Path)`. Just wondering how Windows implementation really behaves for its 'case-insensitive-comparing" for "\u0131 vs "I"

Re: RFR: 8358880: Performance of parsing with DecimalFormat can be improved [v6]

2025-06-16 Thread Johannes Graham
> This PR replaces construction of intermediate strings to be parsed with more > direct manipulation of numbers. It also has a more streamlined mechanism of > handling `Long.MIN_VALUE` when parsing longs by using `Long.parseUnsignedLong` > > As a small side-effect it also eliminates the use of a

Re: RFR: 8294226: Document missing UnsupportedTemporalTypeException

2025-06-16 Thread Naoto Sato
On Mon, 16 Jun 2025 16:36:43 GMT, Gautham Krishnan wrote: > Some methods in the java.time.chrono interfaces—ChronoLocalDate, > ChronoLocalDateTime, and ChronoZonedDateTime—override methods from the > java.time.temporal.Temporal interface that are documented to throw > UnsupportedTemporalTypeE

Re: RFR: 8359123: Misleading examples in jmod man page [v3]

2025-06-16 Thread Ana Maria Mihalceanu
> Please review my PR. This PR includes the following: > > - [x] Fix a small typo in a word and copyright. > - [x] Enhance description for `--target-platform`. > - [x] Rearrange `jmod create` example from basic to complex. Ana Maria Mihalceanu has updated the pull request incrementally with one

Re: RFR: 8359123: Misleading examples in jmod man page [v2]

2025-06-16 Thread Ana Maria Mihalceanu
On Mon, 16 Jun 2025 18:52:02 GMT, Alan Bateman wrote: >> Ana Maria Mihalceanu has updated the pull request incrementally with two >> additional commits since the last revision: >> >> - Fix whitespaces. >> - Update description of commands as per code review > > src/jdk.jlink/share/man/jmod.md

Re: concurrency-discuss mailing list

2025-06-16 Thread Pavel Rappo
> For many years, concurrency-interest was the mailing list to discuss > j.u.concurrent and related topics. The mailing list was hosted on a > server maintained by Prof. Doug Lea. Sadly, the mailing list didn't > survive an OS upgrade and has been unavailable for some time. > > A new mailing li

Re: RFR: 8357089: Remove VFORK launch mechanism from Process implementation (linux)

2025-06-16 Thread Roger Riggs
On Thu, 12 Jun 2025 04:11:15 GMT, Thomas Stuefe wrote: > (for JDK 26) > > Note: This PR is a continuation of the old PR here: > https://github.com/openjdk/jdk/pull/25260; had to close the old one since I > had Skara problems after the JDK25 split-off. > > See the companion CSR (https://bugs.o

Re: RFR: 8210549: Runtime.exec: in closeDescriptors(), use FD_CLOEXEC instead of close() [v4]

2025-06-16 Thread Roger Riggs
On Fri, 13 Jun 2025 06:40:29 GMT, Thomas Stuefe wrote: >> Hi, please consider the following patch. >> >> This patch replaces the existing close-file-descriptors-logic we follow >> before exec'ing a target binary: instead of explicitly closing the file >> descriptors, we mark them as CLOEXEC. T

Re: RFR: 8359123: Misleading examples in jmod man page [v2]

2025-06-16 Thread Alan Bateman
On Sat, 14 Jun 2025 18:16:46 GMT, Ana Maria Mihalceanu wrote: >> Please review my PR. This PR includes the following: >> >> - [x] Fix a small typo in a word and copyright. >> - [x] Enhance description for `--target-platform`. >> - [x] Rearrange `jmod create` example from basic to complex. > > An

Re: RFR: 8359123: Misleading examples in jmod man page [v2]

2025-06-16 Thread Alan Bateman
On Sat, 14 Jun 2025 18:16:46 GMT, Ana Maria Mihalceanu wrote: >> Please review my PR. This PR includes the following: >> >> - [x] Fix a small typo in a word and copyright. >> - [x] Enhance description for `--target-platform`. >> - [x] Rearrange `jmod create` example from basic to complex. > > An

Re: RFR: 8344332: (bf) Migrate DirectByteBuffer away from jdk.internal.ref.Cleaner [v5]

2025-06-16 Thread Kim Barrett
> This change makes java.nio no longer use jdk.internal.ref.Cleaner to manage > native memory for Direct-X-Buffers. Instead it uses bespoke PhantomReferences > and a dedicated ReferenceQueue. This differs from PR 22165, which proposed to > use java.lang.ref.Cleaner. > > This change is algorithmica

Re: RFR: 8358880: Performance of parsing with DecimalFormat can be improved [v3]

2025-06-16 Thread Justin Lu
On Fri, 13 Jun 2025 19:34:40 GMT, Johannes Graham wrote: >> Ah got it, I see your point. We would have goten underflow in >> `ASCIIToBinaryConverter.doubleValue()` for some extreme cases without a >> check. >> >> Is there a specific example you have that requires the switch to the newer >> c

Re: RFR: 8294226: Document missing UnsupportedTemporalTypeException

2025-06-16 Thread Roger Riggs
On Mon, 16 Jun 2025 16:36:43 GMT, Gautham Krishnan wrote: > Some methods in the java.time.chrono interfaces—ChronoLocalDate, > ChronoLocalDateTime, and ChronoZonedDateTime—override methods from the > java.time.temporal.Temporal interface that are documented to throw > UnsupportedTemporalTypeE

Re: RFR: 8358729: jdk/internal/loader/URLClassPath/ClassnameCharTest.java depends on Applet [v5]

2025-06-16 Thread Justin Lu
On Fri, 13 Jun 2025 20:56:49 GMT, Johannes Döbler wrote: >> Justin Lu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address review - Convert to JUnit, correct comment typo, remove 'Infra' >> methods > > test/jdk/jdk/internal/loader/UR

Re: RFR: 8358729: jdk/internal/loader/URLClassPath/ClassnameCharTest.java depends on Applet [v6]

2025-06-16 Thread Justin Lu
> Please review this PR which finishes Applet removal for the test: > jdk/internal/loader/URLClassPath/ClassnameCharTest.java. > > `testclasses.jar` is updated such that the two classes no longer extend > Applet. > > > $ javap fo\ o.class > public class fo o { > } > $ javap æ$'\302\211'$'\302

Re: RFR: 8345292: Improve javadocs for MemorySegment::getStrings defining word boundary cases [v5]

2025-06-16 Thread Per Minborg
> This PR proposes to improve the 'MemorySegment.getString(long offset, Charset > charset)` method documentation with respect to multi-octet concerns. Per Minborg has updated the pull request incrementally with two additional commits since the last revision: - Remove imp note - Add text on N

RFR: 8294226: Document missing UnsupportedTemporalTypeException

2025-06-16 Thread Gautham Krishnan
Some methods in the java.time.chrono interfaces—ChronoLocalDate, ChronoLocalDateTime, and ChronoZonedDateTime—override methods from the java.time.temporal.Temporal interface that are documented to throw UnsupportedTemporalTypeException when given unsupported fields or units. These overridden me

Integrated: 8338140: (str) Add notes to String.trim and String.isEmpty pointing to newer APIs

2025-06-16 Thread Stuart Marks
On Wed, 11 Jun 2025 22:39:48 GMT, Stuart Marks wrote: > Add a note to String.trim pointing to the String.strip family of methods. > > Add notes cross-linking String.isBlank and String.isEmpty. This pull request has now been integrated. Changeset: 06d804a0 Author:Stuart Marks URL: h

Re: Best Practice for Busy Waiting in Java

2025-06-16 Thread Alan Bateman
On 16/06/2025 12:09, Markus KARG wrote: In case you MUST use busy-wait, apply the following rules: * NEVER have EMPTY busy-wait loops, but ALWAYS put Thread.onSpinWait() into it. The performance drop is negligible but the CO2 footprint is considerably smaller. * IF it is acceptable for th

Re: Best Practice for Busy Waiting in Java

2025-06-16 Thread Markus KARG
Thank you, everybody, for your kind input! Having said that, I fully agree with all your proposals, but need to say: I already knew them, and it was **not** what I actually asked for. To repeat: "Is there a *best practice*". If the question is unclear, let me rephrase it using an example:

Withdrawn: 8355698: JDK not supporting sleef could cause exception at runtime after JDK-8353786

2025-06-16 Thread Hamlin Li
On Mon, 28 Apr 2025 10:34:49 GMT, Hamlin Li wrote: > Hi, > Can you help to review this patch? > > Before [JDK-8353786](https://bugs.openjdk.org/browse/JDK-8353786), when a > released jdk not supportting sleef (for any reason, e.g. low gcc version, > intrinsic not supported, rvv not supported,

Re: RFR: 8355698: JDK not supporting sleef could cause exception at runtime after JDK-8353786

2025-06-16 Thread Hamlin Li
On Mon, 28 Apr 2025 10:34:49 GMT, Hamlin Li wrote: > Hi, > Can you help to review this patch? > > Before [JDK-8353786](https://bugs.openjdk.org/browse/JDK-8353786), when a > released jdk not supportting sleef (for any reason, e.g. low gcc version, > intrinsic not supported, rvv not supported,

Re: Best Practice for Busy Waiting in Java

2025-06-16 Thread Per-Ake Minborg
Hi Markus, and thank you for your question, which I think is a very relevant one. There is no silver bullet here. It all depends on the problem at hand. One of the major questions to ask is what the aim of the solution is: are you optimizing latency, throughput, power efficiency, fairness, a ce

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

2025-06-16 Thread Volkan Yazici
On Fri, 30 May 2025 11:07:30 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://bug

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

2025-06-16 Thread Volkan Yazici
On Tue, 3 Jun 2025 20:09:51 GMT, Naoto Sato wrote: >> Volkan Yazici has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix missing `java.io.Reader` import in `Ktab` > > I was thinking if someone made a typo for "stdin.encoding" and then it

Re: RFR: 8352565: Add native method implementation of Reference.get() [v11]

2025-06-16 Thread Kim Barrett
> Please review this change which adds a native method providing the > implementation of Reference::get. Referece::get is an intrinsic candidate, so > this native method implementation is only used when the intrinsic is not. > > Currently there is intrinsic support by the interpreter, C1, C2, and