MCPcopy Create free account
hub / github.com/F-Stack/f-stack / ck_epoch_unregister

Function ck_epoch_unregister

freebsd/contrib/ck/src/ck_epoch.c:297–318  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

295}
296
297void
298ck_epoch_unregister(struct ck_epoch_record *record)
299{
300 struct ck_epoch *global = record->global;
301 size_t i;
302
303 record->active = 0;
304 record->epoch = 0;
305 record->n_dispatch = 0;
306 record->n_peak = 0;
307 record->n_pending = 0;
308 memset(&record->local, 0, sizeof record->local);
309
310 for (i = 0; i < CK_EPOCH_LENGTH; i++)
311 ck_stack_init(&record->pending[i]);
312
313 ck_pr_store_ptr(&record->ct, NULL);
314 ck_pr_fence_store();
315 ck_pr_store_uint(&record->state, CK_EPOCH_STATE_FREE);
316 ck_pr_inc_uint(&global->n_free);
317 return;
318}
319
320static struct ck_epoch_record *
321ck_epoch_scan(struct ck_epoch *global,

Callers

nothing calls this directly

Calls 2

memsetFunction · 0.85
ck_stack_initFunction · 0.85

Tested by

no test coverage detected