Skip to content

Commit 00c936c

Browse files
committed
Only change WC_BENCH_MAX_LINE_LEN when we need to
1 parent d87ca70 commit 00c936c

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

wolfcrypt/benchmark/benchmark.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@
242242

243243
/* define the max length for each string of metric reported */
244244
#ifndef WC_BENCH_MAX_LINE_LEN
245-
#define WC_BENCH_MAX_LINE_LEN 240
245+
#define WC_BENCH_MAX_LINE_LEN 150
246246
#endif
247247

248248
/* default units per second. See WOLFSSL_BENCHMARK_FIXED_UNITS_* to change */
@@ -264,6 +264,12 @@
264264
#define WC_BENCH_STACK_TRACKING
265265
#endif
266266

267+
#if (defined(WC_BENCH_HEAP_TRACKING) || defined(WC_BENCH_STACK_TRACKING)) && \
268+
(WC_BENCH_MAX_LINE_LEN < 240)
269+
#undef WC_BENCH_MAX_LINE_LEN
270+
#define WC_BENCH_MAX_LINE_LEN 240
271+
#endif
272+
267273
#if defined(WC_BENCH_HEAP_TRACKING) || defined(WC_BENCH_STACK_TRACKING)
268274
#include <wolfssl/wolfcrypt/mem_track.h>
269275
#endif

0 commit comments

Comments
 (0)