KirillOsenkov / XmlParser

A Roslyn-inspired full-fidelity XML parser with no dependencies and a simple Visual Studio XML language service
Apache License 2.0
328 stars 49 forks source link

Improve benchmarks #49

Closed DoctorKrolic closed 11 months ago

DoctorKrolic commented 11 months ago

I was actually surprised by the difference between .NET Framework and .NET 8:

BenchmarkDotNet v0.13.10, Windows 11 (10.0.22621.2715/22H2/2022Update/SunValley2)
AMD Ryzen 7 5800X, 1 CPU, 16 logical and 8 physical cores
  [Host]         : .NET Framework 4.8.1 (4.8.9181.0), X64 RyuJIT VectorSize=256
  .NET Framework : .NET Framework 4.8.1 (4.8.9181.0), X64 RyuJIT VectorSize=256
  Modern .NET    : .NET 8.0.0 (8.0.23.53103), X64 RyuJIT AVX2
Method Job Runtime Mean Error StdDev Gen0 Gen1 Gen2 Allocated
ParseLongXml .NET Framework .NET Framework 4.7.2 218.2 us 0.84 us 0.74 us 33.4473 1.2207 - 205.75 KB
ParseLongXml Modern .NET .NET 8.0 127.8 us 0.41 us 0.38 us 11.4746 2.9297 1.2207 188.11 KB