docc 0.8.3 (0d44999b)
C++ API Reference
Loading...
Searching...
No Matches
sdfg::data_flow::PointerGenericAccess Class Reference

It is unknown what is done with this pointer or it is a mix of reads and writes. More...

#include <sdfg/data_flow/pointer_metadata.h>

Inheritance diagram for sdfg::data_flow::PointerGenericAccess:
[legend]

Public Member Functions

 PointerGenericAccess (MemoryAccessPatternType read_pattern, MemoryAccessPatternType write_pattern, bool no_capture)
MemoryAccessPatternType access_read_pattern () const override
 Allows limiting the undefined behavior (assume required input as well as dirtying) to a specific pattern No pattern means could be all the memory-area pointed to.
MemoryAccessPatternType access_write_pattern () const override
bool no_capture () const override
 Despite this being a leak of the pointer, the user will only use it for blocking accesses to the underlying data and not capture a reference to the data in any way.
bool may_contain_reads () const override
 The pointer may be used to read from the backing data.
bool may_contain_writes () const override
 The pointe may be used to write to the backing data.
bool invalidated_after () const override
void replace (const symbolic::Expression old_expression, const symbolic::Expression new_expression) override
void replace (const symbolic::ExpressionMapping &replacements) override
PointerAccessType clone () const override
void serialize_to_json (nlohmann::json &entry) override
Public Member Functions inherited from sdfg::data_flow::PointerAccessMeta
virtual ~PointerAccessMeta ()=default
PointerAccessType ref () const

Additional Inherited Members

Static Public Member Functions inherited from sdfg::data_flow::PointerAccessMeta
static PointerAccessType create_read_only (const symbolic::Expression &size, bool no_capture, std::optional< math::tensor::TensorLayout > layout=std::nullopt, bool every_element_read=false)
static PointerAccessType create_invalidate ()
static PointerAccessType create_full_write_only (const symbolic::Expression &size, bool no_capture, std::optional< math::tensor::TensorLayout > layout=std::nullopt)
static PointerAccessType create_generic (MemoryAccessPatternType read_pattern, MemoryAccessPatternType write_pattern, bool no_capture)
Protected Member Functions inherited from sdfg::data_flow::PointerAccessMeta
 PointerAccessMeta ()=default

Detailed Description

It is unknown what is done with this pointer or it is a mix of reads and writes.

This could overwrite some parts of the area pointed to, but leave others as is. Assume the worst: data is made dirty by a black box. You know nothing about the contents after this

Constructor & Destructor Documentation

◆ PointerGenericAccess()

sdfg::data_flow::PointerGenericAccess::PointerGenericAccess ( MemoryAccessPatternType read_pattern,
MemoryAccessPatternType write_pattern,
bool no_capture )

Member Function Documentation

◆ access_read_pattern()

MemoryAccessPatternType sdfg::data_flow::PointerGenericAccess::access_read_pattern ( ) const
overridevirtual

Allows limiting the undefined behavior (assume required input as well as dirtying) to a specific pattern No pattern means could be all the memory-area pointed to.

Implements sdfg::data_flow::PointerAccessMeta.

◆ access_write_pattern()

MemoryAccessPatternType sdfg::data_flow::PointerGenericAccess::access_write_pattern ( ) const
overridevirtual

◆ clone()

PointerAccessType sdfg::data_flow::PointerGenericAccess::clone ( ) const
overridevirtual

◆ invalidated_after()

bool sdfg::data_flow::PointerGenericAccess::invalidated_after ( ) const
inlineoverridevirtual

◆ may_contain_reads()

bool sdfg::data_flow::PointerGenericAccess::may_contain_reads ( ) const
overridevirtual

The pointer may be used to read from the backing data.

Implements sdfg::data_flow::PointerAccessMeta.

◆ may_contain_writes()

bool sdfg::data_flow::PointerGenericAccess::may_contain_writes ( ) const
overridevirtual

The pointe may be used to write to the backing data.

Implements sdfg::data_flow::PointerAccessMeta.

◆ no_capture()

bool sdfg::data_flow::PointerGenericAccess::no_capture ( ) const
inlineoverridevirtual

Despite this being a leak of the pointer, the user will only use it for blocking accesses to the underlying data and not capture a reference to the data in any way.

Like a Rust temporary borrow for the duration of the LibNode and no more.

Implements sdfg::data_flow::PointerAccessMeta.

◆ replace() [1/2]

void sdfg::data_flow::PointerGenericAccess::replace ( const symbolic::Expression old_expression,
const symbolic::Expression new_expression )
overridevirtual

◆ replace() [2/2]

void sdfg::data_flow::PointerGenericAccess::replace ( const symbolic::ExpressionMapping & replacements)
overridevirtual

◆ serialize_to_json()

void sdfg::data_flow::PointerGenericAccess::serialize_to_json ( nlohmann::json & entry)
overridevirtual

The documentation for this class was generated from the following file: