-
Notifications
You must be signed in to change notification settings - Fork 902
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ECP5 LUT6 enhancement #4774
Comments
again, you can use LUT4s and PFUMX/L2MUX6 to build a LUT6, if you need to. but I guess another question is: what do you need direct LUT6 instantiation for? |
Hi Lofty, |
The ECP5 does not have LUT6s in hardware; it has LUT4s, which you can multiplex together to form LUT6s. To make a LUT5, you combine two LUT4s with a PFUMX, with the fifth input as the PFUMX selector. To make a LUT-N (N > 5), you combine two LUT-(N-1)s with an L6MUX21. |
But note that instantiating LUTs directly will usually result in a worse overall result than using soft logic, because this can be optimised and mapped better. |
Sorry to ask but, would it be possible to provide the code for an example? |
Different approach: if you know the LUT mask, you can right-shift it by the LUT inputs (concatenated). |
a cookbook version of @Ravenslofty's last suggestion would be:
|
Jannis, appreciated! however without wishing to appear lazy, could you please include LUT4, as else.... |
The elephant in the bath? |
ECP5 has no LUT6 blocks available in hardware. If the proprietary software pretends otherwise, it's composing them from LUT4.
from Lattice data sheet FPGA-DS-02012-2.4 section 2.2.2.1. The surrounding descriptions and diagrams are helpful as well. Without being more concrete of what you'd like to achieve and how, there's no clear steps for us to take to help. Jannis has shown Verilog code implementing a LUT6. Synthesis will map it to whatever LUTs are available in hardware. Are you trying to instantiate individual LUTs manually? |
ok got it, thanks all! |
arghh: how to set a 6bit mask?.... |
Anyhow, I believe we've concluded discussing the actual declared topic of this issue |
Feature Description
Lattice ECP5 software has support for LUT6, would be helpful to me and possibly others if this was available in open source variant.
see also: YosysHQ/prjtrellis#240
The text was updated successfully, but these errors were encountered: