288 references to Count
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (2)
AsciiDecoding.cs (1)
57
for (var length = 1; length < Vector<sbyte>.
Count
* 4; length++)
UTF8Decoding.cs (1)
32
for (var length = bytes.Length; length < Vector<sbyte>.
Count
* 4 + bytes.Length; length++)
Microsoft.Data.Analysis (44)
Computations\Arithmetic.netstandard.cs (44)
171
var vectorSize = Vector<byte>.
Count
;
225
var vectorSize = Vector<byte>.
Count
;
279
var vectorSize = Vector<byte>.
Count
;
338
var vectorSize = Vector<byte>.
Count
;
640
var vectorSize = Vector<char>.
Count
;
694
var vectorSize = Vector<char>.
Count
;
748
var vectorSize = Vector<char>.
Count
;
807
var vectorSize = Vector<char>.
Count
;
1383
var vectorSize = Vector<double>.
Count
;
1437
var vectorSize = Vector<double>.
Count
;
1491
var vectorSize = Vector<double>.
Count
;
1550
var vectorSize = Vector<double>.
Count
;
1741
var vectorSize = Vector<float>.
Count
;
1795
var vectorSize = Vector<float>.
Count
;
1849
var vectorSize = Vector<float>.
Count
;
1908
var vectorSize = Vector<float>.
Count
;
2099
var vectorSize = Vector<int>.
Count
;
2153
var vectorSize = Vector<int>.
Count
;
2207
var vectorSize = Vector<int>.
Count
;
2266
var vectorSize = Vector<int>.
Count
;
2568
var vectorSize = Vector<long>.
Count
;
2622
var vectorSize = Vector<long>.
Count
;
2676
var vectorSize = Vector<long>.
Count
;
2735
var vectorSize = Vector<long>.
Count
;
3037
var vectorSize = Vector<sbyte>.
Count
;
3091
var vectorSize = Vector<sbyte>.
Count
;
3145
var vectorSize = Vector<sbyte>.
Count
;
3204
var vectorSize = Vector<sbyte>.
Count
;
3506
var vectorSize = Vector<short>.
Count
;
3560
var vectorSize = Vector<short>.
Count
;
3614
var vectorSize = Vector<short>.
Count
;
3673
var vectorSize = Vector<short>.
Count
;
3975
var vectorSize = Vector<uint>.
Count
;
4029
var vectorSize = Vector<uint>.
Count
;
4083
var vectorSize = Vector<uint>.
Count
;
4142
var vectorSize = Vector<uint>.
Count
;
4444
var vectorSize = Vector<ulong>.
Count
;
4498
var vectorSize = Vector<ulong>.
Count
;
4552
var vectorSize = Vector<ulong>.
Count
;
4611
var vectorSize = Vector<ulong>.
Count
;
4913
var vectorSize = Vector<ushort>.
Count
;
4967
var vectorSize = Vector<ushort>.
Count
;
5021
var vectorSize = Vector<ushort>.
Count
;
5080
var vectorSize = Vector<ushort>.
Count
;
System.Linq (19)
System\Linq\Average.cs (3)
32
if (Vector.IsHardwareAccelerated && span.Length >= Vector<int>.
Count
)
40
i += Vector<int>.
Count
;
42
while (i <= span.Length - Vector<int>.
Count
);
System\Linq\Range.cs (4)
87
destination.Length >= Vector<T>.
Count
)
91
Vector<T> increment = new Vector<T>(T.CreateTruncating(Vector<T>.
Count
));
93
ref T oneVectorFromEnd = ref Unsafe.Subtract(ref end, Vector<T>.
Count
);
98
pos = ref Unsafe.Add(ref pos, Vector<T>.
Count
);
System\Linq\Sum.cs (12)
54
&& Vector<T>.
Count
> 2
55
&& span.Length >= Vector<T>.
Count
* 4)
83
Debug.Assert(span.Length >= Vector<T>.
Count
* 4);
84
Debug.Assert(Vector<T>.
Count
> 2);
124
nuint limit = length - (nuint)Vector<T>.
Count
* 4;
132
data = Vector.LoadUnsafe(ref ptr, index + (nuint)Vector<T>.
Count
);
136
data = Vector.LoadUnsafe(ref ptr, index + (nuint)Vector<T>.
Count
* 2);
140
data = Vector.LoadUnsafe(ref ptr, index + (nuint)Vector<T>.
Count
* 3);
149
index += (nuint)Vector<T>.
Count
* 4;
153
limit = length - (nuint)Vector<T>.
Count
;
165
index += (nuint)Vector<T>.
Count
;
177
for (int i = 0; i < Vector<T>.
Count
; i++)
System.Net.WebSockets (3)
System\Net\WebSockets\ManagedWebSocket.cs (3)
1671
if (Vector.IsHardwareAccelerated && (toMaskEnd - toMaskPtr) >= Vector<byte>.
Count
)
1677
toMaskPtr += Vector<byte>.
Count
;
1679
while (toMaskEnd - toMaskPtr >= Vector<byte>.
Count
);
System.Private.CoreLib (216)
src\libraries\System.Private.CoreLib\src\System\Numerics\Vector.cs (130)
15
internal static int Alignment => Vector<byte>.
Count
;
124
for (int index = 0; index < Vector<T>.
Count
; index++)
151
for (int index = 0; index < Vector<T>.
Count
; index++)
374
for (int index = 0; index < Vector<T>.
Count
; index++)
394
for (int index = 0; index < Vector<double>.
Count
; index++)
413
for (int index = 0; index < Vector<float>.
Count
; index++)
474
if (Vector<double>.
Count
== Vector512<double>.Count)
478
else if (Vector<double>.
Count
== Vector256<double>.Count)
484
Debug.Assert(Vector<double>.
Count
== Vector128<double>.Count);
497
if (Vector<double>.
Count
== Vector512<double>.Count)
501
else if (Vector<double>.
Count
== Vector256<double>.Count)
507
Debug.Assert(Vector<double>.
Count
== Vector128<double>.Count);
520
for (int i = 0; i < Vector<int>.
Count
; i++)
537
for (int i = 0; i < Vector<int>.
Count
; i++)
554
for (int i = 0; i < Vector<long>.
Count
; i++)
571
for (int i = 0; i < Vector<long>.
Count
; i++)
588
for (int i = 0; i < Vector<float>.
Count
; i++)
605
if (Vector<float>.
Count
== Vector512<float>.Count)
609
else if (Vector<float>.
Count
== Vector256<float>.Count)
615
Debug.Assert(Vector<float>.
Count
== Vector128<float>.Count);
629
for (int i = 0; i < Vector<uint>.
Count
; i++)
647
for (int i = 0; i < Vector<uint>.
Count
; i++)
665
for (int i = 0; i < Vector<ulong>.
Count
; i++)
683
for (int i = 0; i < Vector<ulong>.
Count
; i++)
697
for (int index = 0; index < Vector<T>.
Count
; index++)
755
for (int index = 0; index < Vector<T>.
Count
; index++)
772
if (Vector<T>.
Count
== Vector512<T>.Count)
776
else if (Vector<T>.
Count
== Vector256<T>.Count)
782
Debug.Assert(Vector<T>.
Count
== Vector128<T>.Count);
816
for (int index = 0; index < Vector<T>.
Count
; index++)
827
/// <returns>A new <see cref="Vector{T}" /> with its elements set to the first <see cref="Vector{T}.
Count
" /> elements from <paramref name="values" />.</returns>
833
if (values.Length < Vector<T>.
Count
)
886
for (int index = 0; index < Vector<T>.
Count
; index++)
960
for (int index = 0; index < Vector<T>.
Count
; index++)
1014
for (int index = 0; index < Vector<T>.
Count
; index++)
1030
for (int index = 0; index < Vector<T>.
Count
; index++)
1091
for (int index = 0; index < Vector<T>.
Count
; index++)
1111
for (int index = 0; index < Vector<double>.
Count
; index++)
1130
for (int index = 0; index < Vector<float>.
Count
; index++)
1154
for (int index = 0; index < Vector<double>.
Count
; index++)
1178
for (int index = 0; index < Vector<float>.
Count
; index++)
1198
if ((uint)(index) >= (uint)(Vector<T>.
Count
))
1217
for (int index = 0; index < Vector<T>.
Count
; index++)
1263
for (int index = 0; index < Vector<T>.
Count
; index++)
1283
for (int index = 0; index < Vector<T>.
Count
; index++)
1305
for (int index = 0; index < Vector<T>.
Count
; index++)
1351
for (int index = 0; index < Vector<T>.
Count
; index++)
1371
for (int index = 0; index < Vector<T>.
Count
; index++)
1387
for (int index = 0; index < Vector<T>.
Count
; index++)
1429
if (Vector<T>.
Count
== Vector512<T>.Count)
1433
else if (Vector<T>.
Count
== Vector256<T>.Count)
1439
Debug.Assert(Vector<T>.
Count
== Vector128<T>.Count);
1675
if (Vector<T>.
Count
== Vector512<T>.Count)
1679
else if (Vector<T>.
Count
== Vector256<T>.Count)
1685
Debug.Assert(Vector<T>.
Count
== Vector128<T>.Count);
1714
for (int index = 0; index < Vector<T>.
Count
; index++)
1772
for (int index = 0; index < Vector<T>.
Count
; index++)
1818
for (int index = 0; index < Vector<T>.
Count
; index++)
1838
for (int index = 0; index < Vector<T>.
Count
; index++)
1860
for (int index = 0; index < Vector<T>.
Count
; index++)
1906
for (int index = 0; index < Vector<T>.
Count
; index++)
1926
for (int index = 0; index < Vector<T>.
Count
; index++)
2011
for (int index = 0; index < Vector<T>.
Count
; index++)
2053
for (int index = 0; index < Vector<T>.
Count
; index++)
2103
for (int index = 0; index < Vector<T>.
Count
; index++)
2126
for (int index = 0; index < Vector<T>.
Count
; index++)
2149
for (int index = 0; index < Vector<T>.
Count
; index++)
2172
for (int index = 0; index < Vector<T>.
Count
; index++)
2195
for (int index = 0; index < Vector<T>.
Count
; index++)
2218
for (int index = 0; index < Vector<T>.
Count
; index++)
2241
for (int index = 0; index < Vector<T>.
Count
; index++)
2264
for (int index = 0; index < Vector<T>.
Count
; index++)
2287
for (int index = 0; index < Vector<T>.
Count
; index++)
2310
for (int index = 0; index < Vector<T>.
Count
; index++)
2350
for (int index = 0; index < Vector<T>.
Count
; index++)
2366
for (int index = 0; index < Vector<double>.
Count
; index++)
2382
for (int index = 0; index < Vector<float>.
Count
; index++)
2399
for (int i = 0; i < Vector<TSource>.
Count
; i++)
2405
for (int i = Vector<TSource>.
Count
; i < Vector<TResult>.
Count
; i++)
2407
TResult value = TResult.CreateTruncating(high.GetElementUnsafe(i - Vector<TSource>.
Count
));
2468
for (int i = 0; i < Vector<TSource>.
Count
; i++)
2474
for (int i = Vector<TSource>.
Count
; i < Vector<TResult>.
Count
; i++)
2476
TResult value = TResult.CreateSaturating(high.GetElementUnsafe(i - Vector<TSource>.
Count
));
2572
for (int index = 0; index < Vector<T>.
Count
; index++)
2630
for (int index = 0; index < Vector<T>.
Count
; index++)
2726
if (Vector<uint>.
Count
== Vector512<uint>.Count)
2730
else if (Vector<uint>.
Count
== Vector256<uint>.Count)
2736
Debug.Assert(Vector<uint>.
Count
== Vector128<uint>.Count);
2752
if (Vector<ulong>.
Count
== Vector512<ulong>.Count)
2756
else if (Vector<ulong>.
Count
== Vector256<ulong>.Count)
2762
Debug.Assert(Vector<ulong>.
Count
== Vector128<ulong>.Count);
2883
for (int index = 0; index < Vector<T>.
Count
; index++)
2926
for (int index = 0; index < Vector<T>.
Count
; index++)
2974
for (int index = 0; index < Vector<T>.
Count
; index++)
3069
for (int index = 0; index < Vector<T>.
Count
; index++)
3088
for (int index = 0; index < Vector<T>.
Count
; index++)
3129
for (int index = 0; index < Vector<T>.
Count
; index++)
3280
for (int i = 0; i < Vector<ushort>.
Count
; i++)
3298
for (int i = 0; i < Vector<int>.
Count
; i++)
3316
for (int i = 0; i < Vector<long>.
Count
; i++)
3335
for (int i = 0; i < Vector<short>.
Count
; i++)
3353
for (int i = 0; i < Vector<double>.
Count
; i++)
3372
for (int i = 0; i < Vector<uint>.
Count
; i++)
3391
for (int i = 0; i < Vector<ulong>.
Count
; i++)
3410
for (int i = Vector<ushort>.
Count
; i < Vector<byte>.
Count
; i++)
3413
upper.SetElementUnsafe(i - Vector<ushort>.
Count
, value);
3428
for (int i = Vector<int>.
Count
; i < Vector<short>.
Count
; i++)
3431
upper.SetElementUnsafe(i - Vector<int>.
Count
, value);
3446
for (int i = Vector<long>.
Count
; i < Vector<int>.
Count
; i++)
3449
upper.SetElementUnsafe(i - Vector<long>.
Count
, value);
3465
for (int i = Vector<short>.
Count
; i < Vector<sbyte>.
Count
; i++)
3468
upper.SetElementUnsafe(i - Vector<short>.
Count
, value);
3483
for (int i = Vector<double>.
Count
; i < Vector<float>.
Count
; i++)
3486
upper.SetElementUnsafe(i - Vector<double>.
Count
, value);
3502
for (int i = Vector<uint>.
Count
; i < Vector<ushort>.
Count
; i++)
3505
upper.SetElementUnsafe(i - Vector<uint>.
Count
, value);
3521
for (int i = Vector<ulong>.
Count
; i < Vector<uint>.
Count
; i++)
3524
upper.SetElementUnsafe(i - Vector<ulong>.
Count
, value);
3541
if ((uint)(index) >= (uint)(Vector<T>.
Count
))
3562
Debug.Assert((index >= 0) && (index < Vector<T>.
Count
));
3570
Debug.Assert((index >= 0) && (index < Vector<T>.
Count
));
src\libraries\System.Private.CoreLib\src\System\Numerics\Vector_1.cs (40)
48
/// <returns>A new <see cref="Vector{T}" /> with its elements set to the first <see cref="Vector{T}.
Count
" /> elements from <paramref name="values" />.</returns>
50
/// <exception cref="ArgumentOutOfRangeException">The length of <paramref name="values" /> is less than <see cref="Vector{T}.
Count
" />.</exception>
56
if (values.Length <
Count
)
67
/// <returns>A new <see cref="Vector{T}" /> with its elements set to the first <see cref="Vector{T}.
Count
" /> elements from <paramref name="values" />.</returns>
69
/// <exception cref="ArgumentOutOfRangeException">The length of <paramref name="values" />, starting from <paramref name="index" />, is less than <see cref="Vector{T}.
Count
" />.</exception>
75
if ((index < 0) || ((values.Length - index) <
Count
))
85
/// <returns>A new <see cref="Vector{T}" /> with its elements set to the first <see cref="Vector{T}.
Count
" /> elements from <paramref name="values" />.</returns>
86
/// <exception cref="ArgumentOutOfRangeException">The length of <paramref name="values" /> is less than <see cref="Vector{T}.
Count
" />.</exception>
92
if (values.Length <
Count
)
110
if (values.Length < Vector<byte>.
Count
)
120
/// <returns>A new <see cref="Vector{T}" /> with its elements set to the first <see cref="Vector{T}.
Count
" /> elements from <paramref name="values" />.</returns>
121
/// <exception cref="ArgumentOutOfRangeException">The length of <paramref name="values" /> is less than <see cref="Vector{T}.
Count
" />.</exception>
158
for (int i = 0; i <
Count
; i++)
230
for (int index = 0; index <
Count
; index++)
253
for (int index = 0; index < Vector<ulong>.
Count
; index++)
276
for (int index = 0; index < Vector<ulong>.
Count
; index++)
295
for (int index = 0; index <
Count
; index++)
314
for (int index = 0; index <
Count
; index++)
331
for (int index = 0; index <
Count
; index++)
355
for (int index = 0; index < Vector<ulong>.
Count
; index++)
470
for (int index = 0; index <
Count
; index++)
489
for (int index = 0; index <
Count
; index++)
524
for (int index = 0; index < Vector<ulong>.
Count
; index++)
543
for (int index = 0; index <
Count
; index++)
562
for (int index = 0; index <
Count
; index++)
613
for (int index = 0; index <
Count
; index++)
625
/// <exception cref="ArgumentException">The length of <paramref name="destination" /> is less than <see cref="Vector{T}.
Count
" />.</exception>
631
if (destination.Length <
Count
)
643
/// <exception cref="ArgumentException">The length of <paramref name="destination" /> is less than <see cref="Vector{T}.
Count
" />.</exception>
655
if ((destination.Length - startIndex) <
Count
)
671
if (destination.Length < Vector<byte>.
Count
)
681
/// <exception cref="ArgumentException">The length of <paramref name="destination" /> is less than <see cref="Vector{T}.
Count
" />.</exception>
685
if (destination.Length <
Count
)
724
for (int index = 0; index <
Count
; index++)
741
for (int index = 0; index <
Count
; index++)
773
for (int i = 1; i <
Count
; i++)
792
if (destination.Length < Vector<byte>.
Count
)
803
/// <returns><c>true</c> if the current instance was successfully copied to <paramref name="destination" />; otherwise, <c>false</c> if the length of <paramref name="destination" /> is less than <see cref="Vector{T}.
Count
" />.</returns>
807
if (destination.Length <
Count
)
824
static int ISimdVector<Vector<T>, T>.ElementCount => Vector<T>.
Count
;
src\libraries\System.Private.CoreLib\src\System\Numerics\VectorDebugView_1.cs (12)
22
var items = new byte[Vector<byte>.
Count
];
32
var items = new double[Vector<double>.
Count
];
42
var items = new short[Vector<short>.
Count
];
52
var items = new int[Vector<int>.
Count
];
62
var items = new long[Vector<long>.
Count
];
72
var items = new nint[Vector<nint>.
Count
];
82
var items = new nuint[Vector<nuint>.
Count
];
92
var items = new sbyte[Vector<sbyte>.
Count
];
102
var items = new float[Vector<float>.
Count
];
112
var items = new ushort[Vector<ushort>.
Count
];
122
var items = new uint[Vector<uint>.
Count
];
132
var items = new ulong[Vector<ulong>.
Count
];
src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector128.Numerics.cs (2)
103
Debug.Assert(Vector<T>.
Count
>= Vector128<T>.Count);
175
Debug.Assert(Vector<T>.
Count
>= Vector128<T>.Count);
src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector256.cs (2)
367
if (Vector<T>.
Count
>= Vector256<T>.Count)
391
if (Vector256<T>.Count >= Vector<T>.
Count
)
src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector512.cs (2)
364
Debug.Assert(Vector512<T>.Count >= Vector<T>.
Count
);
381
Debug.Assert(Vector512<T>.Count >= Vector<T>.
Count
);
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.ByteMemOps.cs (7)
438
if (len >= (nuint)Vector<byte>.
Count
)
442
nuint stopLoopAtOffset = len & (nuint)(nint)(2 * (int)-Vector<byte>.
Count
); // intentional sign extension carries the negative bit
448
if (len >= (uint)(2 * Vector<byte>.
Count
))
453
Unsafe.WriteUnaligned(ref Unsafe.AddByteOffset(ref dest, offset + (nuint)Vector<byte>.
Count
), vector);
454
offset += (uint)(2 * Vector<byte>.
Count
);
463
if ((len & (nuint)Vector<byte>.
Count
) != 0)
474
Unsafe.WriteUnaligned(ref Unsafe.AddByteOffset(ref dest, len - (nuint)Vector<byte>.
Count
), vector);
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.Char.cs (3)
480
if (Vector.IsHardwareAccelerated && minLength >= (nuint)Vector<ushort>.
Count
)
482
nuint nLength = minLength - (nuint)Vector<ushort>.
Count
;
490
i += (nuint)Vector<ushort>.
Count
;
src\libraries\System.Private.CoreLib\src\System\SpanHelpers.T.cs (12)
25
if (sizeof(T) > Vector<byte>.
Count
) { goto CannotVectorize; }
28
if (numElements >= (uint)(Vector<byte>.
Count
/ sizeof(T)))
56
else if (sizeof(T) == Vector<byte>.
Count
)
62
if (Vector<byte>.
Count
== 32)
66
else if (Vector<byte>.
Count
== 64)
78
if (Vector<byte>.
Count
== 64)
96
nuint stopLoopAtOffset = totalByteLength & (nuint)(nint)(2 * (int)-Vector<byte>.
Count
); // intentional sign extension carries the negative bit
103
if (numElements >= (uint)(2 * Vector<byte>.
Count
/ sizeof(T)))
108
Unsafe.WriteUnaligned(ref Unsafe.AddByteOffset(ref refDataAsBytes, offset + (nuint)Vector<byte>.
Count
), vector);
109
offset += (uint)(2 * Vector<byte>.
Count
);
119
if ((totalByteLength & (nuint)Vector<byte>.
Count
) != 0)
131
Unsafe.WriteUnaligned(ref Unsafe.AddByteOffset(ref refDataAsBytes, totalByteLength - (nuint)Vector<byte>.
Count
), vector);
src\libraries\System.Private.CoreLib\src\System\Text\Latin1Utility.cs (6)
45
if (Vector.IsHardwareAccelerated && bufferLength >= 2 * (uint)Vector<ushort>.
Count
)
47
uint SizeOfVectorInChars = (uint)Vector<ushort>.
Count
; // JIT will make this a const
48
uint SizeOfVectorInBytes = (uint)Vector<byte>.
Count
; // JIT will make this a const
614
Vector<ushort> utf16VectorLow = Unsafe.ReadUnaligned<Vector<ushort>>(pUtf16Buffer + currentOffset + Vector<ushort>.
Count
);
1079
uint SizeOfVector = (uint)Vector<byte>.
Count
; // JIT will make this a const
1092
Unsafe.WriteUnaligned(pUtf16Buffer + currentOffset + Vector<ushort>.
Count
, utf16HighVector);
System.ServiceModel.Http (2)
System\ServiceModel\Channels\HttpTransportSecurityHelpers.cs (2)
129
if ((i + Vector<byte>.
Count
) > certRawData.Length)
152
i += Vector<byte>.
Count
;
System.Text.Encodings.Web (2)
System\Text\Encodings\Web\AllowedBmpCodePointsBitmap.cs (2)
78
definedCharsBitmapAsLittleEndian = definedCharsBitmapAsLittleEndian.Slice(Vector<byte>.
Count
);
79
thisAllowedCharactersBitmap = thisAllowedCharactersBitmap.Slice(Vector<uint>.
Count
);