raid: fix buffer size calculation in perf app

Number of destination buffers are already included in the calculation
of the buffer size for cold cache test.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
This commit is contained in:
Pablo de Lara
2025-10-23 07:28:00 +00:00
committed by Marcel Cornu
parent 4bf531b403
commit 05ce17683f

View File

@@ -135,8 +135,7 @@ run_benchmark(void *buffs[], const size_t len, const int num_sources_dest, const
// Create list of random buffer addresses within the large memory space for cold cache tests // Create list of random buffer addresses within the large memory space for cold cache tests
if (use_cold_cache) { if (use_cold_cache) {
const size_t buffer_size_each = const size_t buffer_size_each = COLD_CACHE_TEST_MEM / num_sources_dest;
COLD_CACHE_TEST_MEM / (num_sources_dest + 2); // +2 for max buffers needed
const size_t num_buffer_sets = buffer_size_each / len; const size_t num_buffer_sets = buffer_size_each / len;
if (num_buffer_sets == 0) { if (num_buffer_sets == 0) {