class accessor<DataT, Dims, Mode, celerity::target::host_task>
Declaration
template <typename DataT, int Dims, access_mode Mode>
class accessor<DataT, Dims, Mode, celerity::target::host_task> { /* full declaration omitted */ };
Declared at: include/accessor.h:334
Template Parameters
- DataT
- int Dims
- access_mode Mode
Member Variables
- subrange<Dims> m_accessed_buffer_subrange
- id<Dims> m_allocation_offset
- range<Dims> m_allocation_range = detail::zeros
- range<Dims> m_buffer_range = detail::zeros
- DataT* m_host_ptr = nullptr
Member Function Overview
- accessor(accessor<DataT, Dims, Mode, celerity::target::host_task> &&) noexcept
- template <typename Functor, access_mode TagMode, access_mode TagModeNoInit>
accessor(const buffer<DataT, Dims> & buff, handler & cgh, const Functor & rmfn, detail::access_tag<TagMode, TagModeNoInit, target::host_task>, const property_list &) - template <typename Functor, access_mode TagMode, access_mode M = Mode, typename = std::enable_if_t<detail::is_producer_mode(M)>>
accessor(const buffer<DataT, Dims> & buff, handler & cgh, const Functor & rmfn, detail::access_tag<TagMode, Mode, target::host_task>, const property::no_init &) - template <typename Functor, access_mode TagModeNoInit>
accessor(const buffer<DataT, Dims> & buff, handler & cgh, const Functor & rmfn, detail::access_tag<Mode, TagModeNoInit, target::host_task>) - template <typename Functor>
accessor(const buffer<DataT, Dims> & buff, handler & cgh, const Functor & rmfn) - template <access_mode TagMode, access_mode TagModeNoInit, int D = Dims, std::enable_if_t<D == 0, int> = 0>
accessor(buffer<DataT, Dims> & buff, handler & cgh, detail::access_tag<TagMode, TagModeNoInit, target::host_task> tag, const property_list & prop_list) - template <access_mode TagMode, int D = Dims, std::enable_if_t<D == 0, int> = 0>
accessor(buffer<DataT, Dims> & buff, handler & cgh, detail::access_tag<TagMode, Mode, target::host_task> tag, const property::no_init & no_init) - template <access_mode TagModeNoInit, int D = Dims, std::enable_if_t<D == 0, int> = 0>
accessor(buffer<DataT, Dims> & buff, handler & cgh, detail::access_tag<Mode, TagModeNoInit, target::host_task> tag) - template <int D = Dims, std::enable_if_t<D == 0, int> = 0>
accessor(buffer<DataT, Dims> & buff, handler & cgh) - template <typename Functor, access_mode TagMode, access_mode M = Mode, typename = std::enable_if_t<detail::is_producer_mode(M)>>
accessor(buffer<DataT, Dims> & buff, handler & cgh, const Functor & rmfn, detail::access_tag<TagMode, Mode, target::host_task>, const property::no_init &) - template <typename Functor, access_mode TagModeNoInit>
accessor(buffer<DataT, Dims> & buff, handler & cgh, const Functor & rmfn, detail::access_tag<Mode, TagModeNoInit, target::host_task>) - template <typename Functor>
accessor(buffer<DataT, Dims> & buff, handler & cgh, const Functor & rmfn) - accessor() noexcept
- accessor(const accessor<DataT, Dims, Mode, celerity::target::host_task> & other)
- template <int KernelDims>
get_allocation_window(const partition<KernelDims> & part) const → buffer_allocation_window<DataT, Dims> - get_pointer() const → DataT *
- template <access_mode M = Mode, std::enable_if_t<Dims == 0 && detail::is_producer_mode(M), int> = 0>
operator DataT &() const - template <access_mode M = Mode, std::enable_if_t<Dims == 0 && detail::is_pure_consumer_mode(M), int> = 0>
operator const DataT &() const - template <access_mode M = Mode>
operator*() const → std::enable_if_t<Dims == 0 && detail::is_producer_mode(M), DataT &> - template <access_mode M = Mode>
operator*() const → std::enable_if_t<Dims == 0 && detail::is_pure_consumer_mode(M), const DataT &> - template <access_mode M = Mode>
operator->() const → std::enable_if_t<Dims == 0 && detail::is_pure_consumer_mode(M), const DataT *> - template <access_mode M = Mode>
operator->() const → std::enable_if_t<Dims == 0 && detail::is_producer_mode(M), DataT *> - operator=(const accessor<DataT, Dims, Mode, celerity::target::host_task> & other) → accessor<DataT, Dims, Mode, celerity::target::host_task> &
- operator=(accessor<DataT, Dims, Mode, celerity::target::host_task> &&) noexcept → accessor<DataT, Dims, Mode, celerity::target::host_task> &
- template <int D = Dims, std::enable_if_t<D == 0, int> = 0>
operator=(const DataT & other) const → const accessor<DataT, Dims, Mode, celerity::target::host_task> & - template <int D = Dims, std::enable_if_t<D == 0, int> = 0>
operator=(DataT && other) const → const accessor<DataT, Dims, Mode, celerity::target::host_task> & - template <access_mode M = Mode>
operator[](const id<Dims> & index) const → std::enable_if_t<detail::is_producer_mode(M), DataT &> - template <access_mode M = Mode>
operator[](const id<Dims> & index) const → std::enable_if_t<detail::is_pure_consumer_mode(M), const DataT &> - template <int D = Dims, std::enable_if_t<(D > 0), int> = 0>
operator[](size_t index) const → decltype(auto) - template <target Target = target::host_task, typename Functor>
accessor(ctor_internal_tag, const buffer<DataT, Dims> & buff, handler & cgh, const Functor & rmfn) - accessor(subrange<Dims> accessed_buffer_subrange, DataT * ptr, const id<Dims> & allocation_offset, const range<Dims> & allocation_range, const range<Dims> & buffer_range)
- accessor(const subrange<Dims> & accessed_buffer_subrange, detail::hydration_id hid, const id<Dims> & allocation_offset, const range<Dims> & allocation_range, range<Dims> buffer_range)
- copy_and_hydrate(const accessor<DataT, Dims, Mode, celerity::target::host_task> & other) → void
- get_linear_offset(const id<Dims> & index) const → size_t
Member Functions
¶accessor(accessor<
DataT,
Dims,
Mode,
celerity::target::host_task>&&) noexcept
accessor(accessor<
DataT,
Dims,
Mode,
celerity::target::host_task>&&) noexcept
Declared at: include/accessor.h:400
Parameters
- accessor<DataT, Dims, Mode, celerity::target::host_task>&&
¶template <typename Functor,
access_mode TagMode,
access_mode TagModeNoInit>
accessor(const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<TagMode,
TagModeNoInit,
target::host_task>,
const property_list&)
template <typename Functor,
access_mode TagMode,
access_mode TagModeNoInit>
accessor(const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<TagMode,
TagModeNoInit,
target::host_task>,
const property_list&)
Declared at: include/accessor.h:392
Template Parameters
- Functor
- access_mode TagMode
- access_mode TagModeNoInit
Parameters
- const buffer<DataT, Dims>& buff
- handler& cgh
- const Functor& rmfn
- detail::access_tag<TagMode, TagModeNoInit, target::host_task>
- const property_list&
¶template <typename Functor,
access_mode TagMode,
access_mode M = Mode,
typename = std::enable_if_t<
detail::is_producer_mode(M)>>
accessor(const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<TagMode,
Mode,
target::host_task>,
const property::no_init&)
template <typename Functor,
access_mode TagMode,
access_mode M = Mode,
typename = std::enable_if_t<
detail::is_producer_mode(M)>>
accessor(const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<TagMode,
Mode,
target::host_task>,
const property::no_init&)
Description
TODO: As of ComputeCpp 2.5.0 they do not support no_init prop, hence this constructor is needed along with discard deduction guide. but once they do this should be replace for a constructor that takes a prop list as an argument.
Declared at: include/accessor.h:387
Template Parameters
- Functor
- access_mode TagMode
- access_mode M = Mode
- = std::enable_if_t<detail::is_producer_mode(M)>
Parameters
- const buffer<DataT, Dims>& buff
- handler& cgh
- const Functor& rmfn
- detail:: access_tag<TagMode, Mode, target::host_task>
- const property::no_init&
¶template <typename Functor,
access_mode TagModeNoInit>
accessor(const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<Mode,
TagModeNoInit,
target::host_task>)
template <typename Functor,
access_mode TagModeNoInit>
accessor(const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<Mode,
TagModeNoInit,
target::host_task>)
Declared at: include/accessor.h:378
Template Parameters
- Functor
- access_mode TagModeNoInit
Parameters
- const buffer<DataT, Dims>& buff
- handler& cgh
- const Functor& rmfn
- detail::access_tag<Mode, TagModeNoInit, target::host_task>
¶template <typename Functor>
accessor(const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn)
template <typename Functor>
accessor(const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn)
Declared at: include/accessor.h:374
Template Parameters
- Functor
Parameters
- const buffer<DataT, Dims>& buff
- handler& cgh
- const Functor& rmfn
¶template <access_mode TagMode,
access_mode TagModeNoInit,
int D = Dims,
std::enable_if_t<D == 0, int> = 0>
accessor(
buffer<DataT, Dims>& buff,
handler& cgh,
detail::access_tag<TagMode,
TagModeNoInit,
target::host_task> tag,
const property_list& prop_list)
template <access_mode TagMode,
access_mode TagModeNoInit,
int D = Dims,
std::enable_if_t<D == 0, int> = 0>
accessor(
buffer<DataT, Dims>& buff,
handler& cgh,
detail::access_tag<TagMode,
TagModeNoInit,
target::host_task> tag,
const property_list& prop_list)
Declared at: include/accessor.h:370
Template Parameters
- access_mode TagMode
- access_mode TagModeNoInit
- int D = Dims
- std::enable_if_t<D == 0, int> = 0
Parameters
- buffer<DataT, Dims>& buff
- handler& cgh
- detail::access_tag<TagMode, TagModeNoInit, target::host_task> tag
- const property_list& prop_list
¶template <access_mode TagMode,
int D = Dims,
std::enable_if_t<D == 0, int> = 0>
accessor(
buffer<DataT, Dims>& buff,
handler& cgh,
detail::access_tag<TagMode,
Mode,
target::host_task> tag,
const property::no_init& no_init)
template <access_mode TagMode,
int D = Dims,
std::enable_if_t<D == 0, int> = 0>
accessor(
buffer<DataT, Dims>& buff,
handler& cgh,
detail::access_tag<TagMode,
Mode,
target::host_task> tag,
const property::no_init& no_init)
Declared at: include/accessor.h:366
Template Parameters
- access_mode TagMode
- int D = Dims
- std::enable_if_t<D == 0, int> = 0
Parameters
- buffer<DataT, Dims>& buff
- handler& cgh
- detail:: access_tag<TagMode, Mode, target::host_task> tag
- const property::no_init& no_init
¶template <access_mode TagModeNoInit,
int D = Dims,
std::enable_if_t<D == 0, int> = 0>
accessor(
buffer<DataT, Dims>& buff,
handler& cgh,
detail::access_tag<Mode,
TagModeNoInit,
target::host_task> tag)
template <access_mode TagModeNoInit,
int D = Dims,
std::enable_if_t<D == 0, int> = 0>
accessor(
buffer<DataT, Dims>& buff,
handler& cgh,
detail::access_tag<Mode,
TagModeNoInit,
target::host_task> tag)
Declared at: include/accessor.h:362
Template Parameters
- access_mode TagModeNoInit
- int D = Dims
- std::enable_if_t<D == 0, int> = 0
Parameters
- buffer<DataT, Dims>& buff
- handler& cgh
- detail::access_tag<Mode, TagModeNoInit, target::host_task> tag
¶template <int D = Dims,
std::enable_if_t<D == 0, int> = 0>
accessor(buffer<DataT, Dims>& buff, handler& cgh)
template <int D = Dims,
std::enable_if_t<D == 0, int> = 0>
accessor(buffer<DataT, Dims>& buff, handler& cgh)
Declared at: include/accessor.h:359
Template Parameters
- int D = Dims
- std::enable_if_t<D == 0, int> = 0
Parameters
- buffer<DataT, Dims>& buff
- handler& cgh
¶template <typename Functor,
access_mode TagMode,
access_mode M = Mode,
typename = std::enable_if_t<
detail::is_producer_mode(M)>>
accessor(buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<TagMode,
Mode,
target::host_task>,
const property::no_init&)
template <typename Functor,
access_mode TagMode,
access_mode M = Mode,
typename = std::enable_if_t<
detail::is_producer_mode(M)>>
accessor(buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<TagMode,
Mode,
target::host_task>,
const property::no_init&)
Description
TODO: As of ComputeCpp 2.5.0 they do not support no_init prop, hence this constructor is needed along with discard deduction guide. but once they do this should be replace for a constructor that takes a prop list as an argument.
Declared at: include/accessor.h:354
Template Parameters
- Functor
- access_mode TagMode
- access_mode M = Mode
- = std::enable_if_t<detail::is_producer_mode(M)>
Parameters
- buffer<DataT, Dims>& buff
- handler& cgh
- const Functor& rmfn
- detail:: access_tag<TagMode, Mode, target::host_task>
- const property::no_init&
¶template <typename Functor,
access_mode TagModeNoInit>
accessor(buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<Mode,
TagModeNoInit,
target::host_task>)
template <typename Functor,
access_mode TagModeNoInit>
accessor(buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn,
detail::access_tag<Mode,
TagModeNoInit,
target::host_task>)
Declared at: include/accessor.h:346
Template Parameters
- Functor
- access_mode TagModeNoInit
Parameters
- buffer<DataT, Dims>& buff
- handler& cgh
- const Functor& rmfn
- detail::access_tag<Mode, TagModeNoInit, target::host_task>
¶template <typename Functor>
accessor(buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn)
template <typename Functor>
accessor(buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn)
Declared at: include/accessor.h:343
Template Parameters
- Functor
Parameters
- buffer<DataT, Dims>& buff
- handler& cgh
- const Functor& rmfn
¶accessor() noexcept
accessor() noexcept
Declared at: include/accessor.h:340
¶accessor(
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
other)
accessor(
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
other)
Declared at: include/accessor.h:403
Parameters
- const accessor<DataT, Dims, Mode, celerity::target::host_task>& other
¶template <int KernelDims>
buffer_allocation_window<DataT, Dims>
get_allocation_window(
const partition<KernelDims>& part) const
template <int KernelDims>
buffer_allocation_window<DataT, Dims>
get_allocation_window(
const partition<KernelDims>& part) const
Description
Returns a pointer to the buffer allocation local to this node along with a description how this potentially smaller allocation maps to the underlying virtual buffer and the partition available in the current host task. Accessing the returned allocation outside the window will lead to undefined results.
Declared at: include/accessor.h:525
Template Parameters
- int KernelDims
Parameters
- const partition<KernelDims>& part
¶DataT* get_pointer() const
DataT* get_pointer() const
Description
Returns a pointer to the underlying buffer.
Since the physical (or "backing") buffer underlying a Celerity buffer might have a different size, it is not always safe to return a pointer, as the stride might not be what is expected. However, it is always possible to get a pointer if the full buffer is being accessed. This API will be deprecated and subsequently removed in a future version.
Declared at: include/accessor.h:500
¶template <
access_mode M = Mode,
std::enable_if_t<
Dims == 0 && detail::is_producer_mode(M),
int> = 0>
inline operator DataT&() const
template <
access_mode M = Mode,
std::enable_if_t<
Dims == 0 && detail::is_producer_mode(M),
int> = 0>
inline operator DataT&() const
Declared at: include/accessor.h:457
Template Parameters
- access_mode M = Mode
- std::enable_if_t<Dims == 0 && detail::is_producer_mode(M), int> = 0
¶template <
access_mode M = Mode,
std::enable_if_t<
Dims == 0 &&
detail::is_pure_consumer_mode(M),
int> = 0>
inline operator const DataT&() const
template <
access_mode M = Mode,
std::enable_if_t<
Dims == 0 &&
detail::is_pure_consumer_mode(M),
int> = 0>
inline operator const DataT&() const
Declared at: include/accessor.h:462
Template Parameters
- access_mode M = Mode
- std::enable_if_t<Dims == 0 && detail::is_pure_consumer_mode(M), int> = 0
¶template <access_mode M = Mode>
inline std::enable_if_t<
Dims == 0 && detail::is_producer_mode(M),
DataT&>
operator*() const
template <access_mode M = Mode>
inline std::enable_if_t<
Dims == 0 && detail::is_producer_mode(M),
DataT&>
operator*() const
Declared at: include/accessor.h:469
Template Parameters
- access_mode M = Mode
¶template <access_mode M = Mode>
inline std::enable_if_t<
Dims == 0 && detail::is_pure_consumer_mode(M),
const DataT&>
operator*() const
template <access_mode M = Mode>
inline std::enable_if_t<
Dims == 0 && detail::is_pure_consumer_mode(M),
const DataT&>
operator*() const
Declared at: include/accessor.h:474
Template Parameters
- access_mode M = Mode
¶template <access_mode M = Mode>
inline std::enable_if_t<
Dims == 0 && detail::is_pure_consumer_mode(M),
const DataT*>
operator->() const
template <access_mode M = Mode>
inline std::enable_if_t<
Dims == 0 && detail::is_pure_consumer_mode(M),
const DataT*>
operator->() const
Declared at: include/accessor.h:484
Template Parameters
- access_mode M = Mode
¶template <access_mode M = Mode>
inline std::enable_if_t<
Dims == 0 && detail::is_producer_mode(M),
DataT*>
operator->() const
template <access_mode M = Mode>
inline std::enable_if_t<
Dims == 0 && detail::is_producer_mode(M),
DataT*>
operator->() const
Declared at: include/accessor.h:479
Template Parameters
- access_mode M = Mode
¶accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
operator=(
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
other)
accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
operator=(
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
other)
Declared at: include/accessor.h:405
Parameters
- const accessor<DataT, Dims, Mode, celerity::target::host_task>& other
¶accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
operator=(accessor<
DataT,
Dims,
Mode,
celerity::target::host_task>&&) noexcept
accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
operator=(accessor<
DataT,
Dims,
Mode,
celerity::target::host_task>&&) noexcept
Declared at: include/accessor.h:401
Parameters
- accessor<DataT, Dims, Mode, celerity::target::host_task>&&
¶template <int D = Dims,
std::enable_if_t<D == 0, int> = 0>
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
operator=(const DataT& other) const
template <int D = Dims,
std::enable_if_t<D == 0, int> = 0>
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
operator=(const DataT& other) const
Declared at: include/accessor.h:413
Template Parameters
- int D = Dims
- std::enable_if_t<D == 0, int> = 0
Parameters
- const DataT& other
¶template <int D = Dims,
std::enable_if_t<D == 0, int> = 0>
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
operator=(DataT&& other) const
template <int D = Dims,
std::enable_if_t<D == 0, int> = 0>
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
operator=(DataT&& other) const
Declared at: include/accessor.h:419
Template Parameters
- int D = Dims
- std::enable_if_t<D == 0, int> = 0
Parameters
- DataT&& other
¶template <access_mode M = Mode>
inline std::enable_if_t<
detail::is_producer_mode(M),
DataT&>
operator[](const id<Dims>& index) const
template <access_mode M = Mode>
inline std::enable_if_t<
detail::is_producer_mode(M),
DataT&>
operator[](const id<Dims>& index) const
Declared at: include/accessor.h:425
Template Parameters
- access_mode M = Mode
Parameters
- const id<Dims>& index
¶template <access_mode M = Mode>
inline std::enable_if_t<
detail::is_pure_consumer_mode(M),
const DataT&>
operator[](const id<Dims>& index) const
template <access_mode M = Mode>
inline std::enable_if_t<
detail::is_pure_consumer_mode(M),
const DataT&>
operator[](const id<Dims>& index) const
Declared at: include/accessor.h:447
Template Parameters
- access_mode M = Mode
Parameters
- const id<Dims>& index
¶template <int D = Dims,
std::enable_if_t<(D > 0), int> = 0>
inline decltype(auto) operator[](
size_t index) const
template <int D = Dims,
std::enable_if_t<(D > 0), int> = 0>
inline decltype(auto) operator[](
size_t index) const
Declared at: include/accessor.h:452
Template Parameters
- int D = Dims
- std::enable_if_t<(D > 0), int> = 0
Parameters
- size_t index
¶template <target Target = target::host_task,
typename Functor>
accessor(ctor_internal_tag,
const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn)
template <target Target = target::host_task,
typename Functor>
accessor(ctor_internal_tag,
const buffer<DataT, Dims>& buff,
handler& cgh,
const Functor& rmfn)
Declared at: include/accessor.h:569
Template Parameters
- target Target = target::host_task
- Functor
Parameters
- ctor_internal_tag
- const buffer<DataT, Dims>& buff
- handler& cgh
- const Functor& rmfn
¶accessor(subrange<Dims> accessed_buffer_subrange,
DataT* ptr,
const id<Dims>& allocation_offset,
const range<Dims>& allocation_range,
const range<Dims>& buffer_range)
accessor(subrange<Dims> accessed_buffer_subrange,
DataT* ptr,
const id<Dims>& allocation_offset,
const range<Dims>& allocation_range,
const range<Dims>& buffer_range)
Declared at: include/accessor.h:576
Parameters
- subrange<Dims> accessed_buffer_subrange
- DataT* ptr
- const id<Dims>& allocation_offset
- const range<Dims>& allocation_range
- const range<Dims>& buffer_range
¶accessor(const subrange<Dims>&
accessed_buffer_subrange,
detail::hydration_id hid,
const id<Dims>& allocation_offset,
const range<Dims>& allocation_range,
range<Dims> buffer_range)
accessor(const subrange<Dims>&
accessed_buffer_subrange,
detail::hydration_id hid,
const id<Dims>& allocation_offset,
const range<Dims>& allocation_range,
range<Dims> buffer_range)
Declared at: include/accessor.h:582
Parameters
- const subrange<Dims>& accessed_buffer_subrange
- detail::hydration_id hid
- const id<Dims>& allocation_offset
- const range<Dims>& allocation_range
- range<Dims> buffer_range
¶void copy_and_hydrate(
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
other)
void copy_and_hydrate(
const accessor<DataT,
Dims,
Mode,
celerity::target::host_task>&
other)
Declared at: include/accessor.h:586
Parameters
- const accessor<DataT, Dims, Mode, celerity::target::host_task>& other
¶size_t get_linear_offset(
const id<Dims>& index) const
size_t get_linear_offset(
const id<Dims>& index) const
Declared at: include/accessor.h:616
Parameters
- const id<Dims>& index