diff options
author | Richard Braun <rbraun@sceen.net> | 2017-02-20 20:46:04 +0100 |
---|---|---|
committer | Richard Braun <rbraun@sceen.net> | 2017-02-20 20:46:04 +0100 |
commit | 257df0fbec0849e8eb3c653346c755344babd6c2 (patch) | |
tree | 9faae2fc730f32342fdb768bf065782d5df6d81a /test | |
parent | dc0906051ac822fe10cd135e600ad896edd51059 (diff) |
test/test_llsync_defer: use a macro to throttle reports
Diffstat (limited to 'test')
-rw-r--r-- | test/test_llsync_defer.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/test/test_llsync_defer.c b/test/test_llsync_defer.c index 954ea390..929ece64 100644 --- a/test/test_llsync_defer.c +++ b/test/test_llsync_defer.c @@ -45,6 +45,8 @@ #include <test/test.h> #include <vm/vm_kmem.h> +#define TEST_LOOPS_PER_PRINT 100000 + struct test_pdsc { struct work work; void *addr; @@ -88,7 +90,7 @@ test_alloc(void *arg) llsync_assign_ptr(test_pdsc, pdsc); condition_signal(&test_condition); - if ((i % 100000) == 0) { + if ((i % TEST_LOOPS_PER_PRINT) == 0) { printk("alloc "); } @@ -137,7 +139,7 @@ test_free(void *arg) condition_signal(&test_condition); - if ((i % 100000) == 0) { + if ((i % TEST_LOOPS_PER_PRINT) == 0) { printk("free "); } @@ -170,7 +172,7 @@ test_read(void *arg) panic("invalid content"); } - if ((i % 100000) == 0) { + if ((i % TEST_LOOPS_PER_PRINT) == 0) { printk("read "); } |