12#ifndef GROWING_BUFFER_H
13#define GROWING_BUFFER_H
39 void *
data()
const {
return reinterpret_cast<void *
>(base); }
42 unsigned long long base = 0;
47 std::vector<unsigned long long> handles;
48 std::vector<size_t> sizes;
Device memory at a fixed address whose backing grows as it fills: a reserved virtual address range wi...
Definition growing_buffer.h:26
void * data() const
Definition growing_buffer.h:39
static bool supported()
Definition growing_buffer.cpp:130
~GrowingBuffer()
Definition growing_buffer.cpp:134
GrowingBuffer(const GrowingBuffer &)=delete
GrowingBuffer & operator=(const GrowingBuffer &)=delete
void ensure(size_t bytes)
Map pages so that the first bytes are backed by device memory.
Definition growing_buffer.cpp:136
KOKKOS_INLINE_FUNCTION rtype dot(const rtype *a, const rtype *b)
Compute the dot product of two arrays.
Definition common_math.h:32
size_t bytes
Definition teno_setup.cpp:1793