@@ -2706,6 +2706,8 @@ emit_sri_vector (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *fsi
2706
2706
if (COMPILE_LLVM (cfg )) {
2707
2707
if ((get_xconst_int_elem (cfg , args [1 ], MONO_TYPE_U8 , 0 ) == 0x300000002 ) &&
2708
2708
(get_xconst_int_elem (cfg , args [1 ], MONO_TYPE_U8 , 1 ) == 0x100000000 )) {
2709
+ etype = m_class_get_byval_arg (mono_defaults .uint64_class );
2710
+ klass = create_class_instance ("System.Runtime.Intrinsics" , "Vector128`1" , new_etype );
2709
2711
new_args [1 ] = args [0 ];
2710
2712
EMIT_NEW_ICONST (cfg , new_args [2 ], 1 );
2711
2713
MonoInst * ins = emit_simd_ins (cfg , klass , OP_ARM64_EXT , new_args [0 ]-> dreg , new_args [1 ]-> dreg );
@@ -2732,6 +2734,8 @@ emit_sri_vector (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *fsi
2732
2734
}
2733
2735
}
2734
2736
}
2737
+ etype = m_class_get_byval_arg (mono_defaults .byte_class );
2738
+ klass = create_class_instance ("System.Runtime.Intrinsics" , "Vector128`1" , new_etype );
2735
2739
new_args [1 ] = emit_xconst_v128 (cfg , klass , vec_cns );
2736
2740
return emit_simd_ins_for_sig (cfg , klass , OP_XOP_OVR_X_X_X , INTRINS_AARCH64_ADV_SIMD_TBL1 , 0 , fsig , new_args );
2737
2741
#elif defined(TARGET_AMD64 )
@@ -2789,6 +2793,8 @@ emit_sri_vector (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *fsi
2789
2793
if (!is_SIMD_feature_supported (cfg , MONO_CPU_X86_SSSE3 )) {
2790
2794
return NULL ;
2791
2795
}
2796
+ etype = m_class_get_byval_arg (mono_defaults .byte_class );
2797
+ klass = create_class_instance ("System.Runtime.Intrinsics" , "Vector128`1" , new_etype );
2792
2798
new_args [1 ] = emit_xconst_v128 (cfg , klass , vec_cns );
2793
2799
return emit_simd_ins_for_sig (cfg , klass , OP_XOP_X_X_X , INTRINS_SSE_PSHUFB , 0 , fsig , new_args );
2794
2800
}
@@ -2798,6 +2804,8 @@ emit_sri_vector (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *fsi
2798
2804
// down into a TYP_INT or TYP_UINT based shuffle, but that's additional complexity for no
2799
2805
// real benefit since shuffle gets its own port rather than using the fp specific ports.
2800
2806
arg0_type = MONO_TYPE_R8 ;
2807
+ etype = m_class_get_byval_arg (mono_defaults .double_class );
2808
+ klass = create_class_instance ("System.Runtime.Intrinsics" , "Vector128`1" , new_etype );
2801
2809
}
2802
2810
if ((arg0_type == MONO_TYPE_R4 ) || (arg0_type == MONO_TYPE_R8 )) {
2803
2811
int opcode = (arg0_type == MONO_TYPE_R4 ) ? OP_SSE_SHUFPS : OP_SSE2_SHUFPD ;
0 commit comments