Update 'Performance'

master
John Zacarias Jekel 1 year ago
parent 5c4f003f4d
commit 062a6be8b7
  1. 10
      Performance.md

@ -1,13 +1,17 @@
# Test results for the current Anslatortray main branch
From Anslatortray 0.3.0 to 0.4.0, the various included programs were consolidated into a single `anslatortray` binary. In addition, this binary recieved a new feature `--benchmark-file`, which makes it much easier to evaluate the time it takes to translate a particular file.
From Anslatortray 0.3.0 to 0.4.0, the various included programs were consolidated into a single `anslatortray` binary. In addition, this binary recieved a new option `--benchmark-file`, which makes it much easier to evaluate the time it takes to translate a particular file.
On my dated system with dual Intel(R) Xeon(R) E5-2670 v2 CPUs, the `translate()` function can process one word every TODO nanoseconds on average in the default UTF-8 mode, and one word every TODO nanoseconds on average in the ASCII-only mode. The `words_alpha.txt` file from <https://github.com/dwyl/english-words> was fed to the `anslatortray --benchmark-file` set to 10000 iterations.
TODO
Although `cargo bench --features nightly-features` benchmarks are still supported, I am no longer including them
# Test results for Anslatortray 0.4.0
TODO
TODO (not released yet)
# Test results for Anslatortray 0.3.0
On my dated system with dual Intel(R) Xeon(R) E5-2670 v2 CPUs, the `translate()` function can process one word every 227.462 nanoseconds on average.
I tested this by feeding the words_alpha.txt file from <https://github.com/dwyl/english-words> to anslatetray-file 10 times, calculating the average runtime,
I tested this by feeding the `words_alpha.txt` file from <https://github.com/dwyl/english-words> to `anslatetray-file` 10 times, calculating the average runtime,
and dividing by 370105 (the number of words in the file). The times do not including loading from and writing to the disk.
Note that raw calls to `translate_word()` would be faster, but `translate()` has to be smart enough to preserve symbols and whitespace surrounding each word, while still accounting for contractions and other edge-cases.

Loading…
Cancel
Save