MathSharp, a vector and matrix library written in C# using hardware intrinsics
github.com
github.com
"Parsing a typical JSON payload and accessing all its members using the JsonDocument is 2-3x faster than Json.NET with little allocations for data that is reasonably sized (that is, < 1 MB)."
From: https://docs.microsoft.com/en-us/dotnet/core/whats-new/dotne...
I'll definitely be checking this math(s) library out after I get our solutions updated from 2.2. I was playing around with some ray tracing in C#-land and something like this could come in really handy.
EDIT: Just realized the Intrinsics namespace was added in Core 3.0 preview. I don't have the setup to test this myself right now. I did find an online compiler, but it looked like it optimized away everything in release mode.
> The IsSupported checks are treated as runtime constants by the JIT (when optimizations are enabled) and so you do not need to cross-compile to support multiple different ISAs, platforms, or architectures. Instead, you just write your code using if-statements and the unused code paths (any code path which is not executed, due to the condition for the branch being false or an earlier branch being taken instead) are dropped from the generated code (the native assembly code generated by the JIT at runtime).
[0] https://news.ycombinator.com/item?id=20915430 [1] https://devblogs.microsoft.com/dotnet/hardware-intrinsics-in...
> The IsSupported checks are treated as runtime constants by the JIT (when optimizations are enabled) and so you do not need to cross-compile to support multiple different ISAs, platforms, or architectures. Instead, you just write your code using if-statements and the unused code paths (any code path which is not executed, due to the condition for the branch being false or an earlier branch being taken instead) are dropped from the generated code (the native assembly code generated by the JIT at runtime).
https://devblogs.microsoft.com/dotnet/hardware-intrinsics-in...
That does not look like a general-purpose linear algebra library to me.
public static MatrixSingle CreateBillboard(in Vector4FParam1_3 objectPosition, in Vector4FParam1_3 cameraPosition, in Vector4FParam1_3 cameraUpVector, in Vector4FParam1_3 cameraForwardVector)
Not sure how MathSharp compares in performance or usability, however.
https://devblogs.microsoft.com/dotnet/hardware-intrinsics-in...
> TODO
:(