]> git.baikalelectronics.ru Git - kernel.git/commit
lib/raid6: skip benchmark of non-chosen xor_syndrome functions
authorDirk Müller <dmueller@suse.de>
Wed, 5 Jan 2022 16:38:46 +0000 (17:38 +0100)
committerSong Liu <song@kernel.org>
Thu, 6 Jan 2022 16:37:03 +0000 (08:37 -0800)
commitda11e478be1ddf3166a0ad81a733a71312c28fa1
tree9b2708cce0705ee8939f5ff85ba982d77cbb3e6e
parent483e4da1802ed4c9126dc1b33af0423a5b4e09d9
lib/raid6: skip benchmark of non-chosen xor_syndrome functions

In commit 8d58b5ecaea7 ("md/raid6 algorithms: delta syndrome functions")
a xor_syndrome() benchmarking was added also to the raid6_choose_gen()
function. However, the results of that benchmarking were intentionally
discarded and did not influence the choice. It picked the
xor_syndrome() variant related to the best performing gen_syndrome().

Reduce runtime of raid6_choose_gen() without modifying its outcome by
only benchmarking the xor_syndrome() of the best gen_syndrome() variant.

For a HZ=250 x86_64 system with avx2 and without avx512 this removes
5 out of 6 xor() benchmarks, saving 340ms of raid6 initialization time.

Signed-off-by: Dirk Müller <dmueller@suse.de>
Signed-off-by: Song Liu <song@kernel.org>
lib/raid6/algos.c