Programming FPGAs in C++ | performance vs. time-to-market


There’s an ingrained belief in parts of the industry that high-level language and compilers can never match the performance of native low-level languages. While that may have been true several years ago, our current experience suggests otherwise.

The question every developer or CTO in the trading world needs to ask themselves is, what our priorities are? Do we want to spend a lot of time optimizing and chasing every single nanosecond or do we prefer investing time into testing and flexibly deploying new ideas, new strategies on various markets?
There is no doubt that high-level development tools significantly reduce time-to-market and also extend the range of developers who can create custom FPGA logic. It's no longer necessary to have a team of hardware engineers to deploy a trading strategy in FPGA. You save both money and time.
The question that remains is, how much performance do we need to sacrifice by using these tools?
Our experiments show that the HLS compiler can often match the performance of manually written code and that can give anyone not only the required performance but the desired flexibility as well.

We at Netcope have actually gone so far that in some cases we have managed HLS to beat the native low-level language in terms of performance. That proves that with the right guidance, anyone can achieve the same.
Which is why we provide training and guidelines to teach our clients and their developers how to get the most out of HLS and how to successfully use it for implementing their strategies. By using HLS, clients also obtain a big level of independence even if they only have software engineers in house.

If you would like to know more we had a talk on this topic at the Trading Show Americas event, check it out here: 

Of course, they are certain trade-offs in HLS that need to be noted. Not a full specification of the C/C++ language is supported, some constructs like recursion, dynamic memory allocation, unconstrained loops have to be avoided. But again, we believe that with the right guidance and partnership you can easily overcome these challenges and be successful.

We have put together HLS coding guidelines where we summed up the recommendations and good coding practice suggestions based on our experience to achieve good performance results with HLS compilation using Vivado HLS. 
If you are interested in reading this document, please contact us.

For further details about this topic check out the white paper written by Bittware.
If this is intriguing for you, get in touch with us. We would be happy to talk and dive deeper into the subject.