HLS & LLVM
Last few days I learned that the C++ translation to IR requires AST (abstract syntax tree), and it seems to me that this is much the same as the HLS. From HLS (high leve synthesis) tool, you input a C++ code and output a RTL, usualy verilog code, which is a hardware descriptoin language. I learned HLS and used tools before, for FPGA mapping we use Vivado HLS, or called Vitis now (original owned by Xilinx, which is aquired by AMD). I think if we can leverage the same technique, perhaps we can do the same techqiue and map arbitary C++ code to RTL. ...