Device memory. More...
#include <buffer.hpp>
Classes | |
struct | send_result |
Public Member Functions | |
buffer (hpx::shared_future< hpx::naming::id_type > const &gid, hpx::naming::id_type device_gid_) | |
hpx::future< std::size_t > | size () const |
Get the size of the buffer. | |
template<typename T , typename... Deps> | |
hpx::future< void > | enqueue_write (std::size_t offset, const hpx::serialization::serialize_buffer< T > data, Deps &&...dependencies) |
Writes data to the buffer. | |
template<typename T , typename... Deps> | |
hpx::future< void > | enqueue_write_rect (rect_props rect_properties, const hpx::serialization::serialize_buffer< T > data, Deps &&...dependencies) |
Writes data to the buffer in a rectangular region. | |
template<typename... Deps> | |
hpx::future < hpx::serialization::serialize_buffer < char > > | enqueue_read (std::size_t offset, std::size_t size, Deps &&...dependencies) |
Reads data from the buffer. | |
template<typename T , typename... Deps> | |
hpx::future < hpx::serialization::serialize_buffer < T > > | enqueue_read (std::size_t offset, hpx::serialization::serialize_buffer< T > data, Deps &&...dependencies) |
Reads data from the buffer. | |
template<typename T , typename... Deps> | |
hpx::future < hpx::serialization::serialize_buffer < T > > | enqueue_read_rect (rect_props rect_properties, hpx::serialization::serialize_buffer< T > data, Deps &&...dependencies) |
Reads data from the buffer. | |
template<typename... Deps> | |
send_result | enqueue_send (const hpx::opencl::buffer &dst, std::size_t src_offset, std::size_t dst_offset, std::size_t size, Deps &&...dependencies) |
template<typename... Deps> | |
send_result | enqueue_send_rect (const hpx::opencl::buffer &dst, rect_props rect_properties, Deps &&...dependencies) |
Friends | |
class | hpx::serialization::access |
hpx::future< hpx::serialization::serialize_buffer< char > > hpx::opencl::buffer::enqueue_read | ( | std::size_t | offset, |
std::size_t | size, | ||
Deps &&... | dependencies | ||
) |
Reads data from the buffer.
offset | The start position of the area to read. |
size | The size of the area to read. |
hpx::future< hpx::serialization::serialize_buffer< T > > hpx::opencl::buffer::enqueue_read | ( | std::size_t | offset, |
hpx::serialization::serialize_buffer< T > | data, | ||
Deps &&... | dependencies | ||
) |
Reads data from the buffer.
offset | The start position of the area to read. |
data | The buffer the result will get written to. The buffer also contains information about the size of the data to read. The buffer will get returned and kept alive through the future. |
hpx::future< hpx::serialization::serialize_buffer< T > > hpx::opencl::buffer::enqueue_read_rect | ( | rect_props | rect_properties, |
hpx::serialization::serialize_buffer< T > | data, | ||
Deps &&... | dependencies | ||
) |
Reads data from the buffer.
rect_properties | Parameters of the rectangle to read. |
data | The buffer the result will get written to. The buffer will get returned and kept alive through the future. |
hpx::future< void > hpx::opencl::buffer::enqueue_write | ( | std::size_t | offset, |
const hpx::serialization::serialize_buffer< T > | data, | ||
Deps &&... | dependencies | ||
) |
Writes data to the buffer.
offset | The start position of the area to write to. |
data | The data to be written. |
hpx::future< void > hpx::opencl::buffer::enqueue_write_rect | ( | rect_props | rect_properties, |
const hpx::serialization::serialize_buffer< T > | data, | ||
Deps &&... | dependencies | ||
) |
Writes data to the buffer in a rectangular region.
rect_properties | The parameters like size, offset, stride |
data | The data to be written. |
hpx::future<std::size_t> hpx::opencl::buffer::size | ( | ) | const |
Get the size of the buffer.