Asynchronous Array RTP - 2023.2 English

Vitis Tutorials: AI Engine

Document ID
XD100
Release Date
2023-11-29
Version
2023.2 English

An array parameter can also work similarly as scalar RTP. Only that the array should be updated as a whole (not partial of the array).

The test case is async_array_rtp.

The kernel signature is:

template<int32 NUM>
void vect_add(input_buffer<int32,extents<NUM>>& __restrict in,output_buffer<int32,extents<NUM>>& __restrict out,const int32 (&value)[NUM]);

The RTP specification can be found in aie/graph.h:

using namespace adf;
adf::port<adf::direction::in> value;
adf::connect<adf::parameter>(value, async(k.in[1])); 

The RTP calls for aiesimulator can be found in aie/graph.cpp:

int value[256];
gr.run(4);
gr.update(gr.value,value,256);

The host code for HW and HW emulation flows can be found in sw/host.cpp:

int value[256];
auto ghdl=xrt::graph(device,uuid,"gr");
const int ITERATION=4;
	
ghdl.run(ITERATION);
ghdl.update("gr.k.in[1]",value);