fastmachinelearning / hls4ml

Machine learning on FPGAs using HLS
https://fastmachinelearning.org/hls4ml
Apache License 2.0
1.27k stars 409 forks source link

Remove io_serial #609

Closed vloncar closed 2 years ago

vloncar commented 2 years ago

Description

Remove the old io_serial from the HLS templates.

Why now? Well, I would like Vitis and Vivado implementations to be as similar as possible (ideally identical) and Vitis changed how PIPELINE pragma can be applied. So constructs like

if (CONFIG_T::io_type == io_parallel){
    #pragma HLS PIPELINE
}

are not allowed anymore, and the function doesn't get pipelined. Since we use this trick to switch between io_parallel and io_serial, removing io_serial will also get rid of the requirement for checking the io_type. This allows the array-based implementations to be identical in Vitis and Vivado (at least it appears so, still need more tests).

Type of change

Tests

No tests, we remove traces of non-functional code.