#include #include #include #include #include #include #include #include #include "fastcommon/skiplist_set.h" #include "fastcommon/logger.h" #include "fastcommon/shared_func.h" #define COUNT 1000000 #define LEVEL_COUNT 16 #define MIN_ALLOC_ONCE 32 #define LAST_INDEX (COUNT - 1) static int *numbers; static SkiplistSet sl; static SkiplistSetIterator iterator; static int instance_count = 0; static void free_test_func(void *ptr) { instance_count--; } static int compare_func(const void *p1, const void *p2) { return *((int *)p1) - *((int *)p2); } void set_rand_numbers(const int multiple) { int i; int tmp; int index1; int index2; for (i=0; i