Update 'Performance'

master
John Zacarias Jekel 1 year ago
parent 8e002e19af
commit 1db1b25cbe
  1. 8
      Performance.md

@ -2,7 +2,7 @@
| Anslatortray Version | Time* in UTF-8 mode (ns) | Time* in ASCII mode (ns) |
| -------- | -------- | -------- |
| main branch | 128.971 | 93.986 |
| main branch | 137.161 | 86.296 |
| 0.4.0 | 128.971 | 93.986 |
| 0.3.0 | 227.462 | N/A |
@ -10,14 +10,14 @@
# Test results for the current Anslatortray main branch
On my dated system with dual Intel(R) Xeon(R) E5-2670 v2 CPUs, the `translate()` function can process one word every **128.971** nanoseconds on average in the default UTF-8 mode, and one word every **93.986** 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 1000 iterations, and then the averages produced were divided by 370105 (the number of words in the file).
On my dated system with dual Intel(R) Xeon(R) E5-2670 v2 CPUs, the `translate()` function can process one word every **137.161** nanoseconds on average in the default UTF-8 mode, and one word every **86.296** 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 1000 iterations, and then the averages produced were divided by 370105 (the number of words in the file).
```
> anslatortray --benchmark-file ./words_alpha.txt 1000
Anslatortray: frontend for the Anslatortray for Rust library
Sucessful: UTF-8 translation took 47732914ns to translate on average over 1000 runs.
Sucessful: ASCII translation took 34784643ns to translate on average over 1000 runs
Sucessful: UTF-8 translation took 50764077ns to translate on average over 1000 runs.
Sucessful: ASCII translation took 31938570ns to translate on average over 1000 runs
```
# Test results for Anslatortray 0.4.0
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.

Loading…
Cancel
Save