Removed unnecessary calls to atomic_add
The polling statistics collection used atomic_add to increment values. This is not an optimal way to update statistical values. Moved to per thread values which are summed up when they are read. Moved the functions used to gather polling statistics to their own file and created a specific data type for statistics.
This commit is contained in:
@ -40,6 +40,7 @@
|
||||
#include <errno.h>
|
||||
#include <poll.h>
|
||||
#include <dcb.h>
|
||||
#include <test_utils.h>
|
||||
|
||||
/**
|
||||
* test1 Allocate a service and do lots of other things
|
||||
@ -56,6 +57,7 @@ int result;
|
||||
/* Poll tests */
|
||||
ss_dfprintf(stderr,
|
||||
"testpoll : Initialise the polling system.");
|
||||
init_test_env(NULL);
|
||||
poll_init();
|
||||
ss_dfprintf(stderr, "\t..done\nAdd a DCB");
|
||||
dcb = dcb_alloc(DCB_ROLE_REQUEST_HANDLER);
|
||||
|
||||
Reference in New Issue
Block a user