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

ABC compilation fails in arch armv71 #2

Open
rodrigomelo9 opened this issue Feb 14, 2021 · 9 comments
Open

ABC compilation fails in arch armv71 #2

rodrigomelo9 opened this issue Feb 14, 2021 · 9 comments
Labels
help wanted Extra attention is needed

Comments

@rodrigomelo9
Copy link
Contributor

After run ./base.sh, then ./yosys.sh (I installed tcl and python, see #1):

[ 94%] ABC: `` Generating dependency: /src/bdd/reo/reoApi.c
[ 94%] ABC: `` Generating dependency: /src/bdd/mtr/mtrGroup.c
make[1]: * duping jobs pipe: Bad file descriptor.  Stop.
make[1]: * Waiting for unfinished jobs....
make: * [Makefile:752: abc/abc-4f5f73d] Error 2
@rodrigomelo9
Copy link
Contributor Author

rodrigomelo9 commented Feb 14, 2021

Maybe related:

make[1]: Entering directory '/data/data/com.termux/files/home/Termux-packages/scripts/yosys/abc'
Using CC=gcc
Using CXX=g++
Using AR=ar
Using LD=g++
CANNOT LINK EXECUTABLE "gcc": library "libiconv.so" not found
Compiling with CUDD
Using libreadline
Using pthreads
CANNOT LINK EXECUTABLE "gcc": library "libiconv.so" not found
Found GCC_VERSION
CANNOT LINK EXECUTABLE "gcc": library "libiconv.so" not found
CANNOT LINK EXECUTABLE "gcc": library "libiconv.so" not found
Found GCC_MAJOR>=5

Seems a missing library. I will investigate.

@umarcor
Copy link
Member

umarcor commented Feb 14, 2021

Maybe pkg install libiconv? It exists for aarch64.

Alternatively, you can try building Yosys without ABC: ENABLE_ABC=0.

@rodrigomelo9
Copy link
Contributor Author

In make -j4 install ... I removed -j4 and it compiles (it takes around 12 hours XD).

However, I detect some problems:

  • Executing yosys and running an invalid command (such as quit) it produces the message ERROR: No such command: quit (type 'help' for a command overview) (which is ok) following by a Segmentation fault (which is wrong). Maybe something to report in Yosys?
  • I tried the following:
    • git clone https://github.com/PyFPGA/pyfpga
    • cd poc/os-mix
    • yosys -p 'read_verilog blinking.v; read_verilog top.v; synth_ice40 -top Top -json blinking.json'
      It works on my PC (using the newest hdlc/yosys) but it fails in Termux (last version from Google Play on Android 9):
3.39.2. Continuing TECHMAP pass.
No more expansions possible.
<suppressed ~4 debug messages>

3.40. Executing ABC pass (technology mapping using ABC).
ERROR: Assert `p != NULL' failed in kernel/yosys.cc:453.

Could you verify what happens on your mobile?

@umarcor
Copy link
Member

umarcor commented Feb 15, 2021

You need to pass -noabc to synth_ice40, since you built Yosys without ABC. See http://www.clifford.at/yosys/cmd_synth_ice40.html. Maybe this can be changed upstream so that Yosys does not try to use ABC.

With regard to the Segmentation fault, I guess it can be reported to Yosys maintainers. However, I would expect it to be a very low priority issue, because testing is a PITA.

@rodrigomelo9
Copy link
Contributor Author

I built Yosys with ABC support (I only remove -j4 from the make instruction).

Anyway, adding -noabc it works.

@umarcor
Copy link
Member

umarcor commented Feb 15, 2021

built Yosys with ABC support

Did you fix the issue with libiconv?

@rodrigomelo9
Copy link
Contributor Author

Did you fix the issue with libiconv?

Not yet. Running now trying a workaround :P

@rodrigomelo9
Copy link
Contributor Author

Running LD_LIBRARY_PATH=$PREFIX/lib ./yosys.sh' the make -j4 ...` instruction works, but it still fails in synthesis (same error).

@umarcor umarcor added the help wanted Extra attention is needed label Feb 16, 2021
@rodrigomelo9
Copy link
Contributor Author

I installed the last Termux from F-Droid. There, no complaints about libiconv, but still problems with 4 jobs:
yosys.log

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants