Jlm
Public Member Functions | List of all members
jlm::util::Worklist< T > Class Template Referenceabstract

#include <Worklist.hpp>

Inheritance diagram for jlm::util::Worklist< T >:
Inheritance graph
[legend]

Public Member Functions

virtual ~Worklist ()=default
 
 Worklist ()=default
 
 Worklist (const Worklist &other)=delete
 
 Worklist (Worklist &&other)=default
 
Worklistoperator= (const Worklist &other)=delete
 
Worklistoperator= (Worklist &&other)=default
 
virtual bool HasMoreWorkItems () const noexcept=0
 
virtual T PopWorkItem ()=0
 
virtual void PushWorkItem (T item)=0
 

Detailed Description

template<typename T>
class jlm::util::Worklist< T >

Class for managing a set of work items, that are waiting to be visited by an algorithm. The implementation decides in what order remaining work items should be processed.

Template Parameters
Tthe type of the work items.

Definition at line 27 of file Worklist.hpp.

Constructor & Destructor Documentation

◆ ~Worklist()

template<typename T >
virtual jlm::util::Worklist< T >::~Worklist ( )
virtualdefault

◆ Worklist() [1/3]

template<typename T >
jlm::util::Worklist< T >::Worklist ( )
default

◆ Worklist() [2/3]

template<typename T >
jlm::util::Worklist< T >::Worklist ( const Worklist< T > &  other)
delete

◆ Worklist() [3/3]

template<typename T >
jlm::util::Worklist< T >::Worklist ( Worklist< T > &&  other)
default

Member Function Documentation

◆ HasMoreWorkItems()

template<typename T >
virtual bool jlm::util::Worklist< T >::HasMoreWorkItems ( ) const
pure virtualnoexcept

◆ operator=() [1/2]

template<typename T >
Worklist& jlm::util::Worklist< T >::operator= ( const Worklist< T > &  other)
delete

◆ operator=() [2/2]

template<typename T >
Worklist& jlm::util::Worklist< T >::operator= ( Worklist< T > &&  other)
default

◆ PopWorkItem()

template<typename T >
virtual T jlm::util::Worklist< T >::PopWorkItem ( )
pure virtual

Removes one work item from the worklist. Requires there to be at least one work item left.

Returns
the removed work item.

Implemented in jlm::util::Workset< T >, jlm::util::TwoPhaseLrfWorklist< T >, jlm::util::LrfWorklist< T >, jlm::util::FifoWorklist< T >, and jlm::util::LifoWorklist< T >.

◆ PushWorkItem()

template<typename T >
virtual void jlm::util::Worklist< T >::PushWorkItem ( item)
pure virtual

Adds a work item to the worklist. If the item is already present, the item is not added again, but its position may be changed.

Parameters
itemthe work item to be added.

Implemented in jlm::util::Workset< T >, jlm::util::TwoPhaseLrfWorklist< T >, jlm::util::LrfWorklist< T >, jlm::util::FifoWorklist< T >, and jlm::util::LifoWorklist< T >.


The documentation for this class was generated from the following file: