#include <AMReX_PODVector.H>
Public Types | |
| using | value_type = T |
| using | allocator_type = Allocator |
| using | size_type = std::size_t |
| using | difference_type = std::ptrdiff_t |
| using | reference = T & |
| using | pointer = T * |
| using | iterator = T * |
| using | reverse_iterator = std::reverse_iterator< iterator > |
| using | const_reference = const T & |
| using | const_pointer = const T * |
| using | const_iterator = const T * |
| using | const_reverse_iterator = std::reverse_iterator< const_iterator > |
Public Member Functions | |
| constexpr | PODVector () noexcept=default |
| constexpr | PODVector (const allocator_type &a_allocator) noexcept |
| PODVector (size_type a_size) | |
| PODVector (size_type a_size, const value_type &a_value, const allocator_type &a_allocator=Allocator()) | |
| PODVector (std::initializer_list< T > a_initializer_list, const allocator_type &a_allocator=Allocator()) | |
| PODVector (const PODVector< T, Allocator > &a_vector) | |
| PODVector (PODVector< T, Allocator > &&a_vector) noexcept | |
| ~PODVector () | |
| PODVector & | operator= (const PODVector< T, Allocator > &a_vector) |
| PODVector & | operator= (PODVector< T, Allocator > &&a_vector) noexcept |
| iterator | erase (const_iterator a_pos) |
| iterator | erase (const_iterator a_first, const_iterator a_last) |
| iterator | insert (const_iterator a_pos, const T &a_item) |
| iterator | insert (const_iterator a_pos, size_type a_count, const T &a_value) |
| iterator | insert (const_iterator a_pos, T &&a_item) |
| iterator | insert (const_iterator a_pos, std::initializer_list< T > a_initializer_list) |
| template<class InputIt , class bar = typename std::iterator_traits<InputIt>::difference_type> | |
| iterator | insert (const_iterator a_pos, InputIt a_first, InputIt a_last) |
| void | assign (size_type a_count, const T &a_value) |
| void | assign (std::initializer_list< T > a_initializer_list) |
| template<class InputIt , class bar = typename std::iterator_traits<InputIt>::difference_type> | |
| void | assign (InputIt a_first, InputIt a_last) |
| void | assign (const T &a_value) |
| allocator_type | get_allocator () const noexcept |
| void | push_back (const T &a_value) |
| void | pop_back () noexcept |
| void | clear () noexcept |
| size_type | size () const noexcept |
| size_type | capacity () const noexcept |
| bool | empty () const noexcept |
| T & | operator[] (size_type a_index) noexcept |
| const T & | operator[] (size_type a_index) const noexcept |
| T & | front () noexcept |
| const T & | front () const noexcept |
| T & | back () noexcept |
| const T & | back () const noexcept |
| T * | data () noexcept |
| const T * | data () const noexcept |
| T * | dataPtr () noexcept |
| const T * | dataPtr () const noexcept |
| iterator | begin () noexcept |
| const_iterator | begin () const noexcept |
| iterator | end () noexcept |
| const_iterator | end () const noexcept |
| reverse_iterator | rbegin () noexcept |
| const_reverse_iterator | rbegin () const noexcept |
| reverse_iterator | rend () noexcept |
| const_reverse_iterator | rend () const noexcept |
| const_iterator | cbegin () const noexcept |
| const_iterator | cend () const noexcept |
| const_reverse_iterator | crbegin () const noexcept |
| const_reverse_iterator | crend () const noexcept |
| void | resize (size_type a_new_size, GrowthStrategy strategy=GrowthStrategy::Poisson) |
| void | resize (size_type a_new_size, const T &a_val, GrowthStrategy strategy=GrowthStrategy::Poisson) |
| void | reserve (size_type a_capacity, GrowthStrategy strategy=GrowthStrategy::Poisson) |
| void | shrink_to_fit () |
| void | swap (PODVector< T, Allocator > &a_vector) noexcept |
| void | free_async () noexcept |
Private Member Functions | |
| void | reserve_doit (size_type a_capacity) |
| size_type | nBytes () const noexcept |
| size_type | GetNewCapacityForPush () const noexcept |
| void | UpdateDataPtr (FatPtr< T > const &fp) |
| void | AllocateBufferForPush (size_type target_capacity) |
| void | AllocateBufferForInsert (size_type a_index, size_type a_count) |
| void | resize_without_init_snan (size_type a_new_size, GrowthStrategy strategy) |
Private Attributes | |
| pointer | m_data = nullptr |
| size_type | m_size {0} |
| size_type | m_capacity {0} |
| using amrex::PODVector< T, Allocator >::allocator_type = Allocator |
| using amrex::PODVector< T, Allocator >::const_iterator = const T* |
| using amrex::PODVector< T, Allocator >::const_pointer = const T* |
| using amrex::PODVector< T, Allocator >::const_reference = const T& |
| using amrex::PODVector< T, Allocator >::const_reverse_iterator = std::reverse_iterator<const_iterator> |
| using amrex::PODVector< T, Allocator >::difference_type = std::ptrdiff_t |
| using amrex::PODVector< T, Allocator >::iterator = T* |
| using amrex::PODVector< T, Allocator >::pointer = T* |
| using amrex::PODVector< T, Allocator >::reference = T& |
| using amrex::PODVector< T, Allocator >::reverse_iterator = std::reverse_iterator<iterator> |
| using amrex::PODVector< T, Allocator >::size_type = std::size_t |
| using amrex::PODVector< T, Allocator >::value_type = T |
|
constexprdefaultnoexcept |
|
inlineexplicitconstexprnoexcept |
|
inlineexplicit |
|
inline |
|
inline |
|
inline |
|
inlinenoexcept |
|
inline |
|
inlineprivate |
|
inlineprivate |
|
inline |
Set the same value to every element of the vector
| a_value | the value to assign |
|
inline |
|
inline |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
|
inline |
|
inlinenoexcept |
Deallocate the memory of the PODVector using amrex::Gpu::freeAsync. Memory deallocated in this way is held in a pool and will not be reused until the next amrex::Gpu::streamSynchronize(). GPU kernels that were already launched on the currently active stream can still continue to use the memory after this function is called.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlineprivatenoexcept |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineprivatenoexcept |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
Sets the capacity of the PODVector to at least a_capacity without changing the size. To minimize reallocations, the capacity of the vector may be increased to a value larger than the requested one. This behavior can be controlled using the strategy parameter. Available strategies are:
| [in] | a_capacity | the new minimum capacity of the PODVector |
| [in] | strategy | the growth strategy to set the new capacity |
|
inlineprivate |
|
inline |
Resizes the PODVector to a_new_size elements. New elements are set to a_val. To minimize reallocations, the capacity of the vector may be increased to a value larger than the requested size. This behavior can be controlled using the strategy parameter. Available strategies are:
| [in] | a_new_size | the new size of the PODVector |
| [in] | a_val | the value of the new elements |
| [in] | strategy | the growth strategy to set the new capacity |
|
inline |
Resizes the PODVector to a_new_size elements. New elements are either uninitialized or, if amrex.init_snan is set to true, initialized to NaN. To minimize reallocations, the capacity of the vector may be increased to a value larger than the requested size. This behavior can be controlled using the strategy parameter. Available strategies are:
| [in] | a_new_size | the new size of the PODVector |
| [in] | strategy | the growth strategy to set the new capacity |
|
inlineprivate |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlineprivate |
|
private |
|
private |
|
private |