11-24-2020 07:40 PM
I have found a incompatible features of using hls:stream interfaces with global memory interfaces in sw emu mode.
For instance, here's two kernels: DataLoad and DataStore. DataLoad is designed to fetch data from independent HBM banks and pass the data stream to DataStore, which then store the data back to a different HBM banks. The codes are as following:
--------------------------------------
-------------------------------------------------------
It was found that when performing sw emulation, all buffers could only be allocated to HBM[0], otherwise, the following ERROR will show up:
[XRT] WARNING: Argument '1' of kernel 'DataLoad' is allocated in memory bank 'HBM[0]'; compute unit 'DataLoad_1' cannot be used with this argument and is ignored.
[XRT] ERROR: kernel 'DataLoad' has no compute units to support required argument connectivity.
ERROR: clSetKernelArg() for kernel "DataLoad", argument index 1.
host/main.cpp:184 Error calling err = krnl_load.setArg(narg++, buffer_c), error code is: -4
Attached is the Vitis project, in which I have forced all buffers to be allocated in HBM[0]. And if not, the above erros will show up.
11-26-2020 09:29 PM
Hi @doonny
The description is incomplete.
Kindly provide more details about the platform, steps and references
11-27-2020 01:44 AM
Hi @nutang
I am using the U50 card on a Ubuntu 18.04.4 LTS machine with Vitis 2020.1 SDK.
I wrote a simple program to test the use of streaming interfaces between two kernels like this:
When performing sw emulation, the runtime give error showing that DataLoad only has access to HBM[0] and host program could not locate buffers in HBM[2]. But the same program works fine on FPGA board with no error. It seems that the runtime failed to connect DataLoad kernel with HBM[2] when performing emulation.
And this error only show when I added the hls::streaming interfaces between two kernels. If I use only One Kernel to fetch and store data (like the hbm_simple exampel did) there will not be any issues when performing emulation.
So my guess was that the hls::stream interface has issue with the HBM multi-bank configuration in emulation runtime.