-
Notifications
You must be signed in to change notification settings - Fork 53
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
tdcc
: Invalid code generated when done
depends on input signal
#621
Comments
The problem is the implementation of
The input signal
The group essentially says that "keep the connection The reason the |
tcam/lpm.futil
testtop-down-cc
: Invalid code generated when done
depends on input signal
The solution to fix issue is making it invalid for the Also, out of curiosity, @cgyurgyik is there a reason |
Also, FWIW, |
I haven't had a moment to look more in-depth, but isn't this the same interface as the Calyx representation of memory, without an address port? Edit: |
Yeah, I just implemented a fix for the problem in #624 and realized that this way of "passing registers/memories by reference" doesn't actually work at all. |
Following up on @rachitnigam's call for deeper thinking on this in #624 (comment): this is an intriguing issue, but I don't fully understand the implications yet. To summarize what I think I understand:
Anyway, seems like a synchronous conversation with at least me, @rachitnigam, and @EclecticGriffin is in order… |
It's annoying to articulate but basically two things need to be true for the cycle to happen:
This leaves us with two distinct problems:
|
Got it; thanks for the explanation! Perhaps stating the obvious again, but this sort of "pass-by-reference" thing needn't be exclusive to combinational situations… you can imagine the same setup being relevant in a situation where everything is sequential. You won't end up with a combinational cycle then (?), but maybe the consequences are still weird. |
Yeah, that seems to be the case---sequential implementation of "pass-by-reference" works fine. Maybe we should require that the group using |
Huh, yeah. Enthusiastic yes to a broader conversation; this is a tricky issue. If the issue is mainly confined to the combinational case, there's a chance the underlying issue is not so much I guess I'm optimistic that we can somehow confine the confusion by creating a special designation for "combinational components" and requiring "normal" components to be sequential. |
Another ponderous solution to this problem, or rather a guarantee that should possibly be provided by the compiler, is that there is no combinational path between a component's |
top-down-cc
: Invalid code generated when done
depends on input signaltdcc
: Invalid code generated when done
depends on input signal
To reproduce, run:
The reason we haven't caught this before is because this doesn't occur with the
static-timing
pass performs the compilation. I have not reduced which pass causes this issue.The text was updated successfully, but these errors were encountered: