3 instantiations of XxHash128
Microsoft.CodeAnalysis.Workspaces (1)
Workspace\Solution\Checksum_Factory.cs (1)
24new(() => new(), size: 20);
Microsoft.CodeAnalysis.Workspaces.UnitTests (2)
XxHash128Tests.cs (2)
98new XxHash128(test.Seed) : 99new XxHash128();
21 references to XxHash128
Microsoft.CodeAnalysis.Workspaces (6)
src\Compilers\Core\Portable\Hashing\XxHash128.cs (2)
37/// <summary>Initializes a new instance of the <see cref="XxHash128"/> class using the default seed value 0.</summary> 42/// <summary>Initializes a new instance of the <see cref="XxHash128"/> class using the specified seed.</summary>
Workspace\Solution\Checksum_Factory.cs (4)
23private static readonly ObjectPool<XxHash128> s_incrementalHashPool = 64XxHash128.Hash(MemoryMarshal.AsBytes(value.AsSpan()), destination); 113XxHash128.Hash(MemoryMarshal.AsBytes(hashes), destination); 166XxHash128.Hash(source, destination);
Microsoft.CodeAnalysis.Workspaces.UnitTests (14)
XxHash128Tests.cs (14)
22Assert.Throws<ArgumentNullException>("source", () => XxHash128.Hash(null)); 23Assert.Throws<ArgumentNullException>("source", () => XxHash128.Hash(null, 42)); 25Assert.Throws<ArgumentException>("destination", () => XxHash128.Hash(new byte[] { 1, 2, 3 }, new byte[7])); 43Assert.Equal(expectedHash128, ReadHashBigEndian(XxHash128.Hash(input))); 44Assert.Equal(expectedHash128, ReadHashBigEndian(XxHash128.Hash((ReadOnlySpan<byte>)input))); 46Assert.Equal(expectedHash128, ReadHashBigEndian(XxHash128.Hash(input, test.Seed))); 47Assert.Equal(expectedHash128, ReadHashBigEndian(XxHash128.Hash((ReadOnlySpan<byte>)input, test.Seed))); 53Assert.False(XxHash128.TryHash(input, destination.AsSpan(0, destination.Length - 1), out int bytesWritten, test.Seed)); 60Assert.True(XxHash128.TryHash(input, destination, out bytesWritten)); 65Assert.True(XxHash128.TryHash(input, destination, out bytesWritten, test.Seed)); 73Assert.Equal(16, XxHash128.Hash(input, destination)); 77Assert.Equal(16, XxHash128.Hash(input, destination, test.Seed)); 97XxHash128 hash = ctorIteration == 0 ? 122Assert.Equal(16, XxHash128.Hash(asciiBytes.AsSpan(0, processed), destination2, test.Seed));
Roslyn.VisualStudio.Next.UnitTests (1)
UnifiedSettings\UnifiedSettingsTests.cs (1)
283var expectedTags = BitConverter.ToInt64([.. XxHash128.Hash(fileBytes).Take(8)], 0).ToString("X16");