ucb-bar / chipyard

An Agile RISC-V SoC Design Framework with in-order cores, out-of-order cores, accelerators, and more
https://chipyard.readthedocs.io/en/stable/
BSD 3-Clause "New" or "Revised" License
1.57k stars 620 forks source link

Regression: Verilator emulator options no longer recognized or displayed in help text, e.g. --cycle-count, --vcd #1609

Open JL102 opened 11 months ago

JL102 commented 11 months ago

Background Work

Chipyard Version and Hash

Affected release: 1.10.0 Affected hash: b7644b2455cc4bae190e811a5d8085f3aad85b87

Working release: 1.9.1 Working hash: 968b207ccade6f61d6f9bb2e19a54781d4a96f26

OS Setup

Linux JDESK 5.15.90.1-microsoft-standard-WSL2 #1 SMP Fri Jan 27 02:56:13 UTC 2023 x86_64 GNU/Linux

No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 20.04.6 LTS
Release:        20.04
Codename:       focal

SHELL=/bin/bash
NVM_INC=/home/drak/.nvm/versions/node/v18.12.1/include/node
WSL2_GUI_APPS_ENABLED=1
CONDA_EXE=/home/drak/.local/miniforge3/bin/conda
_CE_M=
WSL_DISTRO_NAME=Ubuntu
WT_SESSION=b40d23d0-abd8-44aa-b51d-565b4fc43608
JAVA_HOME=/home/drak/chipyard_origin/.conda-env/lib/jvm
JAVA_LD_LIBRARY_PATH=/home/drak/chipyard_origin/.conda-env/lib/jvm/lib/server
XML_CATALOG_FILES=file:///home/drak/chipyard_origin/.conda-env/etc/xml/catalog file:///etc/xml/catalog
NAME=JDESK
PWD=/home/drak/chipyard_origin/sims/verilator
GSETTINGS_SCHEMA_DIR=/home/drak/chipyard_origin/.conda-env/share/glib-2.0/schemas
LOGNAME=drak
CONDA_PREFIX=/home/drak/chipyard_origin/.conda-env
GSETTINGS_SCHEMA_DIR_CONDA_BACKUP=
CONDA_BACKUP_RISCV=/home/drak/chipyard/esp-tools-install
HOME=/home/drak
LANG=C.UTF-8
WSL_INTEROP=/run/WSL/3328_interop
LS_COLORS=<redacted for brevity>
WAYLAND_DISPLAY=wayland-0
CONDA_PROMPT_MODIFIER=(/home/drak/chipyard_origin/.conda-env)
cbench=/home/drak/chipyard/generators/customtensor/benchmarks
NVM_DIR=/home/drak/.nvm
JAVA_LD_LIBRARY_PATH_BACKUP=
BENCH=/home/drak/chipyard/esp-tools-install/riscv64-unknown-elf/share/riscv-tests/benchmarks
LESSCLOSE=/usr/bin/lesspipe %s %s
MAKEFLAGS=-j12
TERM=xterm-256color
_CE_CONDA=
LESSOPEN=| /usr/bin/lesspipe %s
USER=drak
CONDA_SHLVL=2
DISPLAY=:0
SHLVL=1
NVM_CD_FLAGS=
CONDA_PYTHON_EXE=/home/drak/.local/miniforge3/bin/python
LD_LIBRARY_PATH=/home/drak/chipyard_origin/.conda-env/riscv-tools/lib
XDG_RUNTIME_DIR=/mnt/wslg/runtime-dir
CONDA_DEFAULT_ENV=/home/drak/chipyard_origin/.conda-env
WSLENV=WT_SESSION::WT_PROFILE_ID
JAVA_HOME_CONDA_BACKUP=
CONDA_BACKUP_PATH=<redacted for brevity>
PATH=<redacted for brevity>
NVM_BIN=/home/drak/.nvm/versions/node/v18.12.1/bin
HOSTTYPE=x86_64
CONDA_PREFIX_1=/home/drak/.local/miniforge3
PULSE_SERVER=unix:/mnt/wslg/PulseServer
WT_PROFILE_ID={2c4de342-38b7-51cf-b940-2309a097f518}
RISCV=/home/drak/chipyard_origin/.conda-env/riscv-tools
OLDPWD=/home/drak/chipyard_origin/tests
_=/home/drak/chipyard_origin/.conda-env/bin/printenv

# packages in environment at /home/drak/chipyard_origin/.conda-env:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                 conda_forge    conda-forge
_openmp_mutex             4.5                       2_gnu    conda-forge
_sysroot_linux-64_curr_repodata_hack 3                   h69a702a_13    conda-forge
aiohttp                   3.8.4           py310h1fa729e_0    conda-forge
aiosignal                 1.3.1              pyhd8ed1ab_0    conda-forge
alabaster                 0.7.13             pyhd8ed1ab_0    conda-forge
alsa-lib                  1.2.9                hd590300_0    conda-forge
appdirs                   1.4.4              pyh9f0ad1d_0    conda-forge
argcomplete               3.0.8              pyhd8ed1ab_0    conda-forge
asttokens                 2.2.1                    pypi_0    pypi
async-timeout             4.0.2              pyhd8ed1ab_0    conda-forge
atk-1.0                   2.38.0               hd4edc92_1    conda-forge
attrs                     23.1.0             pyh71513ae_1    conda-forge
autoconf                  2.71            pl5321h2b4cb7a_1    conda-forge
aws-sam-translator        1.55.0             pyhd8ed1ab_0    conda-forge
aws-xray-sdk              2.12.0             pyhd8ed1ab_0    conda-forge
awscli                    1.27.145        py310hff52083_0    conda-forge
azure-core                1.27.0             pyhd8ed1ab_0    conda-forge
azure-identity            1.12.0             pyhd8ed1ab_0    conda-forge
babel                     2.12.1             pyhd8ed1ab_1    conda-forge
bash                      5.2.15               hfbf034d_0    conda-forge
bash-completion           2.11                 ha770c72_1    conda-forge
bc                        1.07.1               h7f98852_0    conda-forge
bcrypt                    3.2.2           py310h5764c6d_1    conda-forge
binutils                  2.40                 hdd6e379_0    conda-forge
binutils_impl_linux-64    2.40                 hf600244_0    conda-forge
bison                     3.8.2                h59595ed_0    conda-forge
blinker                   1.6.2              pyhd8ed1ab_0    conda-forge
boto3                     1.26.145           pyhd8ed1ab_0    conda-forge
boto3-stubs               1.26.145           pyhd8ed1ab_0    conda-forge
botocore                  1.29.145           pyhd8ed1ab_0    conda-forge
botocore-stubs            1.29.145           pyhd8ed1ab_0    conda-forge
brotli                    1.0.9                h166bdaf_8    conda-forge
brotli-bin                1.0.9                h166bdaf_8    conda-forge
brotlipy                  0.7.0           py310h5764c6d_1005    conda-forge
bzip2                     1.0.8                h7f98852_4    conda-forge
c-ares                    1.19.1               hd590300_0    conda-forge
ca-certificates           2023.5.7             hbcca054_0    conda-forge
cachecontrol              0.13.0             pyhd8ed1ab_0    conda-forge
cachecontrol-with-filecache 0.13.0             pyhd8ed1ab_0    conda-forge
cachy                     0.3.0              pyhd8ed1ab_1    conda-forge
cairo                     1.16.0            hbbf8b49_1016    conda-forge
certifi                   2023.5.7           pyhd8ed1ab_0    conda-forge
cffi                      1.15.1          py310h255011f_3    conda-forge
cfgv                      3.3.1              pyhd8ed1ab_0    conda-forge
cfn-lint                  0.75.1             pyhd8ed1ab_0    conda-forge
charset-normalizer        2.1.1              pyhd8ed1ab_0    conda-forge
clang-format              16.0.3          default_h1cdf331_2    conda-forge
clang-format-16           16.0.3          default_h1cdf331_2    conda-forge
clang-tools               16.0.3          default_h1cdf331_2    conda-forge
click                     8.1.3           py310hff52083_1    conda-forge
click-default-group       1.2.2              pyhd8ed1ab_1    conda-forge
clikit                    0.6.2              pyhd8ed1ab_2    conda-forge
cloudpickle               2.2.1              pyhd8ed1ab_0    conda-forge
cmake                     3.26.3               h077f3f9_0    conda-forge
colorama                  0.4.4              pyh9f0ad1d_0    conda-forge
conda                     22.11.1         py310hff52083_1    conda-forge
conda-gcc-specs           12.2.0              he6d4335_19    conda-forge
conda-lock                1.4.0              pyhd8ed1ab_2    conda-forge
conda-package-handling    2.0.2              pyh38be061_0    conda-forge
conda-package-streaming   0.8.0              pyhd8ed1ab_0    conda-forge
conda-standalone          22.11.1              ha770c72_0    conda-forge
conda-tree                1.1.0              pyhd8ed1ab_2    conda-forge
constructor               3.4.3              pyhe4f9e05_0    conda-forge
contourpy                 1.0.7           py310hdf3cbec_0    conda-forge
coreutils                 9.3                  h0b41bf4_0    conda-forge
crashtest                 0.4.1              pyhd8ed1ab_0    conda-forge
cryptography              40.0.2          py310h34c0648_0    conda-forge
ctags                     5.8               h14c3975_1000    conda-forge
curl                      7.88.1               hdc1c0ab_1    conda-forge
cycler                    0.11.0             pyhd8ed1ab_0    conda-forge
dbus                      1.13.6               h5008d03_3    conda-forge
diffutils                 3.10                 hf18258e_0    conda-forge
distlib                   0.3.6              pyhd8ed1ab_0    conda-forge
docker-py                 6.1.0              pyhd8ed1ab_0    conda-forge
docutils                  0.15.2          py310hff52083_6    conda-forge
doit                      0.36.0             pyhd8ed1ab_0    conda-forge
dromajo                   1.0.0           0_h1234567_g6a6e34e    ucb-bar
dtc                       1.6.1                h166bdaf_2    conda-forge
ecdsa                     0.18.0             pyhd8ed1ab_1    conda-forge
elfutils                  0.187                h989201e_0    conda-forge
ensureconda               1.4.3              pyhd8ed1ab_0    conda-forge
exceptiongroup            1.1.1              pyhd8ed1ab_0    conda-forge
expat                     2.5.0                hcb278e6_1    conda-forge
expect                    5.45.4               h555a92e_0    conda-forge
fab-classic               1.19.2                   pypi_0    pypi
file                      5.39                 h753d276_1    conda-forge
filelock                  3.12.0             pyhd8ed1ab_0    conda-forge
findutils                 4.6.0             h166bdaf_1001    conda-forge
firtool                   1.30.0          0_h1234567_gdb40efbcd    ucb-bar
flask                     2.3.2              pyhd8ed1ab_0    conda-forge
flask_cors                3.0.10             pyhd3deb0d_0    conda-forge
flex                      2.6.4             h58526e2_1004    conda-forge
font-ttf-dejavu-sans-mono 2.37                 hab24e00_0    conda-forge
font-ttf-inconsolata      3.000                h77eed37_0    conda-forge
font-ttf-source-code-pro  2.038                h77eed37_0    conda-forge
font-ttf-ubuntu           0.83                 hab24e00_0    conda-forge
fontconfig                2.14.2               h14ed4e7_0    conda-forge
fonts-conda-ecosystem     1                             0    conda-forge
fonts-conda-forge         1                             0    conda-forge
fonttools                 4.39.4          py310h2372a71_0    conda-forge
freetype                  2.12.1               hca18f0e_1    conda-forge
fribidi                   1.0.10               h36c2ea0_0    conda-forge
frozenlist                1.3.3           py310h5764c6d_0    conda-forge
fsspec                    2023.5.0           pyh1a96a4e_0    conda-forge
gcc                       12.2.0              h26027b1_13    conda-forge
gcc_impl_linux-64         12.2.0              hcc96c02_19    conda-forge
gdk-pixbuf                2.42.10              h6b639ba_2    conda-forge
gdspy                     1.4                      pypi_0    pypi
gengetopt                 2.23                 h9c3ff4c_0    conda-forge
gettext                   0.21.1               h27087fc_0    conda-forge
giflib                    5.2.1                h0b41bf4_3    conda-forge
git                       2.40.1          pl5321h86e50cf_0    conda-forge
gitdb                     4.0.10             pyhd8ed1ab_0    conda-forge
gitpython                 3.1.31             pyhd8ed1ab_0    conda-forge
gmp                       6.2.1                h58526e2_0    conda-forge
gmpy2                     2.1.2           py310h3ec546c_1    conda-forge
gnutls                    3.7.8                hf3e180e_0    conda-forge
graphite2                 1.3.13            h58526e2_1001    conda-forge
graphql-core              3.2.3              pyhd8ed1ab_0    conda-forge
graphviz                  8.0.5                h28d9a01_0    conda-forge
gtk2                      2.24.33              h90689f9_2    conda-forge
gts                       0.7.6                h64030ff_2    conda-forge
gxx                       12.2.0              h26027b1_13    conda-forge
gxx_impl_linux-64         12.2.0              hcc96c02_19    conda-forge
gzip                      1.12                 h166bdaf_0    conda-forge
hammer-vlsi               1.1.1                    pypi_0    pypi
harfbuzz                  7.3.0                hdb3a94d_0    conda-forge
html5lib                  1.1                pyh9f0ad1d_0    conda-forge
humanfriendly             10.0            py310hff52083_4    conda-forge
icontract                 2.6.2                    pypi_0    pypi
icu                       72.1                 hcb278e6_0    conda-forge
identify                  2.5.24             pyhd8ed1ab_0    conda-forge
idna                      3.4                pyhd8ed1ab_0    conda-forge
imagesize                 1.4.1              pyhd8ed1ab_0    conda-forge
importlib-metadata        6.6.0              pyha770c72_0    conda-forge
importlib_metadata        6.6.0                hd8ed1ab_0    conda-forge
iniconfig                 2.0.0              pyhd8ed1ab_0    conda-forge
itsdangerous              2.1.2              pyhd8ed1ab_0    conda-forge
jaraco.classes            3.2.3              pyhd8ed1ab_0    conda-forge
jeepney                   0.8.0              pyhd8ed1ab_0    conda-forge
jinja2                    3.1.2              pyhd8ed1ab_1    conda-forge
jmespath                  1.0.1              pyhd8ed1ab_0    conda-forge
jq                        1.6               h36c2ea0_1000    conda-forge
jschema-to-python         1.2.3              pyhd8ed1ab_0    conda-forge
jsondiff                  2.0.0              pyhd8ed1ab_0    conda-forge
jsonpatch                 1.32               pyhd8ed1ab_0    conda-forge
jsonpickle                2.2.0              pyhd8ed1ab_0    conda-forge
jsonpointer               2.0                        py_0    conda-forge
jsonschema                3.2.0              pyhd8ed1ab_3    conda-forge
junit-xml                 1.9                pyh9f0ad1d_0    conda-forge
kernel-headers_linux-64   3.10.0              h4a8ded7_13    conda-forge
keyring                   23.13.1         py310hff52083_0    conda-forge
keyutils                  1.6.1                h166bdaf_0    conda-forge
kiwisolver                1.4.4           py310hbf28c38_1    conda-forge
krb5                      1.20.1               h81ceb04_0    conda-forge
lcms2                     2.15                 haa2dc70_1    conda-forge
ld_impl_linux-64          2.40                 h41732ed_0    conda-forge
lerc                      4.0.0                h27087fc_0    conda-forge
libabseil                 20230125.2      cxx17_h59595ed_2    conda-forge
libarchive                3.5.2                hada088e_3    conda-forge
libblas                   3.9.0           16_linux64_openblas    conda-forge
libbrotlicommon           1.0.9                h166bdaf_8    conda-forge
libbrotlidec              1.0.9                h166bdaf_8    conda-forge
libbrotlienc              1.0.9                h166bdaf_8    conda-forge
libcblas                  3.9.0           16_linux64_openblas    conda-forge
libclang-cpp16            16.0.3          default_h1cdf331_2    conda-forge
libclang13                16.0.3          default_h4d60ac6_2    conda-forge
libcups                   2.3.3                h36d4200_3    conda-forge
libcurl                   7.88.1               hdc1c0ab_1    conda-forge
libdeflate                1.18                 h0b41bf4_0    conda-forge
libdwarf                  0.0.0.20190110_28_ga81397fc4      h753d276_0    ucb-bar
libdwarf-dev              0.0.0.20190110_28_ga81397fc4      h753d276_0    ucb-bar
libedit                   3.1.20191231         he28a2e2_2    conda-forge
libev                     4.33                 h516909a_1    conda-forge
libexpat                  2.5.0                hcb278e6_1    conda-forge
libfdt                    1.6.1                h166bdaf_2    conda-forge
libffi                    3.4.2                h7f98852_5    conda-forge
libgcc-devel_linux-64     12.2.0              h3b97bd3_19    conda-forge
libgcc-ng                 12.2.0              h65d4601_19    conda-forge
libgd                     2.3.3                hfa28ad5_6    conda-forge
libgfortran-ng            12.2.0              h69a702a_19    conda-forge
libgfortran5              12.2.0              h337968e_19    conda-forge
libglib                   2.76.3               hebfc3b9_0    conda-forge
libgomp                   12.2.0              h65d4601_19    conda-forge
libiconv                  1.17                 h166bdaf_0    conda-forge
libidn2                   2.3.4                h166bdaf_0    conda-forge
libjpeg-turbo             2.1.5.1              h0b41bf4_0    conda-forge
liblapack                 3.9.0           16_linux64_openblas    conda-forge
libllvm16                 16.0.3               hbf9e925_1    conda-forge
libmagic                  5.39                 h753d276_1    conda-forge
libmicrohttpd             0.9.76               h87ba234_0    conda-forge
libnghttp2                1.52.0               h61bc06f_0    conda-forge
libnsl                    2.0.0                h7f98852_0    conda-forge
libopenblas               0.3.21          pthreads_h78a6416_3    conda-forge
libpng                    1.6.39               h753d276_0    conda-forge
libprotobuf               4.23.2               hd1fb520_2    conda-forge
librsvg                   2.56.0               h5cef280_0    conda-forge
libsanitizer              12.2.0              h46fd767_19    conda-forge
libsodium                 1.0.18               h36c2ea0_1    conda-forge
libsqlite                 3.42.0               h2797004_0    conda-forge
libssh2                   1.10.0               hf14f497_3    conda-forge
libstdcxx-devel_linux-64  12.2.0              h3b97bd3_19    conda-forge
libstdcxx-ng              12.2.0              h46fd767_19    conda-forge
libtasn1                  4.19.0               h166bdaf_0    conda-forge
libtiff                   4.5.0                ha587672_6    conda-forge
libtool                   2.4.7                h27087fc_0    conda-forge
libunistring              0.9.10               h7f98852_0    conda-forge
libusb1                   2.0.1              pyhd8ed1ab_0    conda-forge
libuuid                   2.38.1               h0b41bf4_0    conda-forge
libuv                     1.44.2               h166bdaf_0    conda-forge
libwebp                   1.3.0                hb47c5f0_0    conda-forge
libwebp-base              1.3.0                h0b41bf4_0    conda-forge
libxcb                    1.15                 h0b41bf4_0    conda-forge
libxml2                   2.10.4               hfdac1af_0    conda-forge
libzlib                   1.2.13               h166bdaf_4    conda-forge
livereload                2.6.3              pyh9f0ad1d_0    conda-forge
lockfile                  0.12.2                     py_1    conda-forge
lz4-c                     1.9.4                hcb278e6_0    conda-forge
lzo                       2.10              h516909a_1000    conda-forge
lzop                      1.04                 h3753786_2    conda-forge
m4                        1.4.18            h516909a_1001    conda-forge
make                      4.3                  hd18ef5c_1    conda-forge
markupsafe                2.1.2           py310h1fa729e_0    conda-forge
matplotlib-base           3.7.1           py310he60537e_0    conda-forge
mock                      5.0.2                    pypi_0    pypi
more-itertools            9.1.0              pyhd8ed1ab_0    conda-forge
mosh                      1.4.0           pl5321h4605741_1    conda-forge
moto                      4.1.10             pyhd8ed1ab_0    conda-forge
mpc                       1.3.1                hfe3b2da_0    conda-forge
mpfr                      4.2.0                hb012696_0    conda-forge
msal                      1.22.0             pyhd8ed1ab_0    conda-forge
msal_extensions           1.0.0              pyhd8ed1ab_0    conda-forge
msgpack-python            1.0.5           py310hdf3cbec_0    conda-forge
multidict                 6.0.4           py310h1fa729e_0    conda-forge
munkres                   1.1.4              pyh9f0ad1d_0    conda-forge
mypy                      1.3.0           py310h2372a71_0    conda-forge
mypy-boto3-s3             1.26.127           pyhd8ed1ab_0    conda-forge
mypy_boto3_ec2            1.26.136           pyhd8ed1ab_0    conda-forge
mypy_extensions           1.0.0              pyha770c72_0    conda-forge
ncurses                   6.3                  h27087fc_1    conda-forge
nettle                    3.8.1                hc379101_1    conda-forge
networkx                  2.8.8              pyhd8ed1ab_0    conda-forge
nodeenv                   1.8.0              pyhd8ed1ab_0    conda-forge
numpy                     1.24.3          py310ha4c1d20_0    conda-forge
oniguruma                 6.9.8                h166bdaf_0    conda-forge
open_pdks.sky130a         1.0.406_0_g0c37b7c 20230412_103222    litex-hub
openapi-schema-validator  0.2.3              pyhd8ed1ab_0    conda-forge
openapi-spec-validator    0.4.0              pyhd8ed1ab_1    conda-forge
openjdk                   20.0.0               h8e330f5_0    conda-forge
openjpeg                  2.5.0                hfec8fc6_2    conda-forge
openssl                   3.1.1                hd590300_1    conda-forge
p11-kit                   0.24.1               hc5aa10d_0    conda-forge
packaging                 23.1               pyhd8ed1ab_0    conda-forge
pandas                    2.0.2           py310h7cbd5c2_0    conda-forge
pango                     1.50.14              heaa33ce_1    conda-forge
paramiko                  3.2.0              pyhd8ed1ab_0    conda-forge
paramiko-ng               2.8.10                   pypi_0    pypi
pastel                    0.2.1              pyhd8ed1ab_0    conda-forge
patch                     2.7.6             h7f98852_1002    conda-forge
pbr                       5.11.1             pyhd8ed1ab_0    conda-forge
pcre2                     10.40                hc3806b6_0    conda-forge
perl                      5.32.1          2_h7f98852_perl5    conda-forge
pillow                    9.5.0           py310h582fbeb_1    conda-forge
pip                       23.1.2             pyhd8ed1ab_0    conda-forge
pixman                    0.40.0               h36c2ea0_0    conda-forge
pkginfo                   1.9.6              pyhd8ed1ab_0    conda-forge
platformdirs              3.5.1              pyhd8ed1ab_0    conda-forge
pluggy                    1.0.0           py310hff52083_4    conda-forge
popt                      1.16              h0b475e3_2002    conda-forge
portalocker               2.7.0           py310hff52083_0    conda-forge
pre-commit                3.3.2              pyha770c72_0    conda-forge
psutil                    5.9.5           py310h1fa729e_0    conda-forge
pthread-stubs             0.4               h36c2ea0_1001    conda-forge
pyasn1                    0.4.8                      py_0    conda-forge
pycosat                   0.6.4           py310h5764c6d_1    conda-forge
pycparser                 2.21               pyhd8ed1ab_0    conda-forge
pydantic                  1.10.8          py310h2372a71_0    conda-forge
pygments                  2.15.1             pyhd8ed1ab_0    conda-forge
pyjwt                     2.7.0              pyhd8ed1ab_0    conda-forge
pylddwrap                 1.2.2                    pypi_0    pypi
pylev                     1.4.0              pyhd8ed1ab_0    conda-forge
pynacl                    1.5.0           py310h5764c6d_2    conda-forge
pyopenssl                 23.2.0             pyhd8ed1ab_1    conda-forge
pyparsing                 3.0.9              pyhd8ed1ab_0    conda-forge
pyrsistent                0.19.3          py310h1fa729e_0    conda-forge
pysocks                   1.7.1           py310hff52083_5    conda-forge
pytest                    7.3.1              pyhd8ed1ab_0    conda-forge
pytest-dependency         0.5.1              pyh9f0ad1d_0    conda-forge
pytest-mock               3.10.0             pyhd8ed1ab_0    conda-forge
python                    3.10.11         he550d4f_0_cpython    conda-forge
python-dateutil           2.8.2              pyhd8ed1ab_0    conda-forge
python-graphviz           0.20.1             pyh22cad53_0    conda-forge
python-jose               3.3.0              pyh6c4a22f_1    conda-forge
python-tzdata             2023.3             pyhd8ed1ab_0    conda-forge
python_abi                3.10                    3_cp310    conda-forge
pytz                      2023.3             pyhd8ed1ab_0    conda-forge
pywin32-on-windows        0.1.0              pyh1179c8e_3    conda-forge
pyyaml                    6.0                      pypi_0    pypi
qemu                      5.0.0                hb15d774_0    ucb-bar
readline                  8.2                  h8228510_1    conda-forge
requests                  2.31.0             pyhd8ed1ab_0    conda-forge
responses                 0.21.0             pyhd8ed1ab_0    conda-forge
rhash                     1.4.3                h166bdaf_0    conda-forge
riscv-tools               1.0.3           0_h1234567_ga1b1b14    ucb-bar
rsa                       4.7.2              pyh44b312d_0    conda-forge
rsync                     3.2.7                h70740c4_0    conda-forge
ruamel-yaml               0.17.26                  pypi_0    pypi
ruamel.yaml.clib          0.2.7           py310h1fa729e_1    conda-forge
ruamel_yaml               0.15.80         py310h5764c6d_1008    conda-forge
s3fs                      0.4.2                      py_0    conda-forge
s3transfer                0.6.1              pyhd8ed1ab_0    conda-forge
sarif-om                  1.0.4              pyhd8ed1ab_0    conda-forge
sbt                       1.8.2                hd8ed1ab_0    conda-forge
screen                    4.8.0                he28a2e2_0    conda-forge
secretstorage             3.3.3           py310hff52083_1    conda-forge
sed                       4.8                  he412f7d_0    conda-forge
setuptools                67.7.2             pyhd8ed1ab_0    conda-forge
six                       1.16.0             pyh6c4a22f_0    conda-forge
smmap                     3.0.5              pyh44b312d_0    conda-forge
snowballstemmer           2.2.0              pyhd8ed1ab_0    conda-forge
sphinx                    5.1.1              pyhd8ed1ab_1    conda-forge
sphinx-autobuild          2021.3.14          pyhd8ed1ab_0    conda-forge
sphinx_rtd_theme          1.2.1              pyha770c72_0    conda-forge
sphinxcontrib-applehelp   1.0.4              pyhd8ed1ab_0    conda-forge
sphinxcontrib-devhelp     1.0.2                      py_0    conda-forge
sphinxcontrib-htmlhelp    2.0.1              pyhd8ed1ab_0    conda-forge
sphinxcontrib-jquery      4.1                pyhd8ed1ab_0    conda-forge
sphinxcontrib-jsmath      1.0.1                      py_0    conda-forge
sphinxcontrib-qthelp      1.0.3                      py_0    conda-forge
sphinxcontrib-serializinghtml 1.1.5              pyhd8ed1ab_2    conda-forge
sqlite                    3.42.0               h2c6b66d_0    conda-forge
sshpubkeys                3.3.1              pyhd8ed1ab_0    conda-forge
sty                       1.0.0              pyhd8ed1ab_0    conda-forge
sure                      2.0.1                    pypi_0    pypi
sysroot_linux-64          2.17                h4a8ded7_13    conda-forge
tar                       1.34                 hb2e2bae_1    conda-forge
tk                        8.6.12               h27826a3_0    conda-forge
tomli                     2.0.1              pyhd8ed1ab_0    conda-forge
tomlkit                   0.11.8             pyha770c72_0    conda-forge
toolz                     0.12.0             pyhd8ed1ab_0    conda-forge
tornado                   6.3.2           py310h2372a71_0    conda-forge
tqdm                      4.65.0             pyhd8ed1ab_1    conda-forge
types-awscrt              0.16.19            pyhd8ed1ab_0    conda-forge
types-pytz                2023.3.0.0         pyhd8ed1ab_0    conda-forge
types-pyyaml              6.0.12.10          pyhd8ed1ab_0    conda-forge
types-requests            2.31.0.1           pyhd8ed1ab_0    conda-forge
types-s3transfer          0.6.1                    pypi_0    pypi
types-urllib3             1.26.25.13         pyhd8ed1ab_0    conda-forge
typing-extensions         4.6.2                hd8ed1ab_0    conda-forge
typing_extensions         4.6.2              pyha770c72_0    conda-forge
tzdata                    2023c                h71feb2d_0    conda-forge
ukkonen                   1.0.1           py310hbf28c38_3    conda-forge
unicodedata2              15.0.0          py310h5764c6d_0    conda-forge
unzip                     6.0                  h7f98852_3    conda-forge
urllib3                   1.26.15            pyhd8ed1ab_0    conda-forge
verilator                 5.008                h514fc35_1    conda-forge
vim                       9.0.1425        py310pl5321he660f0e_0    conda-forge
virtualenv                20.23.0            pyhd8ed1ab_0    conda-forge
webencodings              0.5.1                      py_1    conda-forge
websocket-client          1.5.2              pyhd8ed1ab_0    conda-forge
werkzeug                  2.3.4              pyhd8ed1ab_0    conda-forge
wget                      1.20.3               ha35d2d1_1    conda-forge
wheel                     0.40.0             pyhd8ed1ab_0    conda-forge
which                     2.21                 h0b41bf4_1    conda-forge
wrapt                     1.15.0          py310h1fa729e_0    conda-forge
xmltodict                 0.13.0             pyhd8ed1ab_0    conda-forge
xorg-fixesproto           5.0               h7f98852_1002    conda-forge
xorg-inputproto           2.3.2             h7f98852_1002    conda-forge
xorg-kbproto              1.0.7             h7f98852_1002    conda-forge
xorg-libice               1.0.10               h7f98852_0    conda-forge
xorg-libsm                1.2.3             hd9c2040_1000    conda-forge
xorg-libx11               1.8.4                h8ee46fc_1    conda-forge
xorg-libxau               1.0.11               hd590300_0    conda-forge
xorg-libxdmcp             1.1.3                h7f98852_0    conda-forge
xorg-libxext              1.3.4                h0b41bf4_2    conda-forge
xorg-libxfixes            5.0.3             h7f98852_1004    conda-forge
xorg-libxi                1.7.10               h7f98852_0    conda-forge
xorg-libxrender           0.9.10            h7f98852_1003    conda-forge
xorg-libxt                1.3.0                hd590300_0    conda-forge
xorg-libxtst              1.2.3             h7f98852_1002    conda-forge
xorg-recordproto          1.14.2            h7f98852_1002    conda-forge
xorg-renderproto          0.11.1            h7f98852_1002    conda-forge
xorg-xextproto            7.3.0             h0b41bf4_1003    conda-forge
xorg-xproto               7.0.31            h7f98852_1007    conda-forge
xxhash                    0.8.0                h7f98852_3    conda-forge
xz                        5.2.6                h166bdaf_0    conda-forge
yaml                      0.2.5                h7f98852_2    conda-forge
yarl                      1.9.2           py310h2372a71_0    conda-forge
zipp                      3.15.0             pyhd8ed1ab_0    conda-forge
zlib                      1.2.13               h166bdaf_4    conda-forge
zstandard                 0.19.0          py310hdeb6495_1    conda-forge
zstd                      1.5.2                h3eb15da_6    conda-forge

Other Setup

No response

Current Behavior

Note the help text:

$ ./simulator-chipyard.harness-RocketConfig-debug --help
[UART] UART0 is here (stdin/stdout).
Usage: ./simulator-chipyard.harness-RocketConfig-debug [EMULATOR OPTION]... [VERILOG PLUSARG]... [HOST OPTION]... BINARY [TARGET OPTION]...
 Run a BINARY on the Rocket Chip emulator.

Mandatory arguments to long options are mandatory for short options too.

EMULATOR OPTIONS
  Consult emulator.cc if using Verilator or VCS documentation if using VCS
    for available options.
EMUALTOR VERILOG PLUSARGS
  Consult generated-src*/*.plusArgs for available options

HOST OPTIONS
  -h, --help               Display this help and exit
  +h,  +help
       +permissive         The host will ignore any unparsed options up until
                             +permissive-off (Only needed for VCS)
       +permissive-off     Stop ignoring options. This is mandatory if using
                             +permissive (Only needed for VCS)
      --rfb=DISPLAY        Add new remote frame buffer on display DISPLAY
       +rfb=DISPLAY          to be accessible on 5900 + DISPLAY (default = 0)
      --signature=FILE     Write torture test signature to FILE
       +signature=FILE
      --signature-granularity=VAL           Size of each line in signature.
       +signature-granularity=VAL
      --chroot=PATH        Use PATH as location of syscall-servicing binaries
       +chroot=PATH
      --payload=PATH       Load PATH memory as an additional ELF payload
       +payload=PATH
      --symbol-elf=PATH    Populate the symbol table with the ELF file at PATH
       +symbol-elf=PATH

HOST OPTIONS (currently unsupported)
      --disk=DISK          Add DISK device. Use a ramdisk since this isn't
       +disk=DISK            supported

TARGET (RISC-V BINARY) OPTIONS
  These are the options passed to the program executing on the emulated RISC-V
  microprocessor.
terminate called after throwing an instance of 'std::invalid_argument'
  what():  User queried htif_t help text

When this help text is printed, there are two changes relevant to this issue:

  1. EMULATOR OPTIONS no longer shows the command line options like --cycle-count, --vcd, etc.:

    EMULATOR OPTIONS
    Consult emulator.cc if using Verilator or VCS documentation if using VCS
    for available options.

    However, when checking emulator.cc, I can clearly see the command line options that are expected:

    static void usage(const char * program_name)
    {
    printf("Usage: %s [EMULATOR OPTION]... [VERILOG PLUSARG]... [HOST OPTION]... BINARY [TARGET OPTION]...\n",
         program_name);
    fputs("\
    Run a BINARY on the Rocket Chip emulator.\n\
    \n\
    Mandatory arguments to long options are mandatory for short options too.\n\
    \n\
    EMULATOR OPTIONS\n\
    -c, --cycle-count        Print the cycle count before exiting\n\
       +cycle-count\n\
    -h, --help               Display this help and exit\n\
    -m, --max-cycles=CYCLES  Kill the emulation after CYCLES\n\
       +max-cycles=CYCLES\n\
    -s, --seed=SEED          Use random number seed SEED\n\
    -r, --rbb-port=PORT      Use PORT for remote bit bang (with OpenOCD and GDB) \n\
                           If not specified, a random port will be chosen\n\
                           automatically.\n\
    -V, --verbose            Enable all Chisel printfs (cycle-by-cycle info)\n\
       +verbose\n\
    ", stdout);
    #if VM_TRACE == 0
    fputs("\
    \n\
    EMULATOR DEBUG OPTIONS (only supported in debug build -- try `make debug`)\n",
        stdout);
    #endif
    fputs("\
    -v, --vcd=FILE,          Write vcd trace to FILE (or '-' for stdout)\n\
    -x, --dump-start=CYCLE   Start VCD tracing at CYCLE\n\
       +dump-start\n\
    ", stdout);
    fputs("\n" PLUSARG_USAGE_OPTIONS, stdout);
    fputs("\n" HTIF_USAGE_OPTIONS, stdout);
    printf("\n"
    "EXAMPLES\n"
    "  - run a bare metal test:\n"
    "    %s $RISCV/riscv64-unknown-elf/share/riscv-tests/isa/rv64ui-p-add\n"
    "  - run a bare metal test showing cycle-by-cycle information:\n"
    "    %s +verbose $RISCV/riscv64-unknown-elf/share/riscv-tests/isa/rv64ui-p-add 2>&1 | spike-dasm\n"
    #if VM_TRACE
    "  - run a bare metal test to generate a VCD waveform:\n"
    "    %s -v rv64ui-p-add.vcd $RISCV/riscv64-unknown-elf/share/riscv-tests/isa/rv64ui-p-add\n"
    #endif
    "  - run an ELF (you wrote, called 'hello') using the proxy kernel:\n"
    "    %s pk hello\n",
         program_name, program_name, program_name
    #if VM_TRACE
         , program_name
    #endif
         );
    }

    This implies to me that the "Please consult emulator.cc" line is a mistake.

  2. At the bottom, I see an error:

    terminate called after throwing an instance of 'std::invalid_argument'
    what():  User queried htif_t help text

And lastly, 3. using the command line options that are described in emulator.cc, and that used to work, are no longer recognized. For example:

$ ./simulator-chipyard.harness-RocketConfig-debug --vcd=out.vcd ../../tests/hello.riscv
[UART] UART0 is here (stdin/stdout).
./simulator-chipyard.harness-RocketConfig-debug: unrecognized option '--vcd=out.vcd'
terminate called after throwing an instance of 'std::invalid_argument'
  what():  Unknown argument (did you mean to enable +permissive parsing?)

Expected Behavior

I expect the help text to display something like this (Ran from chipyard release 1.9.1):

$ ./simulator-chipyard-RocketConfig-debug --help
Usage: ./simulator-chipyard-RocketConfig-debug [EMULATOR OPTION]... [VERILOG PLUSARG]... [HOST OPTION]... BINARY [TARGET OPTION]...
Run a BINARY on the Rocket Chip emulator.

Mandatory arguments to long options are mandatory for short options too.

EMULATOR OPTIONS
  -c, --cycle-count        Print the cycle count before exiting
       +cycle-count
  -h, --help               Display this help and exit
  -m, --max-cycles=CYCLES  Kill the emulation after CYCLES
       +max-cycles=CYCLES
  -s, --seed=SEED          Use random number seed SEED
  -r, --rbb-port=PORT      Use PORT for remote bit bang (with OpenOCD and GDB)
                           If not specified, a random port will be chosen
                           automatically.
  -V, --verbose            Enable all Chisel printfs (cycle-by-cycle info)
       +verbose
  -v, --vcd=FILE,          Write vcd trace to FILE (or '-' for stdout)
  -x, --dump-start=CYCLE   Start VCD tracing at CYCLE
       +dump-start

EMULATOR VERILOG PLUSARGS
       +custom_boot_pin=INT

                             (default=0)

       +max_core_cycles=INT
                           Kill the emulation after INT rdtime cycles. Off if 0.
                             (default=0)

       +uart_tx_printf=INT
                           Enable/disable the TX printf
                             (default=1)

       +uart_tx=INT
                           Enable/disable the TX to speed up simulation
                             (default=1)

       +jtag_rbb_enable=INT
                           Enable SimJTAG for JTAG Connections. Simulation will pause until connection is made.
                             (default=0)

       +tilelink_timeout=INT
                           Kill emulation after INT waiting TileLink cycles. Off if 0.
                             (default=0)

HOST OPTIONS
  -h, --help               Display this help and exit
  +h,  +help
       +permissive         The host will ignore any unparsed options up until
                             +permissive-off (Only needed for VCS)
       +permissive-off     Stop ignoring options. This is mandatory if using
                             +permissive (Only needed for VCS)
      --rfb=DISPLAY        Add new remote frame buffer on display DISPLAY
       +rfb=DISPLAY          to be accessible on 5900 + DISPLAY (default = 0)
      --signature=FILE     Write torture test signature to FILE
       +signature=FILE
      --signature-granularity=VAL           Size of each line in signature.
       +signature-granularity=VAL
      --chroot=PATH        Use PATH as location of syscall-servicing binaries
       +chroot=PATH
      --payload=PATH       Load PATH memory as an additional ELF payload
       +payload=PATH
      --symbol-elf=PATH    Populate the symbol table with the ELF file at PATH
       +symbol-elf=PATH

HOST OPTIONS (currently unsupported)
      --disk=DISK          Add DISK device. Use a ramdisk since this isn't
       +disk=DISK            supported

TARGET (RISC-V BINARY) OPTIONS
  These are the options passed to the program executing on the emulated RISC-V
  microprocessor.

EXAMPLES
  - run a bare metal test:
    ./simulator-chipyard-RocketConfig-debug $RISCV/riscv64-unknown-elf/share/riscv-tests/isa/rv64ui-p-add
  - run a bare metal test showing cycle-by-cycle information:
    ./simulator-chipyard-RocketConfig-debug +verbose $RISCV/riscv64-unknown-elf/share/riscv-tests/isa/rv64ui-p-add 2>&1 | spike-dasm
  - run a bare metal test to generate a VCD waveform:
    ./simulator-chipyard-RocketConfig-debug -v rv64ui-p-add.vcd $RISCV/riscv64-unknown-elf/share/riscv-tests/isa/rv64ui-p-add
  - run an ELF (you wrote, called 'hello') using the proxy kernel:
    ./simulator-chipyard-RocketConfig-debug pk hello

and for the emulator options to work, for example --cycle-count and --vcd:

$ ./simulator-chipyard-RocketConfig-debug --vcd=out.vcd --cycle-count ../../tests/hello.riscv
This emulator compiled with JTAG Remote Bitbang client. To enable, use +jtag_rbb_enable=1.
Listening on port 44791
[UART] UART0 is here (stdin/stdout).
Hello world from core 0, a rocket
*** PASSED *** Completed after 52394 cycles

$ ls -lah
total 210M
drwxr-xr-x 3 drak drak 4.0K Sep 27 12:48 .
drwxr-xr-x 6 drak drak 4.0K Sep 27 00:58 ..
-rw-r--r-- 1 drak drak   52 Sep 27 00:56 .gitignore
-rw-r--r-- 1 drak drak  11K Sep 27 00:58 Makefile
drwxr-xr-x 3 drak drak 4.0K Sep 27 01:50 generated-src
-rw-r--r-- 1 drak drak 195M Sep 27 13:26 out.vcd
-rwxr-xr-x 1 drak drak 8.8M Sep 27 12:46 simulator-chipyard-RocketConfig-debug

Other Information

I tested this on release 1.10.0, 1.9.1, and on HEAD (from last night). 1.9.1 works as expected, 1.10.0 and HEAD do not.

jerryz123 commented 11 months ago

The verilator backend now no longer uses the emulator.cc driver... it now uses the same TestDriver.v as verilog. So that help message, as well as many of the flags it describes are out-of-date.

JL102 commented 11 months ago

The verilator backend now no longer uses the emulator.cc driver... it now uses the same TestDriver.v as verilog. So that help message, as well as many of the flags it describes are out-of-date.

Understood. I looked at TestDriver.v and I see the vcdfile plusarg, but when trying this:

$ ./simulator-chipyard.harness-RocketConfig-debug +vcdfile=./out.vcd ../../tests/hello.riscv

I get this output:

[UART] UART0 is here (stdin/stdout).
terminate called after throwing an instance of 'std::runtime_error'
  what():  could not open +vcdfile=./out.vcd (did you misspell it? If VCS, did you forget +permissive/+permissive-off?)

How do I output a vcd?

jerryz123 commented 11 months ago

I believe the run-binary-debug make target should output VCDs. The files might not have .vcd extension, but they should be VCDs IIRC?

JL102 commented 11 months ago

Got it, thanks! After passing BINARY=../../tests/hello.riscv into the make arguments too, it outputted a vcd and some other stuff into output/chipyard.harness.TestHarness.RocketConfig

JL102 commented 11 months ago

Hm... There seems to be a significant reduction in performance between the Verilator testharnesses of Chipyard 1.9.1 and Chipyard 1.10.0.

In my local copy of both v1.9.1 and v1.10.0, I ran the same make debug CONFIG=RocketConfig, and then after building, ran time make run-binary-debug BINARY=../../tests/hello.riscv.

Just to check and make sure the variable was not the testbench compilation, I ran 1.9.1's testharness with 1.10.0's binary and vice versa. Switching the binaries had no impact on the simulation time (1.9.1's testharness took ~45 seconds and completed after 306,076 no matter which test binary it ran)

In my own test that I'm working on in my fork, I was used to the "actual" code starting to run after about 80k-100k cycles, but after syncing up my fork with the upstream, the same test takes about 280k cycles before the "actual" code starting to run. Is it known why it's taking so much longer for the testharnesses to run after the update?

jerryz123 commented 11 months ago

Yes. We switched the verilator backend to use --timing, which uses a completely different simulation driver than the old mechanism. The timing-driven simulation is more faithful to real hardware, as it can simulate arbitrary clocks and delays.

To improve performance, you can try make run-binary-debug LOADMEM=1. This will use a fast loadmem mechanism to instantaneously copy the binary into target memory.

JL102 commented 11 months ago

Understood, thank you!

matsbror commented 11 months ago

@JL102 I have an issue you may have a solution to (unrelated to this issue). I see you are on WSL2. Did you have a problem getting FireSim installed as part of the Chipyard setup? I can't get it to work in WSL2, but on a pure Linux host, it works.

JL102 commented 11 months ago

@JL102 I have an issue you may have a solution to (unrelated to this issue). I see you are on WSL2. Did you have a problem getting FireSim installed as part of the Chipyard setup? I can't get it to work in WSL2, but on a pure Linux host, it works.

@matsbror Unfortunately I don't have a very satisfying solution. I was having the same issue as described in #1441, and after seeing this comment - https://github.com/ucb-bar/chipyard/issues/1441#issuecomment-1607767964 - I've been using using that command ever since. I haven't needed to use Firesim within Chipyard in my development environment.

At my workplace they have a VM built for using Firesim, and earlier this summer I was even having the same issue on the VM. (When Firesim was at the project root, with Chipyard as a submodule in target-design/chipyard, it was fine, but when Chipyard was at the project root with a Firesim submodule at software/firesim, it didn't work)

I tested it again now; when I ran the full build-setup.sh on 1.10.0, the FireMarshal build step failed with some weird error I'm unsure of. I then wiped chipyard, re-cloned, and checked out main. Then, the full build-setup.sh actually worked.

EDIT: I just tried the full setup script on my Ubuntu 22.04 server ("pure Linux", not WSL), 1.10.0, and it failed for a similar/same reason as on WSL, "failed to build workload br-base.json"

jerryz123 commented 11 months ago

Can you post the full error message for failed to build workload?