Public Member Functions | List of all members
rmm::mr::detail::fixed_size_free_list Struct Reference
Inheritance diagram for rmm::mr::detail::fixed_size_free_list:
Inheritance graph
[legend]
Collaboration diagram for rmm::mr::detail::fixed_size_free_list:
Collaboration graph
[legend]

Public Member Functions

 fixed_size_free_list (fixed_size_free_list const &)=delete
 
fixed_size_free_listoperator= (fixed_size_free_list const &)=delete
 
 fixed_size_free_list (fixed_size_free_list &&)=delete
 
fixed_size_free_listoperator= (fixed_size_free_list &&)=delete
 
template<class InputIt >
 fixed_size_free_list (InputIt first, InputIt last)
 Construct a new free_list from range defined by input iterators. More...
 
void insert (block_type const &block)
 Inserts a block into the free_list in the correct order, coalescing it with the preceding and following blocks if either is contiguous. More...
 
void insert (free_list &&other)
 Inserts blocks from another free list into this free_list. More...
 
block_type get_block (std::size_t size)
 Returns the first block in the free list. More...
 
- Public Member Functions inherited from rmm::mr::detail::free_list< block_base >
 free_list (free_list const &)=delete
 
 free_list (free_list &&)=delete
 
free_listoperator= (free_list const &)=delete
 
free_listoperator= (free_list &&)=delete
 
iterator begin () noexcept
 beginning of the free list
 
const_iterator begin () const noexcept
 beginning of the free list
 
const_iterator cbegin () const noexcept
 beginning of the free list
 
iterator end () noexcept
 end of the free list
 
const_iterator end () const noexcept
 beginning of the free list
 
const_iterator cend () const noexcept
 beginning of the free list
 
size_type size () const noexcept
 The size of the free list in blocks. More...
 
bool is_empty () const noexcept
 checks whether the free_list is empty. More...
 
void erase (const_iterator iter)
 Removes the block indicated by iter from the free list. More...
 
void clear () noexcept
 Erase all blocks from the free_list.
 

Additional Inherited Members

- Public Types inherited from rmm::mr::detail::free_list< block_base >
using block_type = block_base
 
using list_type = std::list< block_base >
 
using size_type = typename list_type::size_type
 
using iterator = typename list_type::iterator
 
using const_iterator = typename list_type::const_iterator
 
- Protected Member Functions inherited from rmm::mr::detail::free_list< block_base >
void insert (const_iterator pos, block_type const &block)
 Insert a block in the free list before the specified position. More...
 
void splice (const_iterator pos, free_list &&other)
 Inserts a list of blocks in the free list before the specified position. More...
 
void push_back (const block_type &block)
 Appends the given block to the end of the free list. More...
 
void push_back (block_type &&block)
 Appends the given block to the end of the free list. b is moved to the new element. More...
 
void pop_front ()
 Removes the first element of the free list. If there are no elements in the free list, the behavior is undefined. More...
 

Constructor & Destructor Documentation

◆ fixed_size_free_list()

template<class InputIt >
rmm::mr::detail::fixed_size_free_list::fixed_size_free_list ( InputIt  first,
InputIt  last 
)
inline

Construct a new free_list from range defined by input iterators.

Template Parameters
InputItInput iterator
Parameters
firstThe start of the range to insert into the free_list
lastThe end of the range to insert into the free_list

Member Function Documentation

◆ get_block()

block_type rmm::mr::detail::fixed_size_free_list::get_block ( std::size_t  size)
inline

Returns the first block in the free list.

Parameters
sizeThe size in bytes of the desired block (unused).
Returns
A block large enough to store size bytes.

◆ insert() [1/2]

void rmm::mr::detail::fixed_size_free_list::insert ( block_type const &  block)
inline

Inserts a block into the free_list in the correct order, coalescing it with the preceding and following blocks if either is contiguous.

Parameters
blockThe block to insert.

◆ insert() [2/2]

void rmm::mr::detail::fixed_size_free_list::insert ( free_list &&  other)
inline

Inserts blocks from another free list into this free_list.

Parameters
otherThe free_list to insert into this free_list.

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