Skip to content

Commit 2cde843

Browse files
author
Lealem Amedie
committed
Measure max & min durations within the confines of MAX_SAMPLE_RUNS
1 parent 1303c05 commit 2cde843

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

wolfcrypt/benchmark/benchmark.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -254,12 +254,12 @@
254254
}\
255255
else {\
256256
delta = current_time(0) - prev;\
257+
}\
258+
if (runs < MAX_SAMPLE_RUNS) {\
257259
if (max < delta)\
258260
max = delta;\
259261
else if (min > delta)\
260262
min = delta;\
261-
}\
262-
if (runs < MAX_SAMPLE_RUNS) {\
263263
deltas[runs] = delta;\
264264
sum += delta;\
265265
runs++;\

0 commit comments

Comments
 (0)