MCPcopy Create free account
hub / github.com/dmlc/dmlc-core / set_all_empty

Method set_all_empty

include/dmlc/concurrentqueue.h:1568–1578  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1566
1567 template<InnerQueueContext context>
1568 inline void set_all_empty() {
1569 if (context == explicit_context && BLOCK_SIZE <= EXPLICIT_BLOCK_EMPTY_COUNTER_THRESHOLD) {
1570 // Set all flags
1571 for (size_t i = 0; i != BLOCK_SIZE; ++i) {
1572 emptyFlags[i].store(true, std::memory_order_relaxed);
1573 }
1574 } else {
1575 // Reset counter
1576 elementsCompletelyDequeued.store(BLOCK_SIZE, std::memory_order_relaxed);
1577 }
1578 }
1579
1580 template<InnerQueueContext context>
1581 inline void reset_empty() {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected