error: In anonymous_4820: Unrecognized node 'VRR128'!

i need to use v32i32 and v32f32 in store instructions.
I defined my register as;

def VRR128 : RegisterClass<“X86”, [v32i32, v32f32],
1024, (add R_0_V_0, R_1_V_0, R_2_V_0)>;

def STORE_DWORD : I<0x70, MRMDestMem, (outs), (ins i2048mem:$dst, VRR128:$src),
“STORE_DWORD\t{$src, $dst|$dst, $src}”,
[(store (v32i32 (bitconvert VRR128:$src)), addr:$dst)], IIC_MOV_MEM>, TA;

def: Pat<(store (v32f32 (bitconvert (VRR128:$src))), addr:$dst), (STORE_DWORD addr:$dst, VRR128:$src)>;

but getting the following error;
STORE_DWORD: (st (bitconvert:v32i32 VRR128:{v32i32:v32f32}:$src), addr:iPTR:$dst)<<P:Predicate_unindexedstore>><<P:Predicate_store>>

Included from /PIM/lib/Target/X86/
/lib/Target/X86/ error: In STORE_DWORD: Could not infer all types in pattern!
def STORE_DWORD : I<0x70, MRMDestMem, (outs), (ins i2048mem:$dst, VRR128:$src),
anonymous_4820: /PIM/lib/Target/X86/
/lib/Target/X86/ error: In anonymous_4820: Unrecognized node ‘VRR128’!

Please help.

Thank You

You need a type inside this bitconvert. The outer type is the destination type for the bitconvert but it also needs an input type

(store (v32i32 (bitconvert VRR128:$src)), addr:$dst)

Thank You.

How to do the same for add please see the following; it gives duplication error.

def VADD : I<0x0E, MRMDestReg, (outs VRR128:$dst), (ins VRR128:$src1, VRR128:$src2),“VADD\t{$src1, $src2, $dst|$dst, $src1, $src2}”, [(set VRR128:$dst, (add VRR128:$src1, VRR128:$src2))]>, TA;

def : Pat<(add VRR128:$src1, VRR128:$src2), (VADD VRPIM128:$src1, VRPIM128:$src2)>;

Where to place v32f32 to distinguish between the two?

“add” only works for integers. Floating point requires fadd. They are different operations in hardware too so you probably need different instructions.

Thank You.
But can we use same register class for fadd as well,
is this instruction correct?

def VFADD : I<0x0E, MRMDestReg, (outs VRR128:$dst), (ins VRR128:$src1, VRR128:$src2),“VFADD\t{$src1, $src2, $dst|$dst, $src1, $src2}”, [(set VRR128:$dst, (fadd VRR128:$src1, VRR128:$src2))]>, TA;

Yes you can use the same register class for integer and fp. That instruction looks fine.

Thank You so much.