diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2024-04-11 08:55:21 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2024-04-11 21:40:00 +0200 |
commit | c362121f04ffe72eed17126affc9129bbb354c49 (patch) | |
tree | 3a0918ca5f11bb961d465211a49bd4ecdf3659ac /src/CMakeLists.txt | |
parent | 9157adfe80dff953687ec364cc612cf45f2b9609 (diff) |
rewrite bitmask impl
It's slower than the previous version but fixes a bug when stride isn't
a multiple of 8.
It can be improved further by setting `auto& byte` all at once instead
of setting individual bits of multiple bytes in the innermost loop.
------------------------------------------------------------
New version Time CPU Iterations
------------------------------------------------------------
Bitmask_mean 1911 us 1893 us 5
Bitmask_median 1911 us 1885 us 5
Bitmask_stddev 2.00 us 18.7 us 5
Bitmask_cv 0.10 % 0.99 % 5
-------------------------------------------------------------
------------------------------------------------------------
Buggy version Time CPU Iterations
------------------------------------------------------------
Bitmask_mean 841 us 841 us 5
Bitmask_median 839 us 837 us 5
Bitmask_stddev 3.29 us 7.80 us 5
Bitmask_cv 0.39 % 0.93 % 5
------------------------------------------------------------
-----------------------------------------------------------
Naive version Time CPU Iterations
------------------------------------------------------------
Bitmask_mean 4006 us 3997 us 10
Bitmask_median 4006 us 3997 us 10
Bitmask_stddev 2.29 us 0.000 us 10
Bitmask_cv 0.06 % 0.00 % 10
------------------------------------------------------------
Diffstat (limited to 'src/CMakeLists.txt')
0 files changed, 0 insertions, 0 deletions