MCPcopy Create free account
hub / github.com/build2/build2 / unlock_impl

Function unlock_impl

libbuild2/algorithm.cxx:358–372  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

356 }
357
358 void
359 unlock_impl (action a, target& t, size_t offset)
360 {
361 context& ctx (t.ctx);
362
363 assert (ctx.phase == run_phase::match);
364
365 atomic_count& task_count (t[a].task_count);
366
367 // Set the task count and wake up any threads that might be waiting for
368 // this target.
369 //
370 task_count.store (offset + ctx.count_base (), memory_order_release);
371 ctx.sched->resume (task_count);
372 }
373
374 target&
375 add_adhoc_member (target& t,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected