|
NUMA++ 0.11.0
|
NUMA++ General Utilities. More...
Files | |
| file | bitmask.hpp |
| Contains declarations for numapp::Bitmask. | |
| file | cpumask.hpp |
| Contains declarations for CpumaskTrait. | |
| file | nodemask.hpp |
| Contains declarations for Nodemask. | |
Namespaces | |
| namespace | numapp |
Classes | |
| class | numapp::Bitmask< Class > |
| Generic bitmask. More... | |
| class | numapp::Cpumask |
| Type-safe CPU mask. More... | |
| struct | numapp::Nodemask |
| Type-safe NUMA node mask. More... | |
Typedefs | |
| using | numapp::NumaBitmaskPtr = std::unique_ptr<struct bitmask, void (*)(struct bitmask*)> |
| Lowlevel bitmask type. | |
Functions | |
| template<class Class, class F> | |
| void | numapp::ForEach (Bitmask< Class > const &bitmask, F &&f, bool value=true) |
| Invoke function for each bit in mask that matches value. | |
| template<class Class> | |
| std::ostream & | numapp::FormatBitmask (std::ostream &os, Bitmask< Class > const &mask, int min_bits) |
| Formats mask and inserts it to os. | |
| std::ostream & | numapp::FormatBitmask (std::ostream &os, bitmask const *mask, int min_bits) |
| Formats mask and inserts it to os. | |
| std::ostream & | numapp::operator<< (std::ostream &os, Cpumask const &mask) |
| Formats mask and inserts it to os. | |
| std::ostream & | numapp::operator<< (std::ostream &os, Nodemask const &mask) |
| Formats mask and inserts it to os. | |
| bool | numapp::NumaAvailable () noexcept |
| Query whether system has NUMA support. | |
| template<class Class, class F> | |
| void | ForEach (Bitmask< Class > const &bitmask, F &&f, bool value=true) |
| Invoke function for each bit in mask that matches value. | |
| template<class Class> | |
| std::ostream & | FormatBitmask (std::ostream &os, Bitmask< Class > const &mask, int min_bits) |
| Formats mask and inserts it to os. | |
| std::ostream & | FormatBitmask (std::ostream &os, bitmask const *mask, int min_bits) |
| Formats mask and inserts it to os. | |
NUMA++ General Utilities.
|
Invoke function for each bit in mask that matches value.
| bitmask | Bitmask to iterate over. |
| f | function callable as f(position) where position is the unsigned int bit position. |
| value | to test bit for (true == bit is set, false == bit is unset). |
Example that starts a pinned thread for each bit in a CPU mask:
<numapp/bitmask.hpp> Definition at line 220 of file bitmask.hpp.
|
Invoke function for each bit in mask that matches value.
| bitmask | Bitmask to iterate over. |
| f | function callable as f(position) where position is the unsigned int bit position. |
| value | to test bit for (true == bit is set, false == bit is unset). |
Example that starts a pinned thread for each bit in a CPU mask:
<numapp/bitmask.hpp> Definition at line 220 of file bitmask.hpp.
|
Formats mask and inserts it to os.
| os | output stream to insert into. |
| mask | Bitmask to format. |
| min_bits | Minimum number of bits to format. |
Definition at line 13 of file bitmask.cpp.
|
Formats mask and inserts it to os.
| os | output stream to insert into. |
| mask | Bitmask to format. |
| min_bits | Minimum number of bits to format. |
Definition at line 215 of file bitmask.hpp.
|
Formats mask and inserts it to os.
| os | output stream to insert into. |
| mask | Bitmask to format. |
| min_bits | Minimum number of bits to format. |
Definition at line 13 of file bitmask.cpp.
|
Formats mask and inserts it to os.
| os | output stream to insert into. |
| mask | Bitmask to format. |
| min_bits | Minimum number of bits to format. |
Definition at line 215 of file bitmask.hpp.
|
inlinenodiscardnoexcept |
Query whether system has NUMA support.
Example use:
numa(3) (numa_available)<numapp/numa.hpp>
|
inline |
Formats mask and inserts it to os.
Mask up to number of configured CPUs are formatted if no higher bits are set.
| os | output stream to insert into. |
| mask | Cpumask to format. |
Definition at line 96 of file cpumask.hpp.
|
inline |
Formats mask and inserts it to os.
Mask up to number of configured NUMA nodes are formatted if no higher bits are set.
| os | output stream to insert into. |
| mask | Nodemask to format. |
Definition at line 94 of file nodemask.hpp.