Re: Wrong behavior of standard IO library when interacting with Samba (very serious)

2022-03-07 Thread Glavo
Regarding the issue with isWritable, I came across this post after investigating: https://devblogs.microsoft.com/oldnewthing/20060202-00/?p=32413 This does seem to be a Windows `AccessCheck` problem, and there is almost no solution. For this reason, isWritable is not very useful. While you may

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v7]

2022-03-07 Thread Jaikiran Pai
On Mon, 7 Mar 2022 20:36:36 GMT, Jim Laskey wrote: >> Several attempts have been made to improve Formatter's numeric performance >> by caching the current Locale zero. Such fixes, however, ignore the real >> issue, which is the slowness of fetching DecimalFormatSymbols. By directly >> caching

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v2]

2022-03-07 Thread Jaikiran Pai
On Tue, 8 Mar 2022 04:20:17 GMT, Ian Graves wrote: >> test/jdk/java/util/regex/RegExTest.java line 4568: >> >>> 4566: >>> 4567: var matcher1 = Pattern.compile(pat1).matcher(testInput); >>> 4568: var matcher2 = Pattern.compile(pat2).matcher(testInput); >> >> Hello Ian, >> The

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v4]

2022-03-07 Thread Ian Graves
> Fixing a bug in `NFCCharProperty` where code falling through an if-statement > can prematurely set the matcher's `hitEnd` field to true. Ian Graves has updated the pull request incrementally with one additional commit since the last revision: Adding back some missing CANON_EQ flags

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v2]

2022-03-07 Thread Ian Graves
On Tue, 8 Mar 2022 03:49:43 GMT, Jaikiran Pai wrote: >> Ian Graves has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains two commits: >> >> - merging master >> - Catching erronious setting of matcher.hitEnd > >

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v3]

2022-03-07 Thread Ian Graves
> Fixing a bug in `NFCCharProperty` where code falling through an if-statement > can prematurely set the matcher's `hitEnd` field to true. Ian Graves has updated the pull request incrementally with one additional commit since the last revision: Removing errant newline -

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v3]

2022-03-07 Thread Ian Graves
On Mon, 7 Mar 2022 23:05:55 GMT, Lance Andersen wrote: >> Ian Graves has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Removing errant newline > > src/java.base/share/classes/java/util/regex/Pattern.java line 4009: > >> 4007:

RFR: 8264160: Regex \b is not consistent with \w without UNICODE_CHARACTER_CLASS

2022-03-07 Thread Ian Graves
Proposed change in behavior to correct inconsistencies between `\w` and `\b` metacharacters - Commit messages: - Fixing bad javadoc - Merge remote-tracking branch 'upstream/master' into bug-8264160 - Updating spec - Proposed change for \b metacharacter Changes:

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v2]

2022-03-07 Thread Jaikiran Pai
On Mon, 7 Mar 2022 22:29:29 GMT, Ian Graves wrote: >> Fixing a bug in `NFCCharProperty` where code falling through an if-statement >> can prematurely set the matcher's `hitEnd` field to true. > > Ian Graves has updated the pull request with a new target base due to a merge > or a rebase. The

Please help backport the fix with the XSLT compiler in JDK18 to JDK11 & JDK17

2022-03-07 Thread Cheng Jin
Hi there, I notice the issue with the XSLT compiler (https://github.com/openjdk/jdk/blob/master/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XSLTC.java) I raised later last year at https://mail.openjdk.java.net/pipermail/core-libs-dev/2021-November/083135.html

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v2]

2022-03-07 Thread Roger Riggs
On Mon, 7 Mar 2022 22:29:29 GMT, Ian Graves wrote: >> Fixing a bug in `NFCCharProperty` where code falling through an if-statement >> can prematurely set the matcher's `hitEnd` field to true. > > Ian Graves has updated the pull request with a new target base due to a merge > or a rebase. The

Re: RFR: JDK-8266670: Better modeling of access flags in core reflection [v17]

2022-03-07 Thread Joe Darcy
On Sat, 5 Mar 2022 19:54:44 GMT, Joe Darcy wrote: >> This is an early review of changes to better model JVM access flags, that is >> "modifiers" like public, protected, etc. but explicitly at a VM level. >> >> Language level modifiers and JVM level access flags are closely related, but >>

Re: RFR: 8282429: StringBuilder/StringBuffer.toString() skip compressing for UTF16 strings [v2]

2022-03-07 Thread Xin Liu
On Mon, 7 Mar 2022 12:10:51 GMT, Daniel Jeliński wrote: >> Xin Liu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> make sure String(StringBuffer) is still synchronized. > > src/java.base/share/classes/java/lang/String.java line 1446: >

Re: RFR: 8282429: StringBuilder/StringBuffer.toString() skip compressing for UTF16 strings [v2]

2022-03-07 Thread Xin Liu
> If AbstractStringBuilder only grow, the inflated value which has been encoded > in UTF16 can't be compressed. > toString() can skip compression in this case. This can save an > ArrayAllocation in StringUTF16::compress(). > > java.io.BufferedRead::readLine() is a case that StringBuilder grows

Re: RFR: 8281146: Replace StringCoding.hasNegatives with countPositives [v11]

2022-03-07 Thread Claes Redestad
> I'm requesting comments and, hopefully, some help with this patch to replace > `StringCoding.hasNegatives` with `countPositives`. The new method does a very > similar pass, but alters the intrinsic to return the number of leading bytes > in the `byte[]` range which only has positive bytes.

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v2]

2022-03-07 Thread Lance Andersen
On Mon, 7 Mar 2022 22:29:29 GMT, Ian Graves wrote: >> Fixing a bug in `NFCCharProperty` where code falling through an if-statement >> can prematurely set the matcher's `hitEnd` field to true. > > Ian Graves has updated the pull request with a new target base due to a merge > or a rebase. The

Re: RFR: 8281146: Replace StringCoding.hasNegatives with countPositives [v10]

2022-03-07 Thread Claes Redestad
> I'm requesting comments and, hopefully, some help with this patch to replace > `StringCoding.hasNegatives` with `countPositives`. The new method does a very > similar pass, but alters the intrinsic to return the number of leading bytes > in the `byte[]` range which only has positive bytes.

Re: RFR: JDK-8282144 RandomSupport.convertSeedBytesToLongs sign extension overwrites previous bytes

2022-03-07 Thread Brian Burkhalter
On Thu, 24 Feb 2022 14:47:50 GMT, Jim Laskey wrote: > Class: ./java.base/share/classes/jdk/internal/util/random/RandomSupport.java > Method: public static long[] convertSeedBytesToLongs(byte[] seed, int n, int > z) > > The method attempts to create an array of longs by consuming the input

Re: RFR: JDK-8282144 RandomSupport.convertSeedBytesToLongs sign extension overwrites previous bytes

2022-03-07 Thread Brian Burkhalter
On Sun, 27 Feb 2022 22:30:44 GMT, Jim Laskey wrote: >> test/jdk/java/util/Random/T8282144.java line 39: >> >>> 37: public class T8282144 { >>> 38: public static void main(String[] args) { >>> 39: RandomGenerator rng = >>> RandomGeneratorFactory.of("L64X128MixRandom").create(42); >>

Re: RFR: 8281560: Matcher.hitEnd returns unexpected results in presence of CANON_EQ flag. [v2]

2022-03-07 Thread Ian Graves
> Fixing a bug in `NFCCharProperty` where code falling through an if-statement > can prematurely set the matcher's `hitEnd` field to true. Ian Graves has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains two commits: - merging master -

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v7]

2022-03-07 Thread Naoto Sato
On Mon, 7 Mar 2022 20:36:36 GMT, Jim Laskey wrote: >> Several attempts have been made to improve Formatter's numeric performance >> by caching the current Locale zero. Such fixes, however, ignore the real >> issue, which is the slowness of fetching DecimalFormatSymbols. By directly >> caching

Re: RFR: 8282664: Unroll by hand StringUTF16 and StringLatin1 polynomial hash loops [v2]

2022-03-07 Thread Richard Startin
On Fri, 4 Mar 2022 17:44:44 GMT, Ludovic Henry wrote: >> Despite the hash value being cached for Strings, computing the hash still >> represents a significant CPU usage for applications handling lots of text. >> >> Even though it would be generally better to do it through an enhancement to >>

Integrated: 8282657: Code cleanup: removing double semicolons at the end of lines

2022-03-07 Thread Matteo Baccan
On Fri, 28 Jan 2022 14:39:31 GMT, Matteo Baccan wrote: > Hi > > I have reviewed the code for removing double semicolons at the end of lines > > all the best > matteo This pull request has now been integrated. Changeset: ccad3923 Author:Matteo Baccan Committer: Magnus Ihse Bursie URL:

Re: RFR: JDK-8266670: Better modeling of access flags in core reflection [v17]

2022-03-07 Thread Joe Darcy
On Mon, 7 Mar 2022 18:20:23 GMT, Roger Riggs wrote: >> Joe Darcy 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 26 additional commits >> since

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v7]

2022-03-07 Thread Roger Riggs
On Mon, 7 Mar 2022 20:36:36 GMT, Jim Laskey wrote: >> Several attempts have been made to improve Formatter's numeric performance >> by caching the current Locale zero. Such fixes, however, ignore the real >> issue, which is the slowness of fetching DecimalFormatSymbols. By directly >> caching

Re: RFR: 8279185: Support for IsoFields in JapaneseDate/MinguoDate/ThaiBuddhistDate [v3]

2022-03-07 Thread Naoto Sato
On Mon, 7 Mar 2022 17:04:25 GMT, Joe Wang wrote: >> Is `IsoBased` is fine with me. "isISOLike" is too vague. > > That matches the javadoc as well, that it "supports ISO based fields". Renamed the new method to `isIsoBased()`. Modified the CSR accordingly. - PR:

Integrated: 8281093: Violating Attribute-Value Normalization in the XML specification 1.0

2022-03-07 Thread Ravi Reddy
On Mon, 7 Mar 2022 17:07:20 GMT, Ravi Reddy wrote: > This fix is for violation of XML specification on Attribute-Value > normalization for external entities having character "\r". > > While normalizing entity with '\r', we should be checking if the entity is > external before changing the

Re: RFR: 8279185: Support for IsoFields in JapaneseDate/MinguoDate/ThaiBuddhistDate [v4]

2022-03-07 Thread Joe Wang
On Mon, 7 Mar 2022 18:20:43 GMT, Naoto Sato wrote: >> Supporting `IsoFields` temporal fields in chronologies that are similar to >> ISO chronology. Corresponding CSR has also been drafted. > > Naoto Sato has updated the pull request with a new target base due to a merge > or a rebase. The

Re: RFR: 8282664: Unroll by hand StringUTF16 and StringLatin1 polynomial hash loops [v2]

2022-03-07 Thread Paul Sandoz
On Fri, 4 Mar 2022 17:44:44 GMT, Ludovic Henry wrote: >> Despite the hash value being cached for Strings, computing the hash still >> represents a significant CPU usage for applications handling lots of text. >> >> Even though it would be generally better to do it through an enhancement to >>

Re: RFR: 8282657: Code cleanup: removing double semicolons at the end of lines

2022-03-07 Thread Kevin Rushforth
On Mon, 7 Mar 2022 16:40:15 GMT, Lance Andersen wrote: > What problem are you having editing the PR header? You should be able to do > so as the author of the PR Exactly. You should see an "Edit" button near the right edge of the PR title. See the attached image:

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v7]

2022-03-07 Thread Jim Laskey
> Several attempts have been made to improve Formatter's numeric performance by > caching the current Locale zero. Such fixes, however, ignore the real issue, > which is the slowness of fetching DecimalFormatSymbols. By directly caching > DecimalFormatSymbols in the Formatter, this enhancement

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v6]

2022-03-07 Thread Jim Laskey
On Mon, 7 Mar 2022 17:09:37 GMT, Jim Laskey wrote: >> Several attempts have been made to improve Formatter's numeric performance >> by caching the current Locale zero. Such fixes, however, ignore the real >> issue, which is the slowness of fetching DecimalFormatSymbols. By directly >> caching

Re: RFR: 8281093: Violating Attribute-Value Normalization in the XML specification 1.0

2022-03-07 Thread Joe Wang
On Mon, 7 Mar 2022 17:07:20 GMT, Ravi Reddy wrote: > This fix is for violation of XML specification on Attribute-Value > normalization for external entities having character "\r". > > While normalizing entity with '\r', we should be checking if the entity is > external before changing the

Re: RFR: JDK-8266670: Better modeling of access flags in core reflection [v17]

2022-03-07 Thread Roger Riggs
On Sat, 5 Mar 2022 19:54:44 GMT, Joe Darcy wrote: >> This is an early review of changes to better model JVM access flags, that is >> "modifiers" like public, protected, etc. but explicitly at a VM level. >> >> Language level modifiers and JVM level access flags are closely related, but >>

Re: RFR: 8279185: Support for IsoFields in JapaneseDate/MinguoDate/ThaiBuddhistDate [v4]

2022-03-07 Thread Naoto Sato
On Mon, 7 Mar 2022 18:30:28 GMT, Joe Wang wrote: >> Naoto Sato 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 five additional >> commits since

Re: RFR: 8279185: Support for IsoFields in JapaneseDate/MinguoDate/ThaiBuddhistDate [v4]

2022-03-07 Thread Naoto Sato
> Supporting `IsoFields` temporal fields in chronologies that are similar to > ISO chronology. Corresponding CSR has also been drafted. Naoto Sato 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

Re: RFR: 8282657: Code cleanup: removing double semicolons at the end of lines

2022-03-07 Thread Kevin Rushforth
On Mon, 7 Mar 2022 17:12:25 GMT, Magnus Ihse Bursie wrote: > TheShermanTanker is not the author of this PR, he's just assisting the author > by creating the JBS issue. Ah, that explains it then. - PR: https://git.openjdk.java.net/jdk/pull/7268

Re: RFR: 8282657: Code cleanup: removing double semicolons at the end of lines

2022-03-07 Thread Magnus Ihse Bursie
On Mon, 7 Mar 2022 16:40:15 GMT, Lance Andersen wrote: >> Hi >> >> I have reviewed the code for removing double semicolons at the end of lines >> >> all the best >> matteo > > What problem are you having editing the PR header? You should be able to do > so as the author of the PR

RFR: 8281093: Violating Attribute-Value Normalization in the XML specification 1.0

2022-03-07 Thread Ravi Reddy
This fix is for violation of XML specification on Attribute-Value normalization for external entities having character "\r". While normalizing entity with '\r', we should be checking if the entity is external before changing the position and offset. "isExternal()" check is missed in the new

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v6]

2022-03-07 Thread Jim Laskey
> Several attempts have been made to improve Formatter's numeric performance by > caching the current Locale zero. Such fixes, however, ignore the real issue, > which is the slowness of fetching DecimalFormatSymbols. By directly caching > DecimalFormatSymbols in the Formatter, this enhancement

Re: RFR: 8279185: Support for IsoFields in JapaneseDate/MinguoDate/ThaiBuddhistDate [v3]

2022-03-07 Thread Joe Wang
On Mon, 7 Mar 2022 03:00:45 GMT, Roger Riggs wrote: >> OK, I propose `isIsoBased()` for the name, which I initially thought of. If >> there is no objection, I will modify the spec/impl. > > Is `IsoBased` is fine with me. "isISOLike" is too vague. That matches the javadoc as well, that it

Re: RFR: 8282657: Code cleanup: removing double semicolons at the end of lines

2022-03-07 Thread Kevin Rushforth
On Fri, 28 Jan 2022 14:39:31 GMT, Matteo Baccan wrote: > Hi > > I have reviewed the code for removing double semicolons at the end of lines > > all the best > matteo But as the JBS title and PR title now match, this is a moot point. - PR:

Re: RFR: 8282008: Incorrect handling of quoted arguments in ProcessBuilder [v4]

2022-03-07 Thread Roger Riggs
On Thu, 3 Mar 2022 15:38:44 GMT, Olga Mikhaltsova wrote: >> This fix made equal processing of strings such as ""C:\\Program >> Files\\Git\\"" before and after JDK-8250568. >> >> For example, it's needed to execute the following command on Windows: >> `C:\Windows\SysWOW64\WScript.exe

Re: RFR: 8282657: Code cleanup: removing double semicolons at the end of lines

2022-03-07 Thread Lance Andersen
On Fri, 28 Jan 2022 14:39:31 GMT, Matteo Baccan wrote: > Hi > > I have reviewed the code for removing double semicolons at the end of lines > > all the best > matteo What problem are you having editing the PR header? You should be able to do so as the author of the PR - PR:

Re: RFR: 8282657: Code cleanup: removing double semicolons at the end of lines

2022-03-07 Thread Julian Waters
On Mon, 7 Mar 2022 13:40:48 GMT, Erik Joelsson wrote: > > Should I change the JBS issue title to match the PR title, or is it > > preferred for the PR title to change? > > They need to match. You can either do it manually, or change the title to > just the bug number and the bot will change

Integrated: 8280404: Unexpected exception thrown when CEN file entry comment length is not valid

2022-03-07 Thread Lance Andersen
On Thu, 3 Mar 2022 11:19:12 GMT, Lance Andersen wrote: > Hi all, > > This PR addresses an issue where an unexpected exception is thrown when the > CEN file entry comment length is not correct. > > Mach5 tiers 1 - 3 run clean with this change. This pull request has now been integrated.

Re: RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption

2022-03-07 Thread Claes Redestad
On Mon, 7 Mar 2022 15:54:02 GMT, liach wrote: > Notice list.of will have the downside of copying the input array when the > size is not small while arrays aslist does not. Is the tradeoff worth it? A good observation. In a couple of these places we could probably use

Re: RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption

2022-03-07 Thread liach
On Mon, 7 Mar 2022 15:11:50 GMT, Сергей Цыпанов wrote: > `List.of()` along with `Set.of()` create unmodifiable `List/Set` but with > smaller footprint comparing to `Arrays.asList()` / `new HashSet()` when > called with vararg of size 0, 1, 2. > > In general replacement of `Arrays.asList()`

Re: RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption

2022-03-07 Thread Daniel Fuchs
On Mon, 7 Mar 2022 15:11:50 GMT, Сергей Цыпанов wrote: > `List.of()` along with `Set.of()` create unmodifiable `List/Set` but with > smaller footprint comparing to `Arrays.asList()` / `new HashSet()` when > called with vararg of size 0, 1, 2. > > In general replacement of `Arrays.asList()`

RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption

2022-03-07 Thread Сергей Цыпанов
`List.of()` along with `Set.of()` create unmodifiable `List/Set` but with smaller footprint comparing to `Arrays.asList()` / `new HashSet()` when called with vararg of size 0, 1, 2. In general replacement of `Arrays.asList()` with `List.of()` is dubious as the latter is null-hostile, however

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v5]

2022-03-07 Thread Jim Laskey
> Several attempts have been made to improve Formatter's numeric performance by > caching the current Locale zero. Such fixes, however, ignore the real issue, > which is the slowness of fetching DecimalFormatSymbols. By directly caching > DecimalFormatSymbols in the Formatter, this enhancement

Integrated: JDK-8282696: Add constructors taking a cause to InvalidObjectException and InvalidClassException

2022-03-07 Thread Joe Darcy
On Sat, 5 Mar 2022 02:57:47 GMT, Joe Darcy wrote: > Occasionally in core-libs we've discussed whether or not to do a pass over > the exception classes and proactively add any of four missing convention > constructors per java.lang.Throwable (no-arg, string, cause, cause and > string). Last

Re: RFR: JDK-8282696: Add constructors taking a cause to InvalidObjectException and InvalidClassException [v6]

2022-03-07 Thread Joe Darcy
> Occasionally in core-libs we've discussed whether or not to do a pass over > the exception classes and proactively add any of four missing convention > constructors per java.lang.Throwable (no-arg, string, cause, cause and > string). Last time this came up, we decided a wide-scale effort

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v4]

2022-03-07 Thread Jim Laskey
> Several attempts have been made to improve Formatter's numeric performance by > caching the current Locale zero. Such fixes, however, ignore the real issue, > which is the slowness of fetching DecimalFormatSymbols. By directly caching > DecimalFormatSymbols in the Formatter, this enhancement

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v3]

2022-03-07 Thread Jim Laskey
On Mon, 7 Mar 2022 13:05:09 GMT, Jim Laskey wrote: >> Would it be just as effective and improve performance more broadly to cache >> in DecimalFormatSymbols.getInstance()? >> >> Declarations should be private unless there is a package need. >> In this case, the only access to should be via the

Re: RFR: 8282657: Code cleanup: removing double semicolons at the end of lines

2022-03-07 Thread Erik Joelsson
On Sat, 5 Mar 2022 06:49:16 GMT, Julian Waters wrote: > Should I change the JBS issue title to match the PR title, or is it preferred > for the PR title to change? They need to match. You can either do it manually, or change the title to just the bug number and the bot will change it for you.

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v3]

2022-03-07 Thread Jim Laskey
On Mon, 7 Mar 2022 08:25:19 GMT, Stephen Colebourne wrote: >> Jim Laskey has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Too many 'the' > > Just to note that there is also some caching in `DecimalStyle`. It might be > possible to

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v3]

2022-03-07 Thread Jim Laskey
On Fri, 4 Mar 2022 20:04:42 GMT, Roger Riggs wrote: >> Jim Laskey has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Too many 'the' > > src/java.base/share/classes/java/util/Formatter.java line 2025: > >> 2023: >> 2024: // Caching

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v3]

2022-03-07 Thread Jim Laskey
On Mon, 7 Mar 2022 00:33:53 GMT, Naoto Sato wrote: >>> will now try and update/use this cached class level static state DFS. That >>> would thus require some kind of thread safety semantics to be implemented >>> for this new getDecimalFormatSymbols(Locale) method, isn't it? >> >> A bit more

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v3]

2022-03-07 Thread Jim Laskey
On Fri, 4 Mar 2022 19:02:29 GMT, Naoto Sato wrote: >> Jim Laskey has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Too many 'the' > > src/java.base/share/classes/java/util/Formatter.java line 2026: > >> 2024: // Caching zero. >>

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v3]

2022-03-07 Thread Jim Laskey
On Fri, 4 Mar 2022 21:14:26 GMT, Roger Riggs wrote: >> As a separate/future issue, perhaps the constructors should be deprecated to >> nudge people to using the static `getInstance` methods. > > Would it be just as effective and improve performance more broadly to cache > in

Re: RFR: JDK-8266670: Better modeling of access flags in core reflection [v17]

2022-03-07 Thread Peter Levart
On Sat, 5 Mar 2022 19:54:44 GMT, Joe Darcy wrote: >> This is an early review of changes to better model JVM access flags, that is >> "modifiers" like public, protected, etc. but explicitly at a VM level. >> >> Language level modifiers and JVM level access flags are closely related, but >>

Re: RFR: JDK-8266670: Better modeling of access flags in core reflection [v12]

2022-03-07 Thread Peter Levart
On Mon, 28 Feb 2022 18:20:13 GMT, ExE Boss wrote: >> It does because of the AccessFlags.MODULE constant. > >> It does because of the AccessFlags.MODULE constant. > > But that’s exactly what the unqualified `MODULE` identifier refers to, and  > there’s no other bare `MODULE` identifier in scope

Re: RFR: 8282429: StringBuilder/StringBuffer.toString() skip compressing for UTF16 strings

2022-03-07 Thread Daniel Jeliński
On Thu, 3 Mar 2022 02:36:58 GMT, Xin Liu wrote: > If AbstractStringBuilder only grow, the inflated value which has been encoded > in UTF16 can't be compressed. > toString() can skip compression in this case. This can save an > ArrayAllocation in StringUTF16::compress(). > >

Re: RFR: JDK-8266670: Better modeling of access flags in core reflection [v17]

2022-03-07 Thread Peter Levart
On Sat, 5 Mar 2022 19:54:44 GMT, Joe Darcy wrote: >> This is an early review of changes to better model JVM access flags, that is >> "modifiers" like public, protected, etc. but explicitly at a VM level. >> >> Language level modifiers and JVM level access flags are closely related, but >>

Re: Wrong behavior of standard IO library when interacting with Samba (very serious)

2022-03-07 Thread David Holmes
On 7/03/2022 6:28 pm, Alan Bateman wrote: On 07/03/2022 05:33, Glavo wrote: I am a Java application developer. I noticed that when my program runs on Windows in a samba shared folder (mounted as a drive, or accessed via a UNC path), the Java standard IO library has some unusual behavior. Note

Re: RFR: 8280404: Unexpected exception thrown when CEN file entry comment length is not valid [v2]

2022-03-07 Thread Alan Bateman
On Thu, 3 Mar 2022 17:46:53 GMT, Lance Andersen wrote: >> Hi all, >> >> This PR addresses an issue where an unexpected exception is thrown when the >> CEN file entry comment length is not correct. >> >> Mach5 tiers 1 - 3 run clean with this change. > > Lance Andersen has updated the pull

Re: Wrong behavior of standard IO library when interacting with Samba (very serious)

2022-03-07 Thread Alan Bateman
On 07/03/2022 05:33, Glavo wrote: I am a Java application developer. I noticed that when my program runs on Windows in a samba shared folder (mounted as a drive, or accessed via a UNC path), the Java standard IO library has some unusual behavior. Note that these issues only occur when accessing

Re: RFR: JDK-8282625 Formatter caches Locale/DecimalFormatSymbols poorly [v3]

2022-03-07 Thread Stephen Colebourne
On Fri, 4 Mar 2022 21:17:50 GMT, Jim Laskey wrote: >> Several attempts have been made to improve Formatter's numeric performance >> by caching the current Locale zero. Such fixes, however, ignore the real >> issue, which is the slowness of fetching DecimalFormatSymbols. By directly >> caching