hls::axis<T> テンプレートは、任意の型をラップする新しい HLS スタイルです。
#include "ap_axi_sdata.h"
#include "hls_stream.h"
void my_kernel(hls::stream<hls::axis<ap_uint<32>>> &in,
hls::stream<hls::axis<ap_uint<32>>> &out) {
#pragma HLS INTERFACE mode=axis port=in
#pragma HLS INTERFACE mode=axis port=out
for (int i = 0; i < 8; i++) {
#pragma HLS PIPELINE II=1
auto word = in.read();
word.data += 10;
out.write(word);
}
}