-
Notifications
You must be signed in to change notification settings - Fork 0
Speed measurement
Baterka edited this page Jan 3, 2020
·
4 revisions
- Comparison between single-threaded and multithreaded counting.
- The test was performed on computer with an Intel Core i7-8700 CPU (6C/12T) and 16GB DDR4 RAM.
- Measured against commit: 213d23e
- Input files for test were generated by
generator.cpp
- Every test result is averaged from 3 test runs.
- All tests were done on Release build
- Measuring one input file is meaningless because of implementation (One thread is processing one file).
- Test case: 2 input files, 1M words
-
Files generated by:
./Generator 1000000 1000000 -r 1 10
-
Words counted by:
./WordCount words1.txt words2.txt -of output.txt [-mt]
-
Results:
- ST: 2353ms
- MT: 1679ms (1,40x faster)
- Test case: 6 input files, ~500K words
-
Files generated by:
./Generator 450000 475000 500000 510000 525000 550000 -r 1 10
-
Words counted by:
./WordCount words1.txt words2.txt words3.txt ... -of output.txt [-mt]
-
Results:
- ST: 3185ms
- MT: 1720ms (1,85x faster)
(Same as Test 2, but counting trigrams.)
-
Results:
- ST: 5054ms
- MT: 3144ms (1,60x faster)