How to use FPGA multiplier efficiently?
10 views (last 30 days)
Show older comments
I have a timing warning for my compiled HDL code and this is caused by a product block in my Simulink model.
The data type of both inputs is fixdt(1,32,16, 'DataTypeOverride', 'Off'). And both input signals to the product block are delayed by a delay block with an order of 1. This is also done for the output of the product block.
My assumption is that the realization of the product in the HDL generation is done unfavorable. So that the corresponding registers of a multiplier cell in my FPGA are not used and instead extern registers were used which leads to an unwanted delay and this causes the timing violation.
Is there a possibility to configure the product bloc in a way, that the FPGA multiplier cells are used efficiently?
0 Comments
Answers (2)
Bharath Venkataraman
on 3 Dec 2015
Can you see what kind of reset you used for the HDL code? You likely want to set the register to have synchronous reset - this can be done by going to the Configuration Parameters for the model, then going to the HDL Coder pane.
It may also help to reduce your multiplier width - typically, widths of 18 bits or less produce best timing results.
Another option is to increase the pipelining on both sides of the multiplier.
Bharath Venkataraman
on 7 Dec 2015
Open the model, hit Ctrl-E and the Configuration Parameters dialog should open. Click into the HDL Code Generation section and go to Global Settings. You should see the Rest type under Clock settings.
The option to split into smaller multipliers was answered in this post: http://www.mathworks.com/matlabcentral/answers/224202-hdl-coder-pipelined-multipliers-in-logic
See Also
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!