.NET: 100,000 rows, mean time
10 columns per row: integers, strings (one unique per row), floats, a date/time and a boolean, written to a MemoryStream
- Hypaxel, typed Write78 ms, best
- Hypaxel, AddRowAsync76 ms, best
- Hypaxel, object mapping80 ms, 1.1×
- Hypaxel, shared strings89 ms, 1.2×
- SpreadCheetah75 ms, best
- ClosedXML1,845 ms, 25×
| Case | .NET 8 | .NET 9 | .NET 10 | .NET 11 |
|---|---|---|---|---|
| Hypaxel, typed Write | 122 ms | 78 ms | 78 ms | 74 ms |
| Hypaxel, AddRowAsync | 127 ms | 87 ms | 76 ms | 75 ms |
| Hypaxel, object mapping | 118 ms | 78 ms | 80 ms | 75 ms |
| Hypaxel, shared strings | 159 ms | 97 ms | 89 ms | 90 ms |
| SpreadCheetah | 123 ms | 79 ms | 75 ms | 74 ms |
| ClosedXML | 2,369 ms | 1,910 ms | 1,845 ms | 1,773 ms |
- Hardware
- Apple M1 Max, 10 cores, macOS 26.6
- Runtime
- .NET 8.0.34, 9.0.23, 10.0.15 and 11.0.0
- Compared with
- SpreadCheetah 1.29.0, ClosedXML 0.105.1, BenchmarkDotNet 0.15.8
- Method
- BenchmarkDotNet ShortRun, in-process toolchain.
- Hypaxel and SpreadCheetah are within measurement noise of each other; both are roughly 20 to 25 times faster than ClosedXML.
- .NET 8 is the slowest target and allocates more per workbook.
- --inProcess is required on .NET 11, which BenchmarkDotNet 0.15.8 does not recognise otherwise.
cd dotnet/benchmarks/Hypaxel.Benchmarks
dotnet run -c Release -f net10.0 -- --filter '*' --job short --inProcess