From 282eca70f13668aa11072a43d0b6f3bbbac45636 Mon Sep 17 00:00:00 2001 From: Fei Peng Date: Thu, 13 Sep 2018 16:52:42 -0700 Subject: Fix inconsistent Intel hardware intrinsic APIs Signed-off-by: dotnet-bot --- .../shared/System/Runtime/Intrinsics/X86/Avx2.PlatformNotSupported.cs | 2 +- .../shared/System/Runtime/Intrinsics/X86/Avx2.cs | 2 +- .../System/Runtime/Intrinsics/X86/Popcnt.PlatformNotSupported.cs | 4 ++-- .../shared/System/Runtime/Intrinsics/X86/Popcnt.cs | 4 ++-- .../shared/System/Runtime/Intrinsics/X86/Sse2.PlatformNotSupported.cs | 4 ++-- .../shared/System/Runtime/Intrinsics/X86/Sse2.cs | 4 ++-- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Avx2.PlatformNotSupported.cs b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Avx2.PlatformNotSupported.cs index a4b5680c7..79c30d37a 100644 --- a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Avx2.PlatformNotSupported.cs +++ b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Avx2.PlatformNotSupported.cs @@ -1787,7 +1787,7 @@ namespace System.Runtime.Intrinsics.X86 /// __m256i _mm256_sad_epu8 (__m256i a, __m256i b) /// VPSADBW ymm, ymm, ymm/m256 /// - public static Vector256 SumAbsoluteDifferences(Vector256 left, Vector256 right) { throw new PlatformNotSupportedException(); } + public static Vector256 SumAbsoluteDifferences(Vector256 left, Vector256 right) { throw new PlatformNotSupportedException(); } /// /// __m256i _mm256_unpackhi_epi8 (__m256i a, __m256i b) diff --git a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Avx2.cs b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Avx2.cs index 2e949dc83..90c5b315b 100644 --- a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Avx2.cs +++ b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Avx2.cs @@ -2513,7 +2513,7 @@ namespace System.Runtime.Intrinsics.X86 /// __m256i _mm256_sad_epu8 (__m256i a, __m256i b) /// VPSADBW ymm, ymm, ymm/m256 /// - public static Vector256 SumAbsoluteDifferences(Vector256 left, Vector256 right) => SumAbsoluteDifferences(left, right); + public static Vector256 SumAbsoluteDifferences(Vector256 left, Vector256 right) => SumAbsoluteDifferences(left, right); /// /// __m256i _mm256_unpackhi_epi8 (__m256i a, __m256i b) diff --git a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Popcnt.PlatformNotSupported.cs b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Popcnt.PlatformNotSupported.cs index f91b1aecf..bf045bd1f 100644 --- a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Popcnt.PlatformNotSupported.cs +++ b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Popcnt.PlatformNotSupported.cs @@ -20,11 +20,11 @@ namespace System.Runtime.Intrinsics.X86 /// int _mm_popcnt_u32 (unsigned int a) /// POPCNT reg, reg/m32 /// - public static int PopCount(uint value) { throw new PlatformNotSupportedException(); } + public static uint PopCount(uint value) { throw new PlatformNotSupportedException(); } /// /// __int64 _mm_popcnt_u64 (unsigned __int64 a) /// POPCNT reg64, reg/m64 /// - public static long PopCount(ulong value) { throw new PlatformNotSupportedException(); } + public static ulong PopCount(ulong value) { throw new PlatformNotSupportedException(); } } } diff --git a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Popcnt.cs b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Popcnt.cs index 057140ed0..ba73eb234 100644 --- a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Popcnt.cs +++ b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Popcnt.cs @@ -21,11 +21,11 @@ namespace System.Runtime.Intrinsics.X86 /// int _mm_popcnt_u32 (unsigned int a) /// POPCNT reg, reg/m32 /// - public static int PopCount(uint value) => PopCount(value); + public static uint PopCount(uint value) => PopCount(value); /// /// __int64 _mm_popcnt_u64 (unsigned __int64 a) /// POPCNT reg, reg/m64 /// - public static long PopCount(ulong value) => PopCount(value); + public static ulong PopCount(ulong value) => PopCount(value); } } diff --git a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Sse2.PlatformNotSupported.cs b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Sse2.PlatformNotSupported.cs index 8a706ec9b..0f9b1959b 100644 --- a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Sse2.PlatformNotSupported.cs +++ b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Sse2.PlatformNotSupported.cs @@ -893,7 +893,7 @@ namespace System.Runtime.Intrinsics.X86 /// __m128i _mm_madd_epi16 (__m128i a, __m128i b) /// PMADDWD xmm, xmm/m128 /// - public static Vector128 MultiplyHorizontalAdd(Vector128 left, Vector128 right) { throw new PlatformNotSupportedException(); } + public static Vector128 MultiplyAddAdjacent(Vector128 left, Vector128 right) { throw new PlatformNotSupportedException(); } /// /// __m128i _mm_mullo_epi16 (__m128i a, __m128i b) @@ -1074,7 +1074,7 @@ namespace System.Runtime.Intrinsics.X86 /// __m128i _mm_sad_epu8 (__m128i a, __m128i b) /// PSADBW xmm, xmm/m128 /// - public static Vector128 SumAbsoluteDifferences(Vector128 left, Vector128 right) { throw new PlatformNotSupportedException(); } + public static Vector128 SumAbsoluteDifferences(Vector128 left, Vector128 right) { throw new PlatformNotSupportedException(); } /// /// __m128i _mm_shuffle_epi32 (__m128i a, int immediate) diff --git a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Sse2.cs b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Sse2.cs index 1aab686bd..0f8b9a8f5 100644 --- a/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Sse2.cs +++ b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/X86/Sse2.cs @@ -894,7 +894,7 @@ namespace System.Runtime.Intrinsics.X86 /// __m128i _mm_madd_epi16 (__m128i a, __m128i b) /// PMADDWD xmm, xmm/m128 /// - public static Vector128 MultiplyHorizontalAdd(Vector128 left, Vector128 right) => MultiplyHorizontalAdd(left, right); + public static Vector128 MultiplyAddAdjacent(Vector128 left, Vector128 right) => MultiplyAddAdjacent(left, right); /// /// __m128i _mm_mullo_epi16 (__m128i a, __m128i b) @@ -1313,7 +1313,7 @@ namespace System.Runtime.Intrinsics.X86 /// __m128i _mm_sad_epu8 (__m128i a, __m128i b) /// PSADBW xmm, xmm/m128 /// - public static Vector128 SumAbsoluteDifferences(Vector128 left, Vector128 right) => SumAbsoluteDifferences(left, right); + public static Vector128 SumAbsoluteDifferences(Vector128 left, Vector128 right) => SumAbsoluteDifferences(left, right); /// /// __m128i _mm_shuffle_epi32 (__m128i a, int immediate) -- cgit v1.2.3