Allocate the next buffer-local or shared-atomic ID. */
| 262 | |
| 263 | /* Allocate the next buffer-local or shared-atomic ID. */ |
| 264 | static int64_t alloc_next_id(cbm_gbuf_t *gb) { |
| 265 | if (gb->shared_ids) { |
| 266 | return atomic_fetch_add_explicit(gb->shared_ids, SKIP_ONE, memory_order_relaxed); |
| 267 | } |
| 268 | return gb->next_id++; |
| 269 | } |
| 270 | |
| 271 | /* Swap-remove an edge from a pointer array by ID. */ |
| 272 | static void remove_edge_from_ptr_array(edge_ptr_array_t *arr, int64_t edge_id) { |
no outgoing calls
no test coverage detected