Skip to main content

class copy_instruction

Declaration

class copy_instruction : public implement_acceptor { /* full declaration omitted */ };

Description

Copies one or more subranges of elements from one allocation to another, potentially between different memories. Source and destination can be box-shaped allocations (in which case we consider the copy region boxes to be contained within the allocation box) or linearized (such that boxes are laid out sequentially in memory, which must have space for copy_region.get_area() elements).

Declared at: include/instruction_graph.h:116

Inherits from: implement_acceptor

Member Variables

allocation_id m_source_aid
allocation_id m_dest_aid
region_layout m_source_layout
region_layout m_dest_layout
region<3> m_copy_region
size_t m_elem_size

Member Function Overview

Member Functions

explicit copy_instruction(
    instruction_id iid,
    int priority,
    const allocation_id& source_aid,
    const allocation_id& dest_aid,
    const region_layout& source_layout,
    const region_layout& dest_layout,
    region<3> copy_region,
    size_t elem_size)

Declared at: include/instruction_graph.h:118

Parameters

instruction_id iid
int priority
const allocation_id& source_aid
const allocation_id& dest_aid
const region_layout& source_layout
const region_layout& dest_layout
region<3> copy_region
size_t elem_size

const region<3>& get_copy_region() const

Declared at: include/instruction_graph.h:136


allocation_id get_dest_allocation_id() const

Declared at: include/instruction_graph.h:133


const region_layout& get_dest_layout() const

Declared at: include/instruction_graph.h:135


size_t get_element_size() const

Declared at: include/instruction_graph.h:137


allocation_id get_source_allocation_id() const

Declared at: include/instruction_graph.h:132


const region_layout& get_source_layout() const

Declared at: include/instruction_graph.h:134