Closed talex5 closed 5 months ago
The Buf_read benchmark created a large string at start-up using String.init, which adds about 170ms to the start-up time of all benchmarks. Now, only create the string when running that benchmark, and use the more efficient String.make.
String.init
String.make
Before:
After:
The Buf_read benchmark created a large string at start-up using
String.init
, which adds about 170ms to the start-up time of all benchmarks. Now, only create the string when running that benchmark, and use the more efficientString.make
.Before:![before](https://github.com/ocaml-multicore/eio/assets/554131/ba540dc7-1193-4301-bdef-6d8cc0e66723)
After:![after](https://github.com/ocaml-multicore/eio/assets/554131/322213b3-c354-42cc-a1bb-c91e20fad917)