Re: RFR: 8344168: Change Unsafe base offset from int to long [v7]

2025-02-10 Thread Doug Simon
On Mon, 10 Feb 2025 18:54:26 GMT, Chen Liang wrote: >> Shaojin Wen has updated the pull request incrementally with one additional >> commit since the last revision: >> >> copyright > > Re dougxc: This migration is specific to the Java language. I am not so sure > about the C++ counterparts,

Re: RFR: 8344168: Change Unsafe base offset from int to long [v7]

2025-02-10 Thread Chen Liang
On Thu, 30 Jan 2025 00:37:16 GMT, Shaojin Wen wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> st

Re: RFR: 8344168: Change Unsafe base offset from int to long [v7]

2025-02-10 Thread Doug Simon
On Thu, 30 Jan 2025 00:37:16 GMT, Shaojin Wen wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> st

Re: RFR: 8344168: Change Unsafe base offset from int to long [v7]

2025-01-30 Thread Chen Liang
On Thu, 30 Jan 2025 00:37:16 GMT, Shaojin Wen wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> st

Re: RFR: 8344168: Change Unsafe base offset from int to long [v7]

2025-01-29 Thread Shaojin Wen
> The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still unfixed. > > @liach proposed the idea of ​​changing th

Re: RFR: 8344168: Change Unsafe base offset from int to long [v6]

2025-01-29 Thread Shaojin Wen
> The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still unfixed. > > @liach proposed the idea of ​​changing th

Re: RFR: 8344168: Change Unsafe base offset from int to long [v5]

2025-01-25 Thread Shaojin Wen
> The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still unfixed. > > @liach proposed the idea of ​​changing th

Re: RFR: 8344168: Change Unsafe base offset from int to long [v4]

2025-01-03 Thread Chen Liang
On Tue, 26 Nov 2024 18:05:44 GMT, Shaojin Wen wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> st

Re: RFR: 8344168: Change Unsafe base offset from int to long [v4]

2024-12-05 Thread Shaojin Wen
On Tue, 26 Nov 2024 18:05:44 GMT, Shaojin Wen wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> st

Re: RFR: 8344168: Change Unsafe base offset from int to long [v4]

2024-11-26 Thread Shaojin Wen
> The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still unfixed. > > @liach proposed the idea of ​​changing th

Re: RFR: 8344168: Change Unsafe base offset from int to long [v3]

2024-11-26 Thread Shaojin Wen
> The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still unfixed. > > @liach proposed the idea of ​​changing th

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-22 Thread Alan Bateman
On Fri, 22 Nov 2024 10:27:17 GMT, ExE Boss wrote: > Should the CSR FAQ be updated to remove references to jdk.*, or are there > some jdk.* packages that require a CSR? As far as I can tell, none are > exported. The "Design principles" section of JEP 200 may be help. Standard modules, as in ja

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-22 Thread ExE Boss
On Fri, 22 Nov 2024 04:23:26 GMT, Dean Long wrote: > Should the CSR FAQ be updated to remove references to `jdk.*,` or are there > some jdk.* packages that require a CSR? As far as I can tell, none are > exported. The `jdk.incubator.*` packages (such as `jdk.incubator.vector`) are exported. -

Re: RFR: 8344168: Change Unsafe base offset from int to long [v2]

2024-11-21 Thread Shaojin Wen
On Fri, 15 Nov 2024 01:04:58 GMT, Shaojin Wen wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> st

Re: RFR: 8344168: Change Unsafe base offset from int to long [v2]

2024-11-21 Thread Shaojin Wen
On Fri, 15 Nov 2024 01:04:58 GMT, Shaojin Wen wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> st

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-21 Thread Dean Long
On Fri, 15 Nov 2024 01:05:10 GMT, ExE Boss wrote: >> Doesn't this break any apps that use these offsets? Aren't these fields >> part of the public API of Unsafe, so changing them requires a CSR? > > @dean-long >> Doesn't this break any apps that use these offsets? Aren't these fields part >> o

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-16 Thread Alan Bateman
On Fri, 15 Nov 2024 01:05:10 GMT, ExE Boss wrote: >> Doesn't this break any apps that use these offsets? Aren't these fields >> part of the public API of Unsafe, so changing them requires a CSR? > > @dean-long >> Doesn't this break any apps that use these offsets? Aren't these fields part >> o

Re: RFR: 8344168: Change Unsafe base offset from int to long [v2]

2024-11-15 Thread Dean Long
On Fri, 15 Nov 2024 01:04:58 GMT, Shaojin Wen wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> st

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread ExE Boss
On Thu, 14 Nov 2024 23:20:23 GMT, Dean Long wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> stil

Re: RFR: 8344168: Change Unsafe base offset from int to long [v2]

2024-11-14 Thread Shaojin Wen
> The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still unfixed. > > @liach proposed the idea of ​​changing th

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Dean Long
On Thu, 14 Nov 2024 05:32:34 GMT, Shaojin Wen wrote: > The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Jorn Vernee
On Thu, 14 Nov 2024 05:32:34 GMT, Shaojin Wen wrote: > The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Chen Liang
On Thu, 14 Nov 2024 05:32:34 GMT, Shaojin Wen wrote: > The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Shaojin Wen
On Thu, 14 Nov 2024 13:44:10 GMT, Chen Liang wrote: > I think you should convert all array index scales to long too. They are > susceptible to the same overflow problem (actually more susceptible as they > involve in integer multiplications) The only places in JDK where there is a risk of offs

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Chen Liang
On Thu, 14 Nov 2024 14:41:13 GMT, Glavo wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> still un

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Glavo
On Thu, 14 Nov 2024 05:32:34 GMT, Shaojin Wen wrote: > The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Shaojin Wen
On Thu, 14 Nov 2024 13:44:10 GMT, Chen Liang wrote: > I think you should convert all array index scales to long too. They are > susceptible to the same overflow problem (actually more susceptible as they > involve in integer multiplications) Changing the index scale to long type will cause a l

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Chen Liang
On Thu, 14 Nov 2024 05:32:34 GMT, Shaojin Wen wrote: > The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Per Minborg
On Thu, 14 Nov 2024 05:32:34 GMT, Shaojin Wen wrote: > The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread Shaojin Wen
On Thu, 14 Nov 2024 08:08:08 GMT, David Holmes wrote: >> The type of the Unsafe base offset constant is int, which may cause overflow >> when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) >> fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are >> s

Re: RFR: 8344168: Change Unsafe base offset from int to long

2024-11-14 Thread David Holmes
On Thu, 14 Nov 2024 05:32:34 GMT, Shaojin Wen wrote: > The type of the Unsafe base offset constant is int, which may cause overflow > when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) > fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are > still

RFR: 8344168: Change Unsafe base offset from int to long

2024-11-13 Thread Shaojin Wen
The type of the Unsafe base offset constant is int, which may cause overflow when adding int offsets, such as 8343925 (PR #22012). 8343984 (PR #22027) fixes most of the offset overflows in JDK, but ArraysSupport and CRC32C are still unfixed. @liach proposed the idea of ​​changing the Unsafe bas