Loading...
Searching...
No Matches
stdex::pool< T > Class Template Reference

Per-NUMA pool of items. More...

`#include <stdex/pool.hpp>`

## Public Types

using | numaid_t = int

## Public Member Functions

T | pop (numaid_t numa=numa_node())
| Removes an item from the pool.
void | push (T &&r, numaid_t numa=numa_node())
| Adds an item to the pool.

## Detailed Description

template<class T>
class stdex::pool< T >

Per-NUMA pool of items.

## Member Function Documentation

## pop()

template<class T >

T stdex::pool< T >::pop | ( | numaid_t | numa = `numa_node()` | ) |

inline

Removes an item from the pool.

Parameters

  [in] | numa | NUMA node to identify subpool to remove item from

Returns
  An item from the pool or default value if pool is empty

## push()

template<class T >

void stdex::pool< T >::push | ( | T && | r,
|  | numaid_t | numa = `numa_node()`
| ) |  |

inline

Adds an item to the pool.

Parameters

  [in] | r | Item to add
  [in] | numa | NUMA node to identify subpool to add item to

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

- include/stdex/pool.hpp