Refactor trigonometric funcs, optimize GGX benchmark

- Replaced SIMD-based Sin/Cos/SinCos in WideLane with generic polynomial approximations for hardware independence.
- Updated ScalarLane Cast to use CreateTruncating.
- Applied AggressiveOptimization to key GGX methods; improved luma calculation and radical inverse LUT handling.
- Enhanced GGX benchmark setup, cleanup, and timing logic.
- Bumped project version to 1.3.1.
This commit is contained in:
2026-04-28 22:17:59 +09:00
parent 1074f9836e
commit 0acaf00767
5 changed files with 145 additions and 67 deletions

View File

@@ -171,7 +171,7 @@ public readonly unsafe struct ScalarLane<TNumber> : ISPMDLane<ScalarLane<TNumber
where TOther : ISPMDLane<TOther, TOtherNumber>
where TOtherNumber : unmanaged, INumber<TOtherNumber>, IBinaryNumber<TOtherNumber>, IMinMaxValue<TOtherNumber>, IBitwiseOperators<TOtherNumber, TOtherNumber, TOtherNumber>
{
return TOther.Create(TOtherNumber.CreateChecked(value));
return TOther.Create(TOtherNumber.CreateTruncating(value));
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]