Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
RooFit::MultiProcess::PriorityQueue Class Reference

Queue that orders tasks according to specified task priorities.

Definition at line 30 of file PriorityQueue.h.

Public Member Functions

void add (JobTask job_task) override
 See Queue::add.
 
bool pop (JobTask &job_task) override
 See Queue::pop.
 
void setTaskPriorities (std::size_t job_id, const std::vector< std::size_t > &task_priorities)
 Set the priority for Job tasks.
 
void suggestTaskOrder (std::size_t job_id, const std::vector< Task > &task_order)
 Set the desired order for executing tasks of a Job.
 
- Public Member Functions inherited from RooFit::MultiProcess::Queue
virtual ~Queue ()=default
 
void loop ()
 The queue process's event loop.
 
void process_master_message (M2Q message)
 Helper function for 'Queue::loop()'.
 
void process_worker_message (std::size_t this_worker_id, W2Q message)
 Helper function for 'Queue::loop()'.
 

Private Attributes

std::priority_queue< OrderedJobTaskqueue_
 
std::unordered_map< std::size_t, std::vector< std::size_t > > task_priority_
 

Additional Inherited Members

- Protected Attributes inherited from RooFit::MultiProcess::Queue
std::size_t N_tasks_ = 0
 
std::size_t N_tasks_at_workers_ = 0
 

#include </home/sftnight/build/workspace/root-makedoc-v630/rootspi/rdoc/src/v6-30-00-patches/roofit/multiprocess/src/PriorityQueue.h>

Inheritance diagram for RooFit::MultiProcess::PriorityQueue:
[legend]

Member Function Documentation

◆ add()

void RooFit::MultiProcess::PriorityQueue::add ( JobTask  job_task)
overridevirtual

See Queue::add.

Implements RooFit::MultiProcess::Queue.

Definition at line 40 of file PriorityQueue.cxx.

◆ pop()

bool RooFit::MultiProcess::PriorityQueue::pop ( JobTask job_task)
overridevirtual

See Queue::pop.

Implements RooFit::MultiProcess::Queue.

Definition at line 29 of file PriorityQueue.cxx.

◆ setTaskPriorities()

void RooFit::MultiProcess::PriorityQueue::setTaskPriorities ( std::size_t  job_id,
const std::vector< std::size_t > &  task_priorities 
)

Set the priority for Job tasks.

See Config::Queue::setTaskPriorities.

Definition at line 72 of file PriorityQueue.cxx.

◆ suggestTaskOrder()

void RooFit::MultiProcess::PriorityQueue::suggestTaskOrder ( std::size_t  job_id,
const std::vector< Task > &  task_order 
)

Set the desired order for executing tasks of a Job.

See Config::Queue::suggestTaskOrder.

Definition at line 60 of file PriorityQueue.cxx.

Member Data Documentation

◆ queue_

std::priority_queue<OrderedJobTask> RooFit::MultiProcess::PriorityQueue::queue_
private

Definition at line 37 of file PriorityQueue.h.

◆ task_priority_

std::unordered_map<std::size_t, std::vector<std::size_t> > RooFit::MultiProcess::PriorityQueue::task_priority_
private

Definition at line 39 of file PriorityQueue.h.

  • roofit/multiprocess/src/PriorityQueue.h
  • roofit/multiprocess/src/PriorityQueue.cxx