cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
thisisbaback
Observer
Observer
450 Views
Registered: ‎08-23-2020

FIFO data count in Vivado HLS

Jump to solution

Hello everyone!

I'm designing an IP-Core with Vivado HLS. I have a stream in my design, and I have added the following pragma in my top-level to store that in a FIFO. st_out1 is derived in a function called in the top function.

#pragma HLS STREAM variable=st_out1 depth=2048 dim=1

I want to read this FIFO's data count, and make decisions with respect to this number. I've used the function size(), and it is definitely the data count. It increases by 1 after each write(), and decreases by 1 after each read(). But this can't be synthesized, and the synthesizer reports the size() function can be used only in simulation. The error is like:

ERROR: [XFORM 203-733] Function hls::stream::size() (top.cpp:20:18) is not synthesizable, it can only be used in C simulation.
ERROR: [HLS 200-70] Pre-synthesis failed.

What can I do for this porpuse? How can I measure a stream's data count?

0 Kudos
1 Solution

Accepted Solutions
thisisbaback
Observer
Observer
380 Views
Registered: ‎08-23-2020

I've done this task by making my own data count. But I really like to know if there's a way to measure the data count of a stream in Vivado HLS.

Thanks

View solution in original post

0 Kudos
1 Reply
thisisbaback
Observer
Observer
381 Views
Registered: ‎08-23-2020

I've done this task by making my own data count. But I really like to know if there's a way to measure the data count of a stream in Vivado HLS.

Thanks

View solution in original post

0 Kudos