Add benchmarks for ISet<T> (de)serialization and general framework fo…#540
Add benchmarks for ISet<T> (de)serialization and general framework fo…#540adamsitnik merged 3 commits intodotnet:masterfrom
Conversation
…r generic collections
|
|
||
| namespace System.Text.Json.Serialization.Tests | ||
| { | ||
| public class WriteGenericCollection |
There was a problem hiding this comment.
File mismatch. ReadJson.X has the test for Write and vice versa.
There was a problem hiding this comment.
Is there another commit coming that resolves this @layomia ?
| } | ||
|
|
||
| [Benchmark] | ||
| public ISet<string> DeserializeISet() |
There was a problem hiding this comment.
Please share the perf results of any new tests added within the PR you add them in.
Nevermind, I see it in the PR: dotnet/corefx#38210
There was a problem hiding this comment.
Looking at the Error/Std Dev of some of the results shared, I recommend commenting out the RecommendedConfig before running the tests locally to improve accuracy.
For example, this is quite inaccurate:
| DeserializeISet | 2 | 21,030.9 ns | 3,649.67 ns | 10,412.72 ns |
|---|
|
@layomia similar to other stale PRs (#478, #530, #589) I have cloned your fork, updated the code and pushed some fixes. I need to make sure that we don't regress it for 3.0. PTAL at my changes dotnet run -c Release -f netcoreapp3.0 --filter *WriteJson<*Set*>* *ReadJson<*Set*>* --joinBenchmarkDotNet=v0.11.3.1003-nightly, OS=Windows 10.0.18362
Intel Xeon CPU E5-1650 v4 3.60GHz, 1 CPU, 12 logical and 6 physical cores
.NET Core SDK=3.0.100-preview7-012697
[Host] : .NET Core 3.0.0-preview7-27826-20 (CoreCLR 4.700.19.32603, CoreFX 4.700.19.32613), 64bit RyuJIT
Job-KNHVRD : .NET Core 3.0.0-preview7-27826-20 (CoreCLR 4.700.19.32603, CoreFX 4.700.19.32613), 64bit RyuJIT
IterationTime=250.0000 ms MaxIterationCount=20 MinIterationCount=15
WarmupCount=1
|
|
@adamsitnik LGTM, thanks! |
…r generic collections
cc @ahsonkhan, @steveharter, @adamsitnik , @billwert