Lines Matching defs:work
57 struct work
68 struct work *w_next; /* next in queue */
71 typedef struct work WORK;
74 static int NumWorkGroups; /* number of work groups */
100 ** Each work group contains one or more queue groups. This is done
103 ** The number of queue groups that can be run on the next work run
109 int wg_numqgrp; /* number of queue groups in work grp */
121 static WORKGRP volatile WorkGrp[MAXWORKGROUPS + 1]; /* work groups */
604 ** Output future work requests.
1151 ** MARK_WORK_GROUP_RESTART -- mark a work group as needing a restart
1156 ** wgrp -- the work group id to restart.
1183 ** RESTART_MARKED_WORK_GROUPS -- restart work groups marked as needing restart
1227 ** RESTART_WORK_GROUP -- restart a specific work group
1230 ** If the requested work group has been restarted too many times log
1234 ** wgrp -- the work group id to restart
1240 ** starts another process doing the work of wgrp
1268 ** SCHEDULE_QUEUE_RUNS -- schedule the next queue run for a work group.
1272 ** wgrp -- the work group id to schedule.
1273 ** didit -- the queue run was performed for this work group.
1299 ** code that "walks" through a work queue group.
1505 ** i.e., this work group might "starve" then.
1633 ** RUNNER_WORK -- have a queue runner do its work
1635 ** Have a queue runner do its work a list of entries.
1636 ** When work isn't directly being done then this process can take a signal
1638 ** When work is directly being done, it's not to be interrupted
1639 ** immediately: the work should be allowed to finish at a clean point
1673 ** middle of direct work. If a signal does come, the test for
1695 /* do no more work */
1706 w = WorkQ; /* assign current work item */
1709 ** Set the head of the WorkQ to the next work item.
1715 ** is a domain, so we work on every 'skip'th (N-th) domain.
1851 ** RUN_WORK_GROUP -- run the jobs in a queue group from a work group.
1857 ** wgrp -- work group to process.
1889 ** If no work will ever be selected, don't even bother reading
1927 ** See if we want to go off and do other useful work.
2038 ** Here is where we choose the queue group from the work group.
2055 ** Find the next queue group within the work group that
2103 ** Then, process the work in that order.
2127 /* order the existing work requests */
2142 ** queue group within the work group. This saves us forking
2143 ** a new runner-child for each work item.
2198 /* No additional work, no additional runners */
2260 ** work group to process.
2279 ** When current process will not fork children to do the work,
2280 ** it will do the work itself. The 'skip' will be 1 since
2281 ** there are no child runners to divide the work across.
2291 /* Are there still more queues in the work group to process? */
2300 /* No more queues in work group to process. Now check persistent. */
2408 ** that any work done here that sets errno doesn't return a
2441 ** GATHERQ -- gather messages from the message queue(s) the work queue.
2460 ** prepares available work into WorkList
2471 static WORK *WorkList = NULL; /* list of unsort work */
2473 static int WorkListCount = 0; /* # of work items in WorkList */
2563 ** Read the work directory.
2618 /* grow work list if necessary */
2665 /* avoid work if possible */
2926 ** SORTQ -- sort the work list
2941 ** WorkQ gets released and filled with new work. WorkList
2982 ** Sort the work directory for the first time,
3018 ** Sort the work directory for the second time,
3088 ** Convert the work list into canonical form.
3140 ** GROW_WLIST -- make the work list larger
3226 ** WORKCMPF1 -- first compare function for ordering work based on host name.
3265 ** WORKCMPF2 -- second compare function for ordering work based on host name.
3399 ** WORKCMPF7 -- compare function for ordering work based on shuffled host name.
3526 ** DOWORK -- do a work request.
3543 ** The work request is satisfied if possible.
3562 ** Fork for work.
3715 ** DOWORKLIST -- process a list of envelopes as work requests
3718 ** envelope and its siblings, treating each envelope as a work request.
3732 ** The work request is satisfied if possible.
3748 ** Fork for work.
4861 ** Print the work list that we have read.
6851 ** Currently it is not a fatal error if this doesn't work.
7189 ** CLEANUP_SHM -- do some cleanup work for shared memory etc
7218 ** CLEANUP_QUEUES -- do some cleanup work for queues
7270 ** J -- the maximum # of jobs in work list
7391 case 'J': /* maximum # of jobs in work list */
7598 ** MAKEWORKGROUP -- balance queue groups into work groups per MaxQueueChildren
7600 ** Take the now defined queue groups and assign them to work groups.
7603 ** result in more than one queue group per work group. In such a case
7604 ** the number of running queue groups in that work group will have no
7605 ** more than the work group maximum number of runners (a "fair" portion
7606 ** of MaxQueueRunners). All queue groups within a work group will get a
7683 ** We now know the number of work groups to pack the queue groups
7687 ** into work groups first. Then the smaller ones are fitted in
7716 syserr("!cannot allocate memory for work queues, need %d bytes",
8504 ** do that work and return the open