fast-replace/go-fast-replace
2023-12-31 18:18:29 +01:00
..
2023-12-31 18:18:29 +01:00
2023-12-30 22:35:09 +01:00
2023-12-31 18:18:29 +01:00
2023-12-30 22:35:09 +01:00
2023-12-30 22:40:16 +01:00
2023-12-30 22:42:14 +01:00

Go Fast Replace

An implementation in Go.

To build

make build

To run

make run

To test

make test

Conclusions

Replace

Current implementations:

Results

  • bm varies a lot, but is never over 460µs.
  • cw is a lot slower, at around 3.5ms, but it can search for multiple patterns at once.
$ make run
./bin/corpus
Creating corpus...
./bin/pairs
Creating pairs...
./bin/replace

bm: 273.621µs

cw: 2.939254ms

Todo: