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

Yosys ABC Tool crashes with exit code 139 #2124

Open
Fabbboy opened this issue May 22, 2024 · 7 comments
Open

Yosys ABC Tool crashes with exit code 139 #2124

Fabbboy opened this issue May 22, 2024 · 7 comments
Labels
blocked This issue is blocked on a bugfix or enhancement of another repository or tool bug Something isn't working Yosys This issue is related to yosys

Comments

@Fabbboy
Copy link

Fabbboy commented May 22, 2024

Description

I encountered a segmentation fault in the ABC tool while trying to build a Verilog project within the OpenLane container. Despite attempting to resolve all warnings and even reducing the codebase to its minimal form, the error persists. This issue occurs during the synthesis stage managed by Yosys, specifically when executing ABC for technology mapping.

I'm not sure if I have to report this here or in the Yosys Project

Expected Behavior

The ABC tool shouldn't crash

Environment report

Failed to get distribution info.
open_pdks bdc9412b3e468c102d01b7cf6337be06ec6e9c9a
Kernel: Linux v5.15.146.1-microsoft-standard-WSL2
Python: v3.11.6 (OK)
Critical Alert: No Docker or Docker-compatible container engine was found.
OpenLane Git Version: 77eb5ffc00966b47b36e332ccbf42103eb95e974
python-venv: INSTALLED
---
PDK Version Verification Status: OK
---
Git Log (Last 3 Commits)

77eb5ff 2024-05-13T09:25:58+03:00 remove thread count from volare - Mohamed Gaber -  (grafted, HEAD -> master, tag: 2024.05.14, origin/master, origin/HEAD)
---
Git Remotes

origin  https://github.com/The-OpenROAD-Project/OpenLane.git (fetch)
origin  https://github.com/The-OpenROAD-Project/OpenLane.git (push)

Reproduction material

issue_reproducible.zip

Relevant log output

$ ../../flow.tcl -design ./ -tag build -overwrite
[....]

[STEP 1]
[INFO]: Running Synthesis (log: runs/build/logs/synthesis/1-synthesis.log)...
[ERROR]: during executing yosys script /openlane/scripts/yosys/synth.tcl
[ERROR]: Log: runs/build/logs/synthesis/1-synthesis.log
[ERROR]: Last 10 lines:
[INFO]: USING STRATEGY AREA 0

59. Executing ABC pass (technology mapping using ABC).

59.1. Extracting gate netlist of module `\fx32' to `/tmp/yosys-abc-NMil3M/input.blif'..
Extracted 32 gates and 33 wires to a netlist network with 0 inputs and 32 outputs.

59.1.1. Executing ABC.
ERROR: ABC: execution of command ""/nix/store/5bgsgwzww9f2z7wl7kga42xrf1vpmnql-yosys-abc/bin/abc" -s -f /tmp/yosys-abc-NMil3M/abc.script 2>&1" failed: return code 139.
child process exited abnormally

[ERROR]: Creating issue reproducible...
[INFO]: Saving runtime environment...

[....]

[ERROR]: Step 1 (synthesis) failed with error:
-code 1 -level 0 -errorstack {INNER {invokeStk1 throw_error} CALL {run_tcl_script -tool yosys -no_consume /openlane/scripts/yosys/synth.tcl -indexed_log /openlane/designs/fx32/runs/build/logs/synthesis/1-synthesis.log} CALL {run_yosys_script /openlane/scripts/yosys/synth.tcl -indexed_log /openlane/designs/fx32/runs/build/logs/synthesis/1-synthesis.log} CALL {run_yosys -indexed_log /openlane/designs/fx32/runs/build/logs/synthesis/1-synthesis.log} CALL run_synthesis CALL {run_non_interactive_mode -design ./ -tag build -overwrite}} -errorcode NONE -errorinfo {
    while executing
"throw_error"
    (procedure "run_tcl_script" line 219)
    invoked from within
"run_tcl_script -tool yosys -no_consume {*}$args"
    (procedure "run_yosys_script" line 2)
    invoked from within
"run_yosys_script $::env(SYNTH_SCRIPT) -indexed_log $arg_values(-indexed_log)"
    (procedure "run_yosys" line 40)
    invoked from within
"run_yosys -indexed_log $log"
    (procedure "run_synthesis" line 13)
    invoked from within
"run_synthesis"} -errorline 1
[INFO]: Saving current set of views in 'runs/build/results/final'...
[INFO]: Generating final set of reports...
[INFO]: Created manufacturability report at 'runs/build/reports/manufacturability.rpt'.
[INFO]: Created metrics report at 'runs/build/reports/metrics.csv'.
[INFO]: Saving runtime environment...
[ERROR]: Flow failed.
@kareefardi
Copy link
Collaborator

@Fabbboy The issue reproducible is missing some files. Since this crash happens early in the flow, can you upload your input files (config, rtl, gds..)? It will also be useful to determine if there is an issue in producing the reproducibles in OpenLane.

@Fabbboy
Copy link
Author

Fabbboy commented May 28, 2024

This is weird. I just zipped the folder and did not change anything. Sadly I currently have no more access to the project.... This was kinda dumb. I give my best to recover it.

@Fabbboy
Copy link
Author

Fabbboy commented May 29, 2024

@kareefardi
-I'm not able to upload the project because it's too big. How should I provide it to you?-

I'm able to upload the project file but I'm not able to compress the whole logs to less or equal the limit I have.

fx32.zip

@Fabbboy
Copy link
Author

Fabbboy commented May 29, 2024

@kareefardi
Copy link
Collaborator

@Fabbboy I can confirm the issue. I will try compiling the latest yosys and see if the crash persists.

@kareefardi kareefardi added bug Something isn't working Yosys This issue is related to yosys labels Jun 23, 2024
@Fabbboy
Copy link
Author

Fabbboy commented Jun 23, 2024

Perfect I'm glad its not my fault

@kareefardi kareefardi moved this to New in OpenLane Jun 25, 2024
@kareefardi
Copy link
Collaborator

Created a test case and submitted an issue to Yosys YosysHQ/yosys#4473

@kareefardi kareefardi added the blocked This issue is blocked on a bugfix or enhancement of another repository or tool label Aug 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked This issue is blocked on a bugfix or enhancement of another repository or tool bug Something isn't working Yosys This issue is related to yosys
Projects
None yet
Development

No branches or pull requests

2 participants