Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Bench/Bench.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
Expand Down
15 changes: 0 additions & 15 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
@@ -1,20 +1,5 @@
<Project>
<ItemGroup>
<PackageReference Update="Fody" Version="6.0.8">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Update="LocalsInit.Fody" Version="1.1.0">
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Update="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.8">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Update="Microsoft.CodeQuality.Analyzers" Version="2.9.8">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Update="Microsoft.SourceLink.GitHub" Version="1.0.0" PrivateAssets="All" />
<PackageReference Update="coverlet.collector" Version="1.2.0">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
Expand Down
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ VxSort is based on the following ideas/papers:

VxSort uses the following projects:

* [**`Fody`**](https://github.com/Fody/Fody) by the Fody developers.
* [**`LocalsInit.Fody`**](https://github.com/ltrzesniewski/LocalsInit.Fody/tree/master/src) for getting rid of `.locals init` by [Lucas Trzesniewski](https://github.com/ltrzesniewski)
* The Logo `sort` by Markus from the Noun Project

## Author
Expand Down
16 changes: 6 additions & 10 deletions Test/DataGeneration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,14 @@ internal static (int[] randomData, int[] sortedData, string reproContext) Genera
Array.Sort(sorted);
}

var reproContext = "";
Span<byte> hash = stackalloc byte[20];
SHA1.HashData(MemoryMarshal.Cast<int, byte>(new ReadOnlySpan<int>(data)), hash);
var dataHash = Convert.ToBase64String(hash);
SHA1.HashData(MemoryMarshal.Cast<int, byte>(new ReadOnlySpan<int>(sorted)), hash);
var sortedHash = Convert.ToBase64String(hash);

using (var sha1 = new SHA1CryptoServiceProvider()) {
Span<byte> hash = stackalloc byte[20];
sha1.TryComputeHash(MemoryMarshal.Cast<int, byte>(new ReadOnlySpan<int>(data)), hash, out _);
var dataHash = Convert.ToBase64String(hash);
sha1.TryComputeHash(MemoryMarshal.Cast<int, byte>(new ReadOnlySpan<int>(sorted)), hash, out _);
var sortedHash = Convert.ToBase64String(hash);
var reproContext = $"[{size},{seed}] -> [{dataHash},{sortedHash}]";

reproContext = $"[{size},{seed}] -> [{dataHash},{sortedHash}]";
}

return (data, sorted, reproContext);
}
}
Expand Down
2 changes: 1 addition & 1 deletion Test/Test.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="coverlet.collector" />
Expand Down
4 changes: 0 additions & 4 deletions VxSort/FodyWeavers.xml

This file was deleted.

34 changes: 0 additions & 34 deletions VxSort/FodyWeavers.xsd

This file was deleted.

1 change: 0 additions & 1 deletion VxSort/InternalsVisibleTo.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using System.Runtime.CompilerServices;
using LocalsInit;

[assembly: InternalsVisibleTo("Test")]
[assembly: InternalsVisibleTo("Bench")]
Expand Down
4 changes: 2 additions & 2 deletions VxSort/LocalsInit.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using LocalsInit;
using System.Runtime.CompilerServices;

[assembly: LocalsInit(false)]
[module: SkipLocalsInit]

6 changes: 1 addition & 5 deletions VxSort/VxSort.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<Title>VxSort</Title>
<Authors>damageboy</Authors>
Expand All @@ -22,10 +22,6 @@
<PackageIconUrl>..\vxsort.png</PackageIconUrl>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Fody" />
<PackageReference Include="LocalsInit.Fody" />
<PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" />
<PackageReference Include="Microsoft.CodeQuality.Analyzers" />
<PackageReference Include="Microsoft.SourceLink.GitHub" />
</ItemGroup>
<ItemGroup>
Expand Down