|
| LVARRAY_HOST_DEVICE constexpr | MallocBuffer (bool=true) |
| | Constructor for creating an empty or uninitialized buffer. More...
|
| |
|
| MallocBuffer (MallocBuffer const &)=default |
| | Copy constructor, creates a shallow copy.
|
| |
| | MallocBuffer (MallocBuffer const &src, std::ptrdiff_t) |
| | Sized copy constructor, creates a shallow copy. More...
|
| |
| LVARRAY_HOST_DEVICE constexpr | MallocBuffer (MallocBuffer &&src) |
| | Move constructor, creates a shallow copy. More...
|
| |
| template<typename U > |
| LVARRAY_HOST_DEVICE constexpr | MallocBuffer (MallocBuffer< U > const &src) |
| | Create a shallow copy of src but with a different type. More...
|
| |
| LVARRAY_HOST_DEVICE LVARRAY_INTEL_CONSTEXPR MallocBuffer & | operator= (MallocBuffer const &src) |
| | Copy assignment operator, creates a shallow copy. More...
|
| |
| LVARRAY_HOST_DEVICE LVARRAY_INTEL_CONSTEXPR MallocBuffer & | operator= (MallocBuffer &&src) |
| | Move assignment operator, creates a shallow copy. More...
|
| |
| LVARRAY_HOST_DEVICE void | reallocate (std::ptrdiff_t const size, MemorySpace const space, std::ptrdiff_t const newCapacity) |
| | Reallocate the buffer to the new capacity. More...
|
| |
| LVARRAY_HOST_DEVICE void | free () |
| | Free the data in the buffer but does not destroy any values. More...
|
| |
| LVARRAY_HOST_DEVICE std::ptrdiff_t | capacity () const |
| |
| LVARRAY_HOST_DEVICE constexpr T * | data () const |
| |
| template<typename INDEX_TYPE > |
| LVARRAY_HOST_DEVICE constexpr T & | operator[] (INDEX_TYPE const i) const |
| |
| void | moveNested (MemorySpace const space, std::ptrdiff_t const size, bool const touch) const |
| | Move the buffer to the given execution space, optionally touching it. More...
|
| |
| void | move (MemorySpace const space, bool const touch) const |
| | Move the buffer to the given execution space, optionally touching it. More...
|
| |
| MemorySpace | getPreviousSpace () const |
| |
| void | registerTouch (MemorySpace const space) const |
| | Touch the buffer in the given space. More...
|
| |
| template<typename = VoidBuffer> |
| LVARRAY_HOST_DEVICE void | setName (std::string const &name) |
| | Set the name associated with this buffer. More...
|
| |
template<typename T>
class LvArray::MallocBuffer< T >
Implements the Buffer interface using malloc and free.
- Template Parameters
-
| T | type of data that is contained in the buffer. |
Both the copy constructor and copy assignment constructor perform a shallow copy of the source. Similarly the destructor does not free the allocation.
- Note
- The parent class bufferManipulation::VoidBuffer provides the default execution space related methods.