Lines Matching defs:rb_node
75 static int thread_rb_node__cmp_tid(const void *key, const struct rb_node *nd)
79 return to_find - (int)thread__tid(rb_entry(nd, struct thread_rb_node, rb_node)->thread);
86 struct rb_node *nd = rb_find(&to_find, tree, thread_rb_node__cmp_tid);
88 return rb_entry(nd, struct thread_rb_node, rb_node);
121 RB_CLEAR_NODE(&machine->rb_node);
208 RB_CLEAR_NODE(&pos->rb_node);
225 struct rb_node *nd;
233 struct thread_rb_node *trb = rb_entry(nd, struct thread_rb_node, rb_node);
289 struct rb_node **p = &machines->guests.rb_root.rb_node;
290 struct rb_node *parent = NULL;
304 pos = rb_entry(parent, struct machine, rb_node);
313 rb_link_node(&machine->rb_node, parent, p);
314 rb_insert_color_cached(&machine->rb_node, &machines->guests, leftmost);
323 struct rb_node *nd;
328 struct machine *machine = rb_entry(nd, struct machine, rb_node);
336 struct rb_node **p = &machines->guests.rb_root.rb_node;
337 struct rb_node *parent = NULL;
346 machine = rb_entry(parent, struct machine, rb_node);
493 struct rb_node *nd;
496 struct machine *pos = rb_entry(nd, struct machine, rb_node);
503 struct rb_node *node;
510 machine = rb_entry(node, struct machine, rb_node);
623 struct rb_node **p = &threads->entries.rb_root.rb_node;
624 struct rb_node *parent = NULL;
635 th = rb_entry(parent, struct thread_rb_node, rb_node)->thread;
665 rb_link_node(&nd->rb_node, parent, p);
666 rb_insert_color_cached(&nd->rb_node, &threads->entries, leftmost);
676 rb_erase_cached(&nd->rb_node, &threads->entries);
677 RB_CLEAR_NODE(&nd->rb_node);
1074 struct rb_node *nd;
1078 struct machine *pos = rb_entry(nd, struct machine, rb_node);
1094 struct rb_node *nd;
1098 struct machine *pos = rb_entry(nd, struct machine, rb_node);
1126 struct rb_node *nd;
1139 struct thread *pos = rb_entry(nd, struct thread_rb_node, rb_node)->thread;
1296 struct map_rb_node *rb_node;
1303 maps__for_each_entry(kmaps, rb_node) {
1304 struct map *dest_map, *map = rb_node->map;
1437 struct rb_node *next = rb_first_cached(&machines->guests);
1442 struct machine *pos = rb_entry(next, struct machine, rb_node);
1444 next = rb_next(&pos->rb_node);
1445 rb_erase_cached(&pos->rb_node, &machines->guests);
1754 struct map_rb_node *rb_node = maps__find_node(machine__kernel_maps(machine),
1756 struct map_rb_node *next = map_rb_node__next(rb_node);
2070 rb_erase_cached(&nd->rb_node, &threads->entries);
2071 RB_CLEAR_NODE(&nd->rb_node);
3217 struct rb_node *nd;
3225 struct thread_rb_node *trb = rb_entry(nd, struct thread_rb_node, rb_node);
3239 struct rb_node *nd;
3247 struct machine *machine = rb_entry(nd, struct machine, rb_node);