From 79d20e683c8391ffb3e311c8f252be26f2c8412c Mon Sep 17 00:00:00 2001 From: Peter Dettman Date: Wed, 9 Nov 2022 16:58:20 +0700 Subject: Remove NET7_0 directive for now --- crypto/src/crypto/engines/AesEngine_X86.cs | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/crypto/src/crypto/engines/AesEngine_X86.cs b/crypto/src/crypto/engines/AesEngine_X86.cs index e61deb174..bd7143cd1 100644 --- a/crypto/src/crypto/engines/AesEngine_X86.cs +++ b/crypto/src/crypto/engines/AesEngine_X86.cs @@ -780,9 +780,6 @@ namespace Org.BouncyCastle.Crypto.Engines [MethodImpl(MethodImplOptions.AggressiveInlining)] private static Vector128 Load128(ReadOnlySpan t) { -#if NET7_0_OR_GREATER - return Vector128.Create(t); -#else if (BitConverter.IsLittleEndian && Unsafe.SizeOf>() == 16) return MemoryMarshal.Read>(t); @@ -790,30 +787,22 @@ namespace Org.BouncyCastle.Crypto.Engines BinaryPrimitives.ReadUInt64LittleEndian(t[..8]), BinaryPrimitives.ReadUInt64LittleEndian(t[8..]) ).AsByte(); -#endif } [MethodImpl(MethodImplOptions.AggressiveInlining)] private static Vector64 Load64(ReadOnlySpan t) { -#if NET7_0_OR_GREATER - return Vector64.Create(t); -#else if (BitConverter.IsLittleEndian && Unsafe.SizeOf>() == 8) return MemoryMarshal.Read>(t); return Vector64.Create( BinaryPrimitives.ReadUInt64LittleEndian(t[..8]) ).AsByte(); -#endif } [MethodImpl(MethodImplOptions.AggressiveInlining)] private static void Store128(Vector128 s, Span t) { -#if NET7_0_OR_GREATER - Vector128.CopyTo(s, t); -#else if (BitConverter.IsLittleEndian && Unsafe.SizeOf>() == 16) { MemoryMarshal.Write(t, ref s); @@ -823,7 +812,6 @@ namespace Org.BouncyCastle.Crypto.Engines var u = s.AsUInt64(); BinaryPrimitives.WriteUInt64LittleEndian(t[..8], u.GetElement(0)); BinaryPrimitives.WriteUInt64LittleEndian(t[8..], u.GetElement(1)); -#endif } } } -- cgit 1.4.1