Skip to content
This repository has been archived by the owner on Jan 23, 2023. It is now read-only.

Commit

Permalink
Add all integer overloads for AVX2/SSSE3 AlignRight
Browse files Browse the repository at this point in the history
  • Loading branch information
FeiPengIntel committed Aug 10, 2018
1 parent 30f0be9 commit aaf044d
Show file tree
Hide file tree
Showing 4 changed files with 172 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,48 @@ internal Avx2() { }
/// </summary>
public static Vector256<sbyte> AlignRight(Vector256<sbyte> left, Vector256<sbyte> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<byte> AlignRight(Vector256<byte> left, Vector256<byte> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<short> AlignRight(Vector256<short> left, Vector256<short> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<ushort> AlignRight(Vector256<ushort> left, Vector256<ushort> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<int> AlignRight(Vector256<int> left, Vector256<int> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<uint> AlignRight(Vector256<uint> left, Vector256<uint> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<long> AlignRight(Vector256<long> left, Vector256<long> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<ulong> AlignRight(Vector256<ulong> left, Vector256<ulong> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m256i _mm256_and_si256 (__m256i a, __m256i b)
/// VPAND ymm, ymm, ymm/m256
Expand Down Expand Up @@ -227,12 +269,12 @@ internal Avx2() { }

/// <summary>
/// __m256i _mm256_blendv_epi8 (__m256i a, __m256i b, __m256i mask)
/// PBLENDVB ymm, ymm, ymm/m256, ymm
/// VPBLENDVB ymm, ymm, ymm/m256, ymm
/// </summary>
public static Vector256<sbyte> BlendVariable(Vector256<sbyte> left, Vector256<sbyte> right, Vector256<sbyte> mask) { throw new PlatformNotSupportedException(); }
/// <summary>
/// __m256i _mm256_blendv_epi8 (__m256i a, __m256i b, __m256i mask)
/// PBLENDVB ymm, ymm, ymm/m256, ymm
/// VPBLENDVB ymm, ymm, ymm/m256, ymm
/// </summary>
public static Vector256<byte> BlendVariable(Vector256<byte> left, Vector256<byte> right, Vector256<byte> mask) { throw new PlatformNotSupportedException(); }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,48 @@ internal Avx2() { }
/// </summary>
public static Vector256<sbyte> AlignRight(Vector256<sbyte> left, Vector256<sbyte> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<byte> AlignRight(Vector256<byte> left, Vector256<byte> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<short> AlignRight(Vector256<short> left, Vector256<short> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<ushort> AlignRight(Vector256<ushort> left, Vector256<ushort> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<int> AlignRight(Vector256<int> left, Vector256<int> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<uint> AlignRight(Vector256<uint> left, Vector256<uint> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<long> AlignRight(Vector256<long> left, Vector256<long> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m256i _mm256_alignr_epi8 (__m256i a, __m256i b, const int count)
/// VPALIGNR ymm, ymm, ymm/m256, imm8
/// </summary>
public static Vector256<ulong> AlignRight(Vector256<ulong> left, Vector256<ulong> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m256i _mm256_and_si256 (__m256i a, __m256i b)
/// VPAND ymm, ymm, ymm/m256
Expand Down Expand Up @@ -227,12 +269,12 @@ internal Avx2() { }

/// <summary>
/// __m256i _mm256_blendv_epi8 (__m256i a, __m256i b, __m256i mask)
/// PBLENDVB ymm, ymm, ymm/m256, ymm
/// VPBLENDVB ymm, ymm, ymm/m256, ymm
/// </summary>
public static Vector256<sbyte> BlendVariable(Vector256<sbyte> left, Vector256<sbyte> right, Vector256<sbyte> mask) => BlendVariable(left, right, mask);
/// <summary>
/// __m256i _mm256_blendv_epi8 (__m256i a, __m256i b, __m256i mask)
/// PBLENDVB ymm, ymm, ymm/m256, ymm
/// VPBLENDVB ymm, ymm, ymm/m256, ymm
/// </summary>
public static Vector256<byte> BlendVariable(Vector256<byte> left, Vector256<byte> right, Vector256<byte> mask) => BlendVariable(left, right, mask);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,48 @@ internal Ssse3() { }
/// </summary>
public static Vector128<sbyte> AlignRight(Vector128<sbyte> left, Vector128<sbyte> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<byte> AlignRight(Vector128<byte> left, Vector128<byte> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<short> AlignRight(Vector128<short> left, Vector128<short> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<ushort> AlignRight(Vector128<ushort> left, Vector128<ushort> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<int> AlignRight(Vector128<int> left, Vector128<int> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<uint> AlignRight(Vector128<uint> left, Vector128<uint> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<long> AlignRight(Vector128<long> left, Vector128<long> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<ulong> AlignRight(Vector128<ulong> left, Vector128<ulong> right, byte mask) { throw new PlatformNotSupportedException(); }

/// <summary>
/// __m128i _mm_hadd_epi16 (__m128i a, __m128i b)
/// PHADDW xmm, xmm/m128
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,48 @@ internal Ssse3() { }
/// </summary>
public static Vector128<sbyte> AlignRight(Vector128<sbyte> left, Vector128<sbyte> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<byte> AlignRight(Vector128<byte> left, Vector128<byte> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<short> AlignRight(Vector128<short> left, Vector128<short> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<ushort> AlignRight(Vector128<ushort> left, Vector128<ushort> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<int> AlignRight(Vector128<int> left, Vector128<int> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<uint> AlignRight(Vector128<uint> left, Vector128<uint> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<long> AlignRight(Vector128<long> left, Vector128<long> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m128i _mm_alignr_epi8 (__m128i a, __m128i b, int count)
/// PALIGNR xmm, xmm/m128, imm8
/// </summary>
public static Vector128<ulong> AlignRight(Vector128<ulong> left, Vector128<ulong> right, byte mask) => AlignRight(left, right, mask);

/// <summary>
/// __m128i _mm_hadd_epi16 (__m128i a, __m128i b)
/// PHADDW xmm, xmm/m128
Expand Down

0 comments on commit aaf044d

Please sign in to comment.