Re: RFR: 8349284: Make libExplicitAttach work on static JDK [v4]

2025-02-09 Thread Alan Bateman
On Mon, 10 Feb 2025 04:00:44 GMT, Jiangli Zhou wrote: >> This is similar to https://github.com/openjdk/jdk/pull/23431 change. It >> removes libjvm.so as a recorded dependency for libExplicitAttach.so by not >> explicitly link libExplicitAttach.so with libjvm.so at build time. To do >> that, it

Re: RFR: 8349284: Make libExplicitAttach work on static JDK

2025-02-09 Thread Alan Bateman
On Fri, 7 Feb 2025 20:10:08 GMT, Jiangli Zhou wrote: > Done, thanks. Moved `JNI_GetCreatedJavaVMs` lookup into JNI_OnLoad. Good, this is much better. - PR Comment: https://git.openjdk.org/jdk/pull/23500#issuecomment-2647141990

Re: RFR: 8342103: C2 compiler support for Float16 type and associated scalar operations [v17]

2025-02-09 Thread Jatin Bhateja
On Tue, 4 Feb 2025 10:05:09 GMT, Jatin Bhateja wrote: >> Hi All, >> >> This patch adds C2 compiler support for various Float16 operations added by >> [PR#22128](https://github.com/openjdk/jdk/pull/22128) >> >> Following is the summary of changes included with this patch:- >> >> 1. Detection o

Re: RFR: 8349284: Make libExplicitAttach work on static JDK [v3]

2025-02-09 Thread Jiangli Zhou
> This is similar to https://github.com/openjdk/jdk/pull/23431 change. It > removes libjvm.so as a recorded dependency for libExplicitAttach.so by not > explicitly link libExplicitAttach.so with libjvm.so at build time. To do > that, it also changes libExplicitAttach.c to dynamically lookup the

Re: RFR: 8349284: Make libExplicitAttach work on static JDK [v2]

2025-02-09 Thread Jiangli Zhou
On Sat, 8 Feb 2025 09:29:48 GMT, Alan Bateman wrote: > Is the JavaVM param passed to JNI_OnLoad usable in static builds? If so then > this just needs to be saved, no need to use GetCreatedJavaVMs, right? Yes, on static JDK, `JNI_OnLoad`'s `JavaVM *` argument behaves the same as on regular JDK.

Re: Request for Enhancement: java.io.Writer.of(Appendable) as an efficient alternative to java.io.StringWriter

2025-02-09 Thread David Alayachew
Hello Markus, I already posted a response, but since you added more detail, I will adress that detail too. > So how to proceed? Stop all my work for many more months? Address the criticisms (which you did), and knock on the door once or twice if you get no responses. But if after all of that, y

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

2025-02-09 Thread David Alayachew
Hello Markus, I am ignorant about the larger topic, so I will only respond to the following point. > Thank you, everybody. As no more comments arrived in the past eight weeks, I assume that there is implicit agreement with my latest arguments (see below), so next I will provide a PR to continue d

Re: RFR: 8346954: [JMH] jdk.incubator.vector.MaskedLogicOpts fails due to IndexOutOfBoundsException

2025-02-09 Thread Nicole Xu
On Wed, 8 Jan 2025 09:04:47 GMT, Nicole Xu wrote: > Suite MaskedLogicOpts.maskedLogicOperationsLong512() failed on both x86 and > AArch64 with the following error: > > > java.lang.IndexOutOfBoundsException: Index 252 out of bounds for length 249 > > > The variable `long256_arr_idx` is misuse

Re: RFR: 8346954: [JMH] jdk.incubator.vector.MaskedLogicOpts fails due to IndexOutOfBoundsException

2025-02-09 Thread Nicole Xu
On Tue, 4 Feb 2025 18:55:25 GMT, Emanuel Peter wrote: >> Suite MaskedLogicOpts.maskedLogicOperationsLong512() failed on both x86 and >> AArch64 with the following error: >> >> >> java.lang.IndexOutOfBoundsException: Index 252 out of bounds for length 249 >> >> >> The variable `long256_arr_id

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

2025-02-09 Thread Chen Liang
This API seems tricky again... I don't wish to see patterns like: cs.getChars(begin, end, dest, 0); if (charSequence.getClass().getModule() != Object.class.getModule()) { dest = dest.clone(); } to ensure the safety of the copy. Also in this pattern, the dest array is often a shared cache arr

Re: Request for Enhancement: java.io.Writer.of(Appendable) as an efficient alternative to java.io.StringWriter

2025-02-09 Thread Chen Liang
Hi Mark, After thinking about the Appendable-Closeable-Flushable trio versus Writer, I believe that one problem with Writer.of is that it goes against interface segregation principle represented by the trifecta, and accidentally leaking the Closeable or Flushable functionality is still dubious to m

Re: Request for Enhancement: java.io.Writer.of(Appendable) as an efficient alternative to java.io.StringWriter

2025-02-09 Thread Markus KARG
Alan, those big projects are really much appreciated by the community. Nevertheless there must not be a mutual exclusive situation, as other contributors are working on other things which are also appreciated by the same community. So how to proceed? Stop all my work for many more months? Lo

Re: Request for Enhancement: java.io.Writer.of(Appendable) as an efficient alternative to java.io.StringWriter

2025-02-09 Thread Alan Bateman
On 26/01/2025 16:37, Markus KARG wrote: As there have not been any more comments so far in the past weeks, I assume there is common agreement with my current proposal. I don't think you can assume this. There are many large projects and other significant efforts in progress so it's more like

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

2025-02-09 Thread Markus KARG
As recently announced, kindly inviting everybody to contribute / review / comment on https://github.com/openjdk/jdk/pull/21730. Thank you! -Markus Karg Am 09.02.2025 um 19:34 schrieb Markus KARG: Thank you, everybody. As no more comments arrived in the past eight weeks, I assume that there

Re: RFR: 8343110: Add getChars(int, int, char[], int) to CharSequence and CharBuffer

2025-02-09 Thread Rob Spoor
On Sat, 8 Feb 2025 18:56:00 GMT, Markus KARG wrote: >> While technically not being necessary, it is definitively a good idea. I >> will add it to the draft once we actually agreed that we really want to go >> with this particular signature (see the discussion with Chen). > > Fixed in `String` a

Re: RFR: 8343110: Add getChars(int, int, char[], int) to CharSequence and CharBuffer

2025-02-09 Thread Markus KARG
On Sat, 26 Oct 2024 17:09:29 GMT, Markus KARG wrote: >> src/java.base/share/classes/java/lang/CharSequence.java line 338: >> >>> 336: * @since 24 >>> 337: */ >>> 338: public default void getChars(int srcBegin, int srcEnd, char[] dst, >>> int dstBegin) { >> >> Shouldn't the `getCh

Re: RFR: 8343110: Add getChars(int, int, char[], int) to CharSequence and CharBuffer

2025-02-09 Thread Markus KARG
On Sat, 26 Oct 2024 16:19:32 GMT, Rob Spoor wrote: >> This Pull Request proposes an implementation for >> [JDK-8343110](https://bugs.openjdk.org/browse/JDK-8343110): Adding the new >> method `public void getChars(int srcBegin, int srcEnd, char[] dst, int >> dstBegin)` to the `CharSequence` int

Re: RFR: 8343110: Add getChars(int, int, char[], int) to CharSequence and CharBuffer

2025-02-09 Thread Rob Spoor
On Sat, 26 Oct 2024 15:48:11 GMT, Markus KARG wrote: > This Pull Request proposes an implementation for > [JDK-8343110](https://bugs.openjdk.org/browse/JDK-8343110): Adding the new > method `public void getChars(int srcBegin, int srcEnd, char[] dst, int > dstBegin)` to the `CharSequence` inter

Re: RFR: 8343110: Add getChars(int, int, char[], int) to CharSequence and CharBuffer

2025-02-09 Thread Chen Liang
On Sat, 26 Oct 2024 15:48:11 GMT, Markus KARG wrote: > This Pull Request proposes an implementation for > [JDK-8343110](https://bugs.openjdk.org/browse/JDK-8343110): Adding the new > method `public void getChars(int srcBegin, int srcEnd, char[] dst, int > dstBegin)` to the `CharSequence` inter

Re: RFR: 8343110: Add getChars(int, int, char[], int) to CharSequence and CharBuffer

2025-02-09 Thread Markus KARG
On Sat, 26 Oct 2024 16:26:29 GMT, Chen Liang wrote: > Sorry for belated mail response, but I think we should design the API to not > take source start/end. I think JIT can escape analysis the new String in > practice. Chen, thank you for chiming in! There is nothing to be sorry, I was just po

RFR: 8343110: Add getChars(int, int, char[], int) to CharSequence and CharBuffer

2025-02-09 Thread Markus KARG
This Pull Request proposes an implementation for [JDK-8343110](https://bugs.openjdk.org/browse/JDK-8343110): Adding the new method `public void getChars(int srcBegin, int srcEnd, char[] dst, int dstBegin)` to the `CharSequence` interface, providing a **bulk-read** facility including a default i

Re: RFR: 8343110: Add getChars(int, int, char[], int) to CharSequence and CharBuffer

2025-02-09 Thread Markus KARG
On Sat, 26 Oct 2024 15:48:11 GMT, Markus KARG wrote: > This Pull Request proposes an implementation for > [JDK-8343110](https://bugs.openjdk.org/browse/JDK-8343110): Adding the new > method `public void getChars(int srcBegin, int srcEnd, char[] dst, int > dstBegin)` to the `CharSequence` inter

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

2025-02-09 Thread Markus KARG
Thank you, everybody. As no more comments arrived in the past eight weeks, I assume that there is implicit agreement with my latest arguments (see below), so next I will provide a PR to continue discussion with real Java code at hand. -Markus Am 01.12.2024 um 19:23 schrieb Markus Karg: As

Re: RFR: 8342682: Errors related to unused code on Windows after 8339120 in dt_shmem jdwp security and jpackage [v7]

2025-02-09 Thread Julian Waters
On Mon, 11 Nov 2024 09:51:35 GMT, Julian Waters wrote: >> After 8339120, gcc began catching many different instances of unused code in >> the Windows specific codebase. Some of these seem to be bugs. I've taken the >> effort to mark out all the relevant globals and locals that trigger the >> u