src\libraries\System.Private.CoreLib\src\System\Buffers\Text\Base64Helper\Base64DecoderHelper.cs (32)
76if (AdvSimd.Arm64.IsSupported && (end >= src))
88if ((Ssse3.IsSupported || AdvSimd.Arm64.IsSupported) && BitConverter.IsLittleEndian && (end >= src))
824[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
828Debug.Assert((Ssse3.IsSupported || AdvSimd.Arm64.IsSupported) && BitConverter.IsLittleEndian);
836return AdvSimd.Arm64.VectorTableLookup(left, right & mask8F);
842[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
916Vector128<byte> decOne1 = AdvSimd.Arm64.VectorTableLookup(decLutOne, str1);
917Vector128<byte> decOne2 = AdvSimd.Arm64.VectorTableLookup(decLutOne, str2);
918Vector128<byte> decOne3 = AdvSimd.Arm64.VectorTableLookup(decLutOne, str3);
919Vector128<byte> decOne4 = AdvSimd.Arm64.VectorTableLookup(decLutOne, str4);
930Vector128<byte> decTwo1 = AdvSimd.SubtractSaturate(str1, offset);
931Vector128<byte> decTwo2 = AdvSimd.SubtractSaturate(str2, offset);
932Vector128<byte> decTwo3 = AdvSimd.SubtractSaturate(str3, offset);
933Vector128<byte> decTwo4 = AdvSimd.SubtractSaturate(str4, offset);
936decTwo1 = AdvSimd.Arm64.VectorTableLookupExtension(decTwo1, decLutTwo, decTwo1);
937decTwo2 = AdvSimd.Arm64.VectorTableLookupExtension(decTwo2, decLutTwo, decTwo2);
938decTwo3 = AdvSimd.Arm64.VectorTableLookupExtension(decTwo3, decLutTwo, decTwo3);
939decTwo4 = AdvSimd.Arm64.VectorTableLookupExtension(decTwo4, decLutTwo, decTwo4);
970AdvSimd.Arm64.StoreVectorAndZip(dest, (res1, res2, res3));
984[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
991Debug.Assert((Ssse3.IsSupported || AdvSimd.Arm64.IsSupported) && BitConverter.IsLittleEndian);
1106else if (AdvSimd.Arm64.IsSupported)
1108Vector128<ushort> evens = AdvSimd.ShiftLeftLogicalWideningLower(AdvSimd.Arm64.UnzipEven(str, one).GetLower(), 6);
1109Vector128<ushort> odds = AdvSimd.Arm64.TransposeOdd(str, Vector128<byte>.Zero).AsUInt16();
1128else if (AdvSimd.Arm64.IsSupported)
1130Vector128<int> ievens = AdvSimd.ShiftLeftLogicalWideningLower(AdvSimd.Arm64.UnzipEven(merge_ab_and_bc, one.AsInt16()).GetLower(), 12);
1131Vector128<int> iodds = AdvSimd.Arm64.TransposeOdd(merge_ab_and_bc, Vector128<short>.Zero).AsInt32();
1279[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
1375[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
1380(str1, str2, str3, str4) = AdvSimd.Arm64.Load4xVector128AndUnzip(src);
src\libraries\System.Private.CoreLib\src\System\Buffers\Text\Base64Helper\Base64EncoderHelper.cs (25)
63if (AdvSimd.Arm64.IsSupported && (end >= src))
73if ((Ssse3.IsSupported || AdvSimd.Arm64.IsSupported) && BitConverter.IsLittleEndian && (end >= src))
387[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
412(str1, str2, str3) = AdvSimd.Arm64.Load3xVector128AndUnzip(src);
415res1 = AdvSimd.ShiftRightLogical(str1, 2);
416res2 = AdvSimd.ShiftRightLogical(str2, 4);
417res3 = AdvSimd.ShiftRightLogical(str3, 6);
418res2 = AdvSimd.ShiftLeftAndInsert(res2, str1, 4);
419res3 = AdvSimd.ShiftLeftAndInsert(res3, str2, 2);
422res2 &= AdvSimd.DuplicateToVector128((byte)0x3F);
423res3 &= AdvSimd.DuplicateToVector128((byte)0x3F);
424res4 = str3 & AdvSimd.DuplicateToVector128((byte)0x3F);
429res1 = AdvSimd.Arm64.VectorTableLookup((tblEnc1, tblEnc2, tblEnc3, tblEnc4), res1);
430res2 = AdvSimd.Arm64.VectorTableLookup((tblEnc1, tblEnc2, tblEnc3, tblEnc4), res2);
431res3 = AdvSimd.Arm64.VectorTableLookup((tblEnc1, tblEnc2, tblEnc3, tblEnc4), res3);
432res4 = AdvSimd.Arm64.VectorTableLookup((tblEnc1, tblEnc2, tblEnc3, tblEnc4), res4);
449[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
508else if (AdvSimd.Arm64.IsSupported)
510Vector128<ushort> odd = Vector128.ShiftRightLogical(AdvSimd.Arm64.UnzipOdd(t0.AsUInt16(), t0.AsUInt16()), 6);
511Vector128<ushort> even = Vector128.ShiftRightLogical(AdvSimd.Arm64.UnzipEven(t0.AsUInt16(), t0.AsUInt16()), 10);
512t1 = AdvSimd.Arm64.ZipLow(even, odd);
554else if (AdvSimd.IsSupported)
556indices = AdvSimd.SubtractSaturate(str.AsByte(), const51);
755[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
760AdvSimd.Arm64.StoreVectorAndZip(dest, (res1, res2, res3, res4));
src\libraries\System.Private.CoreLib\src\System\Numerics\Matrix4x4.Impl.cs (9)
1660if (AdvSimd.Arm64.IsSupported)
1667Vector128<float> lowerXZ = AdvSimd.Arm64.ZipLow(x, z); // x[0], z[0], x[1], z[1]
1668Vector128<float> lowerYW = AdvSimd.Arm64.ZipLow(y, w); // y[0], w[0], y[1], w[1]
1669Vector128<float> upperXZ = AdvSimd.Arm64.ZipHigh(x, z); // x[2], z[2], x[3], z[3]
1670Vector128<float> upperYW = AdvSimd.Arm64.ZipHigh(y, w); // y[2], w[2], y[3], z[3]
1672result.X = AdvSimd.Arm64.ZipLow(lowerXZ, lowerYW).AsVector4(); // x[0], y[0], z[0], w[0]
1673result.Y = AdvSimd.Arm64.ZipHigh(lowerXZ, lowerYW).AsVector4(); // x[1], y[1], z[1], w[1]
1674result.Z = AdvSimd.Arm64.ZipLow(upperXZ, upperYW).AsVector4(); // x[2], y[2], z[2], w[2]
1675result.W = AdvSimd.Arm64.ZipHigh(upperXZ, upperYW).AsVector4(); // x[3], y[3], z[3], w[3]
src\libraries\System.Private.CoreLib\src\System\Text\Ascii.Utility.cs (39)
65[CompExactlyDependsOn(typeof(AdvSimd.Arm64))]
68if (!AdvSimd.Arm64.IsSupported || !BitConverter.IsLittleEndian)
74Vector128<byte> mostSignificantBitIsSet = AdvSimd.ShiftRightArithmetic(value.AsSByte(), 7).AsByte();
75Vector128<byte> extractedBits = AdvSimd.And(mostSignificantBitIsSet, bitmask);
78extractedBits = AdvSimd.Arm64.AddPairwise(extractedBits, extractedBits);
117(Sse2.IsSupported || AdvSimd.IsSupported))
361Debug.Assert(AdvSimd.IsSupported);
372Debug.Assert(Sse2.IsSupported || AdvSimd.Arm64.IsSupported, "Sse2 or AdvSimd64 required.");
403else if (AdvSimd.Arm64.IsSupported)
405currentAdvSimdIndex = (uint)GetIndexOfFirstNonAsciiByteInLane_AdvSimd(AdvSimd.LoadVector128(pBuffer), bitmask); // unaligned load
462else if (AdvSimd.Arm64.IsSupported)
464Vector128<byte> firstVector = AdvSimd.LoadVector128(pBuffer);
465Vector128<byte> secondVector = AdvSimd.LoadVector128(pBuffer + SizeOfVector128);
508else if (AdvSimd.Arm64.IsSupported)
510currentAdvSimdIndex = (uint)GetIndexOfFirstNonAsciiByteInLane_AdvSimd(AdvSimd.LoadVector128(pBuffer), bitmask);
543else if (AdvSimd.Arm64.IsSupported)
545currentAdvSimdIndex = (uint)GetIndexOfFirstNonAsciiByteInLane_AdvSimd(AdvSimd.LoadVector128(pBuffer), bitmask); // unaligned load
577else if (AdvSimd.IsSupported)
600else if (AdvSimd.Arm64.IsSupported)
737(Sse2.IsSupported || AdvSimd.IsSupported))
970Debug.Assert(Sse2.IsSupported || AdvSimd.Arm64.IsSupported, "Should've been checked by caller.");
1142else if (AdvSimd.Arm64.IsSupported)
1150Vector128<byte> compareResult = AdvSimd.CompareGreaterThan(firstVector, largestAsciiValue).AsByte();
1151ulong asciiCompareMask = AdvSimd.Arm64.UnzipOdd(compareResult, compareResult).AsUInt64().ToScalar();
1279else if (AdvSimd.IsSupported)
1285Vector64<byte> lower = AdvSimd.ExtractNarrowingSaturateUnsignedLower(vecWide);
1533else if (AdvSimd.Arm64.IsSupported)
1535Vector128<byte> maxBytes = AdvSimd.Arm64.MaxPairwise(asciiVector, asciiVector);
1563else if (AdvSimd.Arm64.IsSupported)
1567Vector128<ushort> maxChars = AdvSimd.Arm64.MaxPairwise(utf16Vector, utf16Vector);
1619AdvSimd.Arm64.IsSupported ? AllBytesInUInt64AreAscii(AdvSimd.Arm64.MaxPairwise(vector.AsByte(), vector.AsByte()).AsUInt64().ToScalar()) :
1625AdvSimd.Arm64.IsSupported ? AllCharsInUInt64AreAscii(AdvSimd.Arm64.MaxPairwise(vector.AsUInt16(), vector.AsUInt16()).AsUInt64().ToScalar()) :
1676else if (AdvSimd.Arm64.IsSupported)
1678return AdvSimd.Arm64.UnzipEven(vectorFirst.AsByte(), vectorSecond.AsByte());
2278if (AdvSimd.Arm64.IsSupported)
2280Vector128<byte> vecNarrow = AdvSimd.DuplicateToVector128(value).AsByte();
2281Vector128<ulong> vecWide = AdvSimd.Arm64.ZipLow(vecNarrow, Vector128<byte>.Zero).AsUInt64();