From: MaximMolchanov Date: Sat, 14 Nov 2020 00:55:29 +0000 (+0200) Subject: Calculate sum from first elements X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=7615e3485e75c2f1715d372f7bb1f546738a5c76;hp=7615e3485e75c2f1715d372f7bb1f546738a5c76 Calculate sum from first elements in affine transform for AVX512/AVX2/SSSE3 The idea is to initialize sum with the first element instead of zero. Reduce one add_epi32 and one set_zero SIMD instructions for each output dimension. sum = 0; for i = 1 to n sum += a[i] -> sum = a[1]; for i = 2 to n sum += a[i] STC: LLR: 2.95 (-2.94,2.94) {-0.25,1.25} Total: 69048 W: 7024 L: 6799 D: 55225 Ptnml(0-2): 260, 5175, 23458, 5342, 289 https://tests.stockfishchess.org/tests/view/5faf2cf467cbf42301d6aa06 closes https://github.com/official-stockfish/Stockfish/pull/3227 No functional change. ---