The-OpenROAD-Project / OpenROAD-flow-scripts

OpenROAD's scripts implementing an RTL-to-GDS Flow. Documentation at https://openroad-flow-scripts.readthedocs.io/en/latest/
https://theopenroadproject.org/
Other
282 stars 262 forks source link

Excute yosys returns an error message #2035

Closed Bob0111 closed 1 month ago

Bob0111 commented 1 month ago

Subject

[Flow] for any util, flow Makefile, or flow script issues.

Describe the bug

I install openroad form pre-built binaries, and set the environment path as mentioned in https://openroad-flow-scripts.readthedocs.io/en/latest/user/BuildWithPrebuilt.html. But when I do a make in flow directory, it gives me the logs with errors:

mkdir -p ./results/nangate45/gcd/base ./logs/nangate45/gcd/base ./reports/nangate45/gcd/base ./objects/nangate45/gcd/base (/usr/bin/time -f 'Elapsed time: %E[h:]min:sec. CPU time: user %U sys %S (%P). Peak memory: %MKB.' /usr/bin/yosys -v 3 -c /home/lenovo/git-project/OpenROAD-flow-scripts/flow/scripts/synth.tcl) 2>&1 | tee ./logs/nangate45/gcd/base/1_1_yosys.log

  1. Executing Verilog-2005 frontend: ./designs/src/gcd/gcd.v
  2. Executing Liberty frontend: ./objects/nangate45/gcd/base/lib/NangateOpenCellLibrary_typical.lib
  3. Executing Verilog-2005 frontend: /home/lenovo/git-project/OpenROAD-flow-scripts/flow/platforms/nangate45/cells_clkgate.v Using ABC area script. [FLOW] Extracting clock period from SDC file: ./results/nangate45/gcd/base/clock_period.txt [FLOW] Setting clock period to 0.46 ERROR: TCL interpreter returned an error: Yosys command produced an error Command exited with non-zero status 1 Elapsed time: 0:00.11[h:]min:sec. CPU time: user 0.09 sys 0.01 (99%). Peak memory: 29056KB. make[1]: [Makefile:501: do-yosys] Error 1 make: [Makefile:504: results/nangate45/gcd/base/1_1_yosys.v] Error 2

I have tried to change the design config file but it didn't work. From the above log, it seems like the bug is related to yosys.

Expected Behavior

Output logs without errors and generate the gds file successfully.

Environment

[WARNING] Your current OpenROAD version is outdated.
It is recommened to pull the latest changes.
If problem persists, file a github issue with the re-producible test case.
kernel: Linux 6.7.12-amd64
os: Debian GNU/Linux 
cmake version 3.29.3
CMake Error: The source directory "/home/lenovo/git-project/OpenROAD-flow-scripts" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.

I use the newest pre-built OpenRoad binaries, so ignore the cmake error.

To Reproduce

Run make command in the flow directory.

Relevant log output

mkdir -p ./results/nangate45/gcd/base ./logs/nangate45/gcd/base ./reports/nangate45/gcd/base ./objects/nangate45/gcd/base
(/usr/bin/time -f 'Elapsed time: %E[h:]min:sec. CPU time: user %U sys %S (%P). Peak memory: %MKB.' /usr/bin/yosys -v 3 -c /home/lenovo/git-project/OpenROAD-flow-scripts/flow/scripts/synth.tcl) 2>&1 | tee ./logs/nangate45/gcd/base/1_1_yosys.log
1. Executing Verilog-2005 frontend: ./designs/src/gcd/gcd.v
2. Executing Liberty frontend: ./objects/nangate45/gcd/base/lib/NangateOpenCellLibrary_typical.lib
3. Executing Verilog-2005 frontend: /home/lenovo/git-project/OpenROAD-flow-scripts/flow/platforms/nangate45/cells_clkgate.v
Using ABC area script.
[FLOW] Extracting clock period from SDC file: ./results/nangate45/gcd/base/clock_period.txt
[FLOW] Setting clock period to 0.46
ERROR: TCL interpreter returned an error: Yosys command produced an error
Command exited with non-zero status 1
Elapsed time: 0:00.11[h:]min:sec. CPU time: user 0.09 sys 0.01 (99%). Peak memory: 29056KB.
make[1]: *** [Makefile:501: do-yosys] Error 1
make: *** [Makefile:504: results/nangate45/gcd/base/1_1_yosys.v] Error 2

Screenshots

No response

Additional Context

No response

vijayank88 commented 1 month ago

yosys -V just check yosys accessible and which version you're using?

Bob0111 commented 1 month ago

Here is the version information of yosys and klayout:

Yosys 0.33 (git sha1 2584903a060) KLayout 0.29.1

According to the document, I need yosys newer than 0.21 and klayout newer than 0.28.8. Both are satisfied.

rovinski commented 1 month ago

@Bob0111 The document is out of date. I believe right now Yosys 0.39 is required.

Bob0111 commented 1 month ago

Thanks for updating the document. With the updated version of yosys, I can run the flow without problem and successfully generate GDS file.