sync_for_read - 3.0 English

Vitis AI User Guide (UG1414)

Document ID
UG1414
Release Date
2023-02-24
Version
3.0 English
Invalid cache for reading before read. It is no-op in case get_location() returns DEVICE_ONLY or HOST_VIRT.

Prototype

void sync_for_read(uint64_t offset, size_t size) {};

Parameters

The following table lists the sync_for_read function arguments.
Table 1. sync_for_read Arguments
Type Name Description
uint64_t offset The start offset address
size_t size The data size

Returns

None.

Usage

for (auto& output : output_tensor_buffers) {
    output->sync_for_read(0, output->get_tensor()->get_data_size() /
                                output->get_tensor()->get_shape()[0]);
}