-
Notifications
You must be signed in to change notification settings - Fork 13
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
Unconnected CARRY4s #53
Comments
So this is what the logic in fasm2bels should be doing |
@mbpeterson70 Please attach a replicating test case (e.g. a bitstream or FASM file). |
Here is a FASM file as well as what fasm2bels outputs. In cpu8080_f2b.v, an example of two problem CARRY4s can be found on lines 19210-19219 (upper CARRY4 block) and 19065-19074 (lower CARRY4 block). |
@litghost do you have any advice about where I should start looking in the code to provide a fix? |
Here's a very simple design with the same issue. It's just a single 16-bit adder, implemented as 4x CARRY4: |
Commit 514cc91 seems to cause the issue, however I don't really have a clue how to set the input of the next CARRY4 element to |
@e7p So, I believe that, even though 514cc91 solved an issue for which the Looking at the current code though, the COUT source should be added here: https://github.com/SymbiFlow/symbiflow-xc-fasm2bels/blob/99ae85f78cc89d3161d6ab58d64b0337c11e2b77/fasm2bels/models/clb_models.py#L1778-L1780. Might be worth investigating what is happening there, and if the COUT source is correctly added to the site |
Actually, the problem is, that the COUT source is not correctly added, as there is already one source existing ( |
I've noticed that Fasm2bels does not seem to be connecting carry chains correctly. As an example, I have a design where the CARRY4 A's carry-in pin (CI) should be driven by the MSB of CARRY4 B's CO wire.
CARRY4 A:
CARRY4B:
However,
CLBLL_L_X2Y109_SLICE_X1Y109_COUT
(which is connected to CARRY4 A's CI pin) is not driven by anything, so the CARRY4s remain unconnected. I've been able to provide a simple fix to my files by adding in an assign statement that would look something like this:assign CLBLL_L_X2Y109_SLICE_X1Y109_COUT = CLBLL_L_X2Y109_SLICE_X1Y109_D_CY;
This is an easy fix, but it would be nice to contribute a fix to the code, however, I am not very familiar with the Fasm2bels code. Could someone point me to where I might start looking in the code to provide a fix? Also, does it seem better to have fasm2bels just insert an assign statement like I did or to just remove the "*_COUT" middle man entirely and drive CI of CARRY4 A with the original *_D_CY output of CARRY4 B?
The text was updated successfully, but these errors were encountered: