On 06/11/2025 18:48, Stuart Marks wrote:

Hi wenshao,

I've written up a draft JEP for deprecating the disabling of Compact Strings. There hasn't been a good term for running the system with Compact Strings disabled, so I made up a term "UTF-16-only" and used it here.

https://openjdk.org/jeps/8371379


This is deprecating something that I assume most developers have never heard of. It's important that anyone reading the JEP will quickly see that this is not deprecating String, it's not dropping UTF-16, and it's not changing the String constructor that take a Charset. Instead it's all about JDK internal representation of String. No change needed to my code. I think the JEP needs a clear call-to-action:  Audit your application launch scripts and configuration to see if you are using -XX:-CompactStrings. If you are, remove it, and re-test/re-benchmark to see if see if there is any impact, preferably with a recent JDK release.

-Alan.

Reply via email to