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)
commit38640c480939d56cc8b03d58642fc5261761a697
tree9b2708cce0705ee8939f5ff85ba982d77cbb3e6e
parentdd3dc5f416b7247a4b5d7bac6698be623c180572
lib/raid6: skip benchmark of non-chosen xor_syndrome functions

In commit fe5cbc6e06c7 ("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