Closed alexeyraspopov closed 3 weeks ago
Sometimes I've got negative loading time :rofl:
Benchmarking is hard…
I've tested some loading using child_process.fork
. Here some results
https://gist.github.com/alexeyten/667e6163777783ed02879a0e3e66dd5d
@alexeyten, seems like your approach looks better, thank you! I'll try a couple of more tests and will update this PR
Benchmarks are quite random by themselves but there are things we must do to make them close to real numbers. As reported in #35, loading benchmark seems rigged because it uses a single process to test the init time of libraries, thus making the last one to test a clear winner.
In this PR I made it so the libraries are being tested via importing them in a separate node processes. It will take longer to test but the results seem to be more coherent. There is still some deviation but moving
picocolors
up and down does not make significant changes (comparing to the reported issue)cc @ai
Closes #35