one more scope for benchmarks
This commit is contained in:
parent
4572f5cb55
commit
6ff8ff66d1
1 changed files with 9 additions and 6 deletions
|
@ -25,15 +25,18 @@ typedef struct {
|
||||||
|
|
||||||
|
|
||||||
#define BENCHMARK(name) \
|
#define BENCHMARK(name) \
|
||||||
bench B; B.N = 5000000; B.R = 3; \
|
{ \
|
||||||
bench_start(&B); \
|
bench B; B.N = 5000000; B.R = 3; \
|
||||||
for (int _r = 0; _r < B.R ; _r++ ) { \
|
bench_start(&B); \
|
||||||
for (int _i = 0; _i < B.N ; _i++ ) {
|
for (int _r = 0; _r < B.R ; _r++ ) { \
|
||||||
|
for (int _i = 0; _i < B.N ; _i++ ) {
|
||||||
|
|
||||||
#define END_BENCHMARK() \
|
#define END_BENCHMARK() \
|
||||||
|
} \
|
||||||
} \
|
} \
|
||||||
} \
|
bench_stop(&B); \
|
||||||
bench_stop(&B);
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
long unixtime();
|
long unixtime();
|
||||||
|
|
Loading…
Reference in a new issue