diff --git a/src/asm/testbench.c b/src/asm/testbench.c index d1ad81f..12d2af2 100644 --- a/src/asm/testbench.c +++ b/src/asm/testbench.c @@ -202,7 +202,7 @@ int Test10_LoadStore() #define NUM_ELEMENTS 20 -#define NUM_RUNS 3 +#define NUM_RUNS 1 int Test11_AddSub() { int buf[NUM_ELEMENTS], result, i, j, diff, fill, num_right_elements, num_right_runs; @@ -242,24 +242,21 @@ int Test12_MulDiv() div_t div_res; srand(0x19701031); - for (i=0; i < 100; i++) + for (i=0; i < NUM_RUNS; i++) { - for (j=1; j < 1000; j++) - { - mix = (int)rand(); - mix = (mix << 8) ^ (mix << 16); - s1 = (int)rand() ^ mix; - mix = (int)rand(); - mix = (mix << 8) ^ (mix << 16); - s2 = (int)rand() ^ mix; + mix = (int)rand(); + mix = (mix << 8) ^ (mix << 16); + s1 = (int)rand() ^ mix; + mix = (int)rand(); + mix = (mix << 8) ^ (mix << 16); + s2 = (int)rand() ^ mix; - div_res = div(s1, s2); + div_res = div(s1, s2); - sp = s2*div_res.quot; - st = div_res.rem + sp; - if (st != s1) - return TEST12_ERROR; - } + sp = s2*div_res.quot; + st = div_res.rem + sp; + if (st != s1) + return TEST12_ERROR; } return NO_ERROR; }