Skip to content
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

Symbiflow-classroom: Surelog/UHDM and multi-bit input signals #269

Closed
nelsobe opened this issue Mar 9, 2022 · 6 comments
Closed

Symbiflow-classroom: Surelog/UHDM and multi-bit input signals #269

nelsobe opened this issue Mar 9, 2022 · 6 comments

Comments

@nelsobe
Copy link
Contributor

nelsobe commented Mar 9, 2022

SYMBIFLOW-CLASSROOM-PROJECT

Using Surelog/UHDM front end. Obtained from cloning f4pga-examples and then doing:

git pull origin pull/244/head:uhdm;git co uhdm

Attached is a simple design that compiles successfully using
yosys standard frontend. All it does is turn on LEDs when switches are flipped.

This design compiles successfully using SURELOG/UHDM if, instead of naming the
input logic ports iteritavely (sw[0],sw[1],sw[2]),
they are named uniquely (A,B,C).

The issue is shown in compile.log that by the time that the design reaches
Yosys AST, the switch ports have already been flattened which suggests that the
issue resides in Surelog or UHDM.

SwitchBug.zip

@nelsobe nelsobe changed the title Symbiflow-classroom: Surelog/UHDM mishandles multi-bit input signals Symbiflow-classroom: Surelog/UHDM and multi-bit input signals Mar 9, 2022
@kbieganski
Copy link

It does indeed seem to be a bug in Surelog. Filed an issue: chipsalliance/Surelog#2733

@rkapuscik
Copy link
Contributor

The Surelog issue was resolved, but we need to update the plugin to use the newest version. We'll let you know when it's done.

@rkapuscik
Copy link
Contributor

Surelog was updated, this should work now (the AST from plugin looks correct).

@nelsobe
Copy link
Contributor Author

nelsobe commented Mar 29, 2022

@rkapuscik Thanks - I will test it as soon as I can verify it is available. When you say Surelog is updated, what do you mean? Will we get it if we simply re-install f4pga-examples. Or, is there additional work needed to pull it over into f4pga-examples so my student can use it to test with?

@rkapuscik
Copy link
Contributor

Sorry that I wasn't clear enough. By updating Surelog, I mean that

  1. New version of Surelog is available on litex-hub (it is used by conda to setup the tools)
  2. We verify that the new version works with our plugin (tracked in the integration repository)

Reinstalling f4pga-examples will give you the updated version, but you can also update just the conda environment:

conda env update -f xc7/environment.yml

If anything goes wrong, you can also remove and recreate it by

conda env remove -n xc7
conda env create -f xc7/environment.yml

This should give you the updated tools. You can verify which version you have installed by

conda env export -n xc7

@nelsobe
Copy link
Contributor Author

nelsobe commented Apr 15, 2022

@rkapuscik Thanks! Have verified it works, closing issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants