Skip to content

Commit

Permalink
Updates the README
Browse files Browse the repository at this point in the history
  • Loading branch information
aserebryakov committed Jul 9, 2018
1 parent 9a6931c commit 28c0e07
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,23 +41,23 @@ assert_eq!(t.get_value("none".chars()), None);
# Benchmarks

Benchmark `std::HashMap<String, String>` vs `gtrie::Trie` shows that `Trie` is
faster in the case of key mismatch but significantly slower in the case of
significantly faster in the case of key mismatch but significantly slower in the case of
matching key.

```
$ cargo bench
test hash_map_massive_match ... bench: 157,555 ns/iter (+/- 15,801)
test hash_map_massive_mismatch_on_0 ... bench: 95,770 ns/iter (+/- 5,632)
test hash_map_massive_mismatch_on_0_one_symbol_key ... bench: 97,157 ns/iter (+/- 5,428)
test hash_map_match ... bench: 24 ns/iter (+/- 1)
test hash_map_mismatch ... bench: 21 ns/iter (+/- 1)
test trie_massive_match ... bench: 332,543 ns/iter (+/- 15,031)
test trie_massive_mismatch_on_0 ... bench: 54,408 ns/iter (+/- 4,148)
test trie_massive_mismatch_on_1 ... bench: 54,255 ns/iter (+/- 4,052)
test trie_massive_mismatch_on_2 ... bench: 53,679 ns/iter (+/- 4,907)
test trie_massive_mismatch_on_3 ... bench: 54,131 ns/iter (+/- 3,305)
test trie_match ... bench: 42 ns/iter (+/- 2)
test trie_mismatch ... bench: 17 ns/iter (+/- 0)
test hash_map_massive_match ... bench: 150,127 ns/iter (+/- 12,986)
test hash_map_massive_mismatch_on_0 ... bench: 93,246 ns/iter (+/- 5,108)
test hash_map_massive_mismatch_on_0_one_symbol_key ... bench: 93,706 ns/iter (+/- 5,908)
test hash_map_match ... bench: 24 ns/iter (+/- 3)
test hash_map_mismatch ... bench: 20 ns/iter (+/- 0)
test trie_massive_match ... bench: 231,343 ns/iter (+/- 4,940)
test trie_massive_mismatch_on_0 ... bench: 28,743 ns/iter (+/- 8,401)
test trie_massive_mismatch_on_1 ... bench: 28,734 ns/iter (+/- 1,839)
test trie_massive_mismatch_on_2 ... bench: 28,760 ns/iter (+/- 2,582)
test trie_massive_mismatch_on_3 ... bench: 28,829 ns/iter (+/- 2,504)
test trie_match ... bench: 10 ns/iter (+/- 1)
test trie_mismatch ... bench: 5 ns/iter (+/- 0)
```

## Important
Expand All @@ -82,6 +82,8 @@ Source code and issues are hosted on GitHub:

#### 0.4.0

* Significant performance improvement due to switch to data oriented model

#### 0.3.0

* Significantly improved performance of the key mismatch case
Expand Down

0 comments on commit 28c0e07

Please sign in to comment.