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

Is it possible to use newer versions of Verilator and FuseSOC #2116

Open
Aaronyap2002 opened this issue Dec 19, 2023 · 9 comments
Open

Is it possible to use newer versions of Verilator and FuseSOC #2116

Aaronyap2002 opened this issue Dec 19, 2023 · 9 comments
Labels
Type:Question Questions

Comments

@Aaronyap2002
Copy link

Aaronyap2002 commented Dec 19, 2023

The version suggested in this repository is 4.104. Is it possible to use version 4.210, or even 5.107? Or should I install 2 versions of verilator? The reason is because i would like to build the docker container according to the instruction in ibex-demo-system, but the verilator version stated in container/Dockerfile mentioned

# Global configuration options.
ARG VERILATOR_VERSION=4.210
ARG VERIBLE_VERSION=v0.0-2135-gb534c1fe
ARG RISCV_TOOLCHAIN_RELEASE_TAG=20220210-1

This caused my docker to continue looping 5/17.

[+] Building 1483.6s (8/21)                                                             docker:default
 => [internal] load build definition from Dockerfile                                              0.9s
 => => transferring dockerfile: 3.84kB                                                            0.0s
 => [internal] load .dockerignore                                                                 1.2s
 => => transferring context: 2B                                                                   0.0s
 => [internal] load metadata for docker.io/library/ubuntu:20.04                                   4.6s
 => [ 1/17] FROM docker.io/library/ubuntu:20.04@sha256:f2034e7195f61334e6caff6ecf2e965f92d11e888  8.2s
 => => resolve docker.io/library/ubuntu:20.04@sha256:f2034e7195f61334e6caff6ecf2e965f92d11e88830  0.4s
 => => sha256:f2034e7195f61334e6caff6ecf2e965f92d11e888309065da85ff50c617732b8 1.13kB / 1.13kB    0.0s
 => => sha256:bac6081102aae54ba4bcc714695b8f637e42768c7f376f374c428bab043ddc0f 424B / 424B        0.0s
 => => sha256:f78909c2b360d866b3220655c0b079838258b8891a12ac25fc670f0cbb54229f 2.30kB / 2.30kB    0.0s
 => => sha256:527f5363b98e562da03d2e0bbf86fd7c34f487bffd9b27a3cf0a9afea2f0ee1f 27.51MB / 27.51MB  5.0s
 => => extracting sha256:527f5363b98e562da03d2e0bbf86fd7c34f487bffd9b27a3cf0a9afea2f0ee1f         1.3s
 => [internal] load build context                                                                 0.8s
[+] Building 1483.7s (8/21)                                                             docker:default
 => => sha256:bac6081102aae54ba4bcc714695b8f637e42768c7f376f374c428bab043ddc0f 424B / 424B        0.0s
 => => sha256:f78909c2b360d866b3220655c0b079838258b8891a12ac25fc670f0cbb54229f 2.30kB / 2.30kB    0.0s
 => => sha256:527f5363b98e562da03d2e0bbf86fd7c34f487bffd9b27a3cf0a9afea2f0ee1f 27.51MB / 27.51MB  5.0s
 => => extracting sha256:527f5363b98e562da03d2e0bbf86fd7c34f487bffd9b27a3cf0a9afea2f0ee1f         1.3s
 => [internal] load build context                                                                 0.8s
 => => transferring context: 15.44kB                                                              0.0s
 => [ 2/17] RUN ln -sf /bin/bash /bin/sh                                                          3.6s
 => [ 3/17] RUN OBS_URL="https://download.opensuse.org/repositories";     OBS_PATH="/home:/phiw  85.1s
 => [ 4/17] COPY container/apt-requirements.txt /tmp/apt-requirements.txt                         1.4s
 => [ 5/17] RUN echo "verilator-4.210" >> /tmp/apt-requirements.txt     && sed -i -e '/^$/d'   1379.1s

I am worried that if i update to the newest version, i might not be able to build the simulation.

On a side note, I thought of upgrading FuseSOC to the latest one too. Is it advisable to do it?

@Aaronyap2002 Aaronyap2002 added the Type:Question Questions label Dec 19, 2023
@Aaronyap2002 Aaronyap2002 changed the title Is it possible to use newer versions of Verilator Is it possible to use newer versions of Verilator and FuseSOC Dec 19, 2023
@utku1998
Copy link

I have updated the fusesoc to the latest version (2.3), but now I cannot build the simulation, although it works fine before. Now I get the following error:

"""
...
Error validating data.filesets.files_verilator_waiver.files must be array
WARNING: Parse error. Ignoring file ./vendor/lowrisc_ip/ip/prim_generic/prim_generic_and2.core:
Error validating data.filesets.files_verilator_waiver.files must be array
ERROR: Conflicting requirements:
Requirements: 'lowrisc_ibex_ibex_simple_system == 0-0' <- 'lowrisc_ibex_ibex_simple_system_core >= 0-0' <- 'lowrisc_ibex_sim_shared >= 0-0' <- 'lowrisc_prim_ram_1p >= 0-0'
+lowrisc_ibex_sim_shared-0-0 was ignored because it depends on missing packages
Requirements: 'lowrisc_ibex_ibex_simple_system == 0-0' <- 'lowrisc_ibex_ibex_simple_system_core >= 0-0' <- 'lowrisc_ibex_sim_shared >= 0-0'
lowrisc_ibex_ibex_simple_system_core-0-0 requires (+lowrisc_ibex_sim_shared-0-0)
Requirements: 'lowrisc_ibex_ibex_simple_system == 0-0' <- 'lowrisc_ibex_ibex_simple_system_core >= 0-0'
lowrisc_ibex_ibex_simple_system-0-0 requires (+lowrisc_ibex_ibex_simple_system_core-0-0)
Requirements: 'lowrisc_ibex_ibex_simple_system == 0-0'
Install command rule (+lowrisc_ibex_ibex_simple_system-0-0)

Failed to resolve dependencies for lowrisc:ibex:ibex_simple_system:0
"""

Is there a solution for that? And what version should I use? Since, I don't remember what was the version that works, I can't build the simulation again!

@Aaronyap2002
Copy link
Author

Aaronyap2002 commented Dec 19, 2023

i checked my version is 0.1. I can't remember how i installed my fusesoc, but yeah i got the 0.1 instead.
Thanks for letting me know about it!

@utku1998
Copy link

utku1998 commented Dec 19, 2023

Now, I have tried with all of the versions listed here: "1.4, 1.5, 1.6, 1.6.1, 1.7, 1.8, 1.8.1, 1.8.2, 1.8.3, 1.8.4, 1.9, 1.9.1, 1.9.2, 1.9.3, 1.10, 1.11.0, 1.12.0, 2.0rc1, 2.0, 2.1, 2.2, 2.2.1, 2.3" and it worked for 2.0. I checked the version and 2.0 was there.

But then when I try to build the system again, I got the following error: "Key 'cores' not found in GAPI structure. Install a compatible version with 'pip3 install --user -r python-requirements.txt'."" Once I installed the requirements, I could build the system. But now, fusesoc --version command prints "0.1".

I did not understand how it worked, but it worked, although there is no version like "0.1" listed there.

@Aaronyap2002
Copy link
Author

That's interesting! Have you tried using different versions of verilator as well? Is it possible to share the commands you've used to install different versions of FuseSOC, i would like to replicate it myself too.

@utku1998
Copy link

utku1998 commented Dec 19, 2023

I did not try it. Currently, I am using the version "Verilator 5.018 2023-10-30 rev v5.018-38-g344f87abe".

The commands are:

  1. Uninstall the Current Version: pip uninstall fusesoc
  2. Install the Desired Version: pip install fusesoc==2.0
  3. Verify the Installation: fusesoc --version

Please let me know, if you learn something new!

@NovaWu
Copy link

NovaWu commented Mar 21, 2024

I have updated the fusesoc to the latest version (2.3), but now I cannot build the simulation, although it works fine before. Now I get the following error:

""" ... Error validating data.filesets.files_verilator_waiver.files must be array WARNING: Parse error. Ignoring file ./vendor/lowrisc_ip/ip/prim_generic/prim_generic_and2.core: Error validating data.filesets.files_verilator_waiver.files must be array ERROR: Conflicting requirements: Requirements: 'lowrisc_ibex_ibex_simple_system == 0-0' <- 'lowrisc_ibex_ibex_simple_system_core >= 0-0' <- 'lowrisc_ibex_sim_shared >= 0-0' <- 'lowrisc_prim_ram_1p >= 0-0' +lowrisc_ibex_sim_shared-0-0 was ignored because it depends on missing packages Requirements: 'lowrisc_ibex_ibex_simple_system == 0-0' <- 'lowrisc_ibex_ibex_simple_system_core >= 0-0' <- 'lowrisc_ibex_sim_shared >= 0-0' lowrisc_ibex_ibex_simple_system_core-0-0 requires (+lowrisc_ibex_sim_shared-0-0) Requirements: 'lowrisc_ibex_ibex_simple_system == 0-0' <- 'lowrisc_ibex_ibex_simple_system_core >= 0-0' lowrisc_ibex_ibex_simple_system-0-0 requires (+lowrisc_ibex_ibex_simple_system_core-0-0) Requirements: 'lowrisc_ibex_ibex_simple_system == 0-0' Install command rule (+lowrisc_ibex_ibex_simple_system-0-0)

Failed to resolve dependencies for lowrisc:ibex:ibex_simple_system:0 """

Is there a solution for that? And what version should I use? Since, I don't remember what was the version that works, I can't build the simulation again!

——————————————————————————
I also encountered the same problem, please tell me how you solved it?

@thepalbi
Copy link

thepalbi commented May 9, 2024

I was able to build correctly simple_system, following the instructions here. First, I got this same error when trying to use fusesoc installed through my package manger (2.3), and then checking how the CI installs it, found that inside the python requirements, a fork of fusesoc is used.

I'd recommend creating a python virtualenv, installing the requirements there, and using the fusesoc version shipped there:

python -m venv env
source env/bin/activate
pip install -r python-requirements.txt
which fusesoc
fusesoc --version # should return 0.1

@Kreijstal
Copy link

why is fusesoc 2.3 not supported, why can't the changes be upstreamed?

@Kreijstal
Copy link

I just saw the upstream changes of fusesoc, and the changes are ... linting?
https://github.com/lowRISC/fusesoc/

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

No branches or pull requests

5 participants