Add AllBitsSet, refactor WideLane, improve math paths
- Add static AllBitsSet property to ISPMDLane and implement in ScalarLane and WideLane - Refactor WideLane shuffle table pointers and update usages - Improve pointer safety and mask handling in CompressStore, Gather, and MaskLoad - Enhance Sin, Cos, SinCos with fast-math and hardware fallback - Add Newton-Raphson refinement for reciprocal/sqrt when not fast-math - Optimize MathV.Vector vector loading (struct init, pointer ops) - Update project file: version 1.3.4, content packaging, AOT settings - Minor code cleanup and naming consistency fixes
This commit is contained in:
@@ -65,23 +65,22 @@ public static unsafe partial class MathV
|
||||
<#= TLaneRestrictions #>
|
||||
<#= TNumberRestrictions #>
|
||||
{
|
||||
var width = TLane.LaneWidth;
|
||||
|
||||
<# for (int i = 0; i < dimension; i++) { #>
|
||||
var <#= components[i] #> = stackalloc <#= TNumber #>[width];
|
||||
Unsafe.SkipInit(out TLane <#= components[i] #>);
|
||||
var p<#= components[i] #> = (<#= TNumber #>*)&<#= components[i] #>;
|
||||
<# } #>
|
||||
|
||||
for (var i = 0; i < width; i++)
|
||||
for (var i = 0; i < TLane.LaneWidth; i++)
|
||||
{
|
||||
<# for (int i = 0; i < dimension; i++) { #>
|
||||
<#= components[i] #>[i] = pSrc[i * <#= dimension #> + <#= i #>];
|
||||
p<#= components[i] #>[i] = pSrc[i * <#= dimension #> + <#= i #>];
|
||||
<# } #>
|
||||
}
|
||||
|
||||
return new <#= vectorType #>
|
||||
{
|
||||
<# for (int i = 0; i < dimension; i++) { #>
|
||||
<#= components[i] #> = <#= TLane #>.Load(<#= components[i] #>),
|
||||
<#= components[i] #> = <#= components[i] #>,
|
||||
<# } #>
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user