On Wed, 9 Oct 2024 03:49:49 GMT, ExE Boss <d...@openjdk.org> wrote:

>> We haven't done much testing with the other SCF BSMs, so I think it's better 
>> to do that in a follow-up REF.
>
> [`StringConcatFactory​::makeConcat(…)`] is definitely deterministic, as it 
> simply delegates to [`StringConcatFactory​::makeConcatWithConstants(…)`] with 
> the recipe being based on the number of [`MethodType`] parameters:
> https://github.com/openjdk/jdk/blob/de90204b60c408ef258a2d2515ad252de4b23536/src/java.base/share/classes/java/lang/invoke/StringConcatFactory.java#L231-L240
> 
> And there is no other bootstrap method in [`StringConcatFactory`] at the 
> moment.
> 
> [`MethodType`]: 
> https://docs.oracle.com/en/java/javase/23/docs/api/java.base/java/lang/invoke/MethodType.html
> [`StringConcatFactory`]: 
> https://docs.oracle.com/en/java/javase/23/docs/api/java.base/java/lang/invoke/StringConcatFactory.html
> [`StringConcatFactory​::makeConcat(…)`]: 
> https://docs.oracle.com/en/java/javase/23/docs/api/java.base/java/lang/invoke/StringConcatFactory.html#makeConcat(java.lang.invoke.MethodHandles.Lookup,java.lang.String,java.lang.invoke.MethodType)
> [`StringConcatFactory​::makeConcatWithConstants(…)`]: 
> https://docs.oracle.com/en/java/javase/23/docs/api/java.base/java/lang/invoke/StringConcatFactory.html#makeConcatWithConstants(java.lang.invoke.MethodHandles.Lookup,java.lang.String,java.lang.invoke.MethodType,java.lang.String,java.lang.Object...)

Since the comment says "This bootstrap method is unlikely to be used in 
practice", I am not sure if we can sufficiently test it (with aot-linking).

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/21143#discussion_r1792884101

Reply via email to