RFR: 8370863: VectorAPI: Optimize the VectorMaskCast chain in specific patterns [v5]

Emanuel Peter epeter at openjdk.org
Fri Dec 26 11:13:13 UTC 2025


On Wed, 24 Dec 2025 07:12:59 GMT, Eric Fang <erfang at openjdk.org> wrote:

>> src/hotspot/share/opto/vectornode.cpp line 1492:
>> 
>>> 1490:   //   vector[n]{bool} => vector[n]{t} => vector[n]{bool}
>>> 1491:   Node* in1 = VectorNode::uncast_mask(in(1));
>>> 1492:   if (in1->Opcode() == Op_VectorLoadMask && length() == in1->as_Vector()->length()) {
>> 
>> Can there be a mismatch with the length? Can you give me an example?
>
> Hi @eme64 , I’d really appreciate hearing your thoughts on this when you have a moment.

Honestly, I'd just make it an assert, if your code currently does not expect it.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/28313#discussion_r2648043826


More information about the hotspot-compiler-dev mailing list