Lines Matching +full:0 +full:xa

15 static int item_insert_order(struct xarray *xa, unsigned long index,  in item_insert_order()  argument
18 XA_STATE_ORDER(xas, xa, index, order); in item_insert_order()
28 return 0; in item_insert_order()
34 void multiorder_iteration(struct xarray *xa) in multiorder_iteration() argument
36 XA_STATE(xas, xa, 0); in multiorder_iteration()
41 int index[NUM_ENTRIES] = {0, 2, 4, 8, 16, 32, 34, 36, 64, 72, 128}; in multiorder_iteration()
42 int order[NUM_ENTRIES] = {1, 1, 2, 3, 4, 1, 0, 1, 3, 0, 7}; in multiorder_iteration()
46 for (i = 0; i < NUM_ENTRIES; i++) { in multiorder_iteration()
47 err = item_insert_order(xa, index[i], order[i]); in multiorder_iteration()
51 for (j = 0; j < 256; j++) { in multiorder_iteration()
52 for (i = 0; i < NUM_ENTRIES; i++) in multiorder_iteration()
71 item_kill_tree(xa); in multiorder_iteration()
74 void multiorder_tagged_iteration(struct xarray *xa) in multiorder_tagged_iteration() argument
76 XA_STATE(xas, xa, 0); in multiorder_tagged_iteration()
81 int index[MT_NUM_ENTRIES] = {0, 2, 4, 16, 32, 40, 64, 72, 128}; in multiorder_tagged_iteration()
82 int order[MT_NUM_ENTRIES] = {1, 0, 2, 4, 3, 1, 3, 0, 7}; in multiorder_tagged_iteration()
85 int tag_index[TAG_ENTRIES] = {0, 4, 16, 40, 64, 72, 128}; in multiorder_tagged_iteration()
89 for (i = 0; i < MT_NUM_ENTRIES; i++) in multiorder_tagged_iteration()
90 assert(!item_insert_order(xa, index[i], order[i])); in multiorder_tagged_iteration()
92 assert(!xa_marked(xa, XA_MARK_1)); in multiorder_tagged_iteration()
94 for (i = 0; i < TAG_ENTRIES; i++) in multiorder_tagged_iteration()
95 xa_set_mark(xa, tag_index[i], XA_MARK_1); in multiorder_tagged_iteration()
97 for (j = 0; j < 256; j++) { in multiorder_tagged_iteration()
100 for (i = 0; i < TAG_ENTRIES; i++) { in multiorder_tagged_iteration()
122 assert(tag_tagged_items(xa, 0, ULONG_MAX, TAG_ENTRIES, XA_MARK_1, in multiorder_tagged_iteration()
125 for (j = 0; j < 256; j++) { in multiorder_tagged_iteration()
128 for (i = 0; i < TAG_ENTRIES; i++) { in multiorder_tagged_iteration()
149 assert(tag_tagged_items(xa, 1, ULONG_MAX, MT_NUM_ENTRIES * 2, XA_MARK_1, in multiorder_tagged_iteration()
151 i = 0; in multiorder_tagged_iteration()
152 xas_set(&xas, 0); in multiorder_tagged_iteration()
159 item_kill_tree(xa); in multiorder_tagged_iteration()
171 for (i = 0; i < 10000; i++) { in creator_func()
172 item_insert_order(tree, 0, order); in creator_func()
173 item_delete_rcu(tree, 0); in creator_func()
182 XA_STATE(xas, ptr, 0); in iterator_func()
198 static void multiorder_iteration_race(struct xarray *xa) in multiorder_iteration_race() argument
204 pthread_create(&worker_thread[0], NULL, &creator_func, xa); in multiorder_iteration_race()
206 pthread_create(&worker_thread[i], NULL, &iterator_func, xa); in multiorder_iteration_race()
208 for (i = 0; i < num_threads; i++) in multiorder_iteration_race()
211 item_kill_tree(xa); in multiorder_iteration_race()
222 radix_tree_cpu_dead(0); in multiorder_checks()
229 return 0; in main()