Last active
January 29, 2019 17:11
-
-
Save richlander/eb4d5b24746f1bd317738d8ad4c4b0e8 to your computer and use it in GitHub Desktop.
Using Unsafe APIs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Vector256<short> SoftwareFallback(short x) | |
{ | |
var result = Vector256<short>.Zero; | |
Unsafe.WriteUnaligned(ref Unsafe.As<Vector256<short>, byte>(ref result), value); | |
return result; | |
} | |
// https://github.com/dotnet/coreclr/blob/57fd77e6f8f7f2c37cc5c3b36df3ea4f302e143b/src/System.Private.CoreLib/shared/System/Runtime/Intrinsics/Vector256.cs#L1303 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment