MCPcopy Create free account
hub / github.com/apache/cloudberry / groupWaitQueueIsEmpty

Function groupWaitQueueIsEmpty

src/backend/utils/resgroup/resgroup.c:2521–2533  ·  view source on GitHub ↗

* Check whether the resgroup wait queue is empty. */

Source from the content-addressed store, hash-verified

2519 * Check whether the resgroup wait queue is empty.
2520 */
2521static bool
2522groupWaitQueueIsEmpty(const ResGroupData *group)
2523{
2524 const PROC_QUEUE *waitQueue;
2525
2526 Assert(LWLockHeldByMeInMode(ResGroupLock, LW_EXCLUSIVE));
2527
2528 groupWaitQueueValidate(group);
2529
2530 waitQueue = &group->waitProcs;
2531
2532 return waitQueue->size == 0;
2533}
2534
2535#ifdef USE_ASSERT_CHECKING
2536/*

Callers 4

wakeupSlotsFunction · 0.85
groupWaitCancelFunction · 0.85
groupWaitQueuePopFunction · 0.85
groupWaitQueueEraseFunction · 0.85

Calls 2

LWLockHeldByMeInModeFunction · 0.85
groupWaitQueueValidateFunction · 0.85

Tested by

no test coverage detected