On Wed, 16 Jul 2025 18:32:13 GMT, John R Rose <jr...@openjdk.org> wrote:
> The effect of this PR is to make the affected array elements eligible for > constant-folding by the JIT. > > The contract of `@Stable` is private to the JDK, since it is a trusted > annotation. The trusted user promises not to change the array elements after > the JIT might have observed them. > > If we had a frozen (immutable) array feature in the JVM this PR could be > formulated using frozen array constants. But we are not there yet. Yes; my intention was to allow HotSpot greater leeway to optimize the FDLIBM code. Under my limited performance testing, the change seemed to be performance neutral, but if it shouldn't cause a regression, I'd be comfortable pushing the change. ------------- PR Comment: https://git.openjdk.org/jdk/pull/26341#issuecomment-3079867240