필터 지우기
필터 지우기

Atan2 block native floating point single HDL generation needs more pipelining

조회 수: 4 (최근 30일)
Hi, I'm using the atan2 block with single precision to generate HDL and with the MAX latency of 42 clocks but it only achieves a clock rate of about 330 MHz (need more like 360 MHz) in my FPGA synthesis run. The critical path seems to be a stage of DSP48's chained together in cascade mode but without pipelining in the cascade. Is there a way to increase the pipelining internal to the atan2 block? Why does this block have no MIN or MAX range (MIN = MAX = 42). I think if you could just add more pipelining it would be able to run much faster. Retiming does not seems to be able to place registers where needed in this case.
  댓글 수: 2
Bharath Venkataraman
Bharath Venkataraman 2022년 8월 10일
Do you need single precision support or do you think fixed-point would work as well? If fixed-point is an option, you can try the Complex to Magnitude Angle block.
Michael Pratt
Michael Pratt 2022년 8월 10일
Yeah I did end up using the Complex to Magnitude Angle block. But I still think the atan2 block's timing could be improved significantly with a few underlying design changes. I discovered that if some bit slicing between the multiply and pipeline delays was moved to after the pipeline delays, synthesis was able to map the pipeline delays properly to the DSP48. The bit slicing gets in the way of optimal synthesis mapping in FPGAs (though the way it's implemented may be preferable for ASIC targets). I've often found that it's hard to make a design optimal for both ASIC and FPGA designs because often a design maps more efficiently for one than the other.

댓글을 달려면 로그인하십시오.

채택된 답변

Kiran Kintali
Kiran Kintali 2024년 5월 29일
편집: Kiran Kintali 2024년 5월 29일
Improved performance for Atan2 block in the R2024a release.
HDL Coder has enhanced the design implementation of the Atan2 block. The generated code for Atan2 blocks now has more pipelined stages and can be operated at higher frequency. This graph in the release note compares maximum frequency and maximum latency of an Atan2 block that has a single-precision floating-point input between R2024a and R2023b.
You can further use custom latency options to control latency on the block.

추가 답변 (1개)

Bharath Venkataraman
Bharath Venkataraman 2022년 8월 11일
I am glad that using the Complex to Magnitude Angle block worked out for you. Adding that option as an answer in case others run into this issue.
I will pass on your feedback to the relevant team.

카테고리

Help CenterFile Exchange에서 Optimization에 대해 자세히 알아보기

제품


릴리스

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by