f4pga-arch-defs icon indicating copy to clipboard operation
f4pga-arch-defs copied to clipboard

Add techmap for LDCE

Open rw1nkler opened this issue 4 years ago • 4 comments

This commit adds missing LDCE latch techmap. The Xilinx documentation of the primitive is available in [HERE]

rw1nkler avatar Apr 14 '20 13:04 rw1nkler

@litghost is there any reason this pull request hasn't been merged other than a rebase? I have recently run into the issue with LDCEs being generated instead of LDCE_ZINIs and this seems to be the solution.

andrewb1999 avatar Mar 04 '21 18:03 andrewb1999

@litghost is there any reason this pull request hasn't been merged other than a rebase? I have recently run into the issue with LDCEs being generated instead of LDCE_ZINIs and this seems to be the solution.

I don't remember, but I believe this was not enough for LDCE support. In general, latches are not something that should be present in pure FPGA designs, so we haven't prioritized implementing support for them. Are you confident that your design should contain latches?

litghost avatar Mar 04 '21 22:03 litghost

I don't remember, but I believe this was not enough for LDCE support. In general, latches are not something that should be present in pure FPGA designs, so we haven't prioritized implementing support for them. Are you confident that your design should contain latches?

I am definitely not convinced that the design should have latches, but they are inferred by yosys. Is there something I should be doing to prevent yosys from inferring them?

andrewb1999 avatar Mar 06 '21 17:03 andrewb1999

I don't remember, but I believe this was not enough for LDCE support. In general, latches are not something that should be present in pure FPGA designs, so we haven't prioritized implementing support for them. Are you confident that your design should contain latches?

I am definitely not convinced that the design should have latches, but they are inferred by yosys. Is there something I should be doing to prevent yosys from inferring them?

Latches occur when you improperly define the process/state transition. I'm not an expert in HDL, here is an article that speaks to this kind of thing: https://www.nandland.com/articles/how-to-avoid-transparent-latches-in-vhdl-and-verlog.html

Learn how to avoid creating latches by accident. Latches are almost always bad to use in your FPGA design, avoid them!

litghost avatar Mar 08 '21 20:03 litghost