MCPcopy Create free account
hub / github.com/definelicht/hlslib / MultiStageAdd

Function MultiStageAdd

xilinx_test/kernels/MultiStageAdd.cpp:34–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

32}
33
34void MultiStageAdd(Data_t const *memoryIn, Data_t *memoryOut) {
35 #pragma HLS INTERFACE m_axi port=memoryIn offset=slave bundle=gmem0
36 #pragma HLS INTERFACE m_axi port=memoryOut offset=slave bundle=gmem1
37 #pragma HLS INTERFACE s_axilite port=memoryIn bundle=control
38 #pragma HLS INTERFACE s_axilite port=memoryOut bundle=control
39 #pragma HLS INTERFACE s_axilite port=return bundle=control
40 #pragma HLS DATAFLOW
41 HLSLIB_DATAFLOW_INIT();
42 hlslib::Stream<Data_t> pipes[kStages + 1];
43 HLSLIB_DATAFLOW_FUNCTION(MemoryToStream, memoryIn, pipes[0]);
44MultiAddStages:
45 for (int i = 0; i < kStages; ++i) {
46 #pragma HLS UNROLL
47 HLSLIB_DATAFLOW_FUNCTION(AddStage, pipes[i], pipes[i + 1]);
48 }
49 HLSLIB_DATAFLOW_FUNCTION(StreamToMemory, pipes[kStages], memoryOut);
50 HLSLIB_DATAFLOW_FINALIZE();
51}

Callers 1

TestStream.cppFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected