From 8581f750b8606fd9410e9d948a101c1e21506383 Mon Sep 17 00:00:00 2001 From: Han Lee Date: Tue, 6 Jun 2017 09:50:04 -0700 Subject: [PATCH] Design of Intel intrinsic functions --- .../CompilerServices/Intrinsics/Intel/AVX.cs | 666 ++++++++++ .../CompilerServices/Intrinsics/Intel/AVX2.cs | 1161 +++++++++++++++++ .../Intrinsics/Intel/Delegates.cs | 172 +++ .../Intrinsics/Intel/Enums.cs | 57 + .../CompilerServices/Intrinsics/Intel/FMA.cs | 81 ++ .../Intrinsics/Intel/Other.cs | 171 +++ .../CompilerServices/Intrinsics/Intel/SSE2.cs | 699 ++++++++++ .../CompilerServices/Intrinsics/Intel/SSE3.cs | 61 + .../Intrinsics/Intel/SSE41.cs | 324 +++++ .../Intrinsics/Intel/SSE42.cs | 389 ++++++ .../Intrinsics/Intel/SSSE3.cs | 69 + .../CompilerServices/Intrinsics/Types.cs | 13 + .../CompilerServices/ProcessorCapabilities.cs | 28 + 13 files changed, 3891 insertions(+) create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/AVX.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/AVX2.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Delegates.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Enums.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/FMA.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Other.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE2.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE3.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE41.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE42.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSSE3.cs create mode 100644 src/System.Runtime.CompilerServices.Intrinsics/System/Runtime/CompilerServices/Intrinsics/Types.cs create mode 100644 src/System.Runtime.CompilerServices/System/Runtime/CompilerServices/ProcessorCapabilities.cs diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/AVX.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/AVX.cs new file mode 100644 index 00000000000..abccb99e1a4 --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/AVX.cs @@ -0,0 +1,666 @@ +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// AVX.cs +// +// A class that implements intrinsic functions to provide access to Intel SSE4.1 instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.InteropServices; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + /// + /// Provides access to Intel AVX hardware instructions via intrinsics + /// + /// + /// AVX class provides access to AVX SIMD instructions + /// + + public static class AVX + { + // __m256 _mm256_add_ps (__m256 a, __m256 b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_add_pd (__m256d a, __m256d b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_addsub_ps (__m256 a, __m256 b) + public static Vector256 AddSubtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_addsub_pd (__m256d a, __m256d b) + public static Vector256 AddSubtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_and_ps (__m256 a, __m256 b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_and_pd (__m256d a, __m256d b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_andnot_ps (__m256 a, __m256 b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_andnot_pd (__m256d a, __m256d b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_blend_ps (__m256 a, __m256 b, const int imm8) + private static Vector256 Blend(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static BlendVector256Delegate GetBlendVector256Float(byte control) + { + return (left, right) => Blend(left, right, control); + } + // __m256d _mm256_blend_pd (__m256d a, __m256d b, const int imm8) + private static Vector256 Blend(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static BlendVector256Delegate GetBlendVector256Double(byte control) + { + return (left, right) => Blend(left, right, control); + } + + // __m256 _mm256_blendv_ps (__m256 a, __m256 b, __m256 mask) + public static Vector256 BlendVariable(Vector256 left, Vector256 right, Vector256 mask) { throw new NotImplementedException(); } + // __m256d _mm256_blendv_pd (__m256d a, __m256d b, __m256d mask) + public static Vector256 BlendVariable(Vector256 left, Vector256 right, Vector256 mask) { throw new NotImplementedException(); } + + // __m128 _mm_broadcast_ss (float const * mem_addr) + public static Vector128 BroadcastVector128Scalar(ref float source) { throw new NotImplementedException(); } + + // __m256 _mm256_broadcast_ps (__m128 const * mem_addr) + public static unsafe Vector256 BroadcastVector256Packed(float* mem) { throw new NotImplementedException(); } + // __m256 _mm256_broadcast_ss (float const * mem_addr) + public static Vector256 BroadcastVector256Scalar(ref float source) { throw new NotImplementedException(); } + // __m256d _mm256_broadcast_pd (__m128d const * mem_addr) + public static unsafe Vector256 BroadcastVector256Packed(double* mem) { throw new NotImplementedException(); } + // __m256d _mm256_broadcast_sd (double const * mem_addr) + public static Vector256 BroadcastVector256Scalar(ref double source) { throw new NotImplementedException(); } + + // __m256 _mm256_ceil_ps (__m256 a) + public static Vector256 Ceiling(Vector256 value) { throw new NotImplementedException(); } + // __m256d _mm256_ceil_pd (__m256d a) + public static Vector256 Ceiling(Vector256 value) { throw new NotImplementedException(); } + + // __m128 _mm_cmp_ps (__m128 a, __m128 b, const int imm8) + private static Vector128 CompareVector128Float(Vector128 left, Vector128 right, FloatComparisonMode mode) { throw new NotImplementedException(); } + public static CompareVector128Delegate GetCompareVector128Float(FloatComparisonMode mode) + { + return (left, right) => CompareVector128Float(left, right, mode); + } + + // __m128d _mm_cmp_pd (__m128d a, __m128d b, const int imm8) + private static Vector128 CompareVector128Double(Vector128 left, Vector128 right, FloatComparisonMode mode) { throw new NotImplementedException(); } + public static CompareVector128Delegate GetCompareVector128Double(FloatComparisonMode mode) + { + return (left, right) => CompareVector128Double(left, right, mode); + } + + // __m256 _mm256_cmp_ps (__m256 a, __m256 b, const int imm8) + private static Vector256 CompareVector256Float(Vector256 left, Vector256 right, FloatComparisonMode mode) { throw new NotImplementedException(); } + public static CompareVector256Delegate GetCompareVector256Float(FloatComparisonMode mode) + { + return (left, right) => CompareVector256Float(left, right, mode); + } + + // __m256d _mm256_cmp_pd (__m256d a, __m256d b, const int imm8) + private static Vector256 CompareVector256Double(Vector256 left, Vector256 right, FloatComparisonMode mode) { throw new NotImplementedException(); } + public static CompareVector256Delegate GetCompareVector256Double(FloatComparisonMode mode) + { + return (left, right) => CompareVector256Double(left, right, mode); + } + + // __m128i _mm256_cvtpd_epi32 (__m256d a) + public static Vector128 ConvertToVector128Int(Vector256 value) { throw new NotImplementedException(); } + // __m128 _mm256_cvtpd_ps (__m256d a) + public static Vector128 ConvertToVector128Float(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtps_epi32 (__m256 a) + public static Vector256 ConvertToVector256Int(Vector256 value) { throw new NotImplementedException(); } + // __m256 _mm256_cvtepi32_ps (__m256i a) + public static Vector256 ConvertToVector256Float(Vector256 value) { throw new NotImplementedException(); } + // __m256d _mm256_cvtps_pd (__m128 a) + public static Vector256 ConvertToVector256Double(Vector256 value) { throw new NotImplementedException(); } + // __m256d _mm256_cvtepi32_pd (__m128i a) + public static Vector256 ConvertToVector256Double(Vector256 value) { throw new NotImplementedException(); } + + // __m128i _mm256_cvttpd_epi32 (__m256d a) + public static Vector128 ConvertToVector128IntWithTruncation(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvttps_epi32 (__m256 a) + public static Vector256 ConvertToVector256IntWithTruncation(Vector256 value) { throw new NotImplementedException(); } + + // __m256 _mm256_div_ps (__m256 a, __m256 b) + public static Vector256 Divide(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_div_pd (__m256d a, __m256d b) + public static Vector256 Divide(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_dp_ps (__m256 a, __m256 b, const int imm8) + private static Vector256 DotProduct(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static DotProductVectro256Delegate GetDotProductVector256Float(byte control) + { + return (left, right) => DotProduct(left, right, control); + } + + // __m256 _mm256_moveldup_ps (__m256 a) + public static Vector256 DuplicateEvenIndexed(Vector256 value) { throw new NotImplementedException(); } + // __m256d _mm256_movedup_pd (__m256d a) + public static Vector256 DuplicateEvenIndexed(Vector256 value) { throw new NotImplementedException(); } + + // __m256 _mm256_movehdup_ps (__m256 a) + public static Vector256 DuplicateOddIndexed(Vector256 value) { throw new NotImplementedException(); } + + + // __int8 _mm256_extract_epi8 (__m256i a, const int index) + private static sbyte ExtractSbyte(Vector256 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractSbyteVector256Delegate GetExtractSbyte(byte index) where T : struct + { + return (value) => ExtractSbyte(value, index); + } + // __int8 _mm256_extract_epi8 (__m256i a, const int index) + private static byte ExtractByte(Vector256 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractByteVector256Delegate GetExtractByte(byte index) where T : struct + { + return (value) => ExtractByte(value, index); + } + // __int16 _mm256_extract_epi16 (__m256i a, const int index) + private static short ExtractShort(Vector256 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractShortVector256Delegate GetExtractShort(byte index) where T : struct + { + return (value) => ExtractShort(value, index); + } + // __int16 _mm256_extract_epi16 (__m256i a, const int index) + private static ushort ExtractUshort(Vector256 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractUShortVector256Delegate GetExtractUshort(byte index) where T : struct + { + return (value) => ExtractUshort(value, index); + } + // __int32 _mm256_extract_epi32 (__m256i a, const int index) + private static int ExtractInt(Vector256 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractIntVector256Delegate GetExtractInt(byte index) where T : struct + { + return (value) => ExtractInt(value, index); + } + // __int32 _mm256_extract_epi32 (__m256i a, const int index) + private static uint ExtractUint(Vector256 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractUintVector256Delegate GetExtractUint(byte index) where T : struct + { + return (value) => ExtractUint(value, index); + } + // __int64 _mm256_extract_epi64 (__m256i a, const int index) + private static long ExtractLong(Vector256 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractLongVector256Delegate GetExtractLong(byte index) where T : struct + { + return (value) => ExtractLong(value, index); + } + // __int64 _mm256_extract_epi64 (__m256i a, const int index) + private static ulong ExtractUlong(Vector256 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractUlongVector256Delegate GetExtractUlong(byte index) where T : struct + { + return (value) => ExtractUlong(value, index); + } + + //__m128 _mm256_extractf128_ps (__m256 a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Float(byte index) + { + return (value) => ExtractVector128(value, index); + } + // __m128d _mm256_extractf128_pd (__m256d a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Double(byte index) + { + return (value) => ExtractVector128(value, index); + } + + // __m256 _mm256_floor_ps (__m256 a) + public static Vector256 Floor(Vector256 value) { throw new NotImplementedException(); } + // __m256d _mm256_floor_pd (__m256d a) + public static Vector256 Floor(Vector256 value) { throw new NotImplementedException(); } + + // __m256 _mm256_hadd_ps (__m256 a, __m256 b) + public static Vector256 HorizontalAdd(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_hadd_pd (__m256d a, __m256d b) + public static Vector256 HorizontalAdd(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_hsub_ps (__m256 a, __m256 b) + public static Vector256 HorizontalSubtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_hsub_pd (__m256d a, __m256d b) + public static Vector256 HorizontalSubtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_insert_epi8 (__m256i a, __int8 i, const int index) + private static Vector256 InsertSbyte(Vector256 value, sbyte data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertSbyteVector256Delegate GetInsertSbyte(byte index) where T : struct + { + return (value, data) => InsertSbyte(value, data, index); + } + // __m256i _mm256_insert_epi8 (__m256i a, __int8 i, const int index) + private static Vector256 InsertByte(Vector256 value, byte data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertByteVector256Delegate GetInsertByte(byte index) where T : struct + { + return (value, data) => InsertByte(value, data, index); + } + // __m256i _mm256_insert_epi16 (__m256i a, __int16 i, const int index) + private static Vector256 InsertShort(Vector256 value, short data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertShortVector256Delegate GetInsertShort(byte index) where T : struct + { + return (value, data) => InsertShort(value, data, index); + } + // __m256i _mm256_insert_epi16 (__m256i a, __int16 i, const int index) + private static Vector256 InsertUshort(Vector256 value, ushort data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertUshortVector256Delegate GetInsertUshort(byte index) where T : struct + { + return (value, data) => InsertUshort(value, data, index); + } + // __m256i _mm256_insert_epi32 (__m256i a, __int32 i, const int index) + private static Vector256 InsertInt(Vector256 value, int data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertIntVector256Delegate GetInsertInt(byte index) where T : struct + { + return (value, data) => InsertInt(value, data, index); + } + // __m256i _mm256_insert_epi32 (__m256i a, __int32 i, const int index) + private static Vector256 InsertUint(Vector256 value, uint data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertUintVector256Delegate GetInsertUint(byte index) where T : struct + { + return (value, data) => InsertUint(value, data, index); + } + // __m256i _mm256_insert_epi64 (__m256i a, __int64 i, const int index) + private static Vector256 InsertLong(Vector256 value, long data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertLongVector256Delegate GetInsertLong(byte index) where T : struct + { + return (value, data) => InsertLong(value, data, index); + } + // __m256i _mm256_insert_epi64 (__m256i a, __int64 i, const int index) + private static Vector256 InsertUlong(Vector256 value, ulong data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertUlongVector256Delegate GetInsertUlong(byte index) where T : struct + { + return (value, data) => InsertUlong(value, data, index); + } + + // __m256 _mm256_insertf128_ps (__m256 a, __m128 b, int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Float(byte index) + { + return (value, data) => Insert(value, data, index); + } + + // __m256d _mm256_insertf128_pd (__m256d a, __m128d b, int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Double(byte index) + { + return (value, data) => Insert(value, data, index); + } + + // __m256i _mm256_loadu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 Load(sbyte* mem) { throw new NotImplementedException(); } + // __m256i _mm256_loadu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 Load(byte* mem) { throw new NotImplementedException(); } + // __m256i _mm256_loadu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 Load(short* mem) { throw new NotImplementedException(); } + // __m256i _mm256_loadu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 Load(ushort* mem) { throw new NotImplementedException(); } + // __m256i _mm256_loadu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 Load(int* mem) { throw new NotImplementedException(); } + // __m256i _mm256_loadu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 Load(uint* mem) { throw new NotImplementedException(); } + // __m256i _mm256_loadu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 Load(long* mem) { throw new NotImplementedException(); } + // __m256i _mm256_loadu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 Load(ulong* mem) { throw new NotImplementedException(); } + // __m256 _mm256_loadu_ps (float const * mem_addr) + public static unsafe Vector256 Load(float* mem) { throw new NotImplementedException(); } + // __m256d _mm256_loadu_pd (double const * mem_addr) + public static unsafe Vector256 Load(double* mem) { throw new NotImplementedException(); } + + // __m256i _mm256_load_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadAligned(sbyte* mem) { throw new NotImplementedException(); } + // __m256i _mm256_load_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadAligned(byte* mem) { throw new NotImplementedException(); } + // __m256i _mm256_load_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadAligned(short* mem) { throw new NotImplementedException(); } + // __m256i _mm256_load_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadAligned(ushort* mem) { throw new NotImplementedException(); } + // __m256i _mm256_load_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadAligned(int* mem) { throw new NotImplementedException(); } + // __m256i _mm256_load_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadAligned(uint* mem) { throw new NotImplementedException(); } + // __m256i _mm256_load_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadAligned(long* mem) { throw new NotImplementedException(); } + // __m256i _mm256_load_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadAligned(ulong* mem) { throw new NotImplementedException(); } + // __m256 _mm256_load_ps (float const * mem_addr) + public static unsafe Vector256 LoadAligned(float* mem) { throw new NotImplementedException(); } + // __m256d _mm256_load_pd (double const * mem_addr) + public static unsafe Vector256 LoadAligned(double* mem) { throw new NotImplementedException(); } + + // __m256i _mm256_lddqu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadDqu(sbyte* mem) { throw new NotImplementedException(); } + // __m256i _mm256_lddqu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadDqu(byte* mem) { throw new NotImplementedException(); } + // __m256i _mm256_lddqu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadDqu(short* mem) { throw new NotImplementedException(); } + // __m256i _mm256_lddqu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadDqu(ushort* mem) { throw new NotImplementedException(); } + // __m256i _mm256_lddqu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadDqu(int* mem) { throw new NotImplementedException(); } + // __m256i _mm256_lddqu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadDqu(uint* mem) { throw new NotImplementedException(); } + // __m256i _mm256_lddqu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadDqu(long* mem) { throw new NotImplementedException(); } + // __m256i _mm256_lddqu_si256 (__m256i const * mem_addr) + public static unsafe Vector256 LoadDqu(ulong* mem) { throw new NotImplementedException(); } + + // __m128d _mm_maskload_pd (double const * mem_addr, __m128i mask) + public static unsafe Vector128 MaskLoad(float* mem, Vector128 mask) { throw new NotImplementedException(); } + // __m128d _mm_maskload_pd (double const * mem_addr, __m128i mask) + public static unsafe Vector128 MaskLoad(double* mem, Vector128 mask) { throw new NotImplementedException(); } + + // __m256 _mm256_maskload_ps (float const * mem_addr, __m256i mask) + public static unsafe Vector256 MaskLoad(float* mem, Vector256 mask) { throw new NotImplementedException(); } + // __m256d _mm256_maskload_pd (double const * mem_addr, __m256i mask) + public static unsafe Vector256 MaskLoad(double* mem, Vector256 mask) { throw new NotImplementedException(); } + + // void _mm_maskstore_ps (float * mem_addr, __m128i mask, __m128 a) + public static unsafe void MaskStore(float* mem, Vector128 mask, Vector128 source) { throw new NotImplementedException(); } + // void _mm_maskstore_pd (double * mem_addr, __m128i mask, __m128d a) + public static unsafe void MaskStore(double* mem, Vector128 mask, Vector128 source) { throw new NotImplementedException(); } + + // void _mm256_maskstore_ps (float * mem_addr, __m256i mask, __m256 a) + public static unsafe void MaskStore(float* mem, Vector256 mask, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_maskstore_pd (double * mem_addr, __m256i mask, __m256d a) + public static unsafe void MaskStore(double* mem, Vector256 mask, Vector256 source) { throw new NotImplementedException(); } + + // __m256 _mm256_max_ps (__m256 a, __m256 b) + public static Vector256 Max(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_max_pd (__m256d a, __m256d b) + public static Vector256 Max(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_min_ps (__m256 a, __m256 b) + public static Vector256 Min(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_min_pd (__m256d a, __m256d b) + public static Vector256 Min(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // int _mm256_movemask_ps (__m256 a) + public static int MoveMask(Vector256 value) { throw new NotImplementedException(); } + // int _mm256_movemask_pd (__m256d a) + public static int MoveMask(Vector256 value) { throw new NotImplementedException(); } + + // __m256 _mm256_mul_ps (__m256 a, __m256 b) + public static Vector256 Multiply(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_mul_pd (__m256d a, __m256d b) + public static Vector256 Multiply(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_or_ps (__m256 a, __m256 b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_or_pd (__m256d a, __m256d b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m128 _mm_permute_ps (__m128 a, int imm8) + private static Vector128 Permute(Vector128 value, byte control) { throw new NotImplementedException(); } + public static PermuteVector128Delegate GetPermuteVector128Float(byte control) + { + return (value) => Permute(value, control); + } + // __m128d _mm_permute_pd (__m128d a, int imm8) + private static Vector128 Permute(Vector128 value, byte control) { throw new NotImplementedException(); } + public static PermuteVector128Delegate GetPermuteVector128Double(byte control) + { + return (value) => Permute(value, control); + } + + // __m256 _mm256_permute_ps (__m256 a, int imm8) + private static Vector256 Permute(Vector256 value, byte control) { throw new NotImplementedException(); } + public static PermuteVector256Delegate GetPermuteVector256Float(byte control) + { + return (value) => Permute(value, control); + } + // __m256d _mm256_permute_pd (__m256d a, int imm8) + private static Vector256 Permute(Vector256 value, byte control) { throw new NotImplementedException(); } + public static PermuteVector256Delegate GetPermuteVector256Double(byte control) + { + return (value) => Permute(value, control); + } + + // __m256 _mm256_permute2f128_ps (__m256 a, __m256 b, int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Float(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + // __m256d _mm256_permute2f128_pd (__m256d a, __m256d b, int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Double(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + + // __m128 _mm_permutevar_ps (__m128 a, __m128i b) + public static Vector128 PermuteVar(Vector128 left, Vector128 mask) { throw new NotImplementedException(); } + // __m128d _mm_permutevar_pd (__m128d a, __m128i b) + public static Vector128 PermuteVar(Vector128 left, Vector128 mask) { throw new NotImplementedException(); } + // __m256 _mm256_permutevar_ps (__m256 a, __m256i b) + public static Vector256 PermuteVar(Vector256 left, Vector256 mask) { throw new NotImplementedException(); } + // __m256d _mm256_permutevar_pd (__m256d a, __m256i b) + public static Vector256 PermuteVar(Vector256 left, Vector256 mask) { throw new NotImplementedException(); } + + // __m256 _mm256_rcp_ps (__m256 a) + public static Vector256 Reciprocal(Vector256 value) { throw new NotImplementedException(); } + + // __m256 _mm256_rsqrt_ps (__m256 a) + public static Vector256 ReciprocalSqrt(Vector256 value) { throw new NotImplementedException(); } + + // __m256 _mm256_round_ps (__m256 a, int rounding) + // _MM_FROUND_TO_NEAREST_INT |_MM_FROUND_NO_EXC + public static Vector256 RoundToNearestInteger(Vector256 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_NEG_INF |_MM_FROUND_NO_EXC + public static Vector256 RoundToNegativeInfinity(Vector256 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_POS_INF |_MM_FROUND_NO_EXC + public static Vector256 RoundToPositiveInfinity(Vector256 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_ZERO |_MM_FROUND_NO_EXC + public static Vector256 RoundToZero(Vector256 value) { throw new NotImplementedException(); } + // _MM_FROUND_CUR_DIRECTION + public static Vector256 RoundCurrentDirection(Vector256 value) { throw new NotImplementedException(); } + + // __m256d _mm256_round_pd (__m256d a, int rounding) + // _MM_FROUND_TO_NEAREST_INT |_MM_FROUND_NO_EXC + public static Vector256 RoundToNearestInteger(Vector256 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_NEG_INF |_MM_FROUND_NO_EXC + public static Vector256 RoundToNegativeInfinity(Vector256 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_POS_INF |_MM_FROUND_NO_EXC + public static Vector256 RoundToPositiveInfinity(Vector256 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_ZERO |_MM_FROUND_NO_EXC + public static Vector256 RoundToZero(Vector256 value) { throw new NotImplementedException(); } + // _MM_FROUND_CUR_DIRECTION + public static Vector256 RoundCurrentDirection(Vector256 value) { throw new NotImplementedException(); } + + // __m256i _mm256_set_epi8 (char e31, char e30, char e29, char e28, char e27, char e26, char e25, char e24, char e23, char e22, char e21, char e20, char e19, char e18, char e17, char e16, char e15, char e14, char e13, char e12, char e11, char e10, char e9, char e8, char e7, char e6, char e5, char e4, char e3, char e2, char e1, char e0) + public static Vector256 Set(sbyte e31, sbyte e30, sbyte e29, sbyte e28, sbyte e27, sbyte e26, sbyte e25, sbyte e24, sbyte e23, sbyte e22, sbyte e21, sbyte e20, sbyte e19, sbyte e18, sbyte e17, sbyte e16, sbyte e15, sbyte e14, sbyte e13, sbyte e12, sbyte e11, sbyte e10, sbyte e9, sbyte e8, sbyte e7, sbyte e6, sbyte e5, sbyte e4, sbyte e3, sbyte e2, sbyte e1, sbyte e0) + { + throw new NotImplementedException(); + } + // __m256i _mm256_set_epi8 (char e31, char e30, char e29, char e28, char e27, char e26, char e25, char e24, char e23, char e22, char e21, char e20, char e19, char e18, char e17, char e16, char e15, char e14, char e13, char e12, char e11, char e10, char e9, char e8, char e7, char e6, char e5, char e4, char e3, char e2, char e1, char e0) + public static Vector256 Set(byte e31, byte e30, byte e29, byte e28, byte e27, byte e26, byte e25, byte e24, byte e23, byte e22, byte e21, byte e20, byte e19, byte e18, byte e17, byte e16, byte e15, byte e14, byte e13, byte e12, byte e11, byte e10, byte e9, byte e8, byte e7, byte e6, byte e5, byte e4, byte e3, byte e2, byte e1, byte e0) + { + throw new NotImplementedException(); + } + // __m256i _mm256_set_epi16 (short e15, short e14, short e13, short e12, short e11, short e10, short e9, short e8, short e7, short e6, short e5, short e4, short e3, short e2, short e1, short e0) + public static Vector256 Set(short e15, short e14, short e13, short e12, short e11, short e10, short e9, short e8, short e7, short e6, short e5, short e4, short e3, short e2, short e1, short e0) + { + throw new NotImplementedException(); + } + // __m256i _mm256_set_epi16 (short e15, short e14, short e13, short e12, short e11, short e10, short e9, short e8, short e7, short e6, short e5, short e4, short e3, short e2, short e1, short e0) + public static Vector256 Set(ushort e15, ushort e14, ushort e13, ushort e12, ushort e11, ushort e10, ushort e9, ushort e8, ushort e7, ushort e6, ushort e5, ushort e4, ushort e3, ushort e2, ushort e1, ushort e0) + { + throw new NotImplementedException(); + } + // __m256i _mm256_set_epi32 (int e7, int e6, int e5, int e4, int e3, int e2, int e1, int e0) + public static Vector256 Set(int e7, int e6, int e5, int e4, int e3, int e2, int e1, int e0) + { + throw new NotImplementedException(); + } + // __m256i _mm256_set_epi32 (int e7, int e6, int e5, int e4, int e3, int e2, int e1, int e0) + public static Vector256 Set(uint e7, uint e6, uint e5, uint e4, uint e3, uint e2, uint e1, uint e0) + { + throw new NotImplementedException(); + } + // __m256i _mm256_set_epi64x (__int64 e3, __int64 e2, __int64 e1, __int64 e0) + public static Vector256 Set(long e3, long e2, long e1, long e0) { throw new NotImplementedException(); } + // __m256i _mm256_set_epi64x (__int64 e3, __int64 e2, __int64 e1, __int64 e0) + public static Vector256 Set(ulong e3, ulong e2, ulong e1, ulong e0) { throw new NotImplementedException(); } + // __m256 _mm256_set_ps (float e7, float e6, float e5, float e4, float e3, float e2, float e1, float e0) + public static Vector256 Set(float e7, float e6, float e5, float e4, float e3, float e2, float e1, float e0) + { + throw new NotImplementedException(); + } + // __m256d _mm256_set_pd (double e3, double e2, double e1, double e0) + public static Vector256 Set(double e3, double e2, double e1, double e0) { throw new NotImplementedException(); } + + // __m256i _mm256_set1_epi8 (char a) + // __m256i _mm256_set1_epi16 (short a) + // __m256i _mm256_set1_epi32 (int a) + // __m256i _mm256_set1_epi64x (long long a) + // __m256 _mm256_set1_ps (float a) + // __m256d _mm256_set1_pd (double a) + public static Vector256 Set1(T value) where T : struct { throw new NotImplementedException(); } + + // __m256 _mm256_set_m128 (__m128 hi, __m128 lo) + // __m256d _mm256_set_m128d (__m128d hi, __m128d lo) + // __m256i _mm256_set_m128i (__m128i hi, __m128i lo) + public static Vector256 SetHiLo(Vector128 hi, Vector128 lo) where T : struct { throw new NotImplementedException(); } + + // __m256i _mm256_setzero_si256 (void) + // __m256 _mm256_setzero_ps (void) + // __m256d _mm256_setzero_pd (void) + public static Vector256 SetZero() where T : struct { throw new NotImplementedException(); } + + // __m256 _mm256_shuffle_ps (__m256 a, __m256 b, const int imm8) + private static Vector256 Shuffle(Vector256 value, Vector256 right, byte control) { throw new NotImplementedException(); } + public static ShuffleTwoVector256Delegate GetShuffleVector256Float(byte control) + { + return (left, right) => Shuffle(left, right, control); + } + // __m256d _mm256_shuffle_pd (__m256d a, __m256d b, const int imm8) + private static Vector256 Shuffle(Vector256 value, Vector256 right, byte control) { throw new NotImplementedException(); } + public static ShuffleTwoVector256Delegate GetShuffleVector256Double(byte control) + { + return (left, right) => Shuffle(left, right, control); + } + + // __m256 _mm256_sqrt_ps (__m256 a) + public static Vector256 Sqrt(Vector256 value) { throw new NotImplementedException(); } + // __m256d _mm256_sqrt_pd (__m256d a) + public static Vector256 Sqrt(Vector256 value) { throw new NotImplementedException(); } + + // void _mm256_store_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAligned(sbyte* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAligned(byte* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAligned(short* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAligned(ushort* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAligned(int* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAligned(uint* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAligned(long* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAligned(ulong* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_ps (float * mem_addr, __m256 a) + public static unsafe void StoreAligned(float* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_store_pd (double * mem_addr, __m256d a) + public static unsafe void StoreAligned(double* mem, Vector256 source) { throw new NotImplementedException(); } + + // void _mm256_stream_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAlignedNonTemporal(sbyte* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAlignedNonTemporal(byte* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAlignedNonTemporal(short* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAlignedNonTemporal(ushort* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAlignedNonTemporal(int* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAlignedNonTemporal(uint* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAlignedNonTemporal(long* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void StoreAlignedNonTemporal(ulong* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_ps (float * mem_addr, __m256 a) + public static unsafe void StoreAlignedNonTemporal(float* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_stream_pd (double * mem_addr, __m256d a) + public static unsafe void StoreAlignedNonTemporal(double* mem, Vector256 source) { throw new NotImplementedException(); } + + // void _mm256_storeu_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void Store(sbyte* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void Store(byte* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void Store(short* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void Store(ushort* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void Store(int* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void Store(uint* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void Store(long* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_si256 (__m256i * mem_addr, __m256i a) + public static unsafe void Store(ulong* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_ps (float * mem_addr, __m256 a) + public static unsafe void Store(float* mem, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_storeu_pd (double * mem_addr, __m256d a) + public static unsafe void Store(double* mem, Vector256 source) { throw new NotImplementedException(); } + + // __m256 _mm256_sub_ps (__m256 a, __m256 b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_sub_pd (__m256d a, __m256d b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // int _mm_testc_ps (__m128 a, __m128 b) + public static bool TestC(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // int _mm_testc_pd (__m128d a, __m128d b) + public static bool TestC(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // int _mm256_testc_si256 (__m256i a, __m256i b) + // int _mm256_testc_ps (__m256 a, __m256 b) + // int _mm256_testc_pd (__m256d a, __m256d b) + public static bool TestC(Vector256 left, Vector256 right) where T : struct { throw new NotImplementedException(); } + + // int _mm_testnzc_ps (__m128 a, __m128 b) + public static bool TestNotZAndNotC(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // int _mm_testnzc_pd (__m128d a, __m128d b) + public static bool TestNotZAndNotC(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // int _mm256_testnzc_si256 (__m256i a, __m256i b) + // int _mm256_testnzc_ps (__m256 a, __m256 b) + // int _mm256_testnzc_pd (__m256d a, __m256d b) + public static bool TestNotZAndNotC(Vector256 left, Vector256 right) where T : struct { throw new NotImplementedException(); } + + // int _mm_testz_ps (__m128 a, __m128 b) + public static bool TestZ(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // int _mm_testz_ps (__m128 a, __m128 b) + public static bool TestZ(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // int _mm256_testz_si256 (__m256i a, __m256i b) + // int _mm256_testz_ps (__m256 a, __m256 b) + // int _mm256_testz_pd (__m256d a, __m256d b) + public static bool TestZ(Vector256 left, Vector256 right) where T : struct { throw new NotImplementedException(); } + + // __m256 _mm256_unpackhi_ps (__m256 a, __m256 b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_unpackhi_pd (__m256d a, __m256d b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_unpacklo_ps (__m256 a, __m256 b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_unpacklo_pd (__m256d a, __m256d b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256 _mm256_xor_ps (__m256 a, __m256 b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256d _mm256_xor_pd (__m256d a, __m256d b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // void _mm256_zeroall (void) + public static void ZeroAll() { throw new NotImplementedException(); } + // void _mm256_zeroupper (void) + public static void ZeroUpper() { throw new NotImplementedException(); } + } +} + + diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/AVX2.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/AVX2.cs new file mode 100644 index 00000000000..71d1a7a7313 --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/AVX2.cs @@ -0,0 +1,1161 @@ +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// AVX2.cs +// +// A class that implements intrinsic functions to provide access to Intel AVX2 instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + /// + /// Provides access to Intel AVX2 hardware instructions via intrinsics + /// + /// + /// AVX2 class provides access to 256-bit SIMD instructions + /// + + public static class AVX2 + { + // __m256i _mm256_abs_epi8 (__m256i a) + public static Vector256 Abs(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_abs_epi16 (__m256i a) + public static Vector256 Abs(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_abs_epi32 (__m256i a) + public static Vector256 Abs(Vector256 value) { throw new NotImplementedException(); } + + // __m256i _mm256_add_epi8 (__m256i a, __m256i b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_add_epi8 (__m256i a, __m256i b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_add_epi16 (__m256i a, __m256i b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_add_epi16 (__m256i a, __m256i b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_add_epi32 (__m256i a, __m256i b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_add_epi32 (__m256i a, __m256i b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_add_epi64 (__m256i a, __m256i b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_add_epi64 (__m256i a, __m256i b) + public static Vector256 Add(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_adds_epi8 (__m256i a, __m256i b) + public static Vector256 AddSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_adds_epu8 (__m256i a, __m256i b) + public static Vector256 AddSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_adds_epi16 (__m256i a, __m256i b) + public static Vector256 AddSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_adds_epu16 (__m256i a, __m256i b) + public static Vector256 AddSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count) + private static Vector256 AlignRight(Vector256 left, Vector256 right, byte mask) { throw new NotImplementedException(); } + public static AlignRightVector256Delegate GetAlignRightVector256Sbyte(byte mask) + { + return (left, right) => AlignRight(left, right, mask); + } + + // __m256i _mm256_and_si256 (__m256i a, __m256i b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_and_si256 (__m256i a, __m256i b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_and_si256 (__m256i a, __m256i b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_and_si256 (__m256i a, __m256i b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_and_si256 (__m256i a, __m256i b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_and_si256 (__m256i a, __m256i b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_and_si256 (__m256i a, __m256i b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_and_si256 (__m256i a, __m256i b) + public static Vector256 And(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_andnot_si256 (__m256i a, __m256i b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_andnot_si256 (__m256i a, __m256i b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_andnot_si256 (__m256i a, __m256i b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_andnot_si256 (__m256i a, __m256i b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_andnot_si256 (__m256i a, __m256i b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_andnot_si256 (__m256i a, __m256i b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_andnot_si256 (__m256i a, __m256i b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_andnot_si256 (__m256i a, __m256i b) + public static Vector256 AndNot(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_avg_epu8 (__m256i a, __m256i b) + public static Vector256 Average(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_avg_epu16 (__m256i a, __m256i b) + public static Vector256 Average(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m128i _mm_blend_epi32 (__m128i a, __m128i b, const int imm8) + private static Vector128 Blend(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static BlendVector128Delegate GetBlendVector128Short(byte control) + { + return (left, right) => Blend(left, right, control); + } + // __m128i _mm_blend_epi32 (__m128i a, __m128i b, const int imm8) + private static Vector128 Blend(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static BlendVector128Delegate GetBlendVector128Ushort(byte control) + { + return (left, right) => Blend(left, right, control); + } + // __m256i _mm256_blend_epi16 (__m256i a, __m256i b, const int imm8) + private static Vector256 Blend(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static BlendVector256Delegate GetBlendVector256Short(byte control) + { + return (left, right) => Blend(left, right, control); + } + // __m256i _mm256_blend_epi16 (__m256i a, __m256i b, const int imm8) + private static Vector256 Blend(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static BlendVector256Delegate GetBlendVector256Ushort(byte control) + { + return (left, right) => Blend(left, right, control); + } + // __m256i _mm256_blend_epi32 (__m256i a, __m256i b, const int imm8) + private static Vector256 Blend(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static BlendVector256Delegate GetBlendVector256Int(byte control) + { + return (left, right) => Blend(left, right, control); + } + // __m256i _mm256_blend_epi32 (__m256i a, __m256i b, const int imm8) + private static Vector256 Blend(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static BlendVector256Delegate GetBlendVector256Uint(byte control) + { + return (left, right) => Blend(left, right, control); + } + + // __m256i _mm256_blendv_epi8 (__m256i a, __m256i b, __m256i mask) + public static Vector256 BlendVariable(Vector256 left, Vector256 right, Vector256 mask) { throw new NotImplementedException(); } + // __m256i _mm256_blendv_epi8 (__m256i a, __m256i b, __m256i mask) + public static Vector256 BlendVariable(Vector256 left, Vector256 right, Vector256 mask) { throw new NotImplementedException(); } + + // __m128i _mm_broadcastb_epi8 (__m128i a) + // __m128i _mm_broadcastw_epi16 (__m128i a) + // __m128i _mm_broadcastd_epi32 (__m128i a) + // __m128i _mm_broadcastq_epi64 (__m128i a) + // __m128 _mm_broadcastss_ps (__m128 a) + // __m128d _mm_broadcastsd_pd (__m128d a) + public static Vector128 BroadcastVector128(Vector128 value) where T : struct { throw new NotImplementedException(); } + + // __m256i _mm256_broadcastb_epi8 (__m128i a) + // __m256i _mm256_broadcastw_epi16 (__m128i a) + // __m256i _mm256_broadcastd_epi32 (__m128i a) + // __m256i _mm256_broadcastq_epi64 (__m128i a) + // __m128 _mm_broadcastss_ps (__m128 a) + // __m256d _mm256_broadcastsd_pd (__m128d a) + public static Vector256 BroadcastVector256(Vector128 value) where T : struct { throw new NotImplementedException(); } + + // __m256i _mm_broadcastsi128_si256 (__m128i a) + // __m256i _mm256_broadcastsi128_si256 (__m128i a) + public static unsafe Vector256 BroadcastVector256(sbyte* mem) { throw new NotImplementedException(); } + public static unsafe Vector256 BroadcastVector256(byte* mem) { throw new NotImplementedException(); } + public static unsafe Vector256 BroadcastVector256(short* mem) { throw new NotImplementedException(); } + public static unsafe Vector256 BroadcastVector256(ushort* mem) { throw new NotImplementedException(); } + public static unsafe Vector256 BroadcastVector256(int* mem) { throw new NotImplementedException(); } + public static unsafe Vector256 BroadcastVector256(uint* mem) { throw new NotImplementedException(); } + public static unsafe Vector256 BroadcastVector256(long* mem) { throw new NotImplementedException(); } + public static unsafe Vector256 BroadcastVector256(ulong* mem) { throw new NotImplementedException(); } + + // __m256i _mm256_cmpeq_epi8 (__m256i a, __m256i b) + public static Vector256 CompareEqual(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpeq_epi8 (__m256i a, __m256i b) + public static Vector256 CompareEqual(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpeq_epi16 (__m256i a, __m256i b) + public static Vector256 CompareEqual(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpeq_epi16 (__m256i a, __m256i b) + public static Vector256 CompareEqual(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpeq_epi32 (__m256i a, __m256i b) + public static Vector256 CompareEqual(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpeq_epi32 (__m256i a, __m256i b) + public static Vector256 CompareEqual(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpeq_epi64 (__m256i a, __m256i b) + public static Vector256 CompareEqual(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpeq_epi64 (__m256i a, __m256i b) + public static Vector256 CompareEqual(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_cmpgt_epi8 (__m256i a, __m256i b) + public static Vector256 CompareGreaterThan(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpgt_epi16 (__m256i a, __m256i b) + public static Vector256 CompareGreaterThan(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpgt_epi32 (__m256i a, __m256i b) + public static Vector256 CompareGreaterThan(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_cmpgt_epi64 (__m256i a, __m256i b) + public static Vector256 CompareGreaterThan(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_cvtepi8_epi16 (__m128i a) + public static Vector256 ConvertToVector256Short(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepu8_epi16 (__m128i a) + public static Vector256 ConvertToVector256UShort(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepi8_epi32 (__m128i a) + public static Vector256 ConvertToVector256Int(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepi16_epi32 (__m128i a) + public static Vector256 ConvertToVector256Int(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepu8_epi32 (__m128i a) + public static Vector256 ConvertToVector256UInt(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepu16_epi32 (__m128i a) + public static Vector256 ConvertToVector256UInt(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepi8_epi64 (__m128i a) + public static Vector256 ConvertToVector256Long(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepi16_epi64 (__m128i a) + public static Vector256 ConvertToVector256Long(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepi32_epi64 (__m128i a) + public static Vector256 ConvertToVector256Long(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepu8_epi64 (__m128i a) + public static Vector256 ConvertToVector256ULong(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepu16_epi64 (__m128i a) + public static Vector256 ConvertToVector256ULong(Vector256 value) { throw new NotImplementedException(); } + // __m256i _mm256_cvtepu32_epi64 (__m128i a) + public static Vector256 ConvertToVector256ULong(Vector256 value) { throw new NotImplementedException(); } + + // __m128i _mm256_extracti128_si256 (__m256i a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Sbyte(byte index) + { + return (value) => ExtractVector128(value, index); + } + // __m128i _mm256_extracti128_si256 (__m256i a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Byte(byte index) + { + return (value) => ExtractVector128(value, index); + } + // __m128i _mm256_extracti128_si256 (__m256i a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Short(byte index) + { + return (value) => ExtractVector128(value, index); + } + // __m128i _mm256_extracti128_si256 (__m256i a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Ushort(byte index) + { + return (value) => ExtractVector128(value, index); + } + // __m128i _mm256_extracti128_si256 (__m256i a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Int(byte index) + { + return (value) => ExtractVector128(value, index); + } + // __m128i _mm256_extracti128_si256 (__m256i a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Uint(byte index) + { + return (value) => ExtractVector128(value, index); + } + // __m128i _mm256_extracti128_si256 (__m256i a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Long(byte index) + { + return (value) => ExtractVector128(value, index); + } + // __m128i _mm256_extracti128_si256 (__m256i a, const int imm8) + private static Vector128 ExtractVector128(Vector256 value, byte index) { throw new NotImplementedException(); } + public static Extract128Vector256Delegate GetExtractVector128Ulong(byte index) + { + return (value) => ExtractVector128(value, index); + } + + // __m128i _mm_i32gather_epi32 (int const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(int* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector128IntDelegate GetGatherVector128IntIndexVector128Int(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128i _mm_i32gather_epi32 (int const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(uint* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector128UintDelegate GetGatherVector128IntIndexVector128Uint(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128i _mm_i32gather_epi64 (__int64 const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(long* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector128LongDelegate GetGatherVector128IntIndexVector128Long(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128i _mm_i32gather_epi64 (__int64 const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(ulong* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector128UlongDelegate GetGatherVector128IntIndexVector128Ulong(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128 _mm_i32gather_ps (float const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(float* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector128FloatDelegate GetGatherVector128IntIndexVector128Float(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128d _mm_i32gather_pd (double const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(double* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector128DoubleDelegate GetGatherVector128IntIndexVector128Double(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128i _mm_i64gather_epi32 (int const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(int* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128LongIndexVector128IntDelegate GetGatherVector128LongIndexVector128Int(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128i _mm_i64gather_epi32 (int const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(uint* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128LongIndexVector128UintDelegate GetGatherVector128LongIndexVector128Uint(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128i _mm_i64gather_epi64 (__int64 const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(long* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128LongIndexVector128LongDelegate GetGatherVector128LongIndexVector128Long(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128i _mm_i64gather_epi64 (__int64 const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(ulong* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128LongIndexVector128UlongDelegate GetGatherVector128LongIndexVector128Ulong(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128 _mm_i64gather_ps (float const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(float* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128LongIndexVector128FloatDelegate GetGatherVector128LongIndexVector128Float(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128d _mm_i64gather_pd (double const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector128 GatherVector128(double* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128LongIndexVector128DoubleDelegate GetGatherVector128LongIndexVector128Double(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m256i _mm256_i32gather_epi32 (int const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector256 GatherVector256(int* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256IntIndexVector256IntDelegate GetGatherVector256IntIndexVector256Int(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + // __m256i _mm256_i32gather_epi32 (int const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector256 GatherVector256(uint* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256IntIndexVector256UintDelegate GetGatherVector256IntIndexVector256Uint(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + // __m256i _mm256_i32gather_epi64 (__int64 const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector256 GatherVector256(long* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector256LongDelegate GetGatherVector128IntIndexVector256Long(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + // __m256i _mm256_i32gather_epi64 (__int64 const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector256 GatherVector256(ulong* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector256UlongDelegate GetGatherVector128IntIndexVector256Ulong(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + // __m256 _mm256_i32gather_ps (float const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector256 GatherVector256(float* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256IntIndexVector256FloatDelegate GetGatherVector256IntIndexVector256Float(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + // __m256d _mm256_i32gather_pd (double const* base_addr, __m128i vindex, const int scale) + private static unsafe Vector256 GatherVector256(double* start, Vector128 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector128IntIndexVector256DoubleDelegate GetGatherVector128IntIndexVector256Double(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + // __m128i _mm256_i64gather_epi32 (int const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector128 GatherVector128(int* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256LongIndexVector128IntDelegate GetGatherVector256LongIndexVector128Int(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m128i _mm256_i64gather_epi32 (int const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector128 GatherVector128(uint* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256LongIndexVector128UintDelegate GetGatherVector256LongIndexVector256Uint(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m256i _mm256_i64gather_epi64 (__int64 const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector256 GatherVector256(long* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256LongIndexVector256LongDelegate GetGatherVector256LongIndexVector256Long(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + // __m256i _mm256_i64gather_epi64 (__int64 const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector256 GatherVector256(ulong* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256LongIndexVector256UlongDelegate GetGatherVector256LongIndexVector256Ulong(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + // __m128 _mm256_i64gather_ps (float const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector128 GatherVector128(float* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256LongIndexVector128FloatDelegate GetGatherVector256LongIndexVector128Float(byte scale) + { + return (start, index) => GatherVector128(start, index, scale); + } + // __m256d _mm256_i64gather_pd (double const* base_addr, __m256i vindex, const int scale) + private static unsafe Vector256 GatherVector256(double* start, Vector256 index, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherVector256LongIndexVector256DoubleDelegate GetGatherVector256LongIndexVector256Double(byte scale) + { + return (start, index) => GatherVector256(start, index, scale); + } + + // __m128i _mm_mask_i32gather_epi32 (__m128i src, int const* base_addr, __m128i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, int* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector128IntDelegate GetGatherMaskVector128IntIndexVector128Int(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128i _mm_mask_i32gather_epi32 (__m128i src, int const* base_addr, __m128i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, uint* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector128UintDelegate GetGatherMaskVector128IntIndexVector128Uint(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128i _mm_mask_i32gather_epi64 (__m128i src, __int64 const* base_addr, __m128i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, long* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector128LongDelegate GetGatherMaskVector128IntIndexVector128Long(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128i _mm_mask_i32gather_epi64 (__m128i src, __int64 const* base_addr, __m128i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, ulong* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector128UlongDelegate GetGatherMaskVector128IntIndexVector128Ulong(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128 _mm_mask_i32gather_ps (__m128 src, float const* base_addr, __m128i vindex, __m128 mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, float* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector128FloatDelegate GetGatherMaskVector128IntIndexVector128Float(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128d _mm_mask_i32gather_pd (__m128d src, double const* base_addr, __m128i vindex, __m128d mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, double* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector128DoubleDelegate GetGatherMaskVector128IntIndexVector128Double(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128i _mm_mask_i64gather_epi32 (__m128i src, int const* base_addr, __m128i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, int* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128LongIndexVector128IntDelegate GetGatherMaskVector128LongIndexVector128Int(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128i _mm_mask_i64gather_epi32 (__m128i src, int const* base_addr, __m128i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, uint* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128LongIndexVector128UintDelegate GetGatherMaskVector128LongIndexVector128Uint(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128i _mm_mask_i64gather_epi64 (__m128i src, __int64 const* base_addr, __m128i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, long* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128LongIndexVector128LongDelegate GetGatherMaskVector128LongIndexVector128Long(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128i _mm_mask_i64gather_epi64 (__m128i src, __int64 const* base_addr, __m128i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, ulong* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128LongIndexVector128UlongDelegate GetGatherMaskVector128LongIndexVector128Ulong(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128 _mm_mask_i64gather_ps (__m128 src, float const* base_addr, __m128i vindex, __m128 mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, float* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128LongIndexVector128FloatDelegate GetGatherMaskVector128LongIndexVector128Float(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128d _mm_mask_i64gather_pd (__m128d src, double const* base_addr, __m128i vindex, __m128d mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, double* start, Vector128 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128LongIndexVector128DoubleDelegate GetGatherMaskVector128LongIndexVector128Double(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m256i _mm256_mask_i32gather_epi32 (__m256i src, int const* base_addr, __m256i vindex, __m256i mask, const int scale) + private static unsafe Vector256 GatherMaskVector256(Vector256 source, int* start, Vector256 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256IntIndexVector256IntDelegate GetGatherMaskVector256IntIndexVector256Int(byte scale) + { + return (source, start, index, mask) => GatherMaskVector256(source, start, index, mask, scale); + } + // __m256i _mm256_mask_i32gather_epi32 (__m256i src, int const* base_addr, __m256i vindex, __m256i mask, const int scale) + private static unsafe Vector256 GatherMaskVector256(Vector256 source, uint* start, Vector256 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256IntIndexVector256UintDelegate GetGatherMaskVector256IntIndexVector256Uint(byte scale) + { + return (source, start, index, mask) => GatherMaskVector256(source, start, index, mask, scale); + } + // __m256i _mm256_mask_i32gather_epi64 (__m256i src, __int64 const* base_addr, __m128i vindex, __m256i mask, const int scale) + private static unsafe Vector256 GatherMaskVector256(Vector256 source, long* start, Vector128 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector256LongDelegate GetGatherMaskVector128IntIndexVector256Long(byte scale) + { + return (source, start, index, mask) => GatherMaskVector256(source, start, index, mask, scale); + } + // __m256i _mm256_mask_i32gather_epi64 (__m256i src, __int64 const* base_addr, __m128i vindex, __m256i mask, const int scale) + private static unsafe Vector256 GatherMaskVector256(Vector256 source, ulong* start, Vector128 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector256UlongDelegate GetGatherMaskVector128IntIndexVector256Ulong(byte scale) + { + return (source, start, index, mask) => GatherMaskVector256(source, start, index, mask, scale); + } + // __m256 _mm256_mask_i32gather_ps (__m256 src, float const* base_addr, __m256i vindex, __m256 mask, const int scale) + private static unsafe Vector256 GatherMaskVector256(Vector256 source, float* start, Vector256 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256IntIndexVector256FloatDelegate GetGatherMaskVector256IntIndexVector256Float(byte scale) + { + return (source, start, index, mask) => GatherMaskVector256(source, start, index, mask, scale); + } + // __m256d _mm256_mask_i32gather_pd (__m256d src, double const* base_addr, __m128i vindex, __m256d mask, const int scale) + private static unsafe Vector256 GatherMaskVector256(Vector256 source, double* start, Vector128 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector128IntIndexVector256DoubleDelegate GetGatherMaskVector128IntIndexVector256Double(byte scale) + { + return (source, start, index, mask) => GatherMaskVector256(source, start, index, mask, scale); + } + // __m128i _mm256_mask_i64gather_epi32 (__m128i src, int const* base_addr, __m256i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, int* start, Vector256 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256LongIndexVector128IntDelegate GetGatherMaskVector256LongIndexVector128Int(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m128i _mm256_mask_i64gather_epi32 (__m128i src, int const* base_addr, __m256i vindex, __m128i mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, uint* start, Vector256 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256LongIndexVector128UintDelegate GetGatherMaskVector256LongIndexVector128Uint(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m256i _mm256_mask_i64gather_epi64 (__m256i src, __int64 const* base_addr, __m256i vindex, __m256i mask, const int scale) + private static unsafe Vector256 GatherMask(Vector256 source, long* start, Vector256 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256LongIndexVector256LongDelegate GetGatherMaskVector256LongIndexVector256Long(byte scale) + { + return (source, start, index, mask) => GatherMask(source, start, index, mask, scale); + } + // __m256i _mm256_mask_i64gather_epi64 (__m256i src, __int64 const* base_addr, __m256i vindex, __m256i mask, const int scale) + private static unsafe Vector256 GatherMaskVector256(Vector256 source, ulong* start, Vector256 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256LongIndexVector256UlongDelegate GetGatherMaskVector256LongIndexVector256Ulong(byte scale) + { + return (source, start, index, mask) => GatherMaskVector256(source, start, index, mask, scale); + } + // __m128 _mm256_mask_i64gather_ps (__m128 src, float const* base_addr, __m256i vindex, __m128 mask, const int scale) + private static unsafe Vector128 GatherMaskVector128(Vector128 source, float* start, Vector256 index, Vector128 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256LongIndexVector128FloatDelegate GetGatherMaskVector256LongIndexVector128Float(byte scale) + { + return (source, start, index, mask) => GatherMaskVector128(source, start, index, mask, scale); + } + // __m256d _mm256_mask_i64gather_pd (__m256d src, double const* base_addr, __m256i vindex, __m256d mask, const int scale) + private static unsafe Vector256 GatherMaskVector256(Vector256 source, double* start, Vector256 index, Vector256 mask, byte scale) { throw new NotImplementedException(); } + public static unsafe GatherMaskVector256LongIndexVector256DoubleDelegate GetGatherMaskVector256LongIndexVector256Double(byte scale) + { + return (source, start, index, mask) => GatherMaskVector256(source, start, index, mask, scale); + } + + // __m256i _mm256_hadd_epi16 (__m256i a, __m256i b) + public static Vector256 HorizontalAdd(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_hadd_epi32 (__m256i a, __m256i b) + public static Vector256 HorizontalAdd(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_hadds_epi16 (__m256i a, __m256i b) + public static Vector256 HorizontalAddSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_hsub_epi16 (__m256i a, __m256i b) + public static Vector256 HorizontalSubtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_hsub_epi32 (__m256i a, __m256i b) + public static Vector256 HorizontalSubtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_hsubs_epi16 (__m256i a, __m256i b) + public static Vector256 HorizontalSubtractSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_inserti128_si256 (__m256i a, __m128i b, const int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Sbyte(byte index) + { + return (value, data) => Insert(value, data, index); + } + // __m256i _mm256_inserti128_si256 (__m256i a, __m128i b, const int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Byte(byte index) + { + return (value, data) => Insert(value, data, index); + } + // __m256i _mm256_inserti128_si256 (__m256i a, __m128i b, const int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Short(byte index) + { + return (value, data) => Insert(value, data, index); + } + // __m256i _mm256_inserti128_si256 (__m256i a, __m128i b, const int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Ushort(byte index) + { + return (value, data) => Insert(value, data, index); + } + // __m256i _mm256_inserti128_si256 (__m256i a, __m128i b, const int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Int(byte index) + { + return (value, data) => Insert(value, data, index); + } + // __m256i _mm256_inserti128_si256 (__m256i a, __m128i b, const int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Uint(byte index) + { + return (value, data) => Insert(value, data, index); + } + // __m256i _mm256_inserti128_si256 (__m256i a, __m128i b, const int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Long(byte index) + { + return (value, data) => Insert(value, data, index); + } + // __m256i _mm256_inserti128_si256 (__m256i a, __m128i b, const int imm8) + private static Vector256 Insert(Vector256 value, Vector128 data, byte index) { throw new NotImplementedException(); } + public static Insert128Vector256Delegate GetInsertVector128Ulong(byte index) + { + return (value, data) => Insert(value, data, index); + } + + // __m128i _mm_maskload_epi32 (int const* mem_addr, __m128i mask) + public static unsafe Vector128 MaskLoad(int* mem, Vector128 mask) { throw new NotImplementedException(); } + // __m128i _mm_maskload_epi32 (int const* mem_addr, __m128i mask) + public static unsafe Vector128 MaskLoad(uint* mem, Vector128 mask) { throw new NotImplementedException(); } + // __m128i _mm_maskload_epi64 (__int64 const* mem_addr, __m128i mask) + public static unsafe Vector128 MaskLoad(long* mem, Vector128 mask) { throw new NotImplementedException(); } + // __m128i _mm_maskload_epi64 (__int64 const* mem_addr, __m128i mask) + public static unsafe Vector128 MaskLoad(ulong* mem, Vector128 mask) { throw new NotImplementedException(); } + + // __m256i _mm256_maskload_epi32 (int const* mem_addr, __m256i mask) + public static unsafe Vector256 MaskLoad(int* mem, Vector256 mask) { throw new NotImplementedException(); } + // __m256i _mm256_maskload_epi32 (int const* mem_addr, __m256i mask) + public static unsafe Vector256 MaskLoad(uint* mem, Vector256 mask) { throw new NotImplementedException(); } + // __m256i _mm256_maskload_epi64 (__int64 const* mem_addr, __m256i mask) + public static unsafe Vector256 MaskLoad(long* mem, Vector256 mask) { throw new NotImplementedException(); } + // __m256i _mm256_maskload_epi64 (__int64 const* mem_addr, __m256i mask) + public static unsafe Vector256 MaskLoad(ulong* mem, Vector256 mask) { throw new NotImplementedException(); } + + // void _mm_maskstore_epi32 (int* mem_addr, __m128i mask, __m128i a) + public static unsafe void MaskStore(int* mem, Vector128 mask, Vector128 source) { throw new NotImplementedException(); } + // void _mm_maskstore_epi32 (int* mem_addr, __m128i mask, __m128i a) + public static unsafe void MaskStore(uint* mem, Vector128 mask, Vector128 source) { throw new NotImplementedException(); } + // void _mm_maskstore_epi64 (__int64* mem_addr, __m128i mask, __m128i a) + public static unsafe void MaskStore(long* mem, Vector128 mask, Vector128 source) { throw new NotImplementedException(); } + // void _mm_maskstore_epi64 (__int64* mem_addr, __m128i mask, __m128i a) + public static unsafe void MaskStore(ulong* mem, Vector128 mask, Vector128 source) { throw new NotImplementedException(); } + + // void _mm256_maskstore_epi32 (int* mem_addr, __m256i mask, __m256i a) + public static unsafe void MaskStore(int* mem, Vector256 mask, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_maskstore_epi32 (int* mem_addr, __m256i mask, __m256i a) + public static unsafe void MaskStore(uint* mem, Vector256 mask, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_maskstore_epi64 (__int64* mem_addr, __m256i mask, __m256i a) + public static unsafe void MaskStore(long* mem, Vector256 mask, Vector256 source) { throw new NotImplementedException(); } + // void _mm256_maskstore_epi64 (__int64* mem_addr, __m256i mask, __m256i a) + public static unsafe void MaskStore(ulong* mem, Vector256 mask, Vector256 source) { throw new NotImplementedException(); } + + // __m256i _mm256_madd_epi16 (__m256i a, __m256i b) + public static Vector256 MultiplyAddAdjacent(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_maddubs_epi16 (__m256i a, __m256i b) + public static Vector256 MultiplyAddAdjacent(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_max_epi8 (__m256i a, __m256i b) + public static Vector256 Max(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_max_epu8 (__m256i a, __m256i b) + public static Vector256 Max(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_max_epi16 (__m256i a, __m256i b) + public static Vector256 Max(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_max_epu16 (__m256i a, __m256i b) + public static Vector256 Max(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_max_epi32 (__m256i a, __m256i b) + public static Vector256 Max(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_max_epu32 (__m256i a, __m256i b) + public static Vector256 Max(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_min_epi8 (__m256i a, __m256i b) + public static Vector256 Min(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_min_epu8 (__m256i a, __m256i b) + public static Vector256 Min(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_min_epi16 (__m256i a, __m256i b) + public static Vector256 Min(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_min_epu16 (__m256i a, __m256i b) + public static Vector256 Min(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_min_epi32 (__m256i a, __m256i b) + public static Vector256 Min(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_min_epu32 (__m256i a, __m256i b) + public static Vector256 Min(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // int _mm256_movemask_epi8 (__m256i a) + public static int MoveMask(Vector256 value) { throw new NotImplementedException(); } + // int _mm256_movemask_epi8 (__m256i a) + public static int MoveMask(Vector256 value) { throw new NotImplementedException(); } + + // __m256i _mm256_mpsadbw_epu8 (__m256i a, __m256i b, const int imm8) + private static Vector256 MultipleSumAbsoluteDifference(Vector256 left, Vector256 right, byte mask) { throw new NotImplementedException(); } + public static MultipleSumAbsoluteDifferenceVector256Delegate GetMultipleSumAbsoluteDifferenceVector256(byte mask) + { + return (left, right) => MultipleSumAbsoluteDifference(left, right, mask); + } + + // __m256i _mm256_mul_epi32 (__m256i a, __m256i b) + public static Vector256 Multiply(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_mul_epu32 (__m256i a, __m256i b) + public static Vector256 Multiply(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_mulhi_epi16 (__m256i a, __m256i b) + public static Vector256 MultiplyHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_mulhi_epu16 (__m256i a, __m256i b) + public static Vector256 MultiplyHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_mulhrs_epi16 (__m256i a, __m256i b) + public static Vector256 MultiplyHighRoundScale(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_mullo_epi16 (__m256i a, __m256i b) + public static Vector256 MultiplyLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_mullo_epu16 (__m256i a, __m256i b) + public static Vector256 MultiplyLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_or_si256 (__m256i a, __m256i b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_or_si256 (__m256i a, __m256i b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_or_si256 (__m256i a, __m256i b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_or_si256 (__m256i a, __m256i b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_or_si256 (__m256i a, __m256i b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_or_si256 (__m256i a, __m256i b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_or_si256 (__m256i a, __m256i b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_or_si256 (__m256i a, __m256i b) + public static Vector256 Or(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_packs_epi16 (__m256i a, __m256i b) + public static Vector256 PackSignedSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_packs_epi32 (__m256i a, __m256i b) + public static Vector256 PackSignedSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_packus_epi16 (__m256i a, __m256i b) + public static Vector256 PackUnsignedSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_packus_epi32 (__m256i a, __m256i b) + public static Vector256 PackUnsignedSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_permute2x128_si256 (__m256i a, __m256i b, const int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Vector256Sbyte(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + // __m256i _mm256_permute2x128_si256 (__m256i a, __m256i b, const int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Vector256Byte(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + // __m256i _mm256_permute2x128_si256 (__m256i a, __m256i b, const int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Vector256Short(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + // __m256i _mm256_permute2x128_si256 (__m256i a, __m256i b, const int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Vector256Ushort(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + // __m256i _mm256_permute2x128_si256 (__m256i a, __m256i b, const int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Vector256Int(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + // __m256i _mm256_permute2x128_si256 (__m256i a, __m256i b, const int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Vector256Uint(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + // __m256i _mm256_permute2x128_si256 (__m256i a, __m256i b, const int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Vector256Long(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + // __m256i _mm256_permute2x128_si256 (__m256i a, __m256i b, const int imm8) + private static Vector256 Permute2x128(Vector256 left, Vector256 right, byte control) { throw new NotImplementedException(); } + public static Permute2x128Delegate GetPermute2x128Vector256Ulong(byte control) + { + return (left, right) => Permute2x128(left, right, control); + } + + // __m256i _mm256_permute4x64_epi64 (__m256i a, const int imm8) + private static Vector256 Permute4x64(Vector256 value, byte control) { throw new NotImplementedException(); } + public static Permute4x64Delegate GetPermute4x64Vector256Long(byte control) + { + return (value) => Permute4x64(value, control); + } + // __m256i _mm256_permute4x64_epi64 (__m256i a, const int imm8) + private static Vector256 Permute4x64(Vector256 value, byte control) { throw new NotImplementedException(); } + public static Permute4x64Delegate GetPermute4x64Vector256Ulong(byte control) + { + return (value) => Permute4x64(value, control); + } + // __m256d _mm256_permute4x64_pd (__m256d a, const int imm8) + private static Vector256 Permute4x64(Vector256 value, byte control) { throw new NotImplementedException(); } + public static Permute4x64Delegate GetPermute4x64Vector256Double(byte control) + { + return (value) => Permute4x64(value, control); + } + + // __m256i _mm256_permutevar8x32_epi32 (__m256i a, __m256i idx) + public static Vector256 PermuteVar8x32(Vector256 left, Vector256 mask) { throw new NotImplementedException(); } + // __m256i _mm256_permutevar8x32_epi32 (__m256i a, __m256i idx) + public static Vector256 PermuteVar8x32(Vector256 left, Vector256 mask) { throw new NotImplementedException(); } + // __m256 _mm256_permutevar8x32_ps (__m256 a, __m256i idx) + public static Vector256 PermuteVar8x32(Vector256 left, Vector256 mask) { throw new NotImplementedException(); } + + // __m256i _mm256_slli_epi16 (__m256i a, int imm8) + private static Vector256 ShiftLeftLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogicalVector256Short(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m256i _mm256_slli_epi16 (__m256i a, int imm8) + private static Vector256 ShiftLeftLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogicalVector256Ushort(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m256i _mm256_slli_epi32 (__m256i a, int imm8) + private static Vector256 ShiftLeftLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogicalVector256Int(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m256i _mm256_slli_epi32 (__m256i a, int imm8) + private static Vector256 ShiftLeftLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogicalVector256Uint(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m256i _mm256_slli_epi64 (__m256i a, int imm8) + private static Vector256 ShiftLeftLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogicalVector256Long(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m256i _mm256_slli_epi64 (__m256i a, int imm8) + private static Vector256 ShiftLeftLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogicalVector256Ulong(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + + // __m256i _mm256_bslli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftLeftLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogical128BitLaneVector256Sbyte(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bslli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftLeftLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogical128BitLaneVector256Byte(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bslli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftLeftLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogical128BitLaneVector256Short(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bslli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftLeftLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogical128BitLaneVector256Ushort(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bslli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftLeftLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogical128BitLaneVector256Int(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bslli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftLeftLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogical128BitLaneVector256Uint(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bslli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftLeftLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogical128BitLaneVector256Long(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bslli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftLeftLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftLeftLogical128BitLaneVector256Ulong(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + + // __m256i _mm256_sllv_epi32 (__m256i a, __m256i count) + public static Vector256 ShiftLeftLogicalVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + // __m256i _mm256_sllv_epi32 (__m256i a, __m256i count) + public static Vector256 ShiftLeftLogicalVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + // __m256i _mm256_sllv_epi64 (__m256i a, __m256i count) + public static Vector256 ShiftLeftLogicalVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + // __m256i _mm256_sllv_epi64 (__m256i a, __m256i count) + public static Vector256 ShiftLeftLogicalVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + + // __m256i _mm256_srai_epi16 (__m256i a, int imm8) + private static Vector256 ShiftRightArithmetic(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightArithmeticVector256Short(byte count) + { + return (value) => ShiftRightArithmetic(value, count); + } + // __m256i _mm256_srai_epi32 (__m256i a, int imm8) + private static Vector256 ShiftRightArithmetic(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightArithmeticVector256Int(byte count) + { + return (value) => ShiftRightArithmetic(value, count); + } + + // __m256i _mm256_srav_epi32 (__m256i a, __m256i count) + public static Vector256 ShiftRightArithmeticVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + + // __m256i _mm256_srli_epi16 (__m256i a, int imm8) + private static Vector256 ShiftRightLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogicalVector256Short(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m256i _mm256_srli_epi16 (__m256i a, int imm8) + private static Vector256 ShiftRightLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogicalVector256Ushort(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m256i _mm256_srli_epi32 (__m256i a, int imm8) + private static Vector256 ShiftRightLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogicalVector256Int(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m256i _mm256_srli_epi32 (__m256i a, int imm8) + private static Vector256 ShiftRightLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogicalVector256Uint(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m256i _mm256_srli_epi64 (__m256i a, int imm8) + private static Vector256 ShiftRightLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogicalVector256Long(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m256i _mm256_srli_epi64 (__m256i a, int imm8) + private static Vector256 ShiftRightLogical(Vector256 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogicalVector256Ulong(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + + // __m256i _mm256_bsrli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftRightLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogical128BitLaneVector256Sbyte(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bsrli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftRightLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogical128BitLaneVector256Byte(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bsrli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftRightLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogical128BitLaneVector256Short(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bsrli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftRightLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogical128BitLaneVector256Ushort(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bsrli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftRightLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogical128BitLaneVector256Int(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bsrli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftRightLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogical128BitLaneVector256Uint(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bsrli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftRightLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogical128BitLaneVector256Long(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m256i _mm256_bsrli_epi128 (__m256i a, const int imm8) + private static Vector256 ShiftRightLogical128BitLane(Vector256 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector256Delegate GetShiftRightLogical128BitLaneVector256Ulong(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + + // __m256i _mm256_srlv_epi32 (__m256i a, __m256i count) + public static Vector256 ShiftRightLogicalVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + // __m256i _mm256_srlv_epi32 (__m256i a, __m256i count) + public static Vector256 ShiftRightLogicalVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + // __m256i _mm256_srlv_epi64 (__m256i a, __m256i count) + public static Vector256 ShiftRightLogicalVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + // __m256i _mm256_srlv_epi64 (__m256i a, __m256i count) + public static Vector256 ShiftRightLogicalVariable(Vector256 value, Vector256 count) { throw new NotImplementedException(); } + + // __m256i _mm256_shuffle_epi8 (__m256i a, __m256i b) + public static Vector256 Shuffle(Vector256 value, Vector256 mask) { throw new NotImplementedException(); } + // __m256i _mm256_shuffle_epi8 (__m256i a, __m256i b) + public static Vector256 Shuffle(Vector256 value, Vector256 mask) { throw new NotImplementedException(); } + // __m256i _mm256_shuffle_epi32 (__m256i a, const int imm8) + private static Vector256 Shuffle(Vector256 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector256Delegate GetShuffleVector256Int(byte control) + { + return (value) => Shuffle(value, control); + } + // __m256i _mm256_shuffle_epi32 (__m256i a, const int imm8) + private static Vector256 Shuffle(Vector256 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector256Delegate GetShuffleVector256Uint(byte control) + { + return (value) => Shuffle(value, control); + } + + // __m256i _mm256_shufflehi_epi16 (__m256i a, const int imm8) + private static Vector256 ShuffleHigh(Vector256 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector256Delegate GetShuffleHighVector256Short(byte control) + { + return (value) => ShuffleHigh(value, control); + } + // __m256i _mm256_shufflehi_epi16 (__m256i a, const int imm8) + private static Vector256 ShuffleHigh(Vector256 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector256Delegate GetShuffleHighVector256Ushort(byte control) + { + return (value) => ShuffleHigh(value, control); + } + + // __m256i _mm256_shufflelo_epi16 (__m256i a, const int imm8) + private static Vector256 ShuffleLow(Vector256 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector256Delegate GetShuffleLowVector256Short(byte control) + { + return (value) => ShuffleLow(value, control); + } + // __m256i _mm256_shufflelo_epi16 (__m256i a, const int imm8) + private static Vector256 ShuffleLow(Vector256 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector256Delegate GetShuffleLowVector256Ushort(byte control) + { + return (value) => ShuffleLow(value, control); + } + + // __m256i _mm256_sign_epi8 (__m256i a, __m256i b) + public static Vector256 Sign(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sign_epi16 (__m256i a, __m256i b) + public static Vector256 Sign(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sign_epi32 (__m256i a, __m256i b) + public static Vector256 Sign(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_sub_epi8 (__m256i a, __m256i b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sub_epi8 (__m256i a, __m256i b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sub_epi16 (__m256i a, __m256i b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sub_epi16 (__m256i a, __m256i b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sub_epi32 (__m256i a, __m256i b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sub_epi32 (__m256i a, __m256i b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sub_epi64 (__m256i a, __m256i b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_sub_epi64 (__m256i a, __m256i b) + public static Vector256 Subtract(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_subs_epi8 (__m256i a, __m256i b) + public static Vector256 SubtractSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_subs_epi16 (__m256i a, __m256i b) + public static Vector256 SubtractSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_subs_epu8 (__m256i a, __m256i b) + public static Vector256 SubtractSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_subs_epu16 (__m256i a, __m256i b) + public static Vector256 SubtractSaturation(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_sad_epu8 (__m256i a, __m256i b) + public static Vector256 SumAbsoluteDifference(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_unpackhi_epi8 (__m256i a, __m256i b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpackhi_epi8 (__m256i a, __m256i b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpackhi_epi16 (__m256i a, __m256i b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpackhi_epi16 (__m256i a, __m256i b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpackhi_epi32 (__m256i a, __m256i b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpackhi_epi32 (__m256i a, __m256i b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpackhi_epi64 (__m256i a, __m256i b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpackhi_epi64 (__m256i a, __m256i b) + public static Vector256 UnpackHigh(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_unpacklo_epi8 (__m256i a, __m256i b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpacklo_epi8 (__m256i a, __m256i b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpacklo_epi16 (__m256i a, __m256i b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpacklo_epi16 (__m256i a, __m256i b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpacklo_epi32 (__m256i a, __m256i b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpacklo_epi32 (__m256i a, __m256i b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpacklo_epi64 (__m256i a, __m256i b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_unpacklo_epi64 (__m256i a, __m256i b) + public static Vector256 UnpackLow(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + + // __m256i _mm256_xor_si256 (__m256i a, __m256i b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_xor_si256 (__m256i a, __m256i b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_xor_si256 (__m256i a, __m256i b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_xor_si256 (__m256i a, __m256i b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_xor_si256 (__m256i a, __m256i b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_xor_si256 (__m256i a, __m256i b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_xor_si256 (__m256i a, __m256i b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + // __m256i _mm256_xor_si256 (__m256i a, __m256i b) + public static Vector256 Xor(Vector256 left, Vector256 right) { throw new NotImplementedException(); } + } +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Delegates.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Delegates.cs new file mode 100644 index 00000000000..0830a2e05aa --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Delegates.cs @@ -0,0 +1,172 @@ +using System; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + // Delegates for intrinsic functions that take an immediate value parameter which + // should be constants, but cannot be constrained to being constants in C#. + // Use of delegates and partial function application used to constrain the immediate parameter + + public delegate Vector128 AlignRightVector128Delegate(Vector128 left, Vector128 right); + public delegate Vector256 AlignRightVector256Delegate(Vector256 left, Vector256 right); + + public delegate Vector128 BlendVector128Delegate(Vector128 left, Vector128 right) where T : struct; + public delegate Vector256 BlendVector256Delegate(Vector256 left, Vector256 right) where T : struct; + + public delegate Vector128 CarryLessMultiplyVector128Delegate(Vector128 left, Vector128 right) where T : struct; + + public delegate bool CompareImplicitLengthVector128Delegate(Vector128 left, Vector128 right) where T : struct; + public delegate bool CompareExplicitLengthVector128Delegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength) where T : struct; + public delegate byte CompareImplicitLengthIndexVector128Delegate(Vector128 left, Vector128 right) where T : struct; + public delegate byte CompareExplicitLengthIndexVector128Delegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength) where T : struct; + + public delegate Vector128 CompareImplicitLengthBitMaskVector128SbyteDelegate(Vector128 left, Vector128 right); + public delegate Vector128 CompareImplicitLengthBitMaskVector128ByteDelegate(Vector128 left, Vector128 right); + public delegate Vector128 CompareImplicitLengthBitMaskVector128ShortDelegate(Vector128 left, Vector128 right); + public delegate Vector128 CompareImplicitLengthBitMaskVector128UshortDelegate(Vector128 left, Vector128 right); + + public delegate Vector128 CompareImplicitLengthUnitMaskVector128SbyteDelegate(Vector128 left, Vector128 right); + public delegate Vector128 CompareImplicitLengthUnitMaskVector128ByteDelegate(Vector128 left, Vector128 right); + public delegate Vector128 CompareImplicitLengthUnitMaskVector128ShortDelegate(Vector128 left, Vector128 right); + public delegate Vector128 CompareImplicitLengthUnitMaskVector128UshortDelegate(Vector128 left, Vector128 right); + + public delegate Vector128 CompareExplicitLengthBitMaskVector128SbyteDelegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength); + public delegate Vector128 CompareExplicitLengthBitMaskVector128ByteDelegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength); + public delegate Vector128 CompareExplicitLengthBitMaskVector128ShortDelegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength); + public delegate Vector128 CompareExplicitLengthBitMaskVector128UshortDelegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength); + + public delegate Vector128 CompareExplicitLengthUnitMaskVector128SbyteDelegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength); + public delegate Vector128 CompareExplicitLengthUnitMaskVector128ByteDelegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength); + public delegate Vector128 CompareExplicitLengthUnitMaskVector128ShortDelegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength); + public delegate Vector128 CompareExplicitLengthUnitMaskVector128UshortDelegate(Vector128 left, byte leftLength, Vector128 right, byte rightLength); + + public delegate Vector128 CompareVector128Delegate(Vector128 left, Vector128 right) where T : struct; + public delegate Vector256 CompareVector256Delegate(Vector256 left, Vector256 right) where T : struct; + + public delegate Vector256 DotProductVectro256Delegate(Vector256 left, Vector256 right); + + public delegate sbyte ExtractSbyteVector128Delegate(Vector128 value) where T : struct; + public delegate byte ExtractByteVector128Delegate(Vector128 value) where T : struct; + public delegate short ExtractShortVector128Delegate(Vector128 value) where T : struct; + public delegate ushort ExtractUShortVector128Delegate(Vector128 value) where T : struct; + public delegate int ExtractIntVector128Delegate(Vector128 value) where T : struct; + public delegate uint ExtractUIntVector128Delegate(Vector128 value) where T : struct; + public delegate long ExtractLongVector128Delegate(Vector128 value) where T : struct; + public delegate ulong ExtractUlongVector128Delegate(Vector128 value) where T : struct; + public delegate int ExtractFloatVector128Delegate(Vector128 value) where T : struct; + + public delegate sbyte ExtractSbyteVector256Delegate(Vector256 value) where T : struct; + public delegate byte ExtractByteVector256Delegate(Vector256 value) where T : struct; + public delegate short ExtractShortVector256Delegate(Vector256 value) where T : struct; + public delegate ushort ExtractUShortVector256Delegate(Vector256 value) where T : struct; + public delegate int ExtractIntVector256Delegate(Vector256 value) where T : struct; + public delegate uint ExtractUintVector256Delegate(Vector256 value) where T : struct; + public delegate long ExtractLongVector256Delegate(Vector256 value) where T : struct; + public delegate ulong ExtractUlongVector256Delegate(Vector256 value) where T : struct; + + public delegate Vector128 Extract128Vector256Delegate(Vector256 value) where T : struct; + + public unsafe delegate Vector128 GatherVector128IntIndexVector128IntDelegate(int* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128IntIndexVector128UintDelegate(uint* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128IntIndexVector128LongDelegate(long* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128IntIndexVector128UlongDelegate(ulong* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128IntIndexVector128FloatDelegate(float* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128IntIndexVector128DoubleDelegate(double* mem, Vector128 index); + + public unsafe delegate Vector256 GatherVector128IntIndexVector256LongDelegate(long* mem, Vector128 index); + public unsafe delegate Vector256 GatherVector128IntIndexVector256UlongDelegate(ulong* mem, Vector128 index); + public unsafe delegate Vector256 GatherVector128IntIndexVector256DoubleDelegate(double* mem, Vector128 index); + + public unsafe delegate Vector128 GatherVector128LongIndexVector128IntDelegate(int* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128LongIndexVector128UintDelegate(uint* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128LongIndexVector128LongDelegate(long* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128LongIndexVector128UlongDelegate(ulong* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128LongIndexVector128FloatDelegate(float* mem, Vector128 index); + public unsafe delegate Vector128 GatherVector128LongIndexVector128DoubleDelegate(double* mem, Vector128 index); + + public unsafe delegate Vector256 GatherVector256IntIndexVector256IntDelegate(int* mem, Vector256 index); + public unsafe delegate Vector256 GatherVector256IntIndexVector256UintDelegate(uint* mem, Vector256 index); + public unsafe delegate Vector256 GatherVector256IntIndexVector256LongDelegate(long* mem, Vector256 index); + public unsafe delegate Vector256 GatherVector256IntIndexVector256UlongDelegate(ulong* mem, Vector256 index); + public unsafe delegate Vector256 GatherVector256IntIndexVector256FloatDelegate(float* mem, Vector256 index); + public unsafe delegate Vector256 GatherVector256IntIndexVector256DoubleDelegate(double* mem, Vector256 index); + + public unsafe delegate Vector128 GatherVector256LongIndexVector128IntDelegate(int* mem, Vector256 index); + public unsafe delegate Vector128 GatherVector256LongIndexVector128UintDelegate(uint* mem, Vector256 index); + public unsafe delegate Vector256 GatherVector256LongIndexVector256LongDelegate(long* mem, Vector256 index); + public unsafe delegate Vector256 GatherVector256LongIndexVector256UlongDelegate(ulong* mem, Vector256 index); + public unsafe delegate Vector128 GatherVector256LongIndexVector128FloatDelegate(float* mem, Vector256 index); + public unsafe delegate Vector256 GatherVector256LongIndexVector256DoubleDelegate(double* mem, Vector256 index); + + public unsafe delegate Vector128 GatherMaskVector128IntIndexVector128IntDelegate(Vector128 source, int* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128IntIndexVector128UintDelegate(Vector128 source, uint* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128IntIndexVector128LongDelegate(Vector128 source, long* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128IntIndexVector128UlongDelegate(Vector128 source, ulong* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128IntIndexVector128FloatDelegate(Vector128 source, float* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128IntIndexVector128DoubleDelegate(Vector128 source, double* mem, Vector128 index, Vector128 mask); + + public unsafe delegate Vector128 GatherMaskVector128LongIndexVector128IntDelegate(Vector128 source, int* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128LongIndexVector128UintDelegate(Vector128 source, uint* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128LongIndexVector128LongDelegate(Vector128 source, long* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128LongIndexVector128UlongDelegate(Vector128 source, ulong* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128LongIndexVector128FloatDelegate(Vector128 source, float* mem, Vector128 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector128LongIndexVector128DoubleDelegate(Vector128 source, double* mem, Vector128 index, Vector128 mask); + + public unsafe delegate Vector256 GatherMaskVector128IntIndexVector256LongDelegate(Vector256 source, long* mem, Vector128 index, Vector256 mask); + public unsafe delegate Vector256 GatherMaskVector128IntIndexVector256UlongDelegate(Vector256 source, ulong* mem, Vector128 index, Vector256 mask); + public unsafe delegate Vector256 GatherMaskVector128IntIndexVector256DoubleDelegate(Vector256 source, double* mem, Vector128 index, Vector256 mask); + + public unsafe delegate Vector256 GatherMaskVector256IntIndexVector256IntDelegate(Vector256 source, int* mem, Vector256 index, Vector256 mask); + public unsafe delegate Vector256 GatherMaskVector256IntIndexVector256UintDelegate(Vector256 source, uint* mem, Vector256 index, Vector256 mask); + public unsafe delegate Vector256 GatherMaskVector256IntIndexVector256LongDelegate(Vector256 source, long* mem, Vector256 index, Vector256 mask); + public unsafe delegate Vector256 GatherMaskVector256IntIndexVector256UlongDelegate(Vector256 source, ulong* mem, Vector256 index, Vector256 mask); + public unsafe delegate Vector256 GatherMaskVector256IntIndexVector256FloatDelegate(Vector256 source, float* mem, Vector256 index, Vector256 mask); + public unsafe delegate Vector256 GatherMaskVector256IntIndexVector256DoubleDelegate(Vector256 source, double* mem, Vector256 index, Vector256 mask); + + public unsafe delegate Vector128 GatherMaskVector256LongIndexVector128IntDelegate(Vector128 source, int* mem, Vector256 index, Vector128 mask); + public unsafe delegate Vector128 GatherMaskVector256LongIndexVector128UintDelegate(Vector128 source, uint* mem, Vector256 index, Vector128 mask); + public unsafe delegate Vector256 GatherMaskVector256LongIndexVector256LongDelegate(Vector256 source, long* mem, Vector256 index, Vector256 mask); + public unsafe delegate Vector256 GatherMaskVector256LongIndexVector256UlongDelegate(Vector256 source, ulong* mem, Vector256 index, Vector256 mask); + public unsafe delegate Vector128 GatherMaskVector256LongIndexVector128FloatDelegate(Vector128 source, float* mem, Vector256 index, Vector128 mask); + public unsafe delegate Vector256 GatherMaskVector256LongIndexVector256DoubleDelegate(Vector256 source, double* mem, Vector256 index, Vector256 mask); + + public delegate Vector128 InsertSbyteVector128Delegate(Vector128 value, sbyte data) where T : struct; + public delegate Vector128 InsertByteVector128Delegate(Vector128 value, byte data) where T : struct; + public delegate Vector128 InsertShortVector128Delegate(Vector128 value, short data) where T : struct; + public delegate Vector128 InsertUshortVector128Delegate(Vector128 value, ushort data) where T : struct; + public delegate Vector128 InsertIntVector128Delegate(Vector128 value, int data) where T : struct; + public delegate Vector128 InsertUintVector128Delegate(Vector128 value, uint data) where T : struct; + public delegate Vector128 InsertLongVector128Delegate(Vector128 value, long data) where T : struct; + public delegate Vector128 InsertUlongVector128Delegate(Vector128 value, ulong data) where T : struct; + public delegate Vector128 InsertFloatVector128Delegate(Vector128 value, float data) where T : struct; + + public delegate Vector256 InsertSbyteVector256Delegate(Vector256 value, sbyte data) where T : struct; + public delegate Vector256 InsertByteVector256Delegate(Vector256 value, byte data) where T : struct; + public delegate Vector256 InsertShortVector256Delegate(Vector256 value, short data) where T : struct; + public delegate Vector256 InsertUshortVector256Delegate(Vector256 value, ushort data) where T : struct; + public delegate Vector256 InsertIntVector256Delegate(Vector256 value, int data) where T : struct; + public delegate Vector256 InsertUintVector256Delegate(Vector256 value, uint data) where T : struct; + public delegate Vector256 InsertLongVector256Delegate(Vector256 value, long data) where T : struct; + public delegate Vector256 InsertUlongVector256Delegate(Vector256 value, ulong data) where T : struct; + + public delegate Vector256 Insert128Vector256Delegate(Vector256 value, Vector128 data) where T : struct; + + public delegate Vector128 KeygenAssistVector128Delegate(Vector128 value) where T : struct; + + public delegate Vector128 MultipleSumAbsoluteDifferenceVector128Delegate(Vector128 left, Vector128 right); + public delegate Vector256 MultipleSumAbsoluteDifferenceVector256Delegate(Vector256 left, Vector256 right); + + public delegate Vector256 Permute2x128Delegate(Vector256 left, Vector256 right) where T : struct; + public delegate Vector256 Permute4x64Delegate(Vector256 value) where T : struct; + + public delegate Vector128 PermuteVector128Delegate(Vector128 value) where T : struct; + public delegate Vector256 PermuteVector256Delegate(Vector256 value) where T : struct; + + public delegate Vector128 ShiftVector128Delegate(Vector128 value) where T : struct; + public delegate Vector256 ShiftVector256Delegate(Vector256 value) where T : struct; + + public delegate Vector128 ShuffleVector128Delegate(Vector128 value) where T : struct; + public delegate Vector128 ShuffleTwoVector128Delegate(Vector128 left, Vector128 right) where T : struct; + public delegate Vector256 ShuffleVector256Delegate(Vector256 value) where T : struct; + public delegate Vector256 ShuffleTwoVector256Delegate(Vector256 left, Vector256 right) where T : struct; +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Enums.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Enums.cs new file mode 100644 index 00000000000..602a707cc0b --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Enums.cs @@ -0,0 +1,57 @@ +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + public enum StringComparisonMode : byte { + CompareEqualAny = 0x00, + CompareRanges = 0x04, + CompareEqualEach = 0x08, + CompareEqualOrdered = 0x0c, + NegativePolarity = 0x10, + MaskedNegativePolarity = 0x30, + LeastSignificant = 0x00, + MostSignificant = 0x40, + } + + public enum FloatComparisonMode : byte + { + CompareEqualOrderedNonSignaling, + CompareLessThanOrderedSignaling, + CompareLessThanOrEqualOrderedSignaling, + CompareUnorderedNonSignaling, + CompareNotEqualUnorderedNonSignaling, + CompareNotLessThanUnorderedSignaling, + CompareNotLessThanOrEqualUnorderedSignaling, + CompareOrderedNonSignaling, + CompareEqualUnorderedNonSignaling, + CompareNotGreaterThanOrEqualUnorderedSignaling, + CompareNotGreaterThanUnorderedSignaling, + CompareFalseOrderedNonSignaling, + CompareNotEqualOrderedNonSignaling, + CompareGreaterThanOrEqualOrderedSignaling, + CompareGreaterThanOrderedSignaling, + CompareTrueUnorderedNonSignaling, + CompareEqualOrderedSignaling, + CompareLessThanOrderedNonSignaling, + CompareLessThanOrEqualOrderedNonSignaling, + CompareUnorderedSignaling, + CompareNotEqualUnorderedSignaling, + CompareNotLessThanUnorderedNonSignaling, + CompareNotLessThanOrEqualUnorderedNonSignaling, + CompareOrderedSignaling, + CompareEqualUnorderedSignaling, + CompareNotGreaterThanOrEqualUnorderedNonSignaling, + CompareNotGreaterThanUnorderedNonSignaling, + CompareFalseOrderedSignaling, + CompareNotEqualOrderedSignaling, + CompareGreaterThanOrEqualOrderedNonSignaling, + CompareGreaterThanOrderedNonSignaling, + CompareTrueUnorderedSignaling, + } + + public enum ResultsFlag : byte { + CFlag, + NotCFlagAndNotZFlag, + OFlag, + SFlag, + ZFlag, + } +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/FMA.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/FMA.cs new file mode 100644 index 00000000000..996f5a60c05 --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/FMA.cs @@ -0,0 +1,81 @@ +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// FMA.cs +// +// A class that implements intrinsic functions to provide access to Intel FMA instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + /// + /// Provides access to Intel FMA hardware instructions via intrinsics + /// + /// + /// FMA class provides access to FMA instructions + /// + + public static class FMA + { + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + // FMA intrinsics + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + + // __m128 _mm_fmadd_ps (__m128 a, __m128 b, __m128 c) + public static Vector128 MultiplyAdd(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m128d _mm_fmadd_pd (__m128d a, __m128d b, __m128d c) + public static Vector128 MultiplyAdd(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m256 _mm256_fmadd_ps (__m256 a, __m256 b, __m256 c) + public static Vector256 MultiplyAdd(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + // __m256d _mm256_fmadd_pd (__m256d a, __m256d b, __m256d c) + public static Vector256 MultiplyAdd(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + + // __m128 _mm_fmaddsub_ps (__m128 a, __m128 b, __m128 c) + public static Vector128 MultiplyAddSubtract(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m128d _mm_fmaddsub_pd (__m128d a, __m128d b, __m128d c) + public static Vector128 MultiplyAddSubtract(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m256 _mm256_fmaddsub_ps (__m256 a, __m256 b, __m256 c) + public static Vector256 MultiplyAddSubtract(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + // __m256d _mm256_fmaddsub_pd (__m256d a, __m256d b, __m256d c) + public static Vector256 MultiplyAddSubtract(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + + // __m128 _mm_fmsub_ps (__m128 a, __m128 b, __m128 c) + public static Vector128 MultiplySubtract(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m128d _mm_fmsub_pd (__m128d a, __m128d b, __m128d c) + public static Vector128 MultiplySubtract(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m256 _mm256_fmsub_ps (__m256 a, __m256 b, __m256 c) + public static Vector256 MultiplySubtract(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + // __m256d _mm256_fmsub_pd (__m256d a, __m256d b, __m256d c) + public static Vector256 MultiplySubtract(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + + // __m128 _mm_fmsubadd_ps (__m128 a, __m128 b, __m128 c) + public static Vector128 MultiplySubtractAdd(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m128d _mm_fmsubadd_pd (__m128d a, __m128d b, __m128d c) + public static Vector128 MultiplySubtractAdd(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m256 _mm256_fmsubadd_ps (__m256 a, __m256 b, __m256 c) + public static Vector256 MultiplySubtractAdd(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + // __m256d _mm256_fmsubadd_pd (__m256d a, __m256d b, __m256d c) + public static Vector256 MultiplySubtractAdd(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + + // __m128 _mm_fnmadd_ps (__m128 a, __m128 b, __m128 c) + public static Vector128 MultiplyAddNegated(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m128d _mm_fnmadd_pd (__m128d a, __m128d b, __m128d c) + public static Vector128 MultiplyAddNegated(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m256 _mm256_fnmadd_ps (__m256 a, __m256 b, __m256 c) + public static Vector256 MultiplyAddNegated(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + // __m256d _mm256_fnmadd_pd (__m256d a, __m256d b, __m256d c) + public static Vector256 MultiplyAddNegated(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + + // __m128 _mm_fnmsub_ps (__m128 a, __m128 b, __m128 c) + public static Vector128 MultiplySubtractNegated(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m128d _mm_fnmsub_pd (__m128d a, __m128d b, __m128d c) + public static Vector128 MultiplySubtractNegated(Vector128 a, Vector128 b, Vector128 c) { throw new NotImplementedException(); } + // __m256 _mm256_fnmsub_ps (__m256 a, __m256 b, __m256 c) + public static Vector256 MultiplySubtractNegated(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + // __m256d _mm256_fnmsub_pd (__m256d a, __m256d b, __m256d c) + public static Vector256 MultiplySubtractNegated(Vector256 a, Vector256 b, Vector256 c) { throw new NotImplementedException(); } + } +} diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Other.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Other.cs new file mode 100644 index 00000000000..eebfefd777f --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/Other.cs @@ -0,0 +1,171 @@ + +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// Other.cs +// +// A class that implements intrinsic functions to provide access to other Intel instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + public static class LZCNT + { + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + // LZCNT intrinsics + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + + // unsigned int _lzcnt_u32 (unsigned int a) + public static uint LeadingZeroCount(uint value) { throw new NotImplementedException(); } + // unsigned __int64 _lzcnt_u64 (unsigned __int64 a) + public static ulong LeadingZeroCount(ulong value) { throw new NotImplementedException(); } + } + + public static class POPCNT + { + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + // POPCNT intrinsics + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + + // int _mm_popcnt_u32 (unsigned int a) + public static int PopCount(uint value) { throw new NotImplementedException(); } + // __int64 _mm_popcnt_u64 (unsigned __int64 a) + public static long PopCount(ulong value) { throw new NotImplementedException(); } + } + + public static class BMI1 + { + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + // BMI1 intrinsics + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + + // unsigned int _andn_u32 (unsigned int a, unsigned int b) + public static uint AndNot(uint left, uint right) { throw new NotImplementedException(); } + // unsigned __int64 _andn_u64 (unsigned __int64 a, unsigned __int64 b) + public static ulong AndNot(ulong left, ulong right) { throw new NotImplementedException(); } + + // unsigned int _bextr_u32 (unsigned int a, unsigned int start, unsigned int len) + public static uint BitFieldExtract(uint value, uint start, uint length) { throw new NotImplementedException(); } + // unsigned __int64 _bextr_u64 (unsigned __int64 a, unsigned int start, unsigned int len) + public static ulong BitFieldExtract(ulong value, ulong start, ulong length) { throw new NotImplementedException(); } + // unsigned int _bextr2_u32 (unsigned int a, unsigned int control) + public static uint BitFieldExtract(uint value, uint control) { throw new NotImplementedException(); } + // unsigned __int64 _bextr2_u64 (unsigned __int64 a, unsigned __int64 control) + public static ulong BitFieldExtract(ulong value, ulong control) { throw new NotImplementedException(); } + + // unsigned int _blsi_u32 (unsigned int a) + public static uint ExtractLowestSetBit(uint value) { throw new NotImplementedException(); } + // unsigned __int64 _blsi_u64 (unsigned __int64 a) + public static ulong ExtractLowestSetBit(ulong value) { throw new NotImplementedException(); } + + // unsigned int _blsmsk_u32 (unsigned int a) + public static uint GetMaskUptoLowestSetBit(uint value) { throw new NotImplementedException(); } + // unsigned __int64 _blsmsk_u64 (unsigned __int64 a) + public static ulong GetMaskUptoLowestSetBit(ulong value) { throw new NotImplementedException(); } + + // unsigned int _blsr_u32 (unsigned int a) + public static uint ResetLowestSetBit(uint value) { throw new NotImplementedException(); } + // unsigned __int64 _blsr_u64 (unsigned __int64 a) + public static ulong ResetLowestSetBit(ulong value) { throw new NotImplementedException(); } + + // int _mm_tzcnt_32 (unsigned int a) + public static uint TrailingZeroCount(uint value) { throw new NotImplementedException(); } + // __int64 _mm_tzcnt_64 (unsigned __int64 a) + public static ulong TrailingZeroCount(ulong value) { throw new NotImplementedException(); } + } + + public static class BMI2 + { + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + // BMI2 intrinsics + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + + // unsigned int _bzhi_u32 (unsigned int a, unsigned int index) + public static uint ZeroHighBits(uint value, uint index) { throw new NotImplementedException(); } + // unsigned __int64 _bzhi_u64 (unsigned __int64 a, unsigned int index) + public static ulong ZeroHighBits(ulong value, ulong index) { throw new NotImplementedException(); } + + // unsigned int _mulx_u32 (unsigned int a, unsigned int b, unsigned int* hi) + public static unsafe uint MultiplyNoFlags(uint left, uint right, uint* high) { throw new NotImplementedException(); } + // unsigned __int64 _mulx_u64 (unsigned __int64 a, unsigned __int64 b, unsigned __int64* hi) + public static unsafe ulong MultiplyNoFlags(ulong left, ulong right, ulong* high) { throw new NotImplementedException(); } + + // unsigned int _pdep_u32 (unsigned int a, unsigned int mask) + public static uint ParallelBitDeposit(uint value, uint mask) { throw new NotImplementedException(); } + // unsigned __int64 _pdep_u64 (unsigned __int64 a, unsigned __int64 mask) + public static ulong ParallelBitDeposit(ulong value, ulong mask) { throw new NotImplementedException(); } + + // unsigned int _pext_u32 (unsigned int a, unsigned int mask) + public static uint ParallelBitExtract(uint value, uint mask) { throw new NotImplementedException(); } + // unsigned __int64 _pext_u64 (unsigned __int64 a, unsigned __int64 mask) + public static ulong ParallelBitExtract(ulong value, ulong mask) { throw new NotImplementedException(); } + } + + public static class PCLMULQDQ + { + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + // PCLMULQDQ intrinsics + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + + // __m128i _mm_clmulepi64_si128 (__m128i a, __m128i b, const int imm8) + private static Vector128 CarryLessMultiply(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static CarryLessMultiplyVector128Delegate GetCarryLessMultiplyVector128Long(byte control) + { + return (left, right) => CarryLessMultiply(left, right, control); + } + // __m128i _mm_clmulepi64_si128 (__m128i a, __m128i b, const int imm8) + private static Vector128 CarryLessMultiply(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static CarryLessMultiplyVector128Delegate GetCarryLessMultiplyVector128Ulong(byte control) + { + return (left, right) => CarryLessMultiply(left, right, control); + } + } + + public static class AES + { + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + // AES intrinsics + // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + + // __m128i _mm_aesdec_si128 (__m128i a, __m128i RoundKey) + public static Vector128 Decrypt(Vector128 value, Vector128 roundKey) { throw new NotImplementedException(); } + // __m128i _mm_aesdec_si128 (__m128i a, __m128i RoundKey) + public static Vector128 Decrypt(Vector128 value, Vector128 roundKey) { throw new NotImplementedException(); } + + // __m128i _mm_aesdeclast_si128 (__m128i a, __m128i RoundKey) + public static Vector128 DecryptLast(Vector128 value, Vector128 roundKey) { throw new NotImplementedException(); } + // __m128i _mm_aesdeclast_si128 (__m128i a, __m128i RoundKey) + public static Vector128 DecryptLast(Vector128 value, Vector128 roundKey) { throw new NotImplementedException(); } + + // __m128i _mm_aesenc_si128 (__m128i a, __m128i RoundKey) + public static Vector128 Encrypt(Vector128 value, Vector128 roundKey) { throw new NotImplementedException(); } + // __m128i _mm_aesenc_si128 (__m128i a, __m128i RoundKey) + public static Vector128 Encrypt(Vector128 value, Vector128 roundKey) { throw new NotImplementedException(); } + + // __m128i _mm_aesenclast_si128 (__m128i a, __m128i RoundKey) + public static Vector128 EncryptLast(Vector128 value, Vector128 roundKey) { throw new NotImplementedException(); } + // __m128i _mm_aesenclast_si128 (__m128i a, __m128i RoundKey) + public static Vector128 EncryptLast(Vector128 value, Vector128 roundKey) { throw new NotImplementedException(); } + + // __m128i _mm_aesimc_si128 (__m128i a) + public static Vector128 InvisibleMixColumn(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_aesimc_si128 (__m128i a) + public static Vector128 InvisibleMixColumn(Vector128 value) { throw new NotImplementedException(); } + + // __m128i _mm_aeskeygenassist_si128 (__m128i a, const int imm8) + private static Vector128 KeygenAssist(Vector128 value, byte control) { throw new NotImplementedException(); } + public static KeygenAssistVector128Delegate GetKeyGenAssistVector128Byte(byte control) + { + return (value) => KeygenAssist(value, control); + } + // __m128i _mm_aeskeygenassist_si128 (__m128i a, const int imm8) + private static Vector128 KeygenAssist(Vector128 value, byte control) { throw new NotImplementedException(); } + public static KeygenAssistVector128Delegate GetKeyGenAssistVector128Sbyte(byte control) + { + return (value) => KeygenAssist(value, control); + } + } +} diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE2.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE2.cs new file mode 100644 index 00000000000..ef3656e403a --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE2.cs @@ -0,0 +1,699 @@ +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// SSE2.cs +// +// A class that implements intrinsic functions to provide access to Intel SSE/SSE2 instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.CompilerServices.Intrinsics; +using System.Runtime.CompilerServices.Intrinsics.Intel; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + /// + /// Provides access to Intel SSE2 hardware instructions via intrinsics + /// + /// + /// SSE2 class provides access to 128-bit SSE/SSE2 SIMD instructions + /// + + public static class SSE2 + { + // __m128i _mm_add_epi8 (__m128i a, __m128i b) + // __m128i _mm_add_epi16 (__m128i a, __m128i b) + // __m128i _mm_add_epi32 (__m128i a, __m128i b) + // __m128i _mm_add_epi64 (__m128i a, __m128i b) + // __m128 _mm_add_ps (__m128 a, __m128 b) + // __m128d _mm_add_pd (__m128d a, __m128d b) + public static Vector128 Add(Vector128 left, Vector128 right) where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_adds_epi8 (__m128i a, __m128i b) + public static Vector128 AddSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_adds_epu8 (__m128i a, __m128i b) + public static Vector128 AddSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_adds_epi16 (__m128i a, __m128i b) + public static Vector128 AddSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_adds_epu16 (__m128i a, __m128i b) + public static Vector128 AddSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_and_si128 (__m128i a, __m128i b) + public static Vector128 And(Vector128 left, Vector128 right) where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_andnot_si128 (__m128i a, __m128i b) + public static Vector128 AndNot(Vector128 left, Vector128 right) where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_avg_epu8 (__m128i a, __m128i b) + public static Vector128 Average(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_avg_epu16 (__m128i a, __m128i b) + public static Vector128 Average(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_cmpeq_epi8 (__m128i a, __m128i b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmpeq_epi8 (__m128i a, __m128i b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmpeq_epi16 (__m128i a, __m128i b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmpeq_epi16 (__m128i a, __m128i b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmpeq_epi32 (__m128i a, __m128i b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmpeq_epi32 (__m128i a, __m128i b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128 _mm_cmpeq_ps (__m128 a, __m128 b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpeq_pd (__m128d a, __m128d b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_cmpgt_epi8 (__m128i a, __m128i b) + public static Vector128 CompareGreaterThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmpgt_epi16 (__m128i a, __m128i b) + public static Vector128 CompareGreaterThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmpgt_epi32 (__m128i a, __m128i b) + public static Vector128 CompareGreaterThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128 _mm_cmpgt_ps (__m128 a, __m128 b) + public static Vector128 CompareGreaterThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpgt_pd (__m128d a, __m128d b) + public static Vector128 CompareGreaterThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmpge_ps (__m128 a, __m128 b) + public static Vector128 CompareGreaterThanOrEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpge_pd (__m128d a, __m128d b) + public static Vector128 CompareGreaterThanOrEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_cmplt_epi8 (__m128i a, __m128i b) + public static Vector128 CompareLessThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmplt_epi16 (__m128i a, __m128i b) + public static Vector128 CompareLessThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmplt_epi32 (__m128i a, __m128i b) + public static Vector128 CompareLessThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128 _mm_cmplt_ps (__m128 a, __m128 b) + public static Vector128 CompareLessThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmplt_pd (__m128d a, __m128d b) + public static Vector128 CompareLessThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmple_ps (__m128 a, __m128 b) + public static Vector128 CompareLessThanOrEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmple_pd (__m128d a, __m128d b) + public static Vector128 CompareLessThanOrEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmpneq_ps (__m128 a, __m128 b) + public static Vector128 CompareNotEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpneq_pd (__m128d a, __m128d b) + public static Vector128 CompareNotEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmpngt_ps (__m128 a, __m128 b) + public static Vector128 CompareNotGreaterThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpngt_pd (__m128d a, __m128d b) + public static Vector128 CompareNotGreaterThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmpnge_ps (__m128 a, __m128 b) + public static Vector128 CompareNotGreaterThanOrEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpnge_pd (__m128d a, __m128d b) + public static Vector128 CompareNotGreaterThanOrEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmpnlt_ps (__m128 a, __m128 b) + public static Vector128 CompareNotLessThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpnlt_pd (__m128d a, __m128d b) + public static Vector128 CompareNotLessThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmpnle_ps (__m128 a, __m128 b) + public static Vector128 CompareNotLessThanOrEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpnle_pd (__m128d a, __m128d b) + public static Vector128 CompareNotLessThanOrEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmpord_ps (__m128 a, __m128 b) + public static Vector128 CompareOrdered(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpord_pd (__m128d a, __m128d b) + public static Vector128 CompareOrdered(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_cmpunord_ps (__m128 a, __m128 b) + public static Vector128 CompareUnordered(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_cmpunord_pd (__m128d a, __m128d b) + public static Vector128 CompareUnordered(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_cvtps_epi32 (__m128 a) + public static Vector128 ConvertToInt(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtpd_epi32 (__m128d a) + public static Vector128 ConvertToInt(Vector128 value) { throw new NotImplementedException(); } + // __m128 _mm_cvtepi32_ps (__m128i a) + public static Vector128 ConvertToFloat(Vector128 value) { throw new NotImplementedException(); } + // __m128 _mm_cvtpd_ps (__m128d a) + public static Vector128 ConvertToFloat(Vector128 value) { throw new NotImplementedException(); } + // __m128d _mm_cvtepi32_pd (__m128i a) + public static Vector128 ConvertToDouble(Vector128 value) { throw new NotImplementedException(); } + // __m128d _mm_cvtps_pd (__m128 a) + public static Vector128 ConvertToDouble(Vector128 value) { throw new NotImplementedException(); } + + // __m128i _mm_cvttps_epi32 (__m128 a) + public static Vector128 ConvertToIntWithTruncation(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvttpd_epi32 (__m128d a) + public static Vector128 ConvertToIntWithTruncation(Vector128 value) { throw new NotImplementedException(); } + + // __m128 _mm_div_ps (__m128 a, __m128 b) + public static Vector128 Divide(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_div_pd (__m128d a, __m128d b) + public static Vector128 Divide(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // int _mm_extract_epi16 (__m128i a, int immediate) + private static short ExtractShort(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractShortVector128Delegate GetExtractVector128Short(byte index) where T : struct + { + return (value) => ExtractShort(value, index); + } + // int _mm_extract_epi16 (__m128i a, int immediate) + private static ushort ExtractUshort(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractUShortVector128Delegate GetExtractVector128Ushort(byte index) where T : struct + { + return (value) => ExtractUshort(value, index); + } + + // __m128i _mm_insert_epi16 (__m128i a, int i, int immediate) + private static Vector128 InsertShort(Vector128 value, short data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertShortVector128Delegate GetInsertVector128Short(byte index) where T : struct + { + return (value, data) => InsertShort(value, data, index); + } + // __m128i _mm_insert_epi16 (__m128i a, int i, int immediate) + private static Vector128 InsertUshort(Vector128 value, ushort data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertUshortVector128Delegate GetInsertVector128Ushort(byte index) where T : struct + { + return (value, data) => InsertUshort(value, data, index); + } + + // __m128i _mm_loadu_si128 (__m128i const* mem_address) + public static unsafe Vector128 Load(sbyte* mem) { throw new NotImplementedException(); } + // __m128i _mm_loadu_si128 (__m128i const* mem_address) + public static unsafe Vector128 Load(byte* mem) { throw new NotImplementedException(); } + // __m128i _mm_loadu_si128 (__m128i const* mem_address) + public static unsafe Vector128 Load(short* mem) { throw new NotImplementedException(); } + // __m128i _mm_loadu_si128 (__m128i const* mem_address) + public static unsafe Vector128 Load(ushort* mem) { throw new NotImplementedException(); } + // __m128i _mm_loadu_si128 (__m128i const* mem_address) + public static unsafe Vector128 Load(int* mem) { throw new NotImplementedException(); } + // __m128i _mm_loadu_si128 (__m128i const* mem_address) + public static unsafe Vector128 Load(uint* mem) { throw new NotImplementedException(); } + // __m128i _mm_loadu_si128 (__m128i const* mem_address) + public static unsafe Vector128 Load(long* mem) { throw new NotImplementedException(); } + // __m128i _mm_loadu_si128 (__m128i const* mem_address) + public static unsafe Vector128 Load(ulong* mem) { throw new NotImplementedException(); } + // __m128 _mm_loadu_ps (float const* mem_address) + public static unsafe Vector128 Load(float* mem) { throw new NotImplementedException(); } + // __m128d _mm_loadu_pd (double const* mem_address) + public static unsafe Vector128 Load(double* mem) { throw new NotImplementedException(); } + + // __m128i _mm_load_si128 (__m128i const* mem_address) + public static unsafe Vector128 LoadAligned(sbyte* mem) { throw new NotImplementedException(); } + // __m128i _mm_load_si128 (__m128i const* mem_address) + public static unsafe Vector128 LoadAligned(byte* mem) { throw new NotImplementedException(); } + // __m128i _mm_load_si128 (__m128i const* mem_address) + public static unsafe Vector128 LoadAligned(short* mem) { throw new NotImplementedException(); } + // __m128i _mm_load_si128 (__m128i const* mem_address) + public static unsafe Vector128 LoadAligned(ushort* mem) { throw new NotImplementedException(); } + // __m128i _mm_load_si128 (__m128i const* mem_address) + public static unsafe Vector128 LoadAligned(int* mem) { throw new NotImplementedException(); } + // __m128i _mm_load_si128 (__m128i const* mem_address) + public static unsafe Vector128 LoadAligned(uint* mem) { throw new NotImplementedException(); } + // __m128i _mm_load_si128 (__m128i const* mem_address) + public static unsafe Vector128 LoadAligned(long* mem) { throw new NotImplementedException(); } + // __m128i _mm_load_si128 (__m128i const* mem_address) + public static unsafe Vector128 LoadAligned(ulong* mem) { throw new NotImplementedException(); } + // __m128 _mm_load_ps (float const* mem_address) + public static unsafe Vector128 LoadAligned(float* mem) { throw new NotImplementedException(); } + // __m128d _mm_load_pd (double const* mem_address) + public static unsafe Vector128 LoadAligned(double* mem) { throw new NotImplementedException(); } + + // void _mm_maskmoveu_si128 (__m128i a, __m128i mask, char* mem_address) + public static unsafe void MaskMoveAlignedOrUnaligned(Vector128 source, Vector128 mask, sbyte* mem) { throw new NotImplementedException(); } + public static unsafe void MaskMoveAlignedOrUnaligned(Vector128 source, Vector128 mask, byte* mem) { throw new NotImplementedException(); } + + // __m128i _mm_max_epu8 (__m128i a, __m128i b) + public static Vector128 Max(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_max_epi16 (__m128i a, __m128i b) + public static Vector128 Max(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128 _mm_max_ps (__m128 a, __m128 b) + public static Vector128 Max(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_max_pd (__m128d a, __m128d b) + public static Vector128 Max(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_min_epu8 (__m128i a, __m128i b) + public static Vector128 Min(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_min_epi16 (__m128i a, __m128i b) + public static Vector128 Min(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128 _mm_min_ps (__m128 a, __m128 b) + public static Vector128 Min(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_min_pd (__m128d a, __m128d b) + public static Vector128 Min(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_movehl_ps (__m128 a, __m128 b) + public static Vector128 MoveHighToLow(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128 _mm_movelh_ps (__m128 a, __m128 b) + public static Vector128 MoveLowToHigh(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // int _mm_movemask_epi8 (__m128i a) + public static int MoveMask(Vector128 value) { throw new NotImplementedException(); } + // int _mm_movemask_pd (__m128d a) + public static int MoveMask(Vector128 value) { throw new NotImplementedException(); } + + // __m128i _mm_mul_epu32 (__m128i a, __m128i b) + public static Vector128 Multiply(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128 _mm_mul_ps (__m128 a, __m128 b) + public static Vector128 Multiply(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_mul_pd (__m128d a, __m128d b) + public static Vector128 Multiply(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_mulhi_epi16 (__m128i a, __m128i b) + public static Vector128 MultiplyHi(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_mulhi_epu16 (__m128i a, __m128i b) + public static Vector128 MultiplyHi(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_madd_epi16 (__m128i a, __m128i b) + public static Vector128 MultiplyHorizontalAdd(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_mullo_epi16 (__m128i a, __m128i b) + public static Vector128 MultiplyLow(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_or_si128 (__m128i a, __m128i b) + // __m128 _mm_or_ps (__m128 a, __m128 b) + // __m128d _mm_or_pd (__m128d a, __m128d b) + public static Vector128 Or(Vector128 left, Vector128 right) where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_packs_epi16 (__m128i a, __m128i b) + public static Vector128 PackSignedSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_packs_epi32 (__m128i a, __m128i b) + public static Vector128 PackSignedSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_packus_epi16 (__m128i a, __m128i b) + public static Vector128 PackUnsignedSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_rcp_ps (__m128 a) + public static Vector128 Reciprocal(Vector128 value) { throw new NotImplementedException(); } + + // __m128 _mm_rsqrt_ps (__m128 a) + public static Vector128 ReciprocalSquareRoot(Vector128 value) { throw new NotImplementedException(); } + + // ___m128i _mm_set_epi8 (char e15, char e14, char e13, char e12, char e11, char e10, char e9, char e8, char e7, char e6, char e5, char e4, char e3, char e2, char e1, char e0) + public static Vector128 Set(sbyte e15, sbyte e14, sbyte e13, sbyte e12, sbyte e11, sbyte e10, sbyte e9, sbyte e8, sbyte e7, sbyte e6, sbyte e5, sbyte e4, sbyte e3, sbyte e2, sbyte e1, sbyte e0) + { + throw new NotImplementedException(); + } + // ___m128i _mm_set_epi8 (char e15, char e14, char e13, char e12, char e11, char e10, char e9, char e8, char e7, char e6, char e5, char e4, char e3, char e2, char e1, char e0) + public static Vector128 Set(byte e15, byte e14, byte e13, byte e12, byte e11, byte e10, byte e9, byte e8, byte e7, byte e6, byte e5, byte e4, byte e3, byte e2, byte e1, byte e0) + { + throw new NotImplementedException(); + } + // __m128i _mm_set_epi16 (short e7, short e6, short e5, short e4, short e3, short e2, short e1, short e0) + public static Vector128 Set(short e7, short e6, short e5, short e4, short e3, short e2, short e1, short e0) + { + throw new NotImplementedException(); + } + // __m128i _mm_set_epi16 (short e7, short e6, short e5, short e4, short e3, short e2, short e1, short e0) + public static Vector128 Set(ushort e7, ushort e6, ushort e5, ushort e4, ushort e3, ushort e2, ushort e1, ushort e0) + { + throw new NotImplementedException(); + } + // __m128i _mm_set_epi32 (int e3, int e2, int e1, int e0) + public static Vector128 Set(int e3, int e2, int e1, int e0) { throw new NotImplementedException(); } + // __m128i _mm_set_epi32 (int e3, int e2, int e1, int e0) + public static Vector128 Set(uint e3, uint e2, uint e1, uint e0) { throw new NotImplementedException(); } + // __m128i _mm_set_epi64x (__int64 e1, __int64 e0) + public static Vector128 Set(long e1, long e0) { throw new NotImplementedException(); } + // __m128i _mm_set_epi64x (__int64 e1, __int64 e0) + public static Vector128 Set(ulong e1, ulong e0) { throw new NotImplementedException(); } + // __m256 _mm256_set_ps (float e7, float e6, float e5, float e4, float e3, float e2, float e1, float e0) + public static Vector128 Set(float e7, float e6, float e5, float e4, float e3, float e2, float e1, float e0) + { + throw new NotImplementedException(); + } + // __m128d _mm_set_pd (double e1, double e0) + public static Vector128 Set(double e1, double e0) { throw new NotImplementedException(); } + + // __m128i _mm_set1_epi8 (char a) + // __m128i _mm_set1_epi16 (short a) + // __m128i _mm_set1_epi32 (int a) + // __m128i _mm_set1_epi64x (long long a) + // __m128 _mm_set1_ps (float a) + // __m128d _mm_set1_pd (double a) + public static Vector128 Set1(T value) where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_setzero_si128 () + // __m128d _mm_setzero_pd (void) + public static Vector128 SetZero() where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_sad_epu8 (__m128i a, __m128i b) + public static Vector128 SumAbsoluteDifference(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_shuffle_epi32 (__m128i a, int immediate) + private static Vector128 Shuffle(Vector128 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector128Delegate GetShuffleVector128Int(byte control) + { + return (value) => Shuffle(value, control); + } + // __m128i _mm_shuffle_epi32 (__m128i a, int immediate) + private static Vector128 Shuffle(Vector128 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector128Delegate GetShuffleVector128Uint(byte control) + { + return (value) => Shuffle(value, control); + } + // __m128 _mm_shuffle_ps (__m128 a, __m128 b, unsigned int control) + private static Vector128 Shuffle(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static ShuffleTwoVector128Delegate GetShuffleVector128Float(byte control) + { + return (left, right) => Shuffle(left, right, control); + } + // __m128d _mm_shuffle_pd (__m128d a, __m128d b, int immediate) + private static Vector128 Shuffle(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static ShuffleTwoVector128Delegate GetShuffleVector128Double(byte control) + { + return (left, right) => Shuffle(left, right, control); + } + + // __m128i _mm_shufflehi_epi16 (__m128i a, int immediate) + private static Vector128 ShuffleHigh(Vector128 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector128Delegate GetShuffleHighVector128Short(byte control) + { + return (value) => ShuffleHigh(value, control); + } + // __m128i _mm_shufflehi_epi16 (__m128i a, int control) + private static Vector128 ShuffleHigh(Vector128 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector128Delegate GetShuffleHighVector128Ushort(byte control) + { + return (value) => ShuffleHigh(value, control); + } + + // __m128i _mm_shufflelo_epi16 (__m128i a, int control) + private static Vector128 ShuffleLow(Vector128 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector128Delegate GetShuffleLowVector128Short(byte control) + { + return (value) => ShuffleLow(value, control); + } + // __m128i _mm_shufflelo_epi16 (__m128i a, int control) + private static Vector128 ShuffleLow(Vector128 value, byte control) { throw new NotImplementedException(); } + public static ShuffleVector128Delegate GetShuffleLowVector128Ushort(byte control) + { + return (value) => ShuffleLow(value, control); + } + + // __m128i _mm_slli_epi16 (__m128i a, int immediate) + private static Vector128 ShiftLeftLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogicalVector128Short(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m128i _mm_slli_epi16 (__m128i a, int immediate) + private static Vector128 ShiftLeftLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogicalVector128Ushort(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m128i _mm_slli_epi32 (__m128i a, int immediate) + private static Vector128 ShiftLeftLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogicalVector128Int(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m128i _mm_slli_epi32 (__m128i a, int immediate) + private static Vector128 ShiftLeftLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogicalVector128Uint(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m128i _mm_slli_epi64 (__m128i a, int immediate) + private static Vector128 ShiftLeftLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogicalVector128Long(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + // __m128i _mm_slli_epi64 (__m128i a, int immediate) + private static Vector128 ShiftLeftLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogicalVector128Ulong(byte count) + { + return (value) => ShiftLeftLogical(value, count); + } + + // __m128i _mm_bslli_si128 (__m128i a, int imm8) + private static Vector128 ShiftLeftLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogical128BitLaneVector128Sbyte(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m128i _mm_bslli_si128 (__m128i a, int imm8) + private static Vector128 ShiftLeftLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogical128BitLaneVector128Byte(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m128i _mm_bslli_si128 (__m128i a, int imm8) + private static Vector128 ShiftLeftLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogical128BitLaneVector128Short(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m128i _mm_bslli_si128 (__m128i a, int imm8) + private static Vector128 ShiftLeftLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogical128BitLaneVector128Ushort(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m128i _mm_bslli_si128 (__m128i a, int imm8) + private static Vector128 ShiftLeftLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogical128BitLaneVector128Int(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m128i _mm_bslli_si128 (__m128i a, int imm8) + private static Vector128 ShiftLeftLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogical128BitLaneVector128Uint(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m128i _mm_bslli_si128 (__m128i a, int imm8) + private static Vector128 ShiftLeftLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogical128BitLaneVector128Long(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + // __m128i _mm_bslli_si128 (__m128i a, int imm8) + private static Vector128 ShiftLeftLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftLeftLogical128BitLaneVector128Ulong(byte numBytes) + { + return (value) => ShiftLeftLogical128BitLane(value, numBytes); + } + + // __m128i _mm_srai_epi16 (__m128i a, int immediate) + private static Vector128 ShiftRightArithmetic(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightArithmeticVector128Short(byte count) + { + return (value) => ShiftRightArithmetic(value, count); + } + // __m128i _mm_srai_epi32 (__m128i a, int immediate) + private static Vector128 ShiftRightArithmetic(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightArithmeticVector128Int(byte count) + { + return (value) => ShiftRightArithmetic(value, count); + } + + // __m128i _mm_srli_epi16 (__m128i a, int immediate) + private static Vector128 ShiftRightLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogicalVector128Short(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m128i _mm_srli_epi16 (__m128i a, int immediate) + private static Vector128 ShiftRightLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogicalVector128Ushort(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m128i _mm_srli_epi32 (__m128i a, int immediate) + private static Vector128 ShiftRightLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogicalVector128Int(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m128i _mm_srli_epi32 (__m128i a, int immediate) + private static Vector128 ShiftRightLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogicalVector128Uint(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m128i _mm_srli_epi64 (__m128i a, int immediate) + private static Vector128 ShiftRightLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogicalVector128Long(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + // __m128i _mm_srli_epi64 (__m128i a, int immediate) + private static Vector128 ShiftRightLogical(Vector128 value, byte count) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogicalVector128Ulong(byte count) + { + return (value) => ShiftRightLogical(value, count); + } + + // __m128i _mm_bsrli_si128 (__m128i a, int imm8) + private static Vector128 ShiftRightLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogical128BitLaneVector128Sbyte(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m128i _mm_bsrli_si128 (__m128i a, int imm8) + private static Vector128 ShiftRightLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogical128BitLaneVector128Byte(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m128i _mm_bsrli_si128 (__m128i a, int imm8) + private static Vector128 ShiftRightLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogical128BitLaneVector128Short(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m128i _mm_bsrli_si128 (__m128i a, int imm8) + private static Vector128 ShiftRightLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogical128BitLaneVector128Ushort(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m128i _mm_bsrli_si128 (__m128i a, int imm8) + private static Vector128 ShiftRightLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogical128BitLaneVector128Int(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m128i _mm_bsrli_si128 (__m128i a, int imm8) + private static Vector128 ShiftRightLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogical128BitLaneVector128Uint(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m128i _mm_bsrli_si128 (__m128i a, int imm8) + private static Vector128 ShiftRightLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogical128BitLaneVector128Long(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + // __m128i _mm_bsrli_si128 (__m128i a, int imm8) + private static Vector128 ShiftRightLogical128BitLane(Vector128 value, byte numBytes) { throw new NotImplementedException(); } + public static ShiftVector128Delegate GetShiftRightLogical128BitLaneVector128Ulong(byte numBytes) + { + return (value) => ShiftRightLogical128BitLane(value, numBytes); + } + + // __m128 _mm_sqrt_ps (__m128 a) + public static Vector128 Sqrt(Vector128 value) { throw new NotImplementedException(); } + // __m128d _mm_sqrt_pd (__m128d a) + public static Vector128 Sqrt(Vector128 value) { throw new NotImplementedException(); } + + // void _mm_store_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAligned(sbyte* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAligned(byte* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAligned(short* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAligned(ushort* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAligned(int* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAligned(uint* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAligned(long* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAligned(ulong* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_ps (float* mem_addr, __m128 a) + public static unsafe void StoreAligned(float* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_store_pd (double* mem_addr, __m128d a) + public static unsafe void StoreAligned(double* mem, Vector128 source) { throw new NotImplementedException(); } + + // void _mm_stream_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAlignedNonTemporal(sbyte* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAlignedNonTemporal(byte* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAlignedNonTemporal(short* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAlignedNonTemporal(ushort* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAlignedNonTemporal(int* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAlignedNonTemporal(uint* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAlignedNonTemporal(long* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreAlignedNonTemporal(ulong* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_ps (float* mem_addr, __m128 a) + public static unsafe void StoreAlignedNonTemporal(float* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_stream_pd (double* mem_addr, __m128d a) + public static unsafe void StoreAlignedNonTemporal(double* mem, Vector128 source) { throw new NotImplementedException(); } + + // void _mm_storeu_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void Store(sbyte* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void Store(byte* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void Store(short* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void Store(ushort* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void Store(int* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void Store(uint* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void Store(long* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_si128 (__m128i* mem_addr, __m128i a) + public static unsafe void Store(ulong* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_ps (float* mem_addr, __m128 a) + public static unsafe void Store(float* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storeu_pd (double* mem_addr, __m128d a) + public static unsafe void Store(double* mem, Vector128 source) { throw new NotImplementedException(); } + + // void _mm_storeh_pd (double* mem_addr, __m128d a) + public static unsafe void StoreHigh(double* mem, Vector128 source) { throw new NotImplementedException(); } + + // void _mm_storel_epi64 (__m128i* mem_addr, __m128i a) + public static unsafe void StoreLow(long* mem, Vector128 source) { throw new NotImplementedException(); } + public static unsafe void StoreLow(ulong* mem, Vector128 source) { throw new NotImplementedException(); } + // void _mm_storel_pd (double* mem_addr, __m128d a) + public static unsafe void StoreLow(double* mem, Vector128 source) { throw new NotImplementedException(); } + + // __m128i _mm_sub_epi8 (__m128i a, __m128i b) + // __m128i _mm_sub_epi16 (__m128i a, __m128i b) + // __m128i _mm_sub_epi16 (__m128i a, __m128i b) + // __m128i _mm_sub_epi32 (__m128i a, __m128i b) + // __m128i _mm_sub_epi32 (__m128i a, __m128i b) + // __m128i _mm_sub_epi64 (__m128i a, __m128i b) + // __m128i _mm_sub_epi64 (__m128i a, __m128i b) + public static Vector128 Subtract(Vector128 left, Vector128 right) where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_subs_epi8 (__m128i a, __m128i b) + public static Vector128 SubtractSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_subs_epi16 (__m128i a, __m128i b) + public static Vector128 SubtractSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_subs_epu8 (__m128i a, __m128i b) + public static Vector128 SubtractSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_subs_epu16 (__m128i a, __m128i b) + public static Vector128 SubtractSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_unpackhi_epi8 (__m128i a, __m128i b) + // __m128i _mm_unpackhi_epi16 (__m128i a, __m128i b) + // __m128i _mm_unpackhi_epi32 (__m128i a, __m128i b) + // __m128i _mm_unpackhi_epi64 (__m128i a, __m128i b) + // __m128 _mm_unpackhi_ps (__m128 a, __m128 b) + // __m128d _mm_unpackhi_pd (__m128d a, __m128d b) + public static Vector128 UnpackHigh(Vector128 left, Vector128 right) where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_unpacklo_epi8 (__m128i a, __m128i b) + // __m128i _mm_unpacklo_epi16 (__m128i a, __m128i b) + // __m128i _mm_unpacklo_epi32 (__m128i a, __m128i b) + // __m128i _mm_unpacklo_epi64 (__m128i a, __m128i b) + // __m128 _mm_unpacklo_ps (__m128 a, __m128 b) + // __m128d _mm_unpacklo_pd (__m128d a, __m128d b) + public static Vector128 UnpackLow(Vector128 left, Vector128 right) where T : struct { throw new NotImplementedException(); } + + // __m128i _mm_xor_si128 (__m128i a, __m128i b) + // __m128 _mm_xor_ps (__m128 a, __m128 b) + // __m128d _mm_xor_pd (__m128d a, __m128d b) + public static Vector128 Xor(Vector128 left, Vector128 right) where T : struct { throw new NotImplementedException(); } + } +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE3.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE3.cs new file mode 100644 index 00000000000..df6b4407552 --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE3.cs @@ -0,0 +1,61 @@ +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// SSE3.cs +// +// A class that implements intrinsic functions to provide access to Intel SSE3 instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + /// + /// Provides access to Intel SSE3 hardware instructions via intrinsics + /// + /// + /// SSE3 class provides access to 128-bit SSE3 SIMD instructions + /// + + public static class SSE3 + { + // __m128 _mm_addsub_ps (__m128 a, __m128 b) + public static Vector128 AddSubtract(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_addsub_pd (__m128d a, __m128d b) + public static Vector128 AddSubtract(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_hadd_ps (__m128 a, __m128 b) + public static Vector128 HorizontalAdd(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_hadd_pd (__m128d a, __m128d b) + public static Vector128 HorizontalAdd(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_hsub_ps (__m128 a, __m128 b) + public static Vector128 HorizontalSubtract(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128d _mm_hsub_pd (__m128d a, __m128d b) + public static Vector128 HorizontalSubtract(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128d _mm_loaddup_pd (double const* mem_addr) + public static unsafe Vector128 LoadAndDuplicate(double* mem) { throw new NotImplementedException(); } + + // __m128i _mm_lddqu_si128 (__m128i const* mem_addr) + public static unsafe Vector128 LoadDqu(sbyte* mem) { throw new NotImplementedException(); } + public static unsafe Vector128 LoadDqu(byte* mem) { throw new NotImplementedException(); } + public static unsafe Vector128 LoadDqu(short* mem) { throw new NotImplementedException(); } + public static unsafe Vector128 LoadDqu(ushort* mem) { throw new NotImplementedException(); } + public static unsafe Vector128 LoadDqu(int* mem) { throw new NotImplementedException(); } + public static unsafe Vector128 LoadDqu(uint* mem) { throw new NotImplementedException(); } + public static unsafe Vector128 LoadDqu(long* mem) { throw new NotImplementedException(); } + public static unsafe Vector128 LoadDqu(ulong* mem) { throw new NotImplementedException(); } + + // __m128d _mm_movedup_pd (__m128d a) + public static Vector128 MoveAndDuplicate(Vector128 source) { throw new NotImplementedException(); } + + // __m128 _mm_movehdup_ps (__m128 a) + public static Vector128 MoveHighAndDuplicate(Vector128 source) { throw new NotImplementedException(); } + + // __m128 _mm_moveldup_ps (__m128 a) + public static Vector128 MoveLowAndDuplicate(Vector128 source) { throw new NotImplementedException(); } + + } +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE41.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE41.cs new file mode 100644 index 00000000000..9023687f134 --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE41.cs @@ -0,0 +1,324 @@ +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// SSE41.cs +// +// A class that implements intrinsic functions to provide access to Intel SSE4.1 instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.InteropServices; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + /// + /// Provides access to Intel SSE4.1 hardware instructions via intrinsics + /// + /// + /// SSE41 class provides access to 128-bit SSE4.1 SIMD instructions + /// + + public static class SSE41 + { + // __m128i _mm_blend_epi16 (__m128i a, __m128i b, const int imm8) + private static Vector128 Blend(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static BlendVector128Delegate GetBlendVector128Short(byte control) + { + return (left, right) => Blend(left, right, control); + } + + // __m128i _mm_blend_epi16 (__m128i a, __m128i b, const int imm8) + private static Vector128 Blend(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static BlendVector128Delegate GetBlendVector128Ushort(byte control) + { + return (left, right) => Blend(left, right, control); + } + + // __m128 _mm_blend_ps (__m128 a, __m128 b, const int imm8) + private static Vector128 Blend(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static BlendVector128Delegate GetBlendVector128Float(byte control) + { + return (left, right) => Blend(left, right, control); + } + // __m128d _mm_blend_pd (__m128d a, __m128d b, const int imm8) + private static Vector128 Blend(Vector128 left, Vector128 right, byte control) { throw new NotImplementedException(); } + public static BlendVector128Delegate GetBlendVector128Double(byte control) + { + return (left, right) => Blend(left, right, control); + } + + // __m128i _mm_blendv_epi8 (__m128i a, __m128i b, __m128i mask) + public static Vector128 BlendVariable(Vector128 left, Vector128 right, Vector128 mask) { throw new NotImplementedException(); } + // __m128i _mm_blendv_epi8 (__m128i a, __m128i b, __m128i mask) + public static Vector128 BlendVariable(Vector128 left, Vector128 right, Vector128 mask) { throw new NotImplementedException(); } + // __m128 _mm_blendv_ps (__m128 a, __m128 b, __m128 mask) + public static Vector128 BlendVariable(Vector128 left, Vector128 right, Vector128 mask) { throw new NotImplementedException(); } + // __m128d _mm_blendv_pd (__m128d a, __m128d b, __m128d mask) + public static Vector128 BlendVariable(Vector128 left, Vector128 right, Vector128 mask) { throw new NotImplementedException(); } + + // __m128 _mm_ceil_ps (__m128 a) + public static Vector128 Ceiling(Vector128 value) { throw new NotImplementedException(); } + // __m128d _mm_ceil_pd (__m128d a) + public static Vector128 Ceiling(Vector128 value) { throw new NotImplementedException(); } + + // __m128i _mm_cmpeq_epi64 (__m128i a, __m128i b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_cmpeq_epi64 (__m128i a, __m128i b) + public static Vector128 CompareEqual(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_cvtepi8_epi16 (__m128i a) + public static Vector128 ConvertToShort(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepu8_epi16 (__m128i a) + public static Vector128 ConvertToShort(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepi8_epi32 (__m128i a) + public static Vector128 ConvertToInt(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepu8_epi32 (__m128i a) + public static Vector128 ConvertToInt(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepi16_epi32 (__m128i a) + public static Vector128 ConvertToInt(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepu16_epi32 (__m128i a) + public static Vector128 ConvertToInt(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepi8_epi64 (__m128i a) + public static Vector128 ConvertToLong(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepu8_epi64 (__m128i a) + public static Vector128 ConvertToLong(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepi16_epi64 (__m128i a) + public static Vector128 ConvertToLong(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepu16_epi64 (__m128i a) + public static Vector128 ConvertToLong(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepi32_epi64 (__m128i a) + public static Vector128 ConvertToLong(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_cvtepu32_epi64 (__m128i a) + public static Vector128 ConvertToLong(Vector128 value) { throw new NotImplementedException(); } + + // int _mm_extract_epi8 (__m128i a, const int imm8) + private static sbyte ExtractSbyte(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractSbyteVector128Delegate GetExtractVector128Sbyte(byte index) where T : struct + { + return (value) => ExtractSbyte(value, index); + } + // int _mm_extract_epi8 (__m128i a, const int imm8) + private static byte ExtractByte(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractByteVector128Delegate GetExtractVector128Byte(byte index) where T : struct + { + return (value) => ExtractByte(value, index); + } + // int _mm_extract_epi32 (__m128i a, const int imm8) + private static int ExtractInt(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractIntVector128Delegate GetExtractVector128Int(byte index) where T : struct + { + return (value) => ExtractInt(value, index); + } + // int _mm_extract_epi32 (__m128i a, const int imm8) + private static uint ExtractUint(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractUIntVector128Delegate GetExtractVector128Uint(byte index) where T : struct + { + return (value) => ExtractUint(value, index); + } + // __int64 _mm_extract_epi64 (__m128i a, const int imm8) + private static long ExtractLong(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractLongVector128Delegate GetExtractVector128Long(byte index) where T : struct + { + return (value) => ExtractLong(value, index); + } + // __int64 _mm_extract_epi64 (__m128i a, const int imm8) + private static ulong ExtractUlong(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractUlongVector128Delegate GetExtractVector128Ulong(byte index) where T : struct + { + return (value) => ExtractUlong(value, index); + } + // int _mm_extract_ps (__m128 a, const int imm8) + private static int ExtractFloat(Vector128 value, byte index) where T : struct { throw new NotImplementedException(); } + public static ExtractFloatVector128Delegate GetExtractVector128Float(byte index) where T : struct + { + return (value) => ExtractFloat(value, index); + } + + // __m128 _mm_floor_ps (__m128 a) + public static Vector128 Floor(Vector128 value) { throw new NotImplementedException(); } + // __m128d _mm_floor_pd (__m128d a) + public static Vector128 Floor(Vector128 value) { throw new NotImplementedException(); } + + // __m128i _mm_insert_epi8 (__m128i a, int i, const int imm8) + private static Vector128 InsertSbyte(Vector128 value, sbyte data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertSbyteVector128Delegate GetInsertVector128Sbyte(byte index) where T : struct + { + return (value, data) => InsertSbyte(value, data, index); + } + // __m128i _mm_insert_epi8 (__m128i a, int i, const int imm8) + private static Vector128 InsertByte(Vector128 value, byte data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertByteVector128Delegate GetInsertVector128Byte(byte index) where T : struct + { + return (value, data) => InsertByte(value, data, index); + } + // __m128i _mm_insert_epi32 (__m128i a, int i, const int imm8) + private static Vector128 InsertInt(Vector128 value, int data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertIntVector128Delegate GetInsertVector128Int(byte index) where T : struct + { + return (value, data) => InsertInt(value, data, index); + } + // __m128i _mm_insert_epi32 (__m128i a, int i, const int imm8) + private static Vector128 InsertUint(Vector128 value, uint data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertUintVector128Delegate GetInsertVector128Uint(byte index) where T : struct + { + return (value, data) => InsertUint(value, data, index); + } + // __m128i _mm_insert_epi64 (__m128i a, __int64 i, const int imm8) + private static Vector128 InsertLong(Vector128 value, long data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertLongVector128Delegate GetInsertVector128Long(byte index) where T : struct + { + return (value, data) => InsertLong(value, data, index); + } + // __m128i _mm_insert_epi64 (__m128i a, __int64 i, const int imm8) + private static Vector128 InsertUlong(Vector128 value, ulong data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertUlongVector128Delegate GetInsertVector128Ulong(byte index) where T : struct + { + return (value, data) => InsertUlong(value, data, index); + } + // __m128 _mm_insert_ps (__m128 a, __m128 b, const int imm8) + private static Vector128 InsertFloat(Vector128 value, float data, byte index) where T : struct { throw new NotImplementedException(); } + public static InsertFloatVector128Delegate GetInsertVector128Float(byte index) where T : struct + { + return (value, data) => InsertFloat(value, data, index); + } + + // __m128i _mm_max_epi8 (__m128i a, __m128i b) + public static Vector128 Max(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_max_epu16 (__m128i a, __m128i b) + public static Vector128 Max(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_max_epi32 (__m128i a, __m128i b) + public static Vector128 Max(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_max_epu32 (__m128i a, __m128i b) + public static Vector128 Max(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_min_epi8 (__m128i a, __m128i b) + public static Vector128 Min(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_min_epu16 (__m128i a, __m128i b) + public static Vector128 Min(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_min_epi32 (__m128i a, __m128i b) + public static Vector128 Min(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_min_epu32 (__m128i a, __m128i b) + public static Vector128 Min(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_minpos_epu16 (__m128i a) + public static Vector128 MinHorizontal(Vector128 value) { throw new NotImplementedException(); } + + // __m128i _mm_mpsadbw_epu8 (__m128i a, __m128i b, const int imm8) + private static Vector128 MultipleSumAbsoluteDifference(Vector128 left, Vector128 right, byte mask) { throw new NotImplementedException(); } + public static MultipleSumAbsoluteDifferenceVector128Delegate GetMultipleSumAbsoluteDifferenceVector128(byte mask) + { + return (left, right) => MultipleSumAbsoluteDifference(left, right, mask); + } + + // __m128i _mm_mul_epi32 (__m128i a, __m128i b) + public static Vector128 Multiply(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_mullo_epi32 (__m128i a, __m128i b) + public static Vector128 MultiplyLow(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_packus_epi32 (__m128i a, __m128i b) + public static Vector128 PackUnsignedSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128 _mm_round_ps (__m128 a, int rounding) + // _MM_FROUND_TO_NEAREST_INT |_MM_FROUND_NO_EXC + public static Vector128 RoundToNearestInteger(Vector128 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_NEG_INF |_MM_FROUND_NO_EXC + public static Vector128 RoundToNegativeInfinity(Vector128 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_POS_INF |_MM_FROUND_NO_EXC + public static Vector128 RoundToPositiveInfinity(Vector128 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_ZERO |_MM_FROUND_NO_EXC + public static Vector128 RoundToZero(Vector128 value) { throw new NotImplementedException(); } + // _MM_FROUND_CUR_DIRECTION + public static Vector128 RoundCurrentDirection(Vector128 value) { throw new NotImplementedException(); } + + // __m128d _mm_round_pd (__m128d a, int rounding) + // _MM_FROUND_TO_NEAREST_INT |_MM_FROUND_NO_EXC + public static Vector128 RoundToNearestInteger(Vector128 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_NEG_INF |_MM_FROUND_NO_EXC + public static Vector128 RoundToNegativeInfinity(Vector128 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_POS_INF |_MM_FROUND_NO_EXC + public static Vector128 RoundToPositiveInfinity(Vector128 value) { throw new NotImplementedException(); } + // _MM_FROUND_TO_ZERO |_MM_FROUND_NO_EXC + public static Vector128 RoundToZero(Vector128 value) { throw new NotImplementedException(); } + // _MM_FROUND_CUR_DIRECTION + public static Vector128 RoundCurrentDirection(Vector128 value) { throw new NotImplementedException(); } + + // __m128i _mm_stream_load_si128 (const __m128i* mem_addr) + public static unsafe Vector128 LoadAlignedNonTemporal(sbyte* mem) { throw new NotImplementedException(); } + // __m128i _mm_stream_load_si128 (const __m128i* mem_addr) + public static unsafe Vector128 LoadAlignedNonTemporal(byte* mem) { throw new NotImplementedException(); } + // __m128i _mm_stream_load_si128 (const __m128i* mem_addr) + public static unsafe Vector128 LoadAlignedNonTemporal(short* mem) { throw new NotImplementedException(); } + // __m128i _mm_stream_load_si128 (const __m128i* mem_addr) + public static unsafe Vector128 LoadAlignedNonTemporal(ushort* mem) { throw new NotImplementedException(); } + // __m128i _mm_stream_load_si128 (const __m128i* mem_addr) + public static unsafe Vector128 LoadAlignedNonTemporal(int* mem) { throw new NotImplementedException(); } + // __m128i _mm_stream_load_si128 (const __m128i* mem_addr) + public static unsafe Vector128 LoadAlignedNonTemporal(uint* mem) { throw new NotImplementedException(); } + // __m128i _mm_stream_load_si128 (const __m128i* mem_addr) + public static unsafe Vector128 LoadAlignedNonTemporal(long* mem) { throw new NotImplementedException(); } + // __m128i _mm_stream_load_si128 (const __m128i* mem_addr) + public static unsafe Vector128 LoadAlignedNonTemporal(ulong* mem) { throw new NotImplementedException(); } + + // int _mm_test_all_ones (__m128i a) + public static bool TestAllOnes(Vector128 value) { throw new NotImplementedException(); } + public static bool TestAllOnes(Vector128 value) { throw new NotImplementedException(); } + public static bool TestAllOnes(Vector128 value) { throw new NotImplementedException(); } + public static bool TestAllOnes(Vector128 value) { throw new NotImplementedException(); } + public static bool TestAllOnes(Vector128 value) { throw new NotImplementedException(); } + public static bool TestAllOnes(Vector128 value) { throw new NotImplementedException(); } + public static bool TestAllOnes(Vector128 value) { throw new NotImplementedException(); } + public static bool TestAllOnes(Vector128 value) { throw new NotImplementedException(); } + + // int _mm_test_all_zeros (__m128i a, __m128i mask) + public static bool TestAllZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestAllZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestAllZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestAllZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestAllZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestAllZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestAllZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestAllZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // int _mm_testc_si128 (__m128i a, __m128i b) + public static bool TestC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // int _mm_test_mix_ones_zeros (__m128i a, __m128i mask) + public static bool TestMixOnesZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestMixOnesZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestMixOnesZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestMixOnesZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestMixOnesZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestMixOnesZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestMixOnesZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestMixOnesZeros(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // int _mm_testnzc_si128 (__m128i a, __m128i b) + public static bool TestNotZAndNotC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestNotZAndNotC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestNotZAndNotC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestNotZAndNotC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestNotZAndNotC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestNotZAndNotC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestNotZAndNotC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestNotZAndNotC(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // int _mm_testz_si128 (__m128i a, __m128i b) + public static bool TestZ(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestZ(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestZ(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestZ(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestZ(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestZ(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestZ(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + public static bool TestZ(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + } +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE42.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE42.cs new file mode 100644 index 00000000000..6619499f757 --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSE42.cs @@ -0,0 +1,389 @@ +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// SSE42.cs +// +// A class that implements intrinsic functions to provide access to Intel SSE4.1 instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.InteropServices; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + /// + /// Provides access to Intel SSE4.2 hardware instructions via intrinsics + /// + /// + /// SSE42 class provides access to 128-bit SSE4.2 SIMD instructions + /// + + public static class SSE42 + { + // int _mm_cmpistra (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrc (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistro (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrs (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrz (__m128i a, __m128i b, const int imm8) + private static bool CompareImplicitLength(Vector128 left, Vector128 right, ResultsFlag flag, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthVector128Delegate GetCompareImplicitLengthVector128Sbyte(ResultsFlag flag, StringComparisonMode mode) + { + return (left, right) => CompareImplicitLength(left, right, flag, mode); + } + + // int _mm_cmpistra (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrc (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistro (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrs (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrz (__m128i a, __m128i b, const int imm8) + private static bool CompareImplicitLength(Vector128 left, Vector128 right, ResultsFlag flag, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthVector128Delegate GetCompareImplicitLengthVector128Byte(ResultsFlag flag, StringComparisonMode mode) + { + return (left, right) => CompareImplicitLength(left, right, flag, mode); + } + + // int _mm_cmpistra (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrc (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistro (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrs (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrz (__m128i a, __m128i b, const int imm8) + private static bool CompareImplicitLength(Vector128 left, Vector128 right, ResultsFlag flag, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthVector128Delegate GetCompareImplicitLengthVector128Short(ResultsFlag flag, StringComparisonMode mode) + { + return (left, right) => CompareImplicitLength(left, right, flag, mode); + } + + // int _mm_cmpistra (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrc (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistro (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrs (__m128i a, __m128i b, const int imm8) + // int _mm_cmpistrz (__m128i a, __m128i b, const int imm8) + private static bool CompareImplicitLength(Vector128 left, Vector128 right, ResultsFlag flag, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthVector128Delegate GetCompareImplicitLengthVector128Ushort(ResultsFlag flag, StringComparisonMode mode) + { + return (left, right) => CompareImplicitLength(left, right, flag, mode); + } + + // int _mm_cmpestra (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrc (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestro (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrs (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrz (__m128i a, int la, __m128i b, int lb, const int imm8) + private static bool CompareExplicitLength(Vector128 left, byte leftLength, Vector128 right, byte rightLength, ResultsFlag flag, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthVector128Delegate GetCompareExplicitLengthVector128Sbyte(ResultsFlag flag, StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLength(left, leftLength, right, rightLength, flag, mode); + } + + // int _mm_cmpestra (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrc (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestro (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrs (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrz (__m128i a, int la, __m128i b, int lb, const int imm8) + private static bool CompareExplicitLength(Vector128 left, byte leftLength, Vector128 right, byte rightLength, ResultsFlag flag, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthVector128Delegate GetCompareExplicitLengthVector128Byte(ResultsFlag flag, StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLength(left, leftLength, right, rightLength, flag, mode); + } + + // int _mm_cmpestra (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrc (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestro (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrs (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrz (__m128i a, int la, __m128i b, int lb, const int imm8) + private static bool CompareExplicitLength(Vector128 left, byte leftLength, Vector128 right, byte rightLength, ResultsFlag flag, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthVector128Delegate GetCompareExplicitLengthVector128Short(ResultsFlag flag, StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLength(left, leftLength, right, rightLength, flag, mode); + } + + // int _mm_cmpestra (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrc (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestro (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrs (__m128i a, int la, __m128i b, int lb, const int imm8) + // int _mm_cmpestrz (__m128i a, int la, __m128i b, int lb, const int imm8) + private static bool CompareExplicitLength(Vector128 left, byte leftLength, Vector128 right, byte rightLength, ResultsFlag flag, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthVector128Delegate GetCompareExplicitLengthVector128Ushort(ResultsFlag flag, StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLength(left, leftLength, right, rightLength, flag, mode); + } + + + // int _mm_cmpistri (__m128i a, __m128i b, const int imm8) + private static byte CompareImplicitLengthIndex(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthIndexVector128Delegate GetCompareImplicitLengthIndexVector128Sbyte(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthIndex(left, right, mode); + } + + // int _mm_cmpistri (__m128i a, __m128i b, const int imm8) + private static byte CompareImplicitLengthIndex(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthIndexVector128Delegate GetCompareImplicitLengthIndexVector128Byte(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthIndex(left, right, mode); + } + + // int _mm_cmpistri (__m128i a, __m128i b, const int imm8) + private static byte CompareImplicitLengthIndex(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthIndexVector128Delegate GetCompareImplicitLengthIndexVector128Short(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthIndex(left, right, mode); + } + + // int _mm_cmpistri (__m128i a, __m128i b, const int imm8) + private static byte CompareImplicitLengthIndex(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthIndexVector128Delegate GetCompareImplicitLengthIndexVector128Ushort(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthIndex(left, right, mode); + } + + // int _mm_cmpestri (__m128i a, int la, __m128i b, int lb, const int imm8) + private static byte CompareExplicitLengthIndex(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthIndexVector128Delegate GetCompareExplicitLengthIndexVector128Sbyte(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthIndex(left, leftLength, right, rightLength, mode); + } + + // int _mm_cmpestri (__m128i a, int la, __m128i b, int lb, const int imm8) + private static byte CompareExplicitLengthIndex(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthIndexVector128Delegate GetCompareExplicitLengthIndexVector128Byte(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthIndex(left, leftLength, right, rightLength, mode); + } + + // int _mm_cmpestri (__m128i a, int la, __m128i b, int lb, const int imm8) + private static byte CompareExplicitLengthIndex(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthIndexVector128Delegate GetCompareExplicitLengthIndexVector128Short(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthIndex(left, leftLength, right, rightLength, mode); + } + + // int _mm_cmpestri (__m128i a, int la, __m128i b, int lb, const int imm8) + private static byte CompareExplicitLengthIndex(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthIndexVector128Delegate GetCompareExplicitLengthIndexVector128Ushort(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthIndex(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpistrm (__m128i a, __m128i b, const int imm8) + private static Vector128 CompareImplicitLengthBitMask(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthBitMaskVector128SbyteDelegate GetCCompareImplicitLengthBitMaskVector128Sbyte(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthBitMask(left, right, mode); + } + + // __m128i _mm_cmpistrm (__m128i a, __m128i b, const int imm8) + private static Vector128 CompareImplicitLengthBitMask(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthBitMaskVector128ByteDelegate GetCompareImplicitLengthBitMaskVector128Byte(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthBitMask(left, right, mode); + } + + // __m128i _mm_cmpistrm (__m128i a, __m128i b, const int imm8) + private static Vector128 CompareImplicitLengthBitMask(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthBitMaskVector128ShortDelegate GetCompareImplicitLengthBitMaskVector128Short(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthBitMask(left, right, mode); + } + + // __m128i _mm_cmpistrm (__m128i a, __m128i b, const int imm8) + private static Vector128 CompareImplicitLengthBitMask(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthBitMaskVector128UshortDelegate GetCompareImplicitLengthBitMaskVector128Ushort(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthBitMask(left, right, mode); + } + + // __m128i _mm_cmpistrm (__m128i a, __m128i b, const int imm8) + private static Vector128 CompareImplicitLengthUnitMask(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthUnitMaskVector128SbyteDelegate GetCCompareImplicitLengthUnitMaskVector128Sbyte(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthUnitMask(left, right, mode); + } + + // __m128i _mm_cmpistrm (__m128i a, __m128i b, const int imm8) + private static Vector128 CompareImplicitLengthUnitMask(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthUnitMaskVector128ByteDelegate GetCompareImplicitLengthUnitMaskVector128Byte(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthUnitMask(left, right, mode); + } + + // __m128i _mm_cmpistrm (__m128i a, __m128i b, const int imm8) + private static Vector128 CompareImplicitLengthUnitMask(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthUnitMaskVector128ShortDelegate GetCompareImplicitLengthUnitMaskVector128Short(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthUnitMask(left, right, mode); + } + + // __m128i _mm_cmpistrm (__m128i a, __m128i b, const int imm8) + private static Vector128 CompareImplicitLengthUnitMask(Vector128 left, Vector128 right, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareImplicitLengthUnitMaskVector128UshortDelegate GetCompareImplicitLengthUnitMaskVector128Ushort(StringComparisonMode mode) + { + return (left, right) => CompareImplicitLengthUnitMask(left, right, mode); + } + + // __m128i _mm_cmpestrm (__m128i a, int la, __m128i b, int lb, const int imm8) + private static Vector128 CompareExplicitLengthBitMask(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthBitMaskVector128SbyteDelegate GetCompareExplicitLengthBitMaskVector128Sbyte(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthBitMask(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpestrm (__m128i a, int la, __m128i b, int lb, const int imm8) + private static Vector128 CompareExplicitLengthBitMask(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthBitMaskVector128ByteDelegate GetCompareExplicitLengthBitMaskVector128Byte(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthBitMask(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpestrm (__m128i a, int la, __m128i b, int lb, const int imm8) + private static Vector128 CompareExplicitLengthBitMask(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthBitMaskVector128ShortDelegate GetCompareExplicitLengthBitMaskVector128Short(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthBitMask(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpestrm (__m128i a, int la, __m128i b, int lb, const int imm8) + private static Vector128 CompareExplicitLengthBitMask(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthBitMaskVector128UshortDelegate GetCompareExplicitLengthBitMaskVector128Ushort(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthBitMask(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpestrm (__m128i a, int la, __m128i b, int lb, const int imm8) + private static Vector128 CompareExplicitLengthUnitMask(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthUnitMaskVector128SbyteDelegate GetCompareExplicitLengthUnitMaskVector128Sbyte(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthUnitMask(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpestrm (__m128i a, int la, __m128i b, int lb, const int imm8) + private static Vector128 CompareExplicitLengthUnitMask(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthUnitMaskVector128ByteDelegate GetCompareExplicitLengthUnitMaskVector128Byte(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthUnitMask(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpestrm (__m128i a, int la, __m128i b, int lb, const int imm8) + private static Vector128 CompareExplicitLengthUnitMask(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthUnitMaskVector128ShortDelegate GetCompareExplicitLengthUnitMaskVector128Short(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthUnitMask(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpestrm (__m128i a, int la, __m128i b, int lb, const int imm8) + private static Vector128 CompareExplicitLengthUnitMask(Vector128 left, byte leftLength, Vector128 right, byte rightLength, StringComparisonMode mode) + { + throw new NotImplementedException(); + } + public static CompareExplicitLengthUnitMaskVector128UshortDelegate GetCompareExplicitLengthUnitMaskVector128Ushort(StringComparisonMode mode) + { + return (left, leftLength, right, rightLength) => CompareExplicitLengthUnitMask(left, leftLength, right, rightLength, mode); + } + + // __m128i _mm_cmpgt_epi64 (__m128i a, __m128i b) + public static Vector128 CompareGreaterThan(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // unsigned int _mm_crc32_u8 (unsigned int crc, unsigned char v) + public static uint Crc32(uint crc, byte data) { throw new NotImplementedException(); } + // unsigned int _mm_crc32_u16 (unsigned int crc, unsigned short v) + public static uint Crc32(uint crc, ushort data) { throw new NotImplementedException(); } + // unsigned int _mm_crc32_u32 (unsigned int crc, unsigned int v) + public static uint Crc32(uint crc, uint data) { throw new NotImplementedException(); } + // unsigned __int64 _mm_crc32_u64 (unsigned __int64 crc, unsigned __int64 v) + public static ulong Crc32(ulong crc, ulong data) { throw new NotImplementedException(); } + } +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSSE3.cs b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSSE3.cs new file mode 100644 index 00000000000..8df5516f94a --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics.Intel/System/Runtime/CompilerServices/Intrinsics/Intel/SSSE3.cs @@ -0,0 +1,69 @@ +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ +// +// SSSE3.cs +// +// A class that implements intrinsic functions to provide access to Intel SSSE3 instructions. +// +// =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ + +using System; +using System.Runtime.CompilerServices.Intrinsics; + +namespace System.Runtime.CompilerServices.Intrinsics.Intel +{ + /// + /// Provides access to Intel SSSE3 hardware instructions via intrinsics + /// + /// + /// SSSE3 class provides access to 128-bit SSSE3 SIMD instructions + /// + + public static class SSSE3 + { + // __m128i _mm_abs_epi8 (__m128i a) + public static Vector128 Abs(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_abs_epi16 (__m128i a) + public static Vector128 Abs(Vector128 value) { throw new NotImplementedException(); } + // __m128i _mm_abs_epi32 (__m128i a) + public static Vector128 Abs(Vector128 value) { throw new NotImplementedException(); } + + // __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count) + private static Vector128 AlignRight(Vector128 left, Vector128 right, byte mask) { throw new NotImplementedException(); } + public static AlignRightVector128Delegate GetAlignRightVector128Sbyte(byte mask) + { + return (left, right) => AlignRight(left, right, mask); + } + + // __m128i _mm_hadd_epi16 (__m128i a, __m128i b) + public static Vector128 HorizontalAdd(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_hadd_epi32 (__m128i a, __m128i b) + public static Vector128 HorizontalAdd(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_hadds_epi16 (__m128i a, __m128i b) + public static Vector128 HorizontalAddSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_hsub_epi16 (__m128i a, __m128i b) + public static Vector128 HorizontalSubtract(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_hsub_epi32 (__m128i a, __m128i b) + public static Vector128 HorizontalSubtract(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_hsubs_epi16 (__m128i a, __m128i b) + public static Vector128 HorizontalSubtractSaturation(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_maddubs_epi16 (__m128i a, __m128i b) + public static Vector128 MultiplyAddAdjacent(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_mulhrs_epi16 (__m128i a, __m128i b) + public static Vector128 MultiplyHighRoundScale(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + + // __m128i _mm_shuffle_epi8 (__m128i a, __m128i b) + public static Vector128 Shuffle(Vector128 value, Vector128 mask) { throw new NotImplementedException(); } + + // __m128i _mm_sign_epi8 (__m128i a, __m128i b) + public static Vector128 Sign(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_sign_epi16 (__m128i a, __m128i b) + public static Vector128 Sign(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + // __m128i _mm_sign_epi32 (__m128i a, __m128i b) + public static Vector128 Sign(Vector128 left, Vector128 right) { throw new NotImplementedException(); } + } +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices.Intrinsics/System/Runtime/CompilerServices/Intrinsics/Types.cs b/src/System.Runtime.CompilerServices.Intrinsics/System/Runtime/CompilerServices/Intrinsics/Types.cs new file mode 100644 index 00000000000..8ca85e6b3d2 --- /dev/null +++ b/src/System.Runtime.CompilerServices.Intrinsics/System/Runtime/CompilerServices/Intrinsics/Types.cs @@ -0,0 +1,13 @@ +using System; +using System.Runtime.InteropServices; + +namespace System.Runtime.CompilerServices.Intrinsics +{ + // 128 bit types + [StructLayout(LayoutKind.Sequential, Size = 16)] + public struct Vector128 where T : struct {} + + // 256 bit types + [StructLayout(LayoutKind.Sequential, Size = 32)] + public struct Vector256 where T : struct {} +} \ No newline at end of file diff --git a/src/System.Runtime.CompilerServices/System/Runtime/CompilerServices/ProcessorCapabilities.cs b/src/System.Runtime.CompilerServices/System/Runtime/CompilerServices/ProcessorCapabilities.cs new file mode 100644 index 00000000000..a7c62e5ef9c --- /dev/null +++ b/src/System.Runtime.CompilerServices/System/Runtime/CompilerServices/ProcessorCapabilities.cs @@ -0,0 +1,28 @@ +using System; + +namespace System.Runtime.CompilerServices +{ + public static class ProcessorCapabilities + { + public static bool IsSupported(InstructionSet instructionSet) { throw new NotImplementedException(); } + public static InstructionSet GetSupportedInstructionSet() { throw new NotImplementedException(); } + } + + public enum InstructionSet + { + AES, + AVX, + AVX2, + BMI1, + BMI2, + FMA, + LZCNT, + PCLMULQDQ, + POPCNT, + SSE2, + SSE3, + SSE41, + SSE42, + SSSE3, + } +} \ No newline at end of file