On Sat, 26 Oct 2024 02:34:44 GMT, Quan Anh Mai <qa...@openjdk.org> wrote:

>>> By allowing lowering to look through VectorReinterpret and break the 
>>> invariant of Extract nodes that the element types of their inputs and 
>>> outputs must be the same, we can gvn v1 and v, v2 and v0.
>> 
>> I'd warn against breaking existing IR invariants. As an example, precise 
>> type information is important to properly match generic ideal vector nodes.
>
> I believe the matcher only needs the exact type of the node but not its 
> inputs. E.g. it should not be an issue if we `AddVB` a `vector<int,8>` and a 
> `vector<long,2>` into a `vector<byte,16>`.

Generic vector operand resolution cocretizes generic operands based on type 
agnostic node size, its a post matcher pass,  and its job is to replace generic 
MachOper operand nodes with cocrete ones (vec[SDXYZ]) which holds precise 
register mask needed by register allocator.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21599#discussion_r1817960219

Reply via email to