Closed curlup closed 5 years ago
I've improved my result but still building trie takes more time/ops/mem than current impl
$ go test -bench . -benchtime 4s -benchmem
TieKeys-4 1000000 4616 ns/op 565 B/op 7 allocs/op
PrefixSearch-4 30000 217131 ns/op 33710 B/op 16 allocs/op
FuzzySearch-4 1000 5641379 ns/op 480559 B/op 5065 allocs/op
BuildTree-4 30 188456008 ns/op 70782355 B/op 1011021 allocs/op
PASS
Merged via another PR.
Was
And now its
It's better than #16, but there's additional memory footprint and time to build trie.