-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
87 changed files
with
556 additions
and
1,460 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
using BenchmarkDotNet.Configs; | ||
using BenchmarkDotNet.Filters; | ||
using System.Collections.Generic; | ||
|
||
namespace Benchmark | ||
{ | ||
public class BenchConfig : ManualConfig | ||
{ | ||
public const string ZLib = "ZLib"; | ||
public const string XZ = "XZ"; | ||
public const string LZ4 = "LZ4"; | ||
|
||
public BenchConfig() | ||
{ | ||
switch (Program.Opts.Algorithms) | ||
{ | ||
case AlgorithmFlags.None: | ||
case AlgorithmFlags.All: | ||
return; | ||
} | ||
|
||
List<string> categories = new List<string>(); | ||
if (Program.Opts.Algorithms.HasFlag(AlgorithmFlags.ZLib)) | ||
categories.Add(ZLib); | ||
else if (Program.Opts.Algorithms.HasFlag(AlgorithmFlags.XZ)) | ||
categories.Add(XZ); | ||
else if (Program.Opts.Algorithms.HasFlag(AlgorithmFlags.LZ4)) | ||
categories.Add(LZ4); | ||
|
||
AddFilter(new AnyCategoriesFilter(categories.ToArray())); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.