mirror of
https://github.com/verilator/verilator.git
synced 2026-10-02 16:13:34 +02:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
436d3d76f0 | ||
|
|
c1f0787669 | ||
|
|
dae4c8ee22 | ||
|
|
5daf7385f1 | ||
|
|
4ce8164277 | ||
|
|
7ec32799b0 | ||
|
|
812861e7f2 | ||
|
|
1857f6399c | ||
|
|
f7ccc013e7 | ||
|
|
2e1fa8f338 | ||
|
|
70459b3208 | ||
|
|
2a23ec74e4 | ||
|
|
be1ace423e | ||
|
|
2d0149b703 | ||
|
|
34ced254c0 | ||
|
|
fe15171649 | ||
|
|
4092ac7e72 | ||
|
|
1a07af57a3 | ||
|
|
c840ffb0ae | ||
|
|
fbe8439eb8 | ||
|
|
754c5c71f1 | ||
|
|
6940ee420d | ||
|
|
b645fcf027 | ||
|
|
ffb02cea15 | ||
|
|
f753ae2518 | ||
|
|
caa19c0cb3 | ||
|
|
aa3942ab24 | ||
|
|
cc1133c0d9 | ||
|
|
ac659d525b | ||
|
|
283f6c7433 | ||
|
|
5b65c15eca | ||
|
|
6b4183632c | ||
|
|
e0e164cea2 | ||
|
|
a379382d32 | ||
|
|
e2a6e19cac | ||
|
|
61bfb6c308 | ||
|
|
bdcfc4e286 | ||
|
|
70c6651aac | ||
|
|
41bb54bc2c | ||
|
|
001c098e5a | ||
|
|
98e40c847c | ||
|
|
05c7a3b90b | ||
|
|
694f2ff7c7 | ||
|
|
6281385ee8 | ||
|
|
7e6dd9473f | ||
|
|
929e15fa4c | ||
|
|
432d5f851d | ||
|
|
d4f4fefd1d | ||
|
|
d8080008b4 | ||
|
|
bed9aa9904 | ||
|
|
35fa0d051d | ||
|
|
0507fb4655 | ||
|
|
f4a01eb452 | ||
|
|
4954e76b28 | ||
|
|
fa1b11252e | ||
|
|
dddc1b5b4d | ||
|
|
20faa99464 | ||
|
|
dc43071f1c | ||
|
|
fdf29b970f | ||
|
|
70814fa11a | ||
|
|
529b8337ec | ||
|
|
f8dd65c7cd | ||
|
|
28a59a2b21 | ||
|
|
d3e205f201 | ||
|
|
dfe28f7ed0 | ||
|
|
bb871728c9 | ||
|
|
69dce205d3 | ||
|
|
052812bb87 | ||
|
|
0380a36c76 | ||
|
|
44f49669a3 | ||
|
|
ff244c1d1f | ||
|
|
260ac342f4 | ||
|
|
87d856339f | ||
|
|
e171463fa2 | ||
|
|
481adf8fe7 | ||
|
|
b8288b97f7 | ||
|
|
0d34f56b74 | ||
|
|
dcaf6476e8 | ||
|
|
76b2ac9cc1 | ||
|
|
b6a400ee9b | ||
|
|
78d6ec8114 | ||
|
|
88dd95980a | ||
|
|
b531001f55 | ||
|
|
1d0563212e | ||
|
|
8ca49d98c1 | ||
|
|
036c1fb0f9 | ||
|
|
19258ee18a | ||
|
|
578d8d8391 | ||
|
|
010ae580b1 | ||
|
|
951f5eaa82 | ||
|
|
3a69dd4a43 | ||
|
|
f52155a768 | ||
|
|
16b3d9101c | ||
|
|
8ff77e9d47 | ||
|
|
4361c516fd | ||
|
|
7d5772c749 | ||
|
|
f5e2f60dcc | ||
|
|
8fbb725f34 | ||
|
|
72a47e16c1 | ||
|
|
530ebecfb7 | ||
|
|
9a3dcaa10b | ||
|
|
8a121803f5 | ||
|
|
bb45fd6c6c | ||
|
|
62945bb3bc | ||
|
|
079a53e820 | ||
|
|
a23fad91a3 | ||
|
|
5f1df5b389 | ||
|
|
74d5d008bb | ||
|
|
8a9fc9237d | ||
|
|
c093b24342 | ||
|
|
29fb82d3b7 | ||
|
|
c7355b4056 | ||
|
|
4b4ca90c71 | ||
|
|
6aa7123a8c | ||
|
|
80b2fa3583 | ||
|
|
7886204690 | ||
|
|
c2dcca980e | ||
|
|
a23dfdc4ee | ||
|
|
41a038b79b | ||
|
|
a8e06874bd | ||
|
|
54ef9ad31c | ||
|
|
32f9cf072b | ||
|
|
03e8ef0b0f | ||
|
|
a2f327f729 | ||
|
|
6e204ed0dd | ||
|
|
58ddf997e3 | ||
|
|
9656311521 | ||
|
|
676fd31635 | ||
|
|
a7f8c9cc74 | ||
|
|
a247041cab | ||
|
|
59fd238a05 | ||
|
|
a64660a530 | ||
|
|
e9a1c75b7f | ||
|
|
b6f292f556 | ||
|
|
4781a6046a | ||
|
|
b16b48f458 | ||
|
|
b4e91c87a6 | ||
|
|
a668b7c658 | ||
|
|
94fd17e4f7 | ||
|
|
abd4c480cd | ||
|
|
aa2b653c71 | ||
|
|
d75f41b641 | ||
|
|
b0f898cec8 | ||
|
|
9ec5413d33 | ||
|
|
611567c385 | ||
|
|
7a04a5b9a8 | ||
|
|
2d71d66cf5 | ||
|
|
a51e26e62d | ||
|
|
5021989cb6 | ||
|
|
2284ada723 | ||
|
|
e44f34dde3 | ||
|
|
0c820c3068 | ||
|
|
990ccd6763 | ||
|
|
f631587a20 | ||
|
|
9f8fcaf827 | ||
|
|
d7893a60ca | ||
|
|
93090c56ee | ||
|
|
d750ffc129 | ||
|
|
7efa0fc82a | ||
|
|
8db9db7e25 | ||
|
|
d165671225 | ||
|
|
7a8f71e7d8 | ||
|
|
e0ad430cd9 | ||
|
|
7695687e87 | ||
|
|
94e545bdca | ||
|
|
99daa8d24b | ||
|
|
e14903cfb2 | ||
|
|
bee344d1ae | ||
|
|
713dab278c | ||
|
|
29ad93c89d | ||
|
|
7a9140821d | ||
|
|
2ba0749993 | ||
|
|
25d75ee86f | ||
|
|
a72009fb41 | ||
|
|
a934d965be | ||
|
|
1277a40b31 | ||
|
|
6f35fec5ce | ||
|
|
f58aee2ff2 | ||
|
|
f5ee7aa0ab | ||
|
|
749b0345df | ||
|
|
7e9535381a | ||
|
|
0d5fedce92 | ||
|
|
24b5c641f5 | ||
|
|
ca31bcdbb6 | ||
|
|
ae990ebcda | ||
|
|
58dae8f931 | ||
|
|
5470cf9fa9 | ||
|
|
9bde98e912 | ||
|
|
81ac386a4a | ||
|
|
c98744b914 | ||
|
|
904be103df | ||
|
|
8e82440a55 | ||
|
|
32c789c355 | ||
|
|
d4a8cbb1d6 | ||
|
|
192236a832 | ||
|
|
e223228ec0 | ||
|
|
c7dbdf876a | ||
|
|
3ffea76e11 | ||
|
|
09547f839f | ||
|
|
0bf413b260 | ||
|
|
a5b2cb6ddf | ||
|
|
779cf9248a | ||
|
|
1d06364284 | ||
|
|
833c215c45 | ||
|
|
4d95f6f7b8 | ||
|
|
46a5f04840 | ||
|
|
3c686d0eb2 | ||
|
|
7c8ff1d19c | ||
|
|
151c5b6a1d | ||
|
|
15d1751b23 | ||
|
|
b71d49e55a | ||
|
|
c3b2bfbc39 | ||
|
|
b74a8f133f | ||
|
|
873048c21c | ||
|
|
75e9986d39 | ||
|
|
863abdb1f7 | ||
|
|
03bd1bfc63 | ||
|
|
4257fcf9d0 | ||
|
|
a68da7e220 | ||
|
|
77ef2cd487 | ||
|
|
7f1aae640f | ||
|
|
0ec025c40c | ||
|
|
bc87270ca9 | ||
|
|
0e11b0929c | ||
|
|
b741105329 | ||
|
|
2f4d1647f0 | ||
|
|
4a88ddc616 | ||
|
|
99e7dbc82b | ||
|
|
c7a7965c49 | ||
|
|
f073b278f9 | ||
|
|
4969125e5a | ||
|
|
d230ccd716 | ||
|
|
3fae11595a | ||
|
|
1e546bb9d9 | ||
|
|
138daaf565 | ||
|
|
3438d8f2b0 | ||
|
|
e55ed8eb66 | ||
|
|
a55daf5367 | ||
|
|
a173883b2d | ||
|
|
61d2284eab | ||
|
|
6083480abb | ||
|
|
2e1128b417 | ||
|
|
e47208d9b3 | ||
|
|
87bd8fefa0 | ||
|
|
753ea29df8 | ||
|
|
b1dfdef0a9 | ||
|
|
2e4676dc11 | ||
|
|
eaaf91c82b | ||
|
|
4e71f359bf | ||
|
|
b3348a38d0 | ||
|
|
7854118883 | ||
|
|
ed0e1af7aa | ||
|
|
e1a9734917 | ||
|
|
589612f914 | ||
|
|
76b4c2f254 | ||
|
|
b097cec72d | ||
|
|
9689a4f58a | ||
|
|
aac0186871 | ||
|
|
f458951b17 | ||
|
|
4448778dbf | ||
|
|
dab826bef9 | ||
|
|
9fae951d9d | ||
|
|
0f2a8c6c22 | ||
|
|
68e0cf5523 | ||
|
|
d6ba65ba75 | ||
|
|
f496138855 | ||
|
|
2f272a4190 | ||
|
|
469eca7de2 | ||
|
|
ec2eae607a | ||
|
|
292c2e289e | ||
|
|
87ac61140d | ||
|
|
81ee89de15 | ||
|
|
83081aaefc | ||
|
|
fd2917c928 | ||
|
|
4cd69f9feb | ||
|
|
4e5c7f4568 | ||
|
|
647af27274 | ||
|
|
8cc7e180ca | ||
|
|
d3d45c0be5 | ||
|
|
549dd31224 | ||
|
|
36888fac5d | ||
|
|
2409f32d87 | ||
|
|
8c3cc3af8f | ||
|
|
76fe224e7c | ||
|
|
7ccc93d9df | ||
|
|
55661e7f71 | ||
|
|
ece0613e09 | ||
|
|
0dce97b09d | ||
|
|
a3d0cc6522 | ||
|
|
1df20f7076 | ||
|
|
2fc94557a0 | ||
|
|
789698cb5c | ||
|
|
3cced9baad | ||
|
|
f3cc32554c | ||
|
|
2a905c1d6e | ||
|
|
230b145c04 | ||
|
|
9f34764f4b | ||
|
|
69ac3c14e8 | ||
|
|
f98637e122 | ||
|
|
6d936654ba | ||
|
|
4dd4047c47 | ||
|
|
1710b6bab4 | ||
|
|
041f6603c3 | ||
|
|
5acced1e33 | ||
|
|
920c8012de | ||
|
|
8f1ea09558 | ||
|
|
b873c23cf2 | ||
|
|
13c7b6e827 | ||
|
|
bbce7926b9 | ||
|
|
2c445e4bfd | ||
|
|
338d54fd34 | ||
|
|
009d1f2f5b | ||
|
|
08279645ca | ||
|
|
28ecd8e908 | ||
|
|
bc8a332ee8 | ||
|
|
d52822781c | ||
|
|
bdd37e40fe | ||
|
|
4b713e9882 | ||
|
|
fd9f5ab34e | ||
|
|
d06f986b51 | ||
|
|
8638e46cb7 | ||
|
|
85909f02b3 | ||
|
|
3572bd2f1a | ||
|
|
ff1d20d50c | ||
|
|
c300075a20 | ||
|
|
4bdfc653a3 | ||
|
|
554653900a | ||
|
|
b90b81e12c | ||
|
|
bf2b4e1b6a | ||
|
|
c05c48aaf3 | ||
|
|
39143cc15a | ||
|
|
03012da11c | ||
|
|
0547108e3f | ||
|
|
1a31aa5d62 | ||
|
|
13a1240359 | ||
|
|
b7e5486baa | ||
|
|
afeca21d73 | ||
|
|
d0ec6092b3 | ||
|
|
5c923d6629 | ||
|
|
1dc6fd3d93 | ||
|
|
5b56c80830 | ||
|
|
2291d3d4c6 | ||
|
|
02e7767886 | ||
|
|
2a01365f9b | ||
|
|
91c8866ac3 | ||
|
|
798bbe98e8 | ||
|
|
a3bbf13506 | ||
|
|
650da7beb2 | ||
|
|
3bc09d49fb | ||
|
|
6c61a9aff3 | ||
|
|
a4085f3a06 | ||
|
|
3ae18af8dd | ||
|
|
811eab8fa5 | ||
|
|
4ec75b2618 | ||
|
|
5a65d27851 | ||
|
|
685ea0bc65 | ||
|
|
c48d80592e | ||
|
|
0aa8356eca | ||
|
|
670b7c5243 | ||
|
|
706679e6b1 | ||
|
|
d288488b7f | ||
|
|
b17619296a | ||
|
|
88bd479bc7 | ||
|
|
2584befa5a | ||
|
|
90215878f8 | ||
|
|
a1a74cb1d9 | ||
|
|
9f9770e722 | ||
|
|
888af29a72 | ||
|
|
5f39c69d19 | ||
|
|
e7de2c5a05 | ||
|
|
59b07529b1 | ||
|
|
a6e9bce0dd | ||
|
|
2c52119d6c | ||
|
|
48faf8d036 | ||
|
|
0484143282 | ||
|
|
0ee214a157 | ||
|
|
774ec42be4 | ||
|
|
5a6f2b661d | ||
|
|
80cba789f4 | ||
|
|
92dd8ee8f5 | ||
|
|
1665d15d4d | ||
|
|
f0fb0b05ff | ||
|
|
02e88e3848 | ||
|
|
87eef36b1c | ||
|
|
579257bc42 | ||
|
|
e2041f7450 | ||
|
|
70112438c3 | ||
|
|
175e1dde73 | ||
|
|
e990415ee0 | ||
|
|
1543b202b2 | ||
|
|
f63168a5b5 | ||
|
|
49bccb5f1b | ||
|
|
c7e1358bb7 | ||
|
|
62a58f420c | ||
|
|
dd95e033e7 | ||
|
|
371a4055b0 | ||
|
|
f251f7b774 | ||
|
|
0f3e0de891 | ||
|
|
7081ea0ede | ||
|
|
fb04765c0e | ||
|
|
b8bda729d4 | ||
|
|
195a665293 | ||
|
|
c8de3630a5 | ||
|
|
99a29acca0 | ||
|
|
48a607cc78 | ||
|
|
19170badd3 | ||
|
|
77fc771ed0 | ||
|
|
9b9a554489 | ||
|
|
0fe8c73d19 | ||
|
|
eb66e137db | ||
|
|
c2b82c293f | ||
|
|
0b7510befa | ||
|
|
140eb0a6e5 | ||
|
|
6b8f253ecd | ||
|
|
ac29393ec9 | ||
|
|
22d6bb8180 | ||
|
|
f4e4602dcb | ||
|
|
521c5c2f75 | ||
|
|
3525484730 | ||
|
|
4a58997604 | ||
|
|
ef259f63ca | ||
|
|
2f690c0530 | ||
|
|
283a5edbdb | ||
|
|
e566b5a4f5 | ||
|
|
4e4fdd3b66 | ||
|
|
434896d50c | ||
|
|
1e7611edea | ||
|
|
2890126110 | ||
|
|
07bb8c701d | ||
|
|
55ae48ac13 | ||
|
|
c83ee391bb | ||
|
|
d01b917062 | ||
|
|
b21117091b | ||
|
|
3a73d83741 | ||
|
|
9643232d36 | ||
|
|
7b41d2046d | ||
|
|
7eb1b6c32b | ||
|
|
083fb7e9c2 | ||
|
|
afb8428db4 | ||
|
|
d6923c8571 | ||
|
|
1c38744fd1 | ||
|
|
51691dfde5 | ||
|
|
409efa1249 | ||
|
|
e4ff0909dc | ||
|
|
d3670b6890 | ||
|
|
7a74ddc1af | ||
|
|
551862a55e | ||
|
|
d3fcec3e84 | ||
|
|
088862d449 | ||
|
|
e9f758ce67 | ||
|
|
b698bfd850 | ||
|
|
c9970ff822 | ||
|
|
df594ee430 | ||
|
|
201e343795 | ||
|
|
9a307c4abd | ||
|
|
657d7f257b | ||
|
|
0ec5e02ce1 | ||
|
|
cdfb2221bb | ||
|
|
f133a2811f | ||
|
|
aecf38e3ad | ||
|
|
fa32d10f39 | ||
|
|
f4fe89a8c4 | ||
|
|
675d9a641e | ||
|
|
d896f1ff08 | ||
|
|
5cb6f370e9 | ||
|
|
e04ef5d83a | ||
|
|
155dcc5658 | ||
|
|
e927536099 | ||
|
|
f623db7d68 | ||
|
|
d40f7f5167 | ||
|
|
34bb013941 | ||
|
|
ae35be9102 | ||
|
|
bde4097df2 | ||
|
|
17b70788df | ||
|
|
b1927e4fb5 | ||
|
|
c4cb26fa9a | ||
|
|
4e86e60491 | ||
|
|
d3e07b6ad9 | ||
|
|
fa4af38b0a | ||
|
|
a9635aaa2c | ||
|
|
f0cd6dd95c | ||
|
|
d8fdfa6be2 | ||
|
|
f9511e9755 | ||
|
|
cfe1f23fff | ||
|
|
8741fd17ad | ||
|
|
ffe76717c6 | ||
|
|
eb8bbcda05 | ||
|
|
ed7040adc0 | ||
|
|
48776277bd |
+4
-4
@@ -1,6 +1,6 @@
|
||||
---
|
||||
exclude_paths:
|
||||
- '.github/**'
|
||||
- 'ci/build_verilator.sh'
|
||||
- 'include/vltstd/**'
|
||||
- 'nodist/fastcov.py'
|
||||
- ".github/**"
|
||||
- "ci/build_verilator.sh"
|
||||
- "include/vltstd/**"
|
||||
- "nodist/fastcov.py"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "Verilator Build Environment",
|
||||
"name": "Verilator Build Environment",
|
||||
|
||||
"build": {
|
||||
"build": {
|
||||
"dockerfile": "../ci/docker/buildenv/Dockerfile"
|
||||
}
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ assignees: ''
|
||||
|
||||
Thanks for taking the time to report this.
|
||||
|
||||
Can you attach an example that shows the issue? (Must be openly licensed, ideally in test_regress format.)
|
||||
Can you attach an example that shows the issue? (Must be openly licensed, completely self-contaned so can directly run what you provide. Ideally use test_regress format, see https://veripool.org/guide/latest/contributing.html?highlight=test_regress#reporting-bugs
|
||||
|
||||
What 'verilator' command line do we use to run your example?
|
||||
|
||||
|
||||
+84
-84
@@ -1,3 +1,4 @@
|
||||
---
|
||||
# DESCRIPTION: Github actions config
|
||||
# This name is key to badges in README.rst, so we use the name build
|
||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
@@ -9,7 +10,7 @@ on:
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 0 * * 0' # weekly
|
||||
- cron: '0 0 * * 0' # weekly
|
||||
|
||||
env:
|
||||
CI_OS_NAME: linux
|
||||
@@ -35,14 +36,14 @@ jobs:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ubuntu-22.04, ubuntu-20.04]
|
||||
os: [ubuntu-24.04, ubuntu-22.04, ubuntu-20.04]
|
||||
compiler:
|
||||
- { cc: clang, cxx: clang++ }
|
||||
- { cc: gcc, cxx: g++ }
|
||||
- {cc: clang, cxx: clang++}
|
||||
- {cc: gcc, cxx: g++}
|
||||
include:
|
||||
# Build GCC 10 on ubuntu-20.04
|
||||
- os: ubuntu-20.04
|
||||
compiler: { cc: gcc-10, cxx: g++-10 }
|
||||
compiler: {cc: gcc-10, cxx: g++-10}
|
||||
runs-on: ${{ matrix.os }}
|
||||
name: Build | ${{ matrix.os }} | ${{ matrix.compiler.cc }}
|
||||
env:
|
||||
@@ -51,41 +52,40 @@ jobs:
|
||||
CC: ${{ matrix.compiler.cc }}
|
||||
CXX: ${{ matrix.compiler.cxx }}
|
||||
CACHE_BASE_KEY: build-${{ matrix.os }}-${{ matrix.compiler.cc }}
|
||||
CCACHE_MAXSIZE: 1000M # Per build matrix entry (* 5 = 5000M in total)
|
||||
CCACHE_MAXSIZE: 1000M # Per build matrix entry (* 5 = 5000M in total)
|
||||
VERILATOR_ARCHIVE: verilator-${{ github.sha }}-${{ matrix.os }}-${{ matrix.compiler.cc }}.tar.gz
|
||||
steps:
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
path: repo
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
path: repo
|
||||
|
||||
- name: Cache $CCACHE_DIR
|
||||
uses: actions/cache@v4
|
||||
env:
|
||||
CACHE_KEY: ${{ env.CACHE_BASE_KEY }}-ccache
|
||||
with:
|
||||
path: ${{ env.CCACHE_DIR }}
|
||||
key: ${{ env.CACHE_KEY }}-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ env.CACHE_KEY }}-
|
||||
- name: Cache $CCACHE_DIR
|
||||
uses: actions/cache@v4
|
||||
env:
|
||||
CACHE_KEY: ${{ env.CACHE_BASE_KEY }}-ccache
|
||||
with:
|
||||
path: ${{ env.CCACHE_DIR }}
|
||||
key: ${{ env.CACHE_KEY }}-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ env.CACHE_KEY }}-
|
||||
|
||||
- name: Install packages for build
|
||||
run: ./ci/ci-install.bash
|
||||
- name: Install packages for build
|
||||
run: ./ci/ci-install.bash
|
||||
|
||||
- name: Build
|
||||
run: ./ci/ci-script.bash
|
||||
- name: Build
|
||||
run: ./ci/ci-script.bash
|
||||
|
||||
- name: Tar up repository
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: tar --posix -c -z -f ${{ env.VERILATOR_ARCHIVE }} repo
|
||||
|
||||
- name: Upload tar archive
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: ${{ github.workspace }}/${{ env.VERILATOR_ARCHIVE }}
|
||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||
- name: Tar up repository
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: tar --posix -c -z -f ${{ env.VERILATOR_ARCHIVE }} repo
|
||||
|
||||
- name: Upload tar archive
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: ${{ github.workspace }}/${{ env.VERILATOR_ARCHIVE }}
|
||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||
|
||||
test:
|
||||
needs: build
|
||||
@@ -94,25 +94,25 @@ jobs:
|
||||
matrix:
|
||||
os: [ubuntu-22.04, ubuntu-20.04]
|
||||
compiler:
|
||||
- { cc: clang, cxx: clang++ }
|
||||
- { cc: gcc, cxx: g++ }
|
||||
- {cc: clang, cxx: clang++}
|
||||
- {cc: gcc, cxx: g++}
|
||||
reloc: [0]
|
||||
suite: [dist-vlt-0, dist-vlt-1, dist-vlt-2, dist-vlt-3, vltmt-0, vltmt-1]
|
||||
include:
|
||||
# Test with GCC 10 on ubuntu-20.04
|
||||
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: dist-vlt-0}
|
||||
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: dist-vlt-1}
|
||||
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: dist-vlt-2}
|
||||
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: dist-vlt-3}
|
||||
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: vltmt-0}
|
||||
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: vltmt-1}
|
||||
# Test relocated installation - on most common platform only
|
||||
- {os: ubuntu-22.04, compiler: { cc: gcc, cxx: g++ }, reloc: 1, suite: dist-vlt-0}
|
||||
- {os: ubuntu-22.04, compiler: { cc: gcc, cxx: g++ }, reloc: 1, suite: dist-vlt-1}
|
||||
- {os: ubuntu-22.04, compiler: { cc: gcc, cxx: g++ }, reloc: 1, suite: dist-vlt-2}
|
||||
- {os: ubuntu-22.04, compiler: { cc: gcc, cxx: g++ }, reloc: 1, suite: dist-vlt-3}
|
||||
- {os: ubuntu-22.04, compiler: { cc: gcc, cxx: g++ }, reloc: 1, suite: vltmt-0}
|
||||
- {os: ubuntu-22.04, compiler: { cc: gcc, cxx: g++ }, reloc: 1, suite: vltmt-1}
|
||||
# Test with GCC 10 on ubuntu-20.04, also test relocation
|
||||
- {os: ubuntu-20.04, compiler: {cc: gcc-10, cxx: g++-10}, reloc: 1, suite: dist-vlt-0}
|
||||
- {os: ubuntu-20.04, compiler: {cc: gcc-10, cxx: g++-10}, reloc: 1, suite: dist-vlt-1}
|
||||
- {os: ubuntu-20.04, compiler: {cc: gcc-10, cxx: g++-10}, reloc: 1, suite: dist-vlt-2}
|
||||
- {os: ubuntu-20.04, compiler: {cc: gcc-10, cxx: g++-10}, reloc: 1, suite: dist-vlt-3}
|
||||
- {os: ubuntu-20.04, compiler: {cc: gcc-10, cxx: g++-10}, reloc: 1, suite: vltmt-0}
|
||||
- {os: ubuntu-20.04, compiler: {cc: gcc-10, cxx: g++-10}, reloc: 1, suite: vltmt-1}
|
||||
# Ubuntu 24.04 only on GCC; not passing on clang yet
|
||||
- {os: ubuntu-24.04, compiler: {cc: gcc, cxx: g++}, suite: dist-vlt-0}
|
||||
- {os: ubuntu-24.04, compiler: {cc: gcc, cxx: g++}, suite: dist-vlt-1}
|
||||
- {os: ubuntu-24.04, compiler: {cc: gcc, cxx: g++}, suite: dist-vlt-2}
|
||||
- {os: ubuntu-24.04, compiler: {cc: gcc, cxx: g++}, suite: dist-vlt-3}
|
||||
- {os: ubuntu-24.04, compiler: {cc: gcc, cxx: g++}, suite: vltmt-0}
|
||||
- {os: ubuntu-24.04, compiler: {cc: gcc, cxx: g++}, suite: vltmt-1}
|
||||
runs-on: ${{ matrix.os }}
|
||||
name: Test | ${{ matrix.os }} | ${{ matrix.compiler.cc }} | ${{ matrix.reloc && 'reloc | ' || '' }} ${{ matrix.suite }}
|
||||
env:
|
||||
@@ -122,37 +122,37 @@ jobs:
|
||||
CC: ${{ matrix.compiler.cc }}
|
||||
CXX: ${{ matrix.compiler.cxx }}
|
||||
CACHE_BASE_KEY: test-${{ matrix.os }}-${{ matrix.compiler.cc }}-${{ matrix.reloc }}-${{ matrix.suite }}
|
||||
CCACHE_MAXSIZE: 100M # Per build per suite (* 5 * 5 = 2500M in total)
|
||||
CCACHE_MAXSIZE: 100M # Per build per suite (* 5 * 5 = 2500M in total)
|
||||
VERILATOR_ARCHIVE: verilator-${{ github.sha }}-${{ matrix.os }}-${{ matrix.compiler.cc }}.tar.gz
|
||||
steps:
|
||||
|
||||
- name: Download tar archive
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||
path: ${{ github.workspace }}
|
||||
- name: Download tar archive
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||
path: ${{ github.workspace }}
|
||||
|
||||
- name: Unpack tar archive
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: tar -x -z -f ${{ env.VERILATOR_ARCHIVE }}
|
||||
- name: Unpack tar archive
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: tar -x -z -f ${{ env.VERILATOR_ARCHIVE }}
|
||||
|
||||
- name: Cache $CCACHE_DIR
|
||||
uses: actions/cache@v4
|
||||
env:
|
||||
CACHE_KEY: ${{ env.CACHE_BASE_KEY }}-ccache2
|
||||
with:
|
||||
path: ${{ env.CCACHE_DIR }}
|
||||
key: ${{ env.CACHE_KEY }}-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ env.CACHE_KEY }}-
|
||||
- name: Cache $CCACHE_DIR
|
||||
uses: actions/cache@v4
|
||||
env:
|
||||
CACHE_KEY: ${{ env.CACHE_BASE_KEY }}-ccache2
|
||||
with:
|
||||
path: ${{ env.CCACHE_DIR }}
|
||||
key: ${{ env.CACHE_KEY }}-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ env.CACHE_KEY }}-
|
||||
|
||||
- name: Install test dependencies
|
||||
run: ./ci/ci-install.bash
|
||||
- name: Install test dependencies
|
||||
run: ./ci/ci-install.bash
|
||||
|
||||
- name: Test
|
||||
env:
|
||||
TESTS: ${{ matrix.suite }}
|
||||
run: ./ci/ci-script.bash
|
||||
- name: Test
|
||||
env:
|
||||
TESTS: ${{ matrix.suite }}
|
||||
run: ./ci/ci-script.bash
|
||||
|
||||
lint-py:
|
||||
runs-on: ubuntu-22.04
|
||||
@@ -161,21 +161,21 @@ jobs:
|
||||
CI_BUILD_STAGE_NAME: build
|
||||
CI_RUNS_ON: ubuntu-22.04
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
path: repo
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
path: repo
|
||||
|
||||
- name: Install packages for build
|
||||
run: ./ci/ci-install.bash
|
||||
- name: Install packages for build
|
||||
run: ./ci/ci-install.bash
|
||||
|
||||
# We use specific version numbers, otherwise a Python package
|
||||
# update may add a warning and break our build
|
||||
- name: Install packages for lint
|
||||
run: sudo pip3 install pylint==3.0.2 ruff==0.1.3 clang sphinx sphinx_rtd_theme sphinxcontrib-spelling breathe ruff
|
||||
- name: Install packages for lint
|
||||
run: sudo pip3 install pylint==3.0.2 ruff==0.1.3 clang sphinx sphinx_rtd_theme sphinxcontrib-spelling breathe ruff
|
||||
|
||||
- name: Configure
|
||||
run: autoconf && ./configure --enable-longtests --enable-ccwarn
|
||||
- name: Configure
|
||||
run: autoconf && ./configure --enable-longtests --enable-ccwarn
|
||||
|
||||
- name: Lint
|
||||
run: make -k lint-py
|
||||
- name: Lint
|
||||
run: make -k lint-py
|
||||
|
||||
@@ -1,17 +1,16 @@
|
||||
---
|
||||
# DESCRIPTION: Github actions config
|
||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
#
|
||||
name: Contributor Agreement
|
||||
|
||||
on:
|
||||
push:
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
Test:
|
||||
name: "'docs/CONTRIBUTORS' was signed"
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- run: test_regress/t/t_dist_contributors.pl
|
||||
- uses: actions/checkout@v4
|
||||
- run: test_regress/t/t_dist_contributors.py
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
---
|
||||
# DESCRIPTION: Github actions config
|
||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
@@ -6,7 +7,7 @@ name: coverage
|
||||
on:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 0 * * 0' # weekly
|
||||
- cron: '0 0 * * 0' # weekly
|
||||
|
||||
env:
|
||||
CI_OS_NAME: linux
|
||||
@@ -21,7 +22,6 @@ defaults:
|
||||
|
||||
jobs:
|
||||
|
||||
|
||||
Build:
|
||||
runs-on: ubuntu-22.04
|
||||
env:
|
||||
@@ -29,49 +29,36 @@ jobs:
|
||||
CI_RUNS_ON: ubuntu-22.04
|
||||
steps:
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
path: repo
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
path: repo
|
||||
|
||||
- name: Install packages for build
|
||||
run: ./ci/ci-install.bash
|
||||
- name: Install packages for build
|
||||
run: ./ci/ci-install.bash
|
||||
|
||||
- name: Build
|
||||
run: ./ci/ci-script.bash
|
||||
- name: Build
|
||||
run: ./ci/ci-script.bash
|
||||
|
||||
- name: Tar up repository
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: tar --posix -c -z -f ${{ env.VERILATOR_ARCHIVE }} repo
|
||||
|
||||
- name: Upload tar archive
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: ${{ github.workspace }}/${{ env.VERILATOR_ARCHIVE }}
|
||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||
- name: Tar up repository
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: tar --posix -c -z -f ${{ env.VERILATOR_ARCHIVE }} repo
|
||||
|
||||
- name: Upload tar archive
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: ${{ github.workspace }}/${{ env.VERILATOR_ARCHIVE }}
|
||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||
|
||||
Test:
|
||||
needs: Build
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
test:
|
||||
- vlt-
|
||||
- vltmt-
|
||||
num:
|
||||
- 0
|
||||
- 1
|
||||
- 2
|
||||
- 3
|
||||
- 4
|
||||
- 5
|
||||
- 6
|
||||
- 7
|
||||
- 8
|
||||
- 9
|
||||
test: [vlt-, vltmt-]
|
||||
num: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
|
||||
include:
|
||||
- { test: dist, num: '' }
|
||||
- {test: dist, num: ''}
|
||||
runs-on: ubuntu-22.04
|
||||
name: test-${{ matrix.test }}${{ matrix.num }}
|
||||
env:
|
||||
@@ -79,27 +66,27 @@ jobs:
|
||||
CI_RUNS_ON: ubuntu-22.04
|
||||
steps:
|
||||
|
||||
- name: Download tar archive
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||
path: ${{ github.workspace }}
|
||||
- name: Download tar archive
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||
path: ${{ github.workspace }}
|
||||
|
||||
- name: Unpack tar archive
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: tar -x -z -f ${{ env.VERILATOR_ARCHIVE }}
|
||||
- name: Unpack tar archive
|
||||
working-directory: ${{ github.workspace }}
|
||||
run: tar -x -z -f ${{ env.VERILATOR_ARCHIVE }}
|
||||
|
||||
- name: Install test dependencies
|
||||
run: ./ci/ci-install.bash
|
||||
- name: Install test dependencies
|
||||
run: ./ci/ci-install.bash
|
||||
|
||||
- name: Test
|
||||
env:
|
||||
TESTS: coverage-${{ matrix.test }}${{ matrix.num }}
|
||||
run: ./ci/ci-script.bash
|
||||
- name: Test
|
||||
env:
|
||||
TESTS: coverage-${{ matrix.test }}${{ matrix.num }}
|
||||
run: ./ci/ci-script.bash
|
||||
|
||||
- name: Upload coverage data to Codecov
|
||||
env:
|
||||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
||||
run: |
|
||||
find . -name '*.gcno' -exec rm {} \;
|
||||
./ci/codecov -v upload-process -Z --sha ${{ github.sha }} -f nodist/obj_dir/coverage/app_total.info
|
||||
- name: Upload coverage data to Codecov
|
||||
env:
|
||||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
||||
run: |
|
||||
find . -name '*.gcno' -exec rm {} \;
|
||||
./ci/codecov -v upload-process -Z --sha ${{ github.sha }} -f nodist/obj_dir/coverage/app_total.info
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
---
|
||||
# Build and push verilator docker image when tags are pushed to the repository.
|
||||
# The following variable(s) must be configured in the github repository:
|
||||
# DOCKER_HUB_NAMESPACE: docker hub namespace.
|
||||
@@ -8,7 +9,7 @@ name: Build Verilator Container
|
||||
|
||||
on:
|
||||
push:
|
||||
tags: [ 'v*' ]
|
||||
tags: ['v*']
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
manual_tag:
|
||||
@@ -34,52 +35,52 @@ jobs:
|
||||
# - "ci/docker/buildenv:verilator-buildenv"
|
||||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Extract context variables
|
||||
run: |
|
||||
echo "${{ matrix.contexts }}" | sed -r 's/(.*):.*/build_context=\1/' >> "$GITHUB_ENV"
|
||||
echo "${{ matrix.contexts }}" | sed -r 's/.*:(.*)/image_name=\1/' >> "$GITHUB_ENV"
|
||||
echo "git_tag=${GITHUB_REF#refs/*/}" >> "$GITHUB_ENV"
|
||||
- name: Extract context variables
|
||||
run: |
|
||||
echo "${{ matrix.contexts }}" | sed -r 's/(.*):.*/build_context=\1/' >> "$GITHUB_ENV"
|
||||
echo "${{ matrix.contexts }}" | sed -r 's/.*:(.*)/image_name=\1/' >> "$GITHUB_ENV"
|
||||
echo "git_tag=${GITHUB_REF#refs/*/}" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Use manual tag
|
||||
if: ${{ inputs.manual_tag }}
|
||||
run: |
|
||||
echo "git_tag=${{ inputs.manual_tag }}" >> "$GITHUB_ENV"
|
||||
- name: Use manual tag
|
||||
if: ${{ inputs.manual_tag }}
|
||||
run: |
|
||||
echo "git_tag=${{ inputs.manual_tag }}" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Docker meta
|
||||
id: docker_meta
|
||||
uses: docker/metadata-action@v4
|
||||
with:
|
||||
images: |
|
||||
${{ vars.DOCKER_HUB_NAMESPACE }}/${{ env.image_name }}
|
||||
tags: |
|
||||
type=match,pattern=(v.*),group=1,enable=${{ startsWith(github.ref, 'refs/tags/v') }}
|
||||
type=raw,value=${{ inputs.manual_tag }},enable=${{ inputs.manual_tag != '' }}
|
||||
type=raw,value=latest,enable=${{ inputs.add_latest_tag == true }}
|
||||
- name: Docker meta
|
||||
id: docker_meta
|
||||
uses: docker/metadata-action@v4
|
||||
with:
|
||||
images: |
|
||||
${{ vars.DOCKER_HUB_NAMESPACE }}/${{ env.image_name }}
|
||||
tags: |
|
||||
type=match,pattern=(v.*),group=1,enable=${{ startsWith(github.ref, 'refs/tags/v') }}
|
||||
type=raw,value=${{ inputs.manual_tag }},enable=${{ inputs.manual_tag != '' }}
|
||||
type=raw,value=latest,enable=${{ inputs.add_latest_tag == true }}
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v2
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v2
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
with:
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
with:
|
||||
buildkitd-flags: --debug
|
||||
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_HUB_USER }}
|
||||
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_HUB_USER }}
|
||||
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
|
||||
|
||||
- name: Build and Push to Docker
|
||||
uses: docker/build-push-action@v4
|
||||
if: startsWith(github.ref, 'refs/tags/v')
|
||||
with:
|
||||
context: ${{ env.build_context }}
|
||||
build-args: SOURCE_COMMIT=${{ env.git_tag }}
|
||||
platforms: linux/arm64,linux/amd64
|
||||
push: ${{ !env.ACT && startsWith(github.ref, 'refs/tags/v') }}
|
||||
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||
labels: ${{ steps.docker_meta.outputs.labels }}
|
||||
- name: Build and Push to Docker
|
||||
uses: docker/build-push-action@v4
|
||||
if: startsWith(github.ref, 'refs/tags/v')
|
||||
with:
|
||||
context: ${{ env.build_context }}
|
||||
build-args: SOURCE_COMMIT=${{ env.git_tag }}
|
||||
platforms: linux/arm64,linux/amd64
|
||||
push: ${{ !env.ACT && startsWith(github.ref, 'refs/tags/v') }}
|
||||
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||
labels: ${{ steps.docker_meta.outputs.labels }}
|
||||
|
||||
@@ -1,13 +1,12 @@
|
||||
---
|
||||
# DESCRIPTION: Github actions config
|
||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
#
|
||||
name: format
|
||||
|
||||
on:
|
||||
push:
|
||||
pull_request_target:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
format:
|
||||
runs-on: ubuntu-22.04
|
||||
|
||||
@@ -1,55 +1,50 @@
|
||||
---
|
||||
# DESCRIPTION: Github actions config
|
||||
# This name is key to badges in README.rst, so we use the name build
|
||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
#
|
||||
name: msbuild
|
||||
|
||||
on:
|
||||
push:
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 0 * * 0' # weekly
|
||||
|
||||
- cron: 0 0 * * 0 # weekly
|
||||
env:
|
||||
CI_OS_NAME: win
|
||||
CI_COMMIT: ${{ github.sha }}
|
||||
CCACHE_COMPRESS: 1
|
||||
CCACHE_DIR: ${{ github.workspace }}/.ccache
|
||||
CCACHE_LIMIT_MULTIPLE: 0.95
|
||||
|
||||
defaults:
|
||||
run:
|
||||
working-directory: repo
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.ref || github.run_id }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
|
||||
windows:
|
||||
windows:
|
||||
name: run on windows
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
path: repo
|
||||
- name: Cache $CCACHE_DIR
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ${{ env.CCACHE_DIR }}
|
||||
key: msbuild-msvc-cmake
|
||||
- name: compile
|
||||
env:
|
||||
WIN_FLEX_BISON: ${{ github.workspace }}/.ccache
|
||||
run: ./ci/ci-win-compile.ps1
|
||||
- name: test build
|
||||
run: ./ci/ci-win-test.ps1
|
||||
- name: Zip up repository
|
||||
run: Compress-Archive -LiteralPath install -DestinationPath verilator.zip
|
||||
- name: Upload zip archive
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: ${{ github.workspace }}/repo/verilator.zip
|
||||
name: verilator-win.zip
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
path: repo
|
||||
- name: Cache $CCACHE_DIR
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ${{ env.CCACHE_DIR }}
|
||||
key: msbuild-msvc-cmake
|
||||
- name: compile
|
||||
env:
|
||||
WIN_FLEX_BISON: ${{ github.workspace }}/.ccache
|
||||
run: ./ci/ci-win-compile.ps1
|
||||
- name: test build
|
||||
run: ./ci/ci-win-test.ps1
|
||||
- name: Zip up repository
|
||||
run: Compress-Archive -LiteralPath install -DestinationPath verilator.zip
|
||||
- name: Upload zip archive
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: ${{ github.workspace }}/repo/verilator.zip
|
||||
name: verilator-win.zip
|
||||
|
||||
+5
-4
@@ -29,14 +29,15 @@ dddrun*
|
||||
doxygen-doc
|
||||
gdbrun*
|
||||
gmon.out
|
||||
ncverilog.history
|
||||
internals.txt
|
||||
ncverilog.history
|
||||
nohup.out
|
||||
verilator-config-version.cmake
|
||||
verilator-config.cmake
|
||||
verilator.pc
|
||||
verilator.txt
|
||||
verilator_bin*
|
||||
verilator_coverage_bin*
|
||||
verilator.pc
|
||||
verilator-config.cmake
|
||||
verilator-config-version.cmake
|
||||
**/__pycache__/*
|
||||
**/_build/*
|
||||
**/obj_dir/*
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
---
|
||||
- id: verilator
|
||||
name: verilator-lint
|
||||
description: Runs verilator Docker image to lint (System) Verilog designs
|
||||
args: [--lint-only]
|
||||
language: docker_image
|
||||
entry: verilator/verilator:latest
|
||||
types_or: [verilog, system-verilog]
|
||||
@@ -0,0 +1,4 @@
|
||||
[style]
|
||||
based_on_style = pep8
|
||||
column_limit = 99
|
||||
#split_before_arithmetic_operator=True
|
||||
+75
-34
@@ -4,7 +4,7 @@
|
||||
#
|
||||
#*****************************************************************************
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
@@ -14,37 +14,49 @@
|
||||
|
||||
cmake_minimum_required(VERSION 3.15)
|
||||
cmake_policy(SET CMP0091 NEW) # Use MSVC_RUNTIME_LIBRARY to select the runtime
|
||||
project(Verilator
|
||||
VERSION 5.028
|
||||
project(
|
||||
Verilator
|
||||
VERSION 5.034
|
||||
HOMEPAGE_URL https://verilator.org
|
||||
LANGUAGES CXX
|
||||
)
|
||||
|
||||
option(DEBUG_AND_RELEASE_AND_COVERAGE
|
||||
"Builds both the debug and release binaries, overriding CMAKE_BUILD_TYPE. Not supported under MSBuild.")
|
||||
# Set default build type to Release if not specified
|
||||
if(NOT CMAKE_BUILD_TYPE)
|
||||
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Build type" FORCE)
|
||||
endif()
|
||||
|
||||
option(
|
||||
DEBUG_AND_RELEASE_AND_COVERAGE
|
||||
"Builds both the debug and release binaries, overriding CMAKE_BUILD_TYPE. Not supported under MSBuild."
|
||||
)
|
||||
|
||||
find_package(Python3 COMPONENTS Interpreter)
|
||||
set(PYTHON3 ${Python3_EXECUTABLE})
|
||||
set(CMAKE_INSTALL_DATADIR ${CMAKE_INSTALL_PREFIX})
|
||||
# See also CMake built-in; CMAKE_INSTALL_PREFIX is applied by the install command.
|
||||
set(CMAKE_INSTALL_DATADIR .)
|
||||
include(GNUInstallDirs)
|
||||
include(CMakePackageConfigHelpers)
|
||||
include(CheckStructHasMember)
|
||||
include(ExternalProject)
|
||||
include(FindThreads)
|
||||
|
||||
if (NOT WIN32)
|
||||
if(NOT WIN32)
|
||||
message(WARNING "CMake support on Linux/OSX is experimental.")
|
||||
endif()
|
||||
|
||||
if (WIN32)
|
||||
if (DEFINED ENV{WIN_FLEX_BISON})
|
||||
if(WIN32)
|
||||
if(DEFINED ENV{WIN_FLEX_BISON})
|
||||
set(WIN_FLEX_BISON "$ENV{WIN_FLEX_BISON}")
|
||||
endif()
|
||||
if (EXISTS ${WIN_FLEX_BISON})
|
||||
if(EXISTS ${WIN_FLEX_BISON})
|
||||
list(APPEND CMAKE_PREFIX_PATH ${WIN_FLEX_BISON})
|
||||
endif()
|
||||
if (NOT WIN_FLEX_BISON)
|
||||
message(FATAL_ERROR "Please install https://github.com/lexxmark/winflexbison and set WIN_FLEX_BISON environment variable. Please use install cmake target after a successful build.")
|
||||
if(NOT WIN_FLEX_BISON)
|
||||
message(
|
||||
FATAL_ERROR
|
||||
"Please install https://github.com/lexxmark/winflexbison and set WIN_FLEX_BISON environment variable. Please use install cmake target after a successful build."
|
||||
)
|
||||
endif()
|
||||
set(CMAKE_CXX_STANDARD 20)
|
||||
endif()
|
||||
@@ -52,20 +64,25 @@ endif()
|
||||
set(OBJCACHE "" CACHE STRING "Path for ccache, auto-detected if empty")
|
||||
option(OBJCACHE_ENABLED "Compile Verilator with ccache" ON)
|
||||
|
||||
if (OBJCACHE_ENABLED)
|
||||
if (OBJCACHE STREQUAL "")
|
||||
if(OBJCACHE_ENABLED)
|
||||
if(OBJCACHE STREQUAL "")
|
||||
find_program(OBJCACHE_PATH ccache)
|
||||
if (OBJCACHE_PATH STREQUAL "OBJCACHE_PATH-NOTFOUND")
|
||||
if(OBJCACHE_PATH STREQUAL "OBJCACHE_PATH-NOTFOUND")
|
||||
set(OBJCACHE_PATH "")
|
||||
endif()
|
||||
else()
|
||||
set(OBJCACHE_PATH "${OBJCACHE}")
|
||||
endif()
|
||||
if (NOT OBJCACHE_PATH STREQUAL "")
|
||||
execute_process(COMMAND "${OBJCACHE_PATH}" --version
|
||||
OUTPUT_VARIABLE objcache_version)
|
||||
if(NOT OBJCACHE_PATH STREQUAL "")
|
||||
execute_process(
|
||||
COMMAND "${OBJCACHE_PATH}" --version
|
||||
OUTPUT_VARIABLE objcache_version
|
||||
)
|
||||
string(REGEX MATCH "[^\n\r]+" objcache_version "${objcache_version}")
|
||||
message(STATUS "Found ccache: ${OBJCACHE_PATH} (\"${objcache_version}\")")
|
||||
message(
|
||||
STATUS
|
||||
"Found ccache: ${OBJCACHE_PATH} (\"${objcache_version}\")"
|
||||
)
|
||||
set(CMAKE_CXX_COMPILER_LAUNCHER "${OBJCACHE_PATH}")
|
||||
endif()
|
||||
endif()
|
||||
@@ -76,8 +93,8 @@ find_package(FLEX)
|
||||
# Build
|
||||
#set_property(GLOBAL PROPERTY JOB_POOLS one_job=1)
|
||||
|
||||
if (DEBUG_AND_RELEASE_AND_COVERAGE)
|
||||
if (CMAKE_GENERATOR MATCHES "^Visual Studio ")
|
||||
if(DEBUG_AND_RELEASE_AND_COVERAGE)
|
||||
if(CMAKE_GENERATOR MATCHES "^Visual Studio ")
|
||||
error("%Error: The DEBUG_AND_RELEASE_AND_COVERAGE option is not supported in MSBuild-based builds.")
|
||||
endif()
|
||||
set(saved_build_type ${CMAKE_BUILD_TYPE})
|
||||
@@ -102,22 +119,39 @@ set(AR ${CMAKE_AR})
|
||||
configure_file(include/verilated_config.h.in include/verilated_config.h @ONLY)
|
||||
configure_file(include/verilated.mk.in include/verilated.mk @ONLY)
|
||||
|
||||
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/include/verilated_config.h DESTINATION ${CMAKE_INSTALL_PREFIX}/include)
|
||||
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/include/verilated.mk DESTINATION ${CMAKE_INSTALL_PREFIX}/include)
|
||||
|
||||
configure_package_config_file(verilator-config.cmake.in verilator-config.cmake
|
||||
INSTALL_DESTINATION ${CMAKE_INSTALL_PREFIX}
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/include/verilated_config.h
|
||||
DESTINATION include
|
||||
)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/include/verilated.mk
|
||||
DESTINATION include
|
||||
)
|
||||
|
||||
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/verilator-config.cmake DESTINATION ${CMAKE_INSTALL_PREFIX})
|
||||
|
||||
configure_package_config_file(verilator-config-version.cmake.in verilator-config-version.cmake
|
||||
INSTALL_DESTINATION ${CMAKE_INSTALL_PREFIX}
|
||||
configure_package_config_file(
|
||||
verilator-config.cmake.in
|
||||
verilator-config.cmake
|
||||
INSTALL_DESTINATION .
|
||||
)
|
||||
|
||||
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/verilator-config-version.cmake DESTINATION ${CMAKE_INSTALL_PREFIX})
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/verilator-config.cmake
|
||||
DESTINATION .
|
||||
)
|
||||
|
||||
foreach (program
|
||||
configure_package_config_file(
|
||||
verilator-config-version.cmake.in
|
||||
verilator-config-version.cmake
|
||||
INSTALL_DESTINATION .
|
||||
)
|
||||
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/verilator-config-version.cmake
|
||||
DESTINATION .
|
||||
)
|
||||
|
||||
foreach(
|
||||
program
|
||||
verilator
|
||||
verilator_gantt
|
||||
verilator_ccache_report
|
||||
@@ -128,16 +162,23 @@ foreach (program
|
||||
install(PROGRAMS bin/${program} TYPE BIN)
|
||||
endforeach()
|
||||
|
||||
install(DIRECTORY examples TYPE DATA FILES_MATCHING
|
||||
install(
|
||||
DIRECTORY examples
|
||||
TYPE DATA
|
||||
FILES_MATCHING
|
||||
PATTERN "examples/*/*.[chv]*"
|
||||
PATTERN "examples/*/Makefile*"
|
||||
PATTERN "examples/*/CMakeLists.txt"
|
||||
)
|
||||
|
||||
install(DIRECTORY include TYPE DATA FILES_MATCHING
|
||||
install(
|
||||
DIRECTORY include
|
||||
TYPE DATA
|
||||
FILES_MATCHING
|
||||
PATTERN "include/verilated_config.h"
|
||||
PATTERN "include/*.[chv]"
|
||||
PATTERN "include/*.cpp"
|
||||
PATTERN "include/*.vlt"
|
||||
PATTERN "include/*.sv"
|
||||
PATTERN "include/gtkwave/*.[chv]*"
|
||||
PATTERN "include/vltstd/*.[chv]*"
|
||||
|
||||
@@ -8,6 +8,220 @@ The changes in each Verilator version are described below. The
|
||||
contributors that suggested a given feature are shown in []. Thanks!
|
||||
|
||||
|
||||
Verilator 5.034 2025-02-24
|
||||
==========================
|
||||
|
||||
**Important:**
|
||||
|
||||
* This is likely the last version to support Ubuntu 20.04, which is at end-of-life.
|
||||
* Add expression coverage (#4677) (#5719). [Todd Strader]
|
||||
|
||||
**Other:**
|
||||
|
||||
* Add `COVERIGN` warning, as a more specific UNSUPPORTED error.
|
||||
* Add `--public-ignore` to ignore public metacomments (#5716). [Andrew Nolte]
|
||||
* Add `--preproc-token-limit` (#5768). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Add lint error on importing package within a class (#5634) (#5679). [Nick Brereton]
|
||||
* Add `--preproc-resolve` for modules in preprocessor output (#5789). [Kamil Rakoczy, Antmicro Ltd.]
|
||||
* Support multidimensional array access via VPI (#2812) (#5573). [Krzysztof Starecki]
|
||||
* Support nested classes (#4178) (#5778). [Kamil Rakoczy, Antmicro Ltd.]
|
||||
* Support VPI array accessors (#5612). [Moubarak Jeje]
|
||||
* Support unpacked structure constrained randomization (#5657) (#5759). [Yilou Wang]
|
||||
* Support generated classes (#5665). [Shou-Li Hsu]
|
||||
* Support constraints on associative array user-defined keys (#5671) (#5729). [Yilou Wang]
|
||||
* Support `+incdir` with multiple directories.
|
||||
* Support integer atom type ports in `--hierarchical` (#5748). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Support constrained random for arrays in structs (#5765) (#5802). [Yilou Wang]
|
||||
* Support selects on arbitrary string expressions (#5773). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Support side effects of form 'variable[index_function()]++'.
|
||||
* Improve hierarchical DPI wrapper scheduling performance (#2583) (#5734). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Improve VPI write errors (#5712). [Andrew Nolte]
|
||||
* Improve `resetall support (#5728) (#5730). [Ethan Sifferman]
|
||||
* Optimize labels as final `if` block statements (#5744).
|
||||
* Optimize empty function definition bodies (#5750).
|
||||
* Optimize splitting trigger computation and dump (#5798). [Geza Lore]
|
||||
* Fix error message when call task as a function (#3089). [Matthew Ballance]
|
||||
* Fix force VPI public signal visibility (#5225). [Frédéric Requin]
|
||||
* Fix VPI iteration over hierarchy (#5314) (#5731). [Natan Kreimer]
|
||||
* Fix constrained random for > 64-bit associative arrays (#5670) (#5682). [Yilou Wang]
|
||||
* Fix mis-optimizing away `$urandom` (#5703). [Parker Schless]
|
||||
* Fix packages with `--public-depth 1` (#5708). [Andrew Nolte]
|
||||
* Fix V3Simulate constant reuse (#5709). [Geza Lore]
|
||||
* Fix man pages what-is section (#5710). [Ahmed El-Mahmoudy]
|
||||
* Fix pattern assignment to real inside struct (#5713).
|
||||
* Fix %p format output for real inside struct (#5713).
|
||||
* Fix segfault when only enum value referenced in package (#5714). [Dan Katz]
|
||||
* Fix `BLKSEQ` on suspendable processes (#5722). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix vpiDefName issues with non-inlined scopes and dpi conflicts (#5732). [Andrew Nolte]
|
||||
* Fix inlined expression with assignment under LHS of NBA (#5736) (#5740). [Geza Lore]
|
||||
* Fix duplicate-named class variable equivalence (#5737).
|
||||
* Fix `-j` ignored after `-f` (#5749). [Luca Colagrande]
|
||||
* Fix handling forced assigns in V3Life (#5757). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Fix VFileContent reference count (#5769) (#5771). [Dave Sargeant]
|
||||
* Fix ignoring joins in stringify in preprocessor (#5777). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix unpacked split_var (#5782) (#5785). [Yutetsu TAKATSUKASA]
|
||||
* Fix time import error on time parameters (#5786). [Luca Colagrande]
|
||||
* Fix dpi context functions (#5788). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix `$monitor` with dotted references (#5794). [Ahmed Elzeftawi]
|
||||
* Fix parsing input wire with default and range (#5800). [RJ Cunningham]
|
||||
* Fix matching language extension options including dots.
|
||||
|
||||
|
||||
Verilator 5.032 2025-01-01
|
||||
==========================
|
||||
|
||||
**Minor:**
|
||||
|
||||
* Support queue's assignment `push_back/push_front('{})` (#5585) (#5586). [Yilou Wang]
|
||||
* Support basic constrained random for multi-dimensional dynamic array and queue (#5591). [Yilou Wang]
|
||||
* Support vpiDefName (#3906) (#5572). [Krzysztof Starecki]
|
||||
* Support parameter names in pattern initialization (#5593) (#5596). [Greg Davill]
|
||||
* Support randomize size constraints with restrictions (#5582 partial) (#5611). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Support associative array basic constrained randomization (#5658) (#5670). [Yilou Wang]
|
||||
* Support `default disable iff` and `$inferred_disable` (#4016). [Srinivasan Venkataramanan]
|
||||
* Support `extern constraint` and `pure constraint`.
|
||||
* Add `--no-std-waiver` and default reading of standard lint waivers file (#5607).
|
||||
* Add `--no-std-package` as subset-alias of `--no-std` (#5607).
|
||||
* Add `lint_off --contents` in configuration files (#5606).
|
||||
* Add `--waiver-multiline` for context-sensitive `--waiver-output` (#5608).
|
||||
* Add `--fno-inline-funcs` to disable function inlining.
|
||||
* Add `--fno-slice` to disable array assignment slicing (#5644).
|
||||
* Add error on illegal enum base type (#3010). [Iztok Jeras]
|
||||
* Add error on `wait` with missing `.triggered` (#4457).
|
||||
* Add error when improperly storing to parameter (#5147). [Gökçe Aydos]
|
||||
* Add error on illegal `--prefix` etc. values (#5507). [Fabian Keßler]
|
||||
* Add error on `--savable --timing` (#5690). [Narcis Rodas]
|
||||
* Add coverage point hierarchy to coverage reports (#5575) (#5576). [Andrew Nolte]
|
||||
* Add warning on global constraints (#5625). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Add default CMAKE_BUILD_TYPE (#5691) (#5692). [Anthony Moore]
|
||||
* Add error on `solve before` or soft constraints of `randc` variable.
|
||||
* Improve concatenation performance (#5598) (#5599) (#5602). [Geza Lore]
|
||||
* Improve optimization of duplicate wide expressions (#5637). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Fix dotted reference in delay value (#2410).
|
||||
* Fix `function fork...join_none` regression with unknown type (#4449).
|
||||
* Fix public_module requiring a wire to become public (#4916). [Andrew Nolte]
|
||||
* Fix --hierarchical on projects with dot-f dependency lists (#5199) (#5669). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Fix can't locate scope error in interface task delayed assignment (#5462) (#5568). [Zhou Shen]
|
||||
* Fix BLKANDNBLK for for VARXREFs (#5569). [Todd Strader]
|
||||
* Fix VPI error instead of fatal for vpi_get_value() on large signals (#5571). [Todd Strader]
|
||||
* Fix --output-groups leftover files issue (#5574). [Todd Strader]
|
||||
* Fix slow unsized number parsing (#5577). [Geza Lore]
|
||||
* Fix negative assignment pattern keys (#5580). [Iztok Jeras]
|
||||
* Fix duplicate scope identifiers decoding (#5584). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Fix `rand` dynamic arrays with null handles (#5594). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix NBAs to unpacked arrays of unpacked structs (#5603). [Geza Lore]
|
||||
* Fix array of struct member overwrites on member update (#5605) (#5618) (#5628). [sumpster]
|
||||
* Fix interface and struct pattern collision (#5639) (#5640). [Todd Strader]
|
||||
* Fix mis-aliasing of instances with mailbox parameter types (#5632 partial).
|
||||
* Fix error on duplicated declaration of gen block (#5663). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix wildcard equality and inside operators for non-fourstate expressions (#5673). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix `randomize..with` of parameterized classes (#5676). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix interface bracketed array parameter access (#5677) (#5678). [Todd Strader]
|
||||
* Fix width extension of operands of `inside` operator (#5685). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix VPI + SYMRSVDWORD intersection (#5686). [Todd Strader]
|
||||
* Fix verilator_gantt for hierarchically Verilated models (#5700). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
|
||||
|
||||
Verilator 5.030 2024-10-27
|
||||
==========================
|
||||
|
||||
**Major:**
|
||||
|
||||
* Add `-output-groups` to build with concatenated .cpp files (#5257). [Mariusz Glebocki]
|
||||
* Self-tests have been converted to Python, run `{test_name}.py` instead of `{test_name}.pl`.
|
||||
|
||||
**Minor:**
|
||||
|
||||
* Change .vlt config files to be read before .v files (#5185). [David Moberg]
|
||||
* Change to use maximum for cover point aggregation (#5402). [Andrew Nolte]
|
||||
* Change `--main` and `--binary` to use a TOP hierarchy name of "" (#5482).
|
||||
* Change install of public executables into bindir instead of pkgdatadir (#5140) (#5544). [Geza Lore]
|
||||
* Support IEEE-compliant intra-assign delays (#3711) (#5441). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Support `wor`, `trior`, `wand`, `triand` (#5386) (#5496). [Zhou Shen]
|
||||
* Support unconstrained randomization for unions (#5395) (#5396). [Yilou Wang]
|
||||
* Support basic constrained queue randomization (#5413). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Support packed/unpacked and dynamic array unconstrained randomization (#5414) (#5415). [Yilou Wang]
|
||||
* Support appending to queue via `[]` (#5421). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Support named event locals (#5422). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Support basic `dist` constraints (#5431). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Support unpacked array constrained randomization (#5437) (#5489). [Yilou Wang]
|
||||
* Support inside array constraints (#5448). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Support DPI imports and exports with double underscores (#5481).
|
||||
* Support ccache when compiling Verilated files with cmake.
|
||||
* Support `local` and `protected` on `typedef` (#5460).
|
||||
* Support unconstrained randomization for associative array and queue (#5515). [Yilou Wang]
|
||||
* Support `rand` dynamic arrays of objects (#5557) (#5564). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Add error on misused genvar (#408). [Alex Solomatnikov]
|
||||
* Add error on instances without parenthesis.
|
||||
* Add Docker pre-commit hook (#5238) (#5452). [Chris Bachhuber]
|
||||
* Add partial coverage symbol and branch data in lcov info files (#5388). [Andrew Nolte]
|
||||
* Add method to check if there are VPI callbacks of the given type (#5399). [Kaleb Barrett]
|
||||
* Remove warning on unsized numbers exceeding 32-bits.
|
||||
* Improve Verilation thread pool (#5161). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Improve performance of V3VariableOrder with parallelism (#5406). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Improve parser error handling (#5493). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Improve process trigger performance (#5483). [Geza Lore]
|
||||
* Fix suppression of WIDTH* warnings when immediately under a size cast (#3417).
|
||||
* Fix `$fatal` to not be affected by `+verilator+error+limit` (#5135). [Gökçe Aydos]
|
||||
* Fix equivalence checking when replacing type parameters (#5213) (#5255). [Han Qi]
|
||||
* Fix display with multiple string formats (#5311). [Luiza de Melo]
|
||||
* Fix performance of V3Trace when many activity blocks (#5372). [Deniz Güzel]
|
||||
* Fix REALCVT warning on integral timescale conversions (#5378). [Liam Braun]
|
||||
* Fix multidimensional function return value selects (#5382). [Gökçe Aydos]
|
||||
* Fix internal error in out-of-range select (#5393) (#5443). [Geza Lore]
|
||||
* Fix dot fallback finding wrong symbols (#5394). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Fix infinite recursion due to recursive functions/tasks (#5398). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix V3Randomize compile error on old GCC (#5403) (#5417). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix extra events in traces (#5405).
|
||||
* Fix empty `foreach` in `if` in constraints (#5408). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix queue `[$-i]` select as reference argument (#5411). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix `pre`/`post_randomize` on `randomize() with` (#5412). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix capturing params in `randomize() with` (#5416) (#5418). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix `sformatf` internal error on initial automatics (#5423). [Todd Strader]
|
||||
* Fix clearing trigger of events with no sensitivity trees (#5426). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Fix driving clocking block in reactive region (#5430). [Krzysztof Bieganski, Antmicro Ltd.]
|
||||
* Fix associative array next/prev/first/last mis-propagating constants (#5435). [Ethan Sifferman]
|
||||
* Fix randomize treated as std::randomize in classes (#5436). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Fix `foreach` colliding index names (#5444). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Fix fault on defparam with UNSUPPORTED ignored (#5450). [Luiza de Melo]
|
||||
* Fix class reference with pin that is a class reference (#5454).
|
||||
* Fix not reporting class reference with extra parameters (#5467).
|
||||
* Fix user-type parameter overlap (#5469). [Todd Strader]
|
||||
* Fix tracing when name() is empty (#5470). [Sam Shahrestani]
|
||||
* Fix timing mode not exiting on empty events (#5472).
|
||||
* Fix coverage counts missing due to table optimization (#5473) (#5474). [Vito Gamberini]
|
||||
* Fix `--binary` with .cpp PLI filenames under relative directory paths.
|
||||
* Fix extra dot in coverage point hierarchy when using name()=''.
|
||||
* Fix short-circuiting with associative array access (#5484). [Ethan Sifferman]
|
||||
* Fix short-circuiting on method calls (#5486). [Ethan Sifferman]
|
||||
* Fix exponential concatenate performance (#5488). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Fix V3Table trying to generate 'x' bits in the lookup table. (#5491). [Geza Lore]
|
||||
* Fix randomize with foreach constraints (#5492). [Arkadiusz Kozdra, Antmicro Ltd.]
|
||||
* Fix explicit CMAKE_INSTALL_PREFIX usages (#5500). [Fabian Keßler]
|
||||
* Fix configure inserting absolute paths for Python and Perl (#5504) (#5505). [Nathan Graybeal]
|
||||
* Fix pattern initialization with typedef key (#5512). [Eugene Feinberg]
|
||||
* Fix `-j` option without argument in hierarchical Verilation (#5514). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix `foreach` with 2-D queues and dynamic arrays (#5525) (#5529). [Yilou Wang]
|
||||
* Fix struct array assignment (#5455) (#5537). [Yilou Wang]
|
||||
* Fix copy constructor of classes that use std::process (#5528). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix foreach on associative array (#5530). [Yilou Wang]
|
||||
* Fix multi-range indices assignment (#5534) (#5547). [Yilou Wang]
|
||||
* Fix static function wrappers (#5536). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix assignments of concatenation to queues and dynamic arrays (#5540). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix container reduction methods (#5542). [Krzysztof Boroński]
|
||||
* Fix complex user type problem with `--x-assign` (#5543). [Todd Strader]
|
||||
* Fix long module names crashing string handling (#5546). [Filip Badáň]
|
||||
* Fix array trace splitting (#5549). [Todd Strader]
|
||||
* Fix queue element access (#5551). [Ryszard Rozak, Antmicro Ltd.]
|
||||
* Fix struct literal on pattern assignment (#5552) (#5559). [Todd Strader]
|
||||
* Fix build on gcc when using the Spack wrapper (#5555). [Eric Müller]
|
||||
* Fix enum name method (#5563). [Todd Strader]
|
||||
* Fix `$countbits` in assert with non-tristates (#5566). [Shou-Li Hsu]
|
||||
* Fix missing VlProcess handle in coroutines with splits (#5623) (#5650). [Bartłomiej Chmiel, Antmicro Ltd.]
|
||||
* Fix imported array assignment literals (#5642) (#5648). [Todd Strader]
|
||||
* Fix foreach mixed array (#5655) (#5656). [Yilou Wang]
|
||||
|
||||
|
||||
Verilator 5.028 2024-08-21
|
||||
==========================
|
||||
|
||||
@@ -208,9 +422,10 @@ Verilator 5.024 2024-04-05
|
||||
* Fix preprocessor to respect strings in joins (#5007).
|
||||
* Fix tracing class parameters (#5014).
|
||||
* Fix memory leaks (#5016). [Geza Lore]
|
||||
* Fix $readmem with missing newline (#5019). [Josse Van Delm]
|
||||
* Fix `$readmem` with missing newline (#5019). [Josse Van Delm]
|
||||
* Fix internal error on missing pattern key (#5023).
|
||||
* Fix tracing replicated hierarchical models (#5027).
|
||||
* Fix false LIFETIME warning on `repeat` in `fork-join` (#5456).
|
||||
|
||||
|
||||
Verilator 5.022 2024-02-24
|
||||
@@ -549,7 +764,7 @@ Verilator 5.012 2023-06-13
|
||||
* Fix wide structure VL_TOSTRING_W generation (#4188) (#4189). [Aylon Chaim Porat]
|
||||
* Fix references to members of parameterized base classes (#4196). [Ryszard Rozak, Antmicro Ltd]
|
||||
* Fix tracing undefined alignment (#4201) (#4288) [John Wehle]
|
||||
* Fix class specific same methods for AstVarScope, AstVar, and AstScope (#4203) (#4250). [John Wehle]
|
||||
* Fix class-specific same methods for AstVarScope, AstVar, and AstScope (#4203) (#4250). [John Wehle]
|
||||
* Fix dotted references in parameterized classes (#4206). [Ryszard Rozak, Antmicro Ltd]
|
||||
* Fix bit selections under parameterized classes (#4210). [Ryszard Rozak, Antmicro Ltd]
|
||||
* Fix duplicate std:: declaration with -I (#4215). [Harald Pretl]
|
||||
@@ -4774,7 +4989,7 @@ Verilator 0.0 1994-07-08
|
||||
Copyright
|
||||
=========
|
||||
|
||||
Copyright 2001-2024 by Wilson Snyder. This program is free software; you
|
||||
Copyright 2001-2025 by Wilson Snyder. This program is free software; you
|
||||
can redistribute it and/or modify it under the terms of either the GNU
|
||||
Lesser General Public License Version 3 or the Perl Artistic License
|
||||
Version 2.0.
|
||||
|
||||
+97
-39
@@ -7,7 +7,7 @@
|
||||
#
|
||||
#*****************************************************************************
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
@@ -52,6 +52,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
MAKEINFO = makeinfo
|
||||
POD2TEXT = pod2text
|
||||
PYTHON3 = @PYTHON3@
|
||||
MKINSTALLDIRS = $(SHELL) $(srcdir)/src/mkinstalldirs
|
||||
|
||||
# Version (for docs/guide/conf.py)
|
||||
@@ -76,7 +77,7 @@ datadir = @datadir@
|
||||
# Directory in which to install documentation info files.
|
||||
infodir = @infodir@
|
||||
|
||||
# Directory in which to install package specific files
|
||||
# Directory in which to install package-specific files
|
||||
# Generally ${prefix}/share/verilator
|
||||
pkgdatadir = @pkgdatadir@
|
||||
|
||||
@@ -96,6 +97,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@
|
||||
|
||||
#### End of system configuration section. ####
|
||||
######################################################################
|
||||
# Main build targets
|
||||
|
||||
.SUFFIXES:
|
||||
|
||||
@@ -146,6 +148,9 @@ verilator_exe verilator_bin$(EXEEXT) verilator_bin_dbg$(EXEEXT) verilator_covera
|
||||
@echo "making verilator in src"
|
||||
$(MAKE) -C src $(OBJCACHE_JOBS)
|
||||
|
||||
######################################################################
|
||||
# Tests
|
||||
|
||||
.PHONY:msg_test
|
||||
msg_test: all_nomsg
|
||||
@echo "Build complete!"
|
||||
@@ -156,7 +161,7 @@ msg_test: all_nomsg
|
||||
.PHONY: test
|
||||
ifeq ($(CFG_WITH_LONGTESTS),yes) # Local... Else don't burden users
|
||||
test: smoke-test test_regress
|
||||
# examples is part of test_regress's test_regress/t/t_a2_examples.pl
|
||||
# examples is part of test_regress's test_regress/t/t_a2_examples.py
|
||||
# (because that allows it to run in parallel with other test_regress's)
|
||||
else
|
||||
test: smoke-test examples
|
||||
@@ -168,8 +173,8 @@ endif
|
||||
@echo
|
||||
|
||||
smoke-test: all_nomsg
|
||||
test_regress/t/t_a1_first_cc.pl
|
||||
test_regress/t/t_a2_first_sc.pl
|
||||
test_regress/t/t_a1_first_cc.py
|
||||
test_regress/t/t_a2_first_sc.py
|
||||
|
||||
test_regress: all_nomsg
|
||||
$(MAKE) -C test_regress
|
||||
@@ -183,8 +188,11 @@ examples: all_nomsg
|
||||
$(MAKE) -C $$p VERILATOR_ROOT=`pwd` || exit 10; \
|
||||
done
|
||||
|
||||
######################################################################
|
||||
# Docs
|
||||
|
||||
.PHONY: docs
|
||||
docs: info
|
||||
docs: info $(VL_INST_MAN_FILES)
|
||||
|
||||
info: $(INFOS)
|
||||
|
||||
@@ -193,7 +201,8 @@ verilator.1: ${srcdir}/bin/verilator
|
||||
verilator_coverage.1: ${srcdir}/bin/verilator_coverage
|
||||
pod2man $< $@
|
||||
%.1: ${srcdir}/bin/%
|
||||
help2man --no-info --no-discard-stderr --version-string=- $< -o $@
|
||||
help2man --no-info --no-discard-stderr --version-string=- \
|
||||
-n "$(shell $< --help | head -n 3 | tail -n 1)" $< -o $@
|
||||
|
||||
.PHONY: verilator.html
|
||||
verilator.html:
|
||||
@@ -204,6 +213,20 @@ verilator.html:
|
||||
verilator.pdf: Makefile
|
||||
$(MAKE) -C docs verilator.pdf
|
||||
|
||||
TAGFILES=${srcdir}/*/*.cpp ${srcdir}/*/*.h ${srcdir}/*/*.in \
|
||||
${srcdir}/*.in ${srcdir}/*.pod
|
||||
|
||||
TAGS: $(TAGFILES)
|
||||
etags $(TAGFILES)
|
||||
|
||||
.PHONY: doxygen
|
||||
|
||||
doxygen:
|
||||
$(MAKE) -C docs doxygen
|
||||
|
||||
######################################################################
|
||||
# Install
|
||||
|
||||
# Public executables intended to be invoked directly by the user
|
||||
# Don't put wildcards in these variables, it might cause an uninstall of other stuff
|
||||
VL_INST_PUBLIC_SCRIPT_FILES = verilator \
|
||||
@@ -227,6 +250,7 @@ VL_INST_INC_BLDDIR_FILES = \
|
||||
# Files under srcdir, instead of build time
|
||||
VL_INST_INC_SRCDIR_FILES = \
|
||||
include/*.[chv]* \
|
||||
include/*.vlt \
|
||||
include/*.sv \
|
||||
include/gtkwave/*.[chv]* \
|
||||
include/vltstd/*.[chv]* \
|
||||
@@ -244,11 +268,15 @@ mkbindirs:
|
||||
installbin: | mkbindirs
|
||||
cd $(srcdir)/bin; \
|
||||
for p in $(VL_INST_PUBLIC_SCRIPT_FILES) ; do \
|
||||
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkgdatadir)/bin/$$p; \
|
||||
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/$$p; \
|
||||
done
|
||||
perl -p -i -e 'use File::Spec;' \
|
||||
-e' $$path = File::Spec->abs2rel("$(realpath $(DESTDIR)$(pkgdatadir))", "$(realpath $(DESTDIR)$(bindir))");' \
|
||||
-e 's/my \$$verilator_pkgdatadir_relpath = .*/my \$$verilator_pkgdatadir_relpath = "$$path";/g' \
|
||||
-- "$(DESTDIR)/$(bindir)/verilator"
|
||||
cd bin; \
|
||||
for p in $(VL_INST_PUBLIC_BIN_FILES) ; do \
|
||||
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkgdatadir)/bin/$$p; \
|
||||
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/$$p; \
|
||||
done
|
||||
cd $(srcdir)/bin; \
|
||||
for p in $(VL_INST_PRIVATE_SCRIPT_FILES) ; do \
|
||||
@@ -258,11 +286,11 @@ installbin: | mkbindirs
|
||||
installredirect: installbin | mkbindirs
|
||||
cp ${srcdir}/bin/redirect ${srcdir}/bin/redirect.tmp
|
||||
perl -p -i -e 'use File::Spec;' \
|
||||
-e' $$path = File::Spec->abs2rel("$(realpath $(DESTDIR)$(pkgdatadir)/bin)", "$(realpath $(DESTDIR)$(bindir))");' \
|
||||
-e' $$path = File::Spec->abs2rel("$(realpath $(DESTDIR)$(bindir))", "$(realpath $(DESTDIR)$(pkgdatadir)/bin)");' \
|
||||
-e 's/RELPATH.*/"$$path";/g' -- "${srcdir}/bin/redirect.tmp"
|
||||
cd $(srcdir)/bin; \
|
||||
for p in $(VL_INST_PUBLIC_SCRIPT_FILES) $(VL_INST_PUBLIC_BIN_FILES) ; do \
|
||||
$(INSTALL_PROGRAM) redirect.tmp $(DESTDIR)$(bindir)/$$p; \
|
||||
$(INSTALL_PROGRAM) redirect.tmp $(DESTDIR)$(pkgdatadir)/bin/$$p; \
|
||||
done
|
||||
rm ${srcdir}/bin/redirect.tmp
|
||||
|
||||
@@ -344,6 +372,19 @@ install-all: installbin installredirect installman installdata install-msg
|
||||
|
||||
install-here: installman info
|
||||
|
||||
install-msg:
|
||||
@echo
|
||||
@echo "Installed binaries to $(DESTDIR)$(bindir)/verilator"
|
||||
@echo "Installed man to $(DESTDIR)$(mandir)/man1"
|
||||
@echo "Installed examples to $(DESTDIR)$(pkgdatadir)/examples"
|
||||
@echo
|
||||
@echo "For documentation see 'man verilator' or 'verilator --help'"
|
||||
@echo "For forums and to report bugs see https://verilator.org"
|
||||
@echo
|
||||
|
||||
######################################################################
|
||||
# Format/Lint
|
||||
|
||||
# Use --xml flag to see the cppcheck code to use for suppression
|
||||
CPPCHECK1_CPP = $(wildcard $(srcdir)/include/*.cpp)
|
||||
CPPCHECK2_CPP = $(wildcard $(srcdir)/examples/*/*.cpp)
|
||||
@@ -411,17 +452,32 @@ analyzer-include:
|
||||
-rm -rf examples/*/obj*
|
||||
scan-build $(MAKE) -k examples
|
||||
|
||||
format: clang-format yapf format-pl-exec
|
||||
format:
|
||||
$(MAKE) -j 4 format-c format-py format-exec
|
||||
|
||||
CLANGFORMAT = clang-format-14
|
||||
CLANGFORMAT_FLAGS = -i
|
||||
CLANGFORMAT_FILES = $(CHECK_CPP) $(CHECK_H) $(CHECK_YL) test_regress/t/*.c* test_regress/t/*.h
|
||||
|
||||
clang-format:
|
||||
format-c clang-format:
|
||||
@$(CLANGFORMAT) --version | egrep 14.0 > /dev/null \
|
||||
|| echo "*** You are not using clang-format-14, indents may differ from master's ***"
|
||||
$(CLANGFORMAT) $(CLANGFORMAT_FLAGS) $(CLANGFORMAT_FILES)
|
||||
|
||||
YAMLFIX = YAMLFIX_WHITELINES=1 YAMLFIX_LINE_LENGTH=130 YAMLFIX_preserve_quotes=true yamlfix
|
||||
|
||||
yamlfix:
|
||||
$(YAMLFIX) .
|
||||
|
||||
# CMake files
|
||||
CMAKE_FILES = \
|
||||
CMakeLists.txt \
|
||||
examples/*/CMakeLists.txt \
|
||||
src/CMakeLists.txt \
|
||||
test_regress/CMakeLists.txt \
|
||||
*.cmake.in \
|
||||
|
||||
# Python programs, subject to format and lint
|
||||
PY_PROGRAMS = \
|
||||
bin/verilator_ccache_report \
|
||||
bin/verilator_difftree \
|
||||
@@ -440,6 +496,7 @@ PY_PROGRAMS = \
|
||||
src/flexfix \
|
||||
src/vlcovgen \
|
||||
src/.gdbinit.py \
|
||||
test_regress/*.py \
|
||||
test_regress/t/*.pf \
|
||||
nodist/clang_check_attributes \
|
||||
nodist/code_coverage \
|
||||
@@ -449,44 +506,53 @@ PY_PROGRAMS = \
|
||||
nodist/install_test \
|
||||
nodist/log_changes \
|
||||
|
||||
# Python files, subject to format but not lint
|
||||
PY_FILES = \
|
||||
$(PY_PROGRAMS) \
|
||||
nodist/code_coverage.dat \
|
||||
test_regress/t/*.py \
|
||||
|
||||
# Python files, test_regress tests
|
||||
PY_TEST_FILES = \
|
||||
test_regress/t/*.py \
|
||||
|
||||
YAPF = yapf3
|
||||
YAPF_FLAGS = -i
|
||||
YAPF_FLAGS = -i --parallel
|
||||
|
||||
yapf:
|
||||
format-py yapf:
|
||||
$(YAPF) $(YAPF_FLAGS) $(PY_FILES)
|
||||
|
||||
GERSEMI = gersemi
|
||||
GERSEMI_FLAGS = -i
|
||||
|
||||
format-cmake:
|
||||
$(GERSEMI) $(GERSEMI_FLAGS) $(CMAKE_FILES)
|
||||
|
||||
PYLINT = pylint
|
||||
PYLINT_FLAGS = --score=n --disable=R0801
|
||||
PYLINT_FLAGS = --recursive=n --score=n --disable=R0801
|
||||
PYLINT_TEST_FLAGS = $(PYLINT_FLAGS) --disable=C0103,C0114,C0116,C0209,C0411,C0413,C0301,R0801,R0912,R0915,R0916,R1702,W0511,W0621
|
||||
|
||||
RUFF = ruff
|
||||
RUFF_FLAGS = check --ignore=E402,E501,E701
|
||||
|
||||
# "make -k" so can see all tool result errors
|
||||
lint-py:
|
||||
$(MAKE) -k lint-py-pylint lint-py-ruff
|
||||
$(MAKE) -k lint-py-pylint lint-py-pylint-tests lint-py-ruff
|
||||
|
||||
lint-py-pylint:
|
||||
$(PYLINT) $(PYLINT_FLAGS) $(PY_PROGRAMS)
|
||||
|
||||
lint-py-pylint-tests:
|
||||
$(PYLINT) $(PYLINT_TEST_FLAGS) $(PY_TEST_FILES) | $(PYTHON3) nodist/lint_py_test_filter
|
||||
|
||||
lint-py-ruff:
|
||||
$(RUFF) $(RUFF_FLAGS) $(PY_PROGRAMS)
|
||||
|
||||
format-pl-exec:
|
||||
-chmod a+x test_regress/t/*.pl
|
||||
format-exec:
|
||||
-chmod a+x test_regress/t/*.py
|
||||
|
||||
install-msg:
|
||||
@echo
|
||||
@echo "Installed binaries to $(DESTDIR)$(bindir)/verilator"
|
||||
@echo "Installed man to $(DESTDIR)$(mandir)/man1"
|
||||
@echo "Installed examples to $(DESTDIR)$(pkgdatadir)/examples"
|
||||
@echo
|
||||
@echo "For documentation see 'man verilator' or 'verilator --help'"
|
||||
@echo "For forums and to report bugs see https://verilator.org"
|
||||
@echo
|
||||
######################################################################
|
||||
# Configure
|
||||
|
||||
IN_WILD := ${srcdir}/*.in ${srcdir}/*/*.in
|
||||
|
||||
@@ -507,6 +573,9 @@ else
|
||||
autoconf
|
||||
endif
|
||||
|
||||
######################################################################
|
||||
# Clean
|
||||
|
||||
maintainer-clean::
|
||||
@echo "This command is intended for maintainers to use;"
|
||||
@echo "rebuilding the deleted files requires autoconf."
|
||||
@@ -537,17 +606,6 @@ distclean maintainer-clean::
|
||||
rm -f bin/verilator_bin* bin/verilator_coverage_bin*
|
||||
rm -f include/verilated.mk include/verilated_config.h
|
||||
|
||||
TAGFILES=${srcdir}/*/*.cpp ${srcdir}/*/*.h ${srcdir}/*/*.in \
|
||||
${srcdir}/*.in ${srcdir}/*.pod
|
||||
|
||||
TAGS: $(TAGFILES)
|
||||
etags $(TAGFILES)
|
||||
|
||||
.PHONY: doxygen
|
||||
|
||||
doxygen:
|
||||
$(MAKE) -C docs doxygen
|
||||
|
||||
######################################################################
|
||||
# Distributions
|
||||
|
||||
|
||||
+3
-5
@@ -1,7 +1,7 @@
|
||||
.. Github doesn't render images unless absolute URL
|
||||
.. Do not know of a conditional tag, "only: github" nor "github display" works
|
||||
|
||||
|badge1| |badge2| |badge3| |badge4| |badge5| |badge6| |badge7| |badge8|
|
||||
|badge1| |badge2| |badge3| |badge4| |badge5| |badge6| |badge7|
|
||||
|
||||
.. |badge1| image:: https://img.shields.io/badge/Website-Verilator.org-181717.svg
|
||||
:target: https://verilator.org
|
||||
@@ -15,9 +15,7 @@
|
||||
:target: https://hub.docker.com/r/verilator/verilator
|
||||
.. |badge6| image:: https://api.codacy.com/project/badge/Grade/fa78caa433c84a4ab9049c43e9debc6f
|
||||
:target: https://www.codacy.com/gh/verilator/verilator
|
||||
.. |badge7| image:: https://codecov.io/gh/verilator/verilator/branch/master/graph/badge.svg
|
||||
:target: https://codecov.io/gh/verilator/verilator
|
||||
.. |badge8| image:: https://github.com/verilator/verilator/workflows/build/badge.svg
|
||||
.. |badge7| image:: https://github.com/verilator/verilator/workflows/build/badge.svg
|
||||
:target: https://github.com/verilator/verilator/actions?query=workflow%3Abuild
|
||||
|
||||
|
||||
@@ -143,7 +141,7 @@ Related Projects
|
||||
Open License
|
||||
============
|
||||
|
||||
Verilator is Copyright 2003-2024 by Wilson Snyder. (Report bugs to
|
||||
Verilator is Copyright 2003-2025 by Wilson Snyder. (Report bugs to
|
||||
`Verilator Issues <https://verilator.org/issues>`_.)
|
||||
|
||||
Verilator is free software; you can redistribute it and/or modify it under
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env perl
|
||||
######################################################################
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
|
||||
+24
-14
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env perl
|
||||
######################################################################
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
@@ -69,7 +69,9 @@ if (! GetOptions(
|
||||
pod2usage(-exitstatus => 2, -verbose => 0);
|
||||
}
|
||||
|
||||
my $verilator_root = realpath("$RealBin/..");
|
||||
# WARNING: $verilator_pkgdatadir_relpath is substituted during Verilator 'make install'
|
||||
my $verilator_pkgdatadir_relpath = "..";
|
||||
my $verilator_root = realpath("$RealBin/$verilator_pkgdatadir_relpath");
|
||||
if (defined $ENV{VERILATOR_ROOT}) {
|
||||
if ((!-d $ENV{VERILATOR_ROOT}) || $verilator_root ne realpath($ENV{VERILATOR_ROOT})) {
|
||||
warn "%Error: verilator: VERILATOR_ROOT is set to inconsistent path. Suggest leaving it unset.\n";
|
||||
@@ -267,8 +269,7 @@ __END__
|
||||
|
||||
=head1 NAME
|
||||
|
||||
Verilator - Translate and simulate SystemVerilog code using C++/SystemC
|
||||
|
||||
Verilator - Lint, compile and simulate SystemVerilog code using C++/SystemC
|
||||
|
||||
=head1 SYNOPSIS
|
||||
|
||||
@@ -327,6 +328,8 @@ detailed descriptions of these arguments.
|
||||
--compiler-include Include additional header in the precompiled one
|
||||
--converge-limit <loops> Tune convergence settle time
|
||||
--coverage Enable all coverage
|
||||
--coverage-expr Enable expression coverage
|
||||
--coverage-expr-max <value> Maximum permutations allowed for an expression
|
||||
--coverage-line Enable line coverage
|
||||
--coverage-max-width <width> Maximum array depth for coverage
|
||||
--coverage-toggle Enable toggle coverage
|
||||
@@ -373,8 +376,8 @@ detailed descriptions of these arguments.
|
||||
--gdb Run Verilator under GDB interactively
|
||||
--gdbbt Run Verilator under GDB for backtrace
|
||||
--generate-key Create random key for --protect-key
|
||||
--getenv <var> Get environment variable with defaults
|
||||
--get-supported <feature> Get if feature is supported
|
||||
--getenv <var> Get environment variable with defaults
|
||||
--help Show this help
|
||||
--hierarchical Enable hierarchical Verilation
|
||||
--hierarchical-params-file <name> Internal option that specifies parameters file for hier blocks
|
||||
@@ -384,6 +387,11 @@ detailed descriptions of these arguments.
|
||||
--inline-mult <value> Tune module inlining
|
||||
--instr-count-dpi <value> Assumed dynamic instruction count of DPI imports
|
||||
-j <jobs> Parallelism for --build-jobs/--verilate-jobs
|
||||
--no-json-edit-nums Don't dump editNum in .tree.json files
|
||||
--no-json-ids Don't use short identifiers instead of adresses/paths in .tree.json
|
||||
--json-only Create JSON parser output (.tree.json and .meta.json)
|
||||
--json-only-output .tree.json output filename
|
||||
--json-only-meta-output .tree.meta.json output filename
|
||||
--l2-name <value> Verilog scope name of the top module
|
||||
--language <lang> Default language standard to parse
|
||||
-LDFLAGS <flags> Linker pre-object arguments for makefile
|
||||
@@ -405,6 +413,7 @@ detailed descriptions of these arguments.
|
||||
-O3 High-performance optimizations
|
||||
-O<optimization-letter> Selectable optimizations
|
||||
-o <executable> Name of final executable
|
||||
--output-groups <numfiles> Group .cpp files into larger ones
|
||||
--output-split <statements> Split .cpp files into pieces
|
||||
--output-split-cfuncs <statements> Split model functions
|
||||
--output-split-ctrace <statements> Split tracing functions
|
||||
@@ -419,6 +428,8 @@ detailed descriptions of these arguments.
|
||||
--pipe-filter <command> Filter all input through a script
|
||||
--pp-comments Show preprocessor comments with -E
|
||||
--prefix <topname> Name of top-level class
|
||||
--preproc-resolve Include all found modules in the output with -E
|
||||
--preproc-token-limit Maximum tokens on a line allowed by preprocessor
|
||||
--private Debugging; see docs
|
||||
--prof-c Compile C++ code with profiling
|
||||
--prof-cfuncs Name functions for profiling
|
||||
@@ -429,8 +440,9 @@ detailed descriptions of these arguments.
|
||||
--protect-lib <name> Create a DPI protected library
|
||||
--public Mark signals as public; see docs
|
||||
--public-depth <level> Mark public to specified module depth
|
||||
--public-params Mark all parameters as public_flat
|
||||
--public-flat-rw Mark all variables, etc as public_flat_rw
|
||||
--public-ignore Ignore all public comment markings
|
||||
--public-params Mark all parameters as public_flat
|
||||
-pvalue+<name>=<value> Overwrite toplevel parameter
|
||||
--quiet Minimize additional printing
|
||||
--quiet-exit Don't print the command on failure
|
||||
@@ -445,7 +457,9 @@ detailed descriptions of these arguments.
|
||||
--no-skip-identical Disable skipping identical output
|
||||
--stats Create statistics file
|
||||
--stats-vars Provide statistics on variables
|
||||
--no-std Prevent parsing standard library
|
||||
--no-std Prevent loading standard files
|
||||
--no-std-package Prevent parsing standard package
|
||||
--no-std-waiver Prevent parsing standard lint waivers
|
||||
--no-stop-fail Do not call $stop when assertion fails
|
||||
--structs-packed Convert all unpacked structures to packed structures
|
||||
-sv Enable SystemVerilog parsing
|
||||
@@ -484,7 +498,8 @@ detailed descriptions of these arguments.
|
||||
+verilog2001ext+<ext> Synonym for +1364-2001ext+<ext>
|
||||
--version Show program version and exits
|
||||
--vpi Enable VPI compiles
|
||||
--waiver-output <filename> Create a waiver file based on the linter warnings
|
||||
--waiver-multiline Create multiline --match for waivers
|
||||
--waiver-output <filename> Create a waiver file based on linter warnings
|
||||
-Wall Enable all style warnings
|
||||
-Werror-<message> Convert warnings to errors
|
||||
-Wfuture-<message> Disable unknown message warnings
|
||||
@@ -500,11 +515,6 @@ detailed descriptions of these arguments.
|
||||
--x-assign <mode> Assign non-initial Xs to this value
|
||||
--x-initial <mode> Assign initial Xs to this value
|
||||
--x-initial-edge Enable initial X->0 and X->1 edge triggers
|
||||
--no-json-edit-nums Don't dump editNum in .tree.json files
|
||||
--no-json-ids Don't use short identifiers instead of adresses/paths in .tree.json
|
||||
--json-only Create JSON parser output (.tree.json and .meta.json)
|
||||
--json-only-output .tree.json output filename
|
||||
--json-only-meta-output .tree.meta.json output filename
|
||||
--xml-only Create XML parser output
|
||||
--xml-output XML output filename
|
||||
-y <dir> Directory to search for modules
|
||||
@@ -537,7 +547,7 @@ description of these arguments.
|
||||
|
||||
The latest version is available from L<https://verilator.org>.
|
||||
|
||||
Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||
Copyright 2003-2025 by Wilson Snyder. This program is free software; you can
|
||||
redistribute it and/or modify the Verilator internals under the terms of
|
||||
either the GNU Lesser General Public License Version 3 or the Perl Artistic
|
||||
License Version 2.0.
|
||||
|
||||
@@ -16,8 +16,7 @@ parser = argparse.ArgumentParser(
|
||||
|
||||
For documentation see
|
||||
https://verilator.org/guide/latest/exe_verilator_ccache_report.html""",
|
||||
epilog=
|
||||
"""Copyright 2002-2024 by Wilson Snyder. This program is free software; you
|
||||
epilog="""Copyright 2002-2025 by Wilson Snyder. This program is free software; you
|
||||
can redistribute it and/or modify it under the terms of either the GNU
|
||||
Lesser General Public License Version 3 or the Perl Artistic License
|
||||
Version 2.0.
|
||||
@@ -67,30 +66,23 @@ else:
|
||||
wnames = max(len(_) for _ in results) + 1
|
||||
wresults = max(len(_) for _ in results.values()) + 1
|
||||
for k in sorted(results.keys()):
|
||||
args.o.write("{:{wnames}} : {:{wresults}} : {}s\n".format(
|
||||
k,
|
||||
results[k],
|
||||
elapsed[k].total_seconds(),
|
||||
wnames=wnames,
|
||||
wresults=wresults))
|
||||
args.o.write("{:{wnames}} : {:{wresults}} : {}s\n".format(k,
|
||||
results[k],
|
||||
elapsed[k].total_seconds(),
|
||||
wnames=wnames,
|
||||
wresults=wresults))
|
||||
|
||||
args.o.write("\nSummary:\n")
|
||||
counts = collections.Counter(_ for _ in results.values())
|
||||
total = sum(counts.values())
|
||||
for k in sorted(counts.keys()):
|
||||
c = counts[k]
|
||||
args.o.write("{:{width}}| {} ({:.2%})\n".format(k,
|
||||
c,
|
||||
c / total,
|
||||
width=wresults))
|
||||
args.o.write("{:{width}}| {} ({:.2%})\n".format(k, c, c / total, width=wresults))
|
||||
|
||||
args.o.write("\nLongest:\n")
|
||||
longest = sorted(list(elapsed.items()),
|
||||
key=lambda kv: -kv[1].total_seconds())
|
||||
longest = sorted(list(elapsed.items()), key=lambda kv: -kv[1].total_seconds())
|
||||
for i, (k, v) in enumerate(longest):
|
||||
args.o.write("{:{width}}| {}s\n".format(k,
|
||||
v.total_seconds(),
|
||||
width=wnames))
|
||||
args.o.write("{:{width}}| {}s\n".format(k, v.total_seconds(), width=wnames))
|
||||
if i > 4:
|
||||
break
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env perl
|
||||
######################################################################
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
@@ -188,7 +188,7 @@ L<https://verilator.org/guide/latest/exe_verilator_coverage.html>.
|
||||
|
||||
The latest version is available from L<https://verilator.org>.
|
||||
|
||||
Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
can redistribute it and/or modify the Verilator internals under the terms
|
||||
of either the GNU Lesser General Public License Version 3 or the Perl
|
||||
Artistic License Version 2.0.
|
||||
|
||||
@@ -47,8 +47,7 @@ def diff_dir(a, b):
|
||||
diff_file(a, b)
|
||||
anyfile = True
|
||||
if not anyfile:
|
||||
sys.stderr.write(
|
||||
"%Warning: No .tree files found that have similar base names\n")
|
||||
sys.stderr.write("%Warning: No .tree files found that have similar base names\n")
|
||||
|
||||
|
||||
def diff_file(a, b):
|
||||
@@ -109,18 +108,14 @@ parser = argparse.ArgumentParser(
|
||||
Verilator_difftree is used for debugging Verilator tree output files.
|
||||
It performs a diff between two files, or all files common between two
|
||||
directories, ignoring irrelevant pointer differences.""",
|
||||
epilog=
|
||||
"""Copyright 2005-2024 by Wilson Snyder. This program is free software; you
|
||||
epilog="""Copyright 2005-2025 by Wilson Snyder. This program is free software; you
|
||||
can redistribute it and/or modify it under the terms of either the GNU
|
||||
Lesser General Public License Version 3 or the Perl Artistic License
|
||||
Version 2.0.
|
||||
|
||||
SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0""")
|
||||
|
||||
parser.add_argument('--debug',
|
||||
action='store_const',
|
||||
const=9,
|
||||
help='enable debug')
|
||||
parser.add_argument('--debug', action='store_const', const=9, help='enable debug')
|
||||
parser.add_argument('--no-lineno',
|
||||
action='store_false',
|
||||
help='do not show differences in line numbering')
|
||||
|
||||
+47
-68
@@ -15,11 +15,7 @@ LongestVcdStrValueLength = 0
|
||||
Threads = collections.defaultdict(lambda: []) # List of records per thread id
|
||||
Mtasks = collections.defaultdict(lambda: {'elapsed': 0, 'end': 0})
|
||||
Cpus = collections.defaultdict(lambda: {'mtask_time': 0})
|
||||
Global = {
|
||||
'args': {},
|
||||
'cpuinfo': collections.defaultdict(lambda: {}),
|
||||
'stats': {}
|
||||
}
|
||||
Global = {'args': {}, 'cpuinfo': collections.defaultdict(lambda: {}), 'stats': {}}
|
||||
ElapsedTime = None # total elapsed time
|
||||
ExecGraphTime = 0 # total elapsed time excuting an exec graph
|
||||
ExecGraphIntervals = [] # list of (start, end) pairs
|
||||
@@ -31,8 +27,7 @@ def read_data(filename):
|
||||
with open(filename, "r", encoding="utf8") as fh:
|
||||
re_thread = re.compile(r'^VLPROFTHREAD (\d+)$')
|
||||
re_record = re.compile(r'^VLPROFEXEC (\S+) (\d+)(.*)$')
|
||||
re_payload_mtaskBegin = re.compile(
|
||||
r'id (\d+) predictStart (\d+) cpu (\d+)')
|
||||
re_payload_mtaskBegin = re.compile(r'id (\d+) predictStart (\d+) cpu (\d+)')
|
||||
re_payload_mtaskEnd = re.compile(r'id (\d+) predictCost (\d+)')
|
||||
|
||||
re_arg1 = re.compile(r'VLPROF arg\s+(\S+)\+([0-9.]*)\s*')
|
||||
@@ -41,7 +36,7 @@ def read_data(filename):
|
||||
re_proc_cpu = re.compile(r'VLPROFPROC processor\s*:\s*(\d+)\s*$')
|
||||
re_proc_dat = re.compile(r'VLPROFPROC ([a-z_ ]+)\s*:\s*(.*)$')
|
||||
cpu = None
|
||||
thread = None
|
||||
thread = 0
|
||||
execGraphStart = None
|
||||
|
||||
global LongestVcdStrValueLength
|
||||
@@ -57,24 +52,21 @@ def read_data(filename):
|
||||
tick = int(tick)
|
||||
payload = payload.strip()
|
||||
if kind == "SECTION_PUSH":
|
||||
LongestVcdStrValueLength = max(LongestVcdStrValueLength,
|
||||
len(payload))
|
||||
LongestVcdStrValueLength = max(LongestVcdStrValueLength, len(payload))
|
||||
SectionStack.append(payload)
|
||||
Sections.append((tick, tuple(SectionStack)))
|
||||
Sections[thread].append((tick, tuple(SectionStack)))
|
||||
elif kind == "SECTION_POP":
|
||||
assert SectionStack, "SECTION_POP without SECTION_PUSH"
|
||||
SectionStack.pop()
|
||||
Sections.append((tick, tuple(SectionStack)))
|
||||
Sections[thread].append((tick, tuple(SectionStack)))
|
||||
elif kind == "MTASK_BEGIN":
|
||||
mtask, predict_start, ecpu = re_payload_mtaskBegin.match(
|
||||
payload).groups()
|
||||
mtask, predict_start, ecpu = re_payload_mtaskBegin.match(payload).groups()
|
||||
mtask = int(mtask)
|
||||
predict_start = int(predict_start)
|
||||
ecpu = int(ecpu)
|
||||
mTaskThread[mtask] = thread
|
||||
records = Threads[thread]
|
||||
assert not records or records[-1]['start'] <= records[-1][
|
||||
'end'] <= tick
|
||||
assert not records or records[-1]['start'] <= records[-1]['end'] <= tick
|
||||
records.append({
|
||||
'start': tick,
|
||||
'mtask': mtask,
|
||||
@@ -85,8 +77,7 @@ def read_data(filename):
|
||||
Mtasks[mtask]['thread'] = thread
|
||||
Mtasks[mtask]['predict_start'] = predict_start
|
||||
elif kind == "MTASK_END":
|
||||
mtask, predict_cost = re_payload_mtaskEnd.match(
|
||||
payload).groups()
|
||||
mtask, predict_cost = re_payload_mtaskEnd.match(payload).groups()
|
||||
mtask = int(mtask)
|
||||
predict_cost = int(predict_cost)
|
||||
begin = Mtasks[mtask]['begin']
|
||||
@@ -106,6 +97,7 @@ def read_data(filename):
|
||||
print("-Unknown execution trace record: %s" % line)
|
||||
elif re_thread.match(line):
|
||||
thread = int(re_thread.match(line).group(1))
|
||||
Sections.append([])
|
||||
elif re.match(r'^VLPROF(THREAD|VERSION)', line):
|
||||
pass
|
||||
elif re_arg1.match(line):
|
||||
@@ -163,8 +155,7 @@ def report():
|
||||
|
||||
print("\nSummary:")
|
||||
print(" Total elapsed time = {} rdtsc ticks".format(ElapsedTime))
|
||||
print(" Parallelized code = {:.2%} of elapsed time".format(
|
||||
ExecGraphTime / ElapsedTime))
|
||||
print(" Parallelized code = {:.2%} of elapsed time".format(ExecGraphTime / ElapsedTime))
|
||||
print(" Total threads = %d" % nthreads)
|
||||
print(" Total CPUs used = %d" % ncpus)
|
||||
print(" Total mtasks = %d" % len(Mtasks))
|
||||
@@ -176,15 +167,12 @@ def report():
|
||||
|
||||
if nthreads > ncpus:
|
||||
print()
|
||||
print("%%Warning: There were fewer CPUs (%d) than threads (%d)." %
|
||||
(ncpus, nthreads))
|
||||
print("%%Warning: There were fewer CPUs (%d) than threads (%d)." % (ncpus, nthreads))
|
||||
print(" : See docs on use of numactl.")
|
||||
else:
|
||||
if 'cpu_socket_cores_warning' in Global:
|
||||
print()
|
||||
print(
|
||||
"%Warning: Multiple threads scheduled on same hyperthreaded core."
|
||||
)
|
||||
print("%Warning: Multiple threads scheduled on same hyperthreaded core.")
|
||||
print(" : See docs on use of numactl.")
|
||||
if 'cpu_sockets_warning' in Global:
|
||||
print()
|
||||
@@ -228,8 +216,7 @@ def report_mtasks():
|
||||
serialTime = ElapsedTime - ExecGraphTime
|
||||
|
||||
def subReport(elapsed, work):
|
||||
print(" Thread utilization = {:7.2%}".format(work /
|
||||
(elapsed * nthreads)))
|
||||
print(" Thread utilization = {:7.2%}".format(work / (elapsed * nthreads)))
|
||||
print(" Speedup = {:6.3}x".format(work / elapsed))
|
||||
|
||||
print("\nParallelized code, measured:")
|
||||
@@ -256,8 +243,7 @@ def report_mtasks():
|
||||
if Mtasks[mtask]['elapsed'] > 0:
|
||||
if Mtasks[mtask]['predict_cost'] == 0:
|
||||
Mtasks[mtask]['predict_cost'] = 1 # don't log(0) below
|
||||
p2e_ratio = math.log(Mtasks[mtask]['predict_cost'] /
|
||||
Mtasks[mtask]['elapsed'])
|
||||
p2e_ratio = math.log(Mtasks[mtask]['predict_cost'] / Mtasks[mtask]['elapsed'])
|
||||
p2e_ratios.append(p2e_ratio)
|
||||
|
||||
if p2e_ratio > max_p2e:
|
||||
@@ -269,18 +255,14 @@ def report_mtasks():
|
||||
|
||||
print("\nMTask statistics:")
|
||||
print(" Longest mtask id = {}".format(long_mtask))
|
||||
print(" Longest mtask time = {:.2%} of time elapsed in parallelized code".
|
||||
format(long_mtask_time / ExecGraphTime))
|
||||
print(" Longest mtask time = {:.2%} of time elapsed in parallelized code".format(
|
||||
long_mtask_time / ExecGraphTime))
|
||||
print(" min log(p2e) = %0.3f" % min_p2e, end="")
|
||||
|
||||
print(" from mtask %d (predict %d," %
|
||||
(min_mtask, Mtasks[min_mtask]['predict_cost']),
|
||||
end="")
|
||||
print(" from mtask %d (predict %d," % (min_mtask, Mtasks[min_mtask]['predict_cost']), end="")
|
||||
print(" elapsed %d)" % Mtasks[min_mtask]['elapsed'])
|
||||
print(" max log(p2e) = %0.3f" % max_p2e, end="")
|
||||
print(" from mtask %d (predict %d," %
|
||||
(max_mtask, Mtasks[max_mtask]['predict_cost']),
|
||||
end="")
|
||||
print(" from mtask %d (predict %d," % (max_mtask, Mtasks[max_mtask]['predict_cost']), end="")
|
||||
print(" elapsed %d)" % Mtasks[max_mtask]['elapsed'])
|
||||
|
||||
stddev = statistics.pstdev(p2e_ratios)
|
||||
@@ -315,8 +297,8 @@ def report_cpus():
|
||||
model = cpuinfo['model_name']
|
||||
|
||||
print(" {:3d} | {:7.2%} / {:16d} | {:>6s} | {:>4s} | {}".format(
|
||||
cpu, Cpus[cpu]['mtask_time'] / ElapsedTime,
|
||||
Cpus[cpu]['mtask_time'], socket, core, model))
|
||||
cpu, Cpus[cpu]['mtask_time'] / ElapsedTime, Cpus[cpu]['mtask_time'], socket, core,
|
||||
model))
|
||||
|
||||
if len(Global['cpu_sockets']) > 1:
|
||||
Global['cpu_sockets_warning'] = True
|
||||
@@ -326,23 +308,27 @@ def report_cpus():
|
||||
|
||||
|
||||
def report_sections():
|
||||
if not Sections:
|
||||
return
|
||||
print("\nSection profile:")
|
||||
for thread, section in enumerate(Sections):
|
||||
if section:
|
||||
print(f"\nSection profile for thread {thread}:")
|
||||
report_section(section)
|
||||
|
||||
|
||||
def report_section(section):
|
||||
totalTime = collections.defaultdict(lambda: 0)
|
||||
selfTime = collections.defaultdict(lambda: 0)
|
||||
|
||||
sectionTree = [0, {}, 1] # [selfTime, childTrees, numberOfTimesEntered]
|
||||
prevTime = 0
|
||||
prevStack = ()
|
||||
for time, stack in Sections:
|
||||
for time, stack in section:
|
||||
if len(stack) > len(prevStack):
|
||||
scope = sectionTree
|
||||
for item in stack:
|
||||
scope = scope[1].setdefault(item, [0, {}, 0])
|
||||
scope[2] += 1
|
||||
dt = time - prevTime
|
||||
assert dt >= 0
|
||||
scope = sectionTree
|
||||
for item in prevStack:
|
||||
scope = scope[1].setdefault(item, [0, {}, 0])
|
||||
@@ -366,8 +352,8 @@ def report_sections():
|
||||
|
||||
def printTree(prefix, name, entries, tree):
|
||||
print(" {:7.2%} | {:7.2%} | {:8} | {:10.2f} | {}".format(
|
||||
treeSum(tree) / ElapsedTime, tree[0] / ElapsedTime, tree[2],
|
||||
tree[2] / entries, prefix + name))
|
||||
treeSum(tree) / ElapsedTime, tree[0] / ElapsedTime, tree[2], tree[2] / entries,
|
||||
prefix + name))
|
||||
for k in sorted(tree[1], key=lambda _: -treeSum(tree[1][_])):
|
||||
printTree(prefix + " ", k, tree[2], tree[1][k])
|
||||
|
||||
@@ -438,10 +424,8 @@ def write_vcd(filename):
|
||||
addValue(code, start, mtask)
|
||||
addValue(code, end, None)
|
||||
|
||||
tStart = sorted(_['start'] for records in Threads.values()
|
||||
for _ in records)
|
||||
tEnd = sorted(_['end'] for records in Threads.values()
|
||||
for _ in records)
|
||||
tStart = sorted(_['start'] for records in Threads.values() for _ in records)
|
||||
tEnd = sorted(_['end'] for records in Threads.values() for _ in records)
|
||||
|
||||
# Predicted graph
|
||||
for start, end in ExecGraphIntervals:
|
||||
@@ -455,11 +439,10 @@ def write_vcd(filename):
|
||||
# Predict mtasks that fill the time the execution occupied
|
||||
for mtask in Mtasks:
|
||||
thread = Mtasks[mtask]['thread']
|
||||
pred_scaled_start = start + int(
|
||||
Mtasks[mtask]['predict_start'] * measured_scaling)
|
||||
pred_scaled_start = start + int(Mtasks[mtask]['predict_start'] * measured_scaling)
|
||||
pred_scaled_end = start + int(
|
||||
(Mtasks[mtask]['predict_start'] +
|
||||
Mtasks[mtask]['predict_cost']) * measured_scaling)
|
||||
(Mtasks[mtask]['predict_start'] + Mtasks[mtask]['predict_cost']) *
|
||||
measured_scaling)
|
||||
if pred_scaled_start == pred_scaled_end:
|
||||
continue
|
||||
|
||||
@@ -479,12 +462,13 @@ def write_vcd(filename):
|
||||
addValue(pcode, time, value)
|
||||
|
||||
# Section graph
|
||||
if Sections:
|
||||
scode = getCode(LongestVcdStrValueLength * 8, "section", "trace")
|
||||
dcode = getCode(32, "section", "depth")
|
||||
for time, stack in Sections:
|
||||
addValue(scode, time, stack[-1] if stack else None)
|
||||
addValue(dcode, time, len(stack))
|
||||
for thread, section in enumerate(Sections):
|
||||
if section:
|
||||
scode = getCode(LongestVcdStrValueLength * 8, "section", f"t{thread}_trace")
|
||||
dcode = getCode(32, "section", f"t{thread}_depth")
|
||||
for time, stack in section:
|
||||
addValue(scode, time, stack[-1] if stack else None)
|
||||
addValue(dcode, time, len(stack))
|
||||
|
||||
# Create output file
|
||||
fh.write("$version Generated by verilator_gantt $end\n")
|
||||
@@ -537,7 +521,7 @@ def write_vcd(filename):
|
||||
parser = argparse.ArgumentParser(
|
||||
allow_abbrev=False,
|
||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||
description="""Create Gantt chart of multi-threaded execution.
|
||||
description="""Create Gantt chart of Verilator multi-threaded execution
|
||||
|
||||
Verilator_gantt creates a visual representation to help analyze Verilator
|
||||
#xmultithreaded simulation performance, by showing when each macro-task
|
||||
@@ -545,8 +529,7 @@ Verilator_gantt creates a visual representation to help analyze Verilator
|
||||
|
||||
For documentation see
|
||||
https://verilator.org/guide/latest/exe_verilator_gantt.html""",
|
||||
epilog=
|
||||
"""Copyright 2018-2024 by Wilson Snyder. This program is free software; you
|
||||
epilog="""Copyright 2018-2025 by Wilson Snyder. This program is free software; you
|
||||
can redistribute it and/or modify it under the terms of either the GNU
|
||||
Lesser General Public License Version 3 or the Perl Artistic License
|
||||
Version 2.0.
|
||||
@@ -554,12 +537,8 @@ Version 2.0.
|
||||
SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0""")
|
||||
|
||||
parser.add_argument('--debug', action='store_true', help='enable debug')
|
||||
parser.add_argument('--no-vcd',
|
||||
help='disable creating vcd',
|
||||
action='store_true')
|
||||
parser.add_argument('--vcd',
|
||||
help='filename for vcd outpue',
|
||||
default='profile_exec.vcd')
|
||||
parser.add_argument('--no-vcd', help='disable creating vcd', action='store_true')
|
||||
parser.add_argument('--vcd', help='filename for vcd outpue', default='profile_exec.vcd')
|
||||
parser.add_argument('filename',
|
||||
help='input profile_exec.dat filename to process',
|
||||
default='profile_exec.dat')
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env python3
|
||||
# pylint: disable=C0114,C0209
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify the Verilator internals under the terms
|
||||
# of either the GNU Lesser General Public License Version 3 or the Perl
|
||||
# Artistic License Version 2.0.
|
||||
|
||||
+12
-23
@@ -34,9 +34,8 @@ def profcfunc(filename):
|
||||
|
||||
# Older gprofs have no call column for single-call functions
|
||||
# %time cumesec selfsec {stuff} name
|
||||
match = re.match(
|
||||
r'^\s*([0-9.]+)\s+[0-9.]+\s+([0-9.]+)\s+[^a-zA-Z_]*([a-zA-Z_].*)$',
|
||||
line)
|
||||
match = re.match(r'^\s*([0-9.]+)\s+[0-9.]+\s+([0-9.]+)\s+[^a-zA-Z_]*([a-zA-Z_].*)$',
|
||||
line)
|
||||
if match:
|
||||
pct = float(match.group(1))
|
||||
sec = float(match.group(2))
|
||||
@@ -136,19 +135,15 @@ def profcfunc(filename):
|
||||
|
||||
design_width = 1
|
||||
for func, func_item in vfuncs.items():
|
||||
if design_width < len(func_item['design']):
|
||||
design_width = len(func_item['design'])
|
||||
design_width = max(design_width, len(func_item['design']))
|
||||
|
||||
print("Verilog code profile:")
|
||||
print(" These are split into three categories:")
|
||||
print(" C++: Time in non-Verilated C++ code")
|
||||
print(" Prof: Time in profile overhead")
|
||||
print(" VBlock: Time attributable to a block in a" +
|
||||
" Verilog file and line")
|
||||
print(" VCommon: Time in a Verilated module," +
|
||||
" due to all parts of the design")
|
||||
print(" VLib: Time in Verilated common libraries," +
|
||||
" called by the Verilated code")
|
||||
print(" VBlock: Time attributable to a block in a" + " Verilog file and line")
|
||||
print(" VCommon: Time in a Verilated module," + " due to all parts of the design")
|
||||
print(" VLib: Time in Verilated common libraries," + " called by the Verilated code")
|
||||
print()
|
||||
|
||||
print(" % cumulative self ")
|
||||
@@ -156,13 +151,11 @@ def profcfunc(filename):
|
||||
"s type filename and line number") % "design")
|
||||
|
||||
cume = 0
|
||||
for func in sorted(vfuncs.keys(),
|
||||
key=lambda f: vfuncs[f]['sec'],
|
||||
reverse=True):
|
||||
for func in sorted(vfuncs.keys(), key=lambda f: vfuncs[f]['sec'], reverse=True):
|
||||
cume += vfuncs[func]['sec']
|
||||
print(("%6.2f %9.2f %8.2f %10d %-" + str(design_width) + "s %s") %
|
||||
(vfuncs[func]['pct'], cume, vfuncs[func]['sec'],
|
||||
vfuncs[func]['calls'], vfuncs[func]['design'], func))
|
||||
(vfuncs[func]['pct'], cume, vfuncs[func]['sec'], vfuncs[func]['calls'],
|
||||
vfuncs[func]['design'], func))
|
||||
|
||||
|
||||
######################################################################
|
||||
@@ -171,7 +164,7 @@ def profcfunc(filename):
|
||||
parser = argparse.ArgumentParser(
|
||||
allow_abbrev=False,
|
||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||
description="""Read gprof report created with --prof-cfuncs.
|
||||
description="""Read gprof report created with Verilator --prof-cfuncs
|
||||
|
||||
Verilator_profcfunc reads a profile report created by gprof. The names of
|
||||
the functions are then transformed, assuming the user used Verilator's
|
||||
@@ -180,18 +173,14 @@ in each Verilog block.
|
||||
|
||||
For documentation see
|
||||
https://verilator.org/guide/latest/exe_verilator_profcfunc.html""",
|
||||
epilog=
|
||||
"""Copyright 2002-2024 by Wilson Snyder. This program is free software; you
|
||||
epilog="""Copyright 2002-2025 by Wilson Snyder. This program is free software; you
|
||||
can redistribute it and/or modify it under the terms of either the GNU
|
||||
Lesser General Public License Version 3 or the Perl Artistic License
|
||||
Version 2.0.
|
||||
|
||||
SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0""")
|
||||
|
||||
parser.add_argument('--debug',
|
||||
action='store_const',
|
||||
const=9,
|
||||
help='enable debug')
|
||||
parser.add_argument('--debug', action='store_const', const=9, help='enable debug')
|
||||
parser.add_argument('filename', help='input gprof output to process')
|
||||
|
||||
Args = parser.parse_args()
|
||||
|
||||
+5
-12
@@ -60,17 +60,14 @@ if [ "$CI_BUILD_STAGE_NAME" = "build" ]; then
|
||||
sudo apt-get install libgoogle-perftools-dev ||
|
||||
sudo apt-get install libgoogle-perftools-dev
|
||||
fi
|
||||
if [ "$CI_RUNS_ON" = "ubuntu-20.04" ] || [ "$CI_RUNS_ON" = "ubuntu-22.04" ]; then
|
||||
if [ "$CI_RUNS_ON" = "ubuntu-20.04" ] || [ "$CI_RUNS_ON" = "ubuntu-22.04" ] || [ "$CI_RUNS_ON" = "ubuntu-24.04" ]; then
|
||||
sudo apt-get install libsystemc libsystemc-dev ||
|
||||
sudo apt-get install libsystemc libsystemc-dev
|
||||
fi
|
||||
if [ "$CI_RUNS_ON" = "ubuntu-22.04" ]; then
|
||||
if [ "$CI_RUNS_ON" = "ubuntu-22.04" ] || [ "$CI_RUNS_ON" = "ubuntu-24.04" ]; then
|
||||
sudo apt-get install bear mold ||
|
||||
sudo apt-get install bear mold
|
||||
fi
|
||||
if [ "$COVERAGE" = 1 ]; then
|
||||
yes yes | sudo cpan -fi Parallel::Forker
|
||||
fi
|
||||
elif [ "$CI_OS_NAME" = "osx" ]; then
|
||||
brew update
|
||||
brew install ccache perl gperftools
|
||||
@@ -94,12 +91,12 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
||||
# libfl-dev needed for internal coverage's test runs
|
||||
sudo apt-get install gdb gtkwave lcov libfl-dev ccache jq z3 ||
|
||||
sudo apt-get install gdb gtkwave lcov libfl-dev ccache jq z3
|
||||
# Required for test_regress/t/t_dist_attributes.pl
|
||||
if [ "$CI_RUNS_ON" = "ubuntu-22.04" ]; then
|
||||
# Required for test_regress/t/t_dist_attributes.py
|
||||
if [ "$CI_RUNS_ON" = "ubuntu-22.04" ] || [ "$CI_RUNS_ON" = "ubuntu-24.04" ]; then
|
||||
sudo apt-get install python3-clang mold ||
|
||||
sudo apt-get install python3-clang mold
|
||||
fi
|
||||
if [ "$CI_RUNS_ON" = "ubuntu-20.04" ] || [ "$CI_RUNS_ON" = "ubuntu-22.04" ]; then
|
||||
if [ "$CI_RUNS_ON" = "ubuntu-20.04" ] || [ "$CI_RUNS_ON" = "ubuntu-22.04" ] || [ "$CI_RUNS_ON" = "ubuntu-24.04" ]; then
|
||||
sudo apt-get install libsystemc-dev ||
|
||||
sudo apt-get install libsystemc-dev
|
||||
fi
|
||||
@@ -114,10 +111,6 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
||||
fatal "Unknown os: '$CI_OS_NAME'"
|
||||
fi
|
||||
# Common installs
|
||||
if [ "$CI_RUNS_ON" != "ubuntu-14.04" ]; then
|
||||
CI_CPAN_REPO=https://cpan.org
|
||||
fi
|
||||
yes yes | sudo cpan -M $CI_CPAN_REPO -fi Parallel::Forker
|
||||
install-vcddiff
|
||||
# Workaround -fsanitize=address crash
|
||||
sudo sysctl -w vm.mmap_rnd_bits=28
|
||||
|
||||
+5
-1
@@ -33,6 +33,7 @@ elif [ "$CI_OS_NAME" = "freebsd" ]; then
|
||||
else
|
||||
fatal "Unknown os: '$CI_OS_NAME'"
|
||||
fi
|
||||
NPROC=$(expr $NPROC '+' 1)
|
||||
|
||||
if [ "$CI_BUILD_STAGE_NAME" = "build" ]; then
|
||||
##############################################################################
|
||||
@@ -61,6 +62,7 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
||||
# Run tests
|
||||
|
||||
export VERILATOR_TEST_NO_CONTRIBUTORS=1 # Separate workflow check
|
||||
export VERILATOR_TEST_NO_LINT_PY=1 # Separate workflow check
|
||||
|
||||
if [ "$CI_OS_NAME" = "osx" ]; then
|
||||
export VERILATOR_TEST_NO_GDB=1 # Pain to get GDB to work on OS X
|
||||
@@ -85,7 +87,7 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
||||
fi
|
||||
|
||||
# Run sanitize on Ubuntu 22.04 only
|
||||
[ "$CI_RUNS_ON" = 'ubuntu-22.04' ] && sanitize='--sanitize' || sanitize=''
|
||||
( [ "$CI_RUNS_ON" = 'ubuntu-22.04' ] || [ "$CI_RUNS_ON" = 'ubuntu-24.04' ] ) && sanitize='--sanitize' || sanitize=''
|
||||
|
||||
TEST_REGRESS=test_regress
|
||||
if [ "$CI_RELOC" == 1 ]; then
|
||||
@@ -193,6 +195,8 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
||||
;;
|
||||
esac
|
||||
|
||||
# To see load average (1 minute, 5 minute, 15 minute)
|
||||
uptime
|
||||
# 22.04: ccache -s -v
|
||||
ccache -s
|
||||
|
||||
|
||||
@@ -11,14 +11,14 @@
|
||||
Set-PSDebug -Trace 1
|
||||
|
||||
if (-Not (Test-Path $PWD/../.ccache/win_bison.exe)) {
|
||||
git clone --depth 1 https://github.com/lexxmark/winflexbison
|
||||
cd winflexbison
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. --install-prefix $PWD/../../../.ccache
|
||||
cmake --build . --config Release -j 3
|
||||
cmake --install . --prefix $PWD/../../../.ccache
|
||||
cd ../..
|
||||
git clone --depth 1 https://github.com/lexxmark/winflexbison
|
||||
cd winflexbison
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. --install-prefix $PWD/../../../.ccache
|
||||
cmake --build . --config Release -j 3
|
||||
cmake --install . --prefix $PWD/../../../.ccache
|
||||
cd ../..
|
||||
}
|
||||
|
||||
mkdir build
|
||||
|
||||
@@ -51,8 +51,6 @@ RUN apt-get update \
|
||||
|
||||
WORKDIR /tmp
|
||||
|
||||
RUN cpan install -fi Parallel::Forker
|
||||
|
||||
RUN git clone https://github.com/veripool/vcddiff.git && \
|
||||
make -C vcddiff && \
|
||||
cp -p vcddiff/vcddiff /usr/local/bin/vcddiff && \
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Verilator Build Docker Container:
|
||||
|
||||
Verilator Build Docker Container
|
||||
================================
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
Verilator Executable Docker Container
|
||||
|
||||
+16
-18
@@ -1,6 +1,7 @@
|
||||
---
|
||||
# DESCRIPTION: codecov.io config
|
||||
#
|
||||
# Copyright 2020-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2020-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
@@ -8,31 +9,28 @@
|
||||
####################
|
||||
# Validate:
|
||||
# curl --data-binary @codecov.yml https://codecov.io/validate
|
||||
|
||||
#
|
||||
codecov:
|
||||
require_ci_to_pass: no
|
||||
|
||||
require_ci_to_pass: false
|
||||
coverage:
|
||||
precision: 2
|
||||
round: down
|
||||
range: "50...100"
|
||||
range: 50...100
|
||||
ignore:
|
||||
- "ci"
|
||||
- "docs"
|
||||
- "examples"
|
||||
- "include/gtkwave"
|
||||
- "include/vltstd"
|
||||
- "test_regress"
|
||||
|
||||
- "ci" #
|
||||
- "docs" #
|
||||
- "examples" #
|
||||
- "include/gtkwave" #
|
||||
- "include/vltstd" #
|
||||
- "test_regress" #
|
||||
parsers:
|
||||
gcov:
|
||||
branch_detection:
|
||||
conditional: yes
|
||||
loop: yes
|
||||
method: no
|
||||
macro: no
|
||||
|
||||
conditional: true
|
||||
loop: true
|
||||
method: false
|
||||
macro: false
|
||||
comment:
|
||||
layout: "reach,diff,flags,tree"
|
||||
behavior: default
|
||||
require_changes: yes
|
||||
require_changes: true
|
||||
|
||||
+25
-9
@@ -1,6 +1,6 @@
|
||||
# DESCRIPTION: Process this file with autoconf to produce a configure script.
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. Verilator is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. Verilator is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU Lesser
|
||||
# General Public License Version 3 or the Perl Artistic License Version 2.0.
|
||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
@@ -10,7 +10,7 @@
|
||||
# Then 'make maintainer-dist'
|
||||
#AC_INIT([Verilator],[#.### YYYY-MM-DD])
|
||||
#AC_INIT([Verilator],[#.### devel])
|
||||
AC_INIT([Verilator],[5.028 2024-08-21],
|
||||
AC_INIT([Verilator],[5.034 2025-02-24],
|
||||
[https://verilator.org],
|
||||
[verilator],[https://verilator.org])
|
||||
|
||||
@@ -29,6 +29,9 @@ AC_DEFINE_UNQUOTED([PACKAGE_VERSION_STRING_CHAR],
|
||||
[Package version as a number])
|
||||
AC_SUBST(PACKAGE_VERSION_STRING_CHAR)
|
||||
|
||||
######################################################################
|
||||
## Arguments/flag checking
|
||||
|
||||
# Ignore automake flags passed by Ubuntu builds
|
||||
AC_ARG_ENABLE([dependency-tracking],
|
||||
[AS_HELP_STRING([--disable-dependency-tracking], [ignored])])
|
||||
@@ -156,6 +159,11 @@ AC_ARG_WITH([solver],
|
||||
AC_SUBST(CFG_WITH_SOLVER)
|
||||
AC_MSG_RESULT($CFG_WITH_SOLVER)
|
||||
|
||||
######################################################################
|
||||
## Compiler checks
|
||||
|
||||
AC_MSG_RESULT([compiler CXX inbound is set to... $CXX])
|
||||
|
||||
# Compiler flags (ensure they are not empty to avoid configure defaults)
|
||||
CFLAGS="$CFLAGS "
|
||||
CPPFLAGS="$CPPFLAGS "
|
||||
@@ -168,8 +176,10 @@ AC_PROG_CXX
|
||||
AC_PROG_INSTALL
|
||||
|
||||
AC_LANG_PUSH(C++)
|
||||
cxx_version=$($CXX --version | head -1)
|
||||
AC_MSG_RESULT([compiler is $CXX --version = $cxx_version])
|
||||
CFG_CXX_VERSION=`$CXX --version | head -1`
|
||||
AC_MSG_RESULT([compiler $CXX --version = $CFG_CXX_VERSION])
|
||||
AC_SUBST(CFG_CXX_VERSION)
|
||||
|
||||
AC_MSG_CHECKING([that C++ compiler can compile simple program])
|
||||
AC_RUN_IFELSE(
|
||||
[AC_LANG_SOURCE([int main() { return 0; }])],
|
||||
@@ -182,24 +192,26 @@ if test "x$AR" = "x" ; then
|
||||
AC_MSG_ERROR([Cannot find "ar" in your PATH, please install it])
|
||||
fi
|
||||
|
||||
AC_PATH_PROG(PERL,perl)
|
||||
AC_CHECK_PROG(PERL,perl,perl)
|
||||
if test "x$PERL" = "x" ; then
|
||||
AC_MSG_ERROR([Cannot find "perl" in your PATH, please install it])
|
||||
fi
|
||||
|
||||
AC_PATH_PROG(PYTHON3,python3)
|
||||
AC_CHECK_PROG(PYTHON3,python3,python3)
|
||||
if test "x$PYTHON3" = "x" ; then
|
||||
AC_MSG_ERROR([Cannot find "python3" in your PATH, please install it])
|
||||
fi
|
||||
python3_version=$($PYTHON3 --version | head -1)
|
||||
AC_MSG_RESULT([$PYTHON3 --version = $python3_version])
|
||||
|
||||
AC_PATH_PROG(LEX,flex)
|
||||
AC_CHECK_PROG(LEX,flex,flex)
|
||||
if test "x$LEX" = "x" ; then
|
||||
AC_MSG_ERROR([Cannot find "flex" in your PATH, please install it])
|
||||
fi
|
||||
flex_version=$($LEX --version | head -1)
|
||||
AC_MSG_RESULT([$LEX --version = $flex_version])
|
||||
|
||||
AC_PATH_PROG(YACC,bison)
|
||||
AC_CHECK_PROG(YACC,bison,bison)
|
||||
if test "x$YACC" = "x" ; then
|
||||
AC_MSG_ERROR([Cannot find "bison" in your PATH, please install it])
|
||||
fi
|
||||
@@ -466,6 +478,7 @@ m4_foreach([cflag],[
|
||||
[-Wno-parentheses-equality],
|
||||
[-Wno-shadow],
|
||||
[-Wno-sign-compare],
|
||||
[-Wno-subobject-linkage],
|
||||
[-Wno-tautological-bitwise-compare],
|
||||
[-Wno-tautological-compare],
|
||||
[-Wno-uninitialized],
|
||||
@@ -526,7 +539,7 @@ _MY_LDLIBS_CHECK_IFELSE(
|
||||
[if test "$CFG_WITH_TCMALLOC" != "no"; then
|
||||
CFG_LIBS="$LTCMALLOC $CFG_LIBS";
|
||||
# If using tcmalloc, add some extra options to make the compiler not assume
|
||||
# it is using it's own versions of the standard library functions
|
||||
# it is using its own versions of the standard library functions
|
||||
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-fno-builtin-malloc)
|
||||
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-fno-builtin-calloc)
|
||||
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-fno-builtin-realloc)
|
||||
@@ -623,6 +636,9 @@ AC_SUBST(HAVE_SYSTEMC)
|
||||
|
||||
# Checks for system services
|
||||
|
||||
######################################################################
|
||||
## Output
|
||||
|
||||
# Other install directories
|
||||
pkgdatadir=${datadir}/verilator
|
||||
AC_SUBST(pkgdatadir)
|
||||
|
||||
@@ -7,8 +7,8 @@ This contributing document contains some suggestions that may make
|
||||
contributions flow more efficiently.
|
||||
|
||||
|
||||
Did you find a bug?
|
||||
-------------------
|
||||
Did you find a Verilator bug?
|
||||
-----------------------------
|
||||
|
||||
- Please **ensure the bug was not already reported** by searching
|
||||
`Verilator Issues <https://verilator.org/issues>`__.
|
||||
@@ -28,8 +28,8 @@ Did you find a bug?
|
||||
<https://github.com/verilator/verilator/blob/master/docs/internals.rst>`__.
|
||||
|
||||
|
||||
Did you write a patch that fixes a bug?
|
||||
---------------------------------------
|
||||
Did you write a patch that fixes a Verilator bug?
|
||||
-------------------------------------------------
|
||||
|
||||
- Please `Open a new Verilator issue <https://verilator.org/issues/new>`__
|
||||
if there is not one already describing the bug.
|
||||
@@ -72,8 +72,8 @@ Did you write a patch that fixes a bug?
|
||||
- Most important is we get your patch.
|
||||
|
||||
|
||||
Do you have questions?
|
||||
----------------------
|
||||
Do you have questions on Verilator?
|
||||
-----------------------------------
|
||||
|
||||
- Please see FAQ section and rest of the `Verilator
|
||||
manual <https://verilator.org/verilator_doc.html>`__, or `Verilator
|
||||
|
||||
@@ -7,6 +7,7 @@ Adam Bagley
|
||||
Adrian Sampson
|
||||
Adrien Le Masle
|
||||
Ahmed El-Mahmoudy
|
||||
Aidan McNay
|
||||
Aleksander Kiryk
|
||||
Alex Chadwick
|
||||
Alex Solomatnikov
|
||||
@@ -19,6 +20,7 @@ Andrei Kostovski
|
||||
Andrew Miloradovsky
|
||||
Andrew Nolte
|
||||
Anthony Donlon
|
||||
Anthony Moore
|
||||
Arkadiusz Kozdra
|
||||
Arthur Rosa
|
||||
Aylon Chaim Porat
|
||||
@@ -36,17 +38,22 @@ Daniel Bates
|
||||
David Horton
|
||||
David Ledger
|
||||
David Metz
|
||||
Dave Sargeant
|
||||
David Stanford
|
||||
David Turner
|
||||
Dercury
|
||||
Diego Roux
|
||||
Don Williamson
|
||||
Drew Ranck
|
||||
Drew Taussig
|
||||
Driss Hafdi
|
||||
Edgar E. Iglesias
|
||||
Eric Müller
|
||||
Eric Rippey
|
||||
Ethan Sifferman
|
||||
Eyck Jentzsch
|
||||
Furqan Nadir
|
||||
Fabian Keßler
|
||||
Fan Shupei
|
||||
february cozzocrea
|
||||
Felix Neumärker
|
||||
@@ -61,9 +68,11 @@ Gijs Burghoorn
|
||||
Glen Gibb
|
||||
Gökçe Aydos
|
||||
Graham Rushton
|
||||
Greg Davill
|
||||
Guokai Chen
|
||||
Gus Smith
|
||||
Gustav Svensk
|
||||
Han Qi
|
||||
Harald Heckmann
|
||||
Hennadii Chernyshchyk
|
||||
Howard Su
|
||||
@@ -92,6 +101,7 @@ Jesse Taube
|
||||
Jevin Sweval
|
||||
Jiacheng Qian
|
||||
Jiamin Zhu
|
||||
Jitesh Nayak
|
||||
Jinyan Xu
|
||||
Jiuyang Liu
|
||||
Joey Liu
|
||||
@@ -121,6 +131,7 @@ Krzysztof Bieganski
|
||||
Krzysztof Boronski
|
||||
Krzysztof Boroński
|
||||
Krzysztof Obłonczek
|
||||
Krzysztof Starecki
|
||||
Kuba Ober
|
||||
Larry Doolittle
|
||||
Liam Braun
|
||||
@@ -147,9 +158,13 @@ Miodrag Milanović
|
||||
Mladen Slijepcevic
|
||||
Morten Borup Petersen
|
||||
Mostafa Gamal
|
||||
Moubarak Jeje
|
||||
Nandu Raj
|
||||
Natan Kreimer
|
||||
Nathan Graybeal
|
||||
Nathan Kohagen
|
||||
Nathan Myers
|
||||
Nick Brereton
|
||||
Nolan Poe
|
||||
Oleh Maksymenko
|
||||
Patrick Stewart
|
||||
@@ -188,9 +203,11 @@ Srinivasan Venkataramanan
|
||||
Stefan Wallentowitz
|
||||
Stephen Henry
|
||||
Steven Hugg
|
||||
sumpster
|
||||
Szymon Gizler
|
||||
Sören Tempel
|
||||
Teng Huang
|
||||
Tom Manner
|
||||
Tim Hutt
|
||||
Tim Snyder
|
||||
Tobias Rosenkranz
|
||||
@@ -199,6 +216,7 @@ Todd Strader
|
||||
Tomasz Gorochowik
|
||||
Topa Topino
|
||||
Toru Niina
|
||||
Trung Nguyen
|
||||
Tudor Timi
|
||||
Tymoteusz Blazejczyk
|
||||
Udi Finkelstein
|
||||
@@ -215,6 +233,7 @@ Wilson Snyder
|
||||
Xi Zhang
|
||||
Yan Xu
|
||||
Yangyu Chen
|
||||
Yilou Wang
|
||||
Yinan Xu
|
||||
Yoda Lee
|
||||
Yossi Nivin
|
||||
|
||||
+2
-2
@@ -5,7 +5,7 @@
|
||||
#
|
||||
# Code available from: https://verilator.org
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
@@ -23,7 +23,7 @@ SPHINXBUILD ?= sphinx-build
|
||||
SOURCEDIR = guide
|
||||
BUILDDIR = _build
|
||||
|
||||
SPHINXOPTS ?= -c guide
|
||||
SPHINXOPTS ?= -c guide -j 4
|
||||
ifneq ($(VERILATOR_ANALYTICS_ID),)
|
||||
SPHINXOPTS += -D html_theme_options.analytics_id=$(VERILATOR_ANALYTICS_ID)
|
||||
endif
|
||||
|
||||
@@ -23,9 +23,7 @@ class VlSphinxExtract:
|
||||
outname = match.group(1)
|
||||
print("Writing %s" % outname)
|
||||
fhw = open(outname, "w", encoding="utf8") # pylint: disable=consider-using-with
|
||||
fhw.write(
|
||||
".. comment: generated by vl_sphinx_extract from " +
|
||||
filename + "\n")
|
||||
fhw.write(".. comment: generated by vl_sphinx_extract from " + filename + "\n")
|
||||
fhw.write(".. code-block::\n")
|
||||
elif re.match(r'^[=a-zA-Z0-9_]', line):
|
||||
fhw = None
|
||||
@@ -39,18 +37,14 @@ parser = argparse.ArgumentParser(
|
||||
allow_abbrev=False,
|
||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||
description="""Read a file and extract documentation data.""",
|
||||
epilog=
|
||||
""" Copyright 2021-2024 by Wilson Snyder. This package is free software;
|
||||
epilog=""" Copyright 2021-2025 by Wilson Snyder. This package is free software;
|
||||
you can redistribute it and/or modify it under the terms of either the GNU
|
||||
Lesser General Public License Version 3 or the Perl Artistic License
|
||||
Version 2.0.
|
||||
|
||||
SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0""")
|
||||
|
||||
parser.add_argument('--debug',
|
||||
action='store_const',
|
||||
const=9,
|
||||
help='enable debug')
|
||||
parser.add_argument('--debug', action='store_const', const=9, help='enable debug')
|
||||
parser.add_argument('path', help='path to extract from')
|
||||
Args = parser.parse_args()
|
||||
|
||||
|
||||
@@ -18,8 +18,7 @@ class VlSphinxFix:
|
||||
if os.path.isdir(path):
|
||||
for basefile in os.listdir(path):
|
||||
file = os.path.join(path, basefile)
|
||||
if ((basefile != ".") and (basefile != "..")
|
||||
and basefile not in self.SkipBasenames
|
||||
if ((basefile != ".") and (basefile != "..") and basefile not in self.SkipBasenames
|
||||
and not os.path.islink(file)):
|
||||
self.process(file)
|
||||
elif re.search(r'\.(html|tex)$', path):
|
||||
@@ -54,18 +53,14 @@ parser = argparse.ArgumentParser(
|
||||
allow_abbrev=False,
|
||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||
description="""Post-process Sphinx HTML.""",
|
||||
epilog=
|
||||
""" Copyright 2021-2024 by Wilson Snyder. This package is free software;
|
||||
epilog=""" Copyright 2021-2025 by Wilson Snyder. This package is free software;
|
||||
you can redistribute it and/or modify it under the terms of either the GNU
|
||||
Lesser General Public License Version 3 or the Perl Artistic License
|
||||
Version 2.0.
|
||||
|
||||
SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0""")
|
||||
|
||||
parser.add_argument('--debug',
|
||||
action='store_const',
|
||||
const=9,
|
||||
help='enable debug')
|
||||
parser.add_argument('--debug', action='store_const', const=9, help='enable debug')
|
||||
parser.add_argument('path', help='path to edit')
|
||||
Args = parser.parse_args()
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
.. comment: generated by t_lint_multidriven_bad
|
||||
.. code-block::
|
||||
|
||||
%Warning-MULTIDRIVEN: example.v:1:22 Signal has multiple driving blocks with different clocking: 't.mem'
|
||||
%Warning-MULTIDRIVEN: example.v:1:22 Signal has multiple driving blocks with different clocking: 'out2'
|
||||
example.v:1:7 ... Location of first driving block
|
||||
example.v:1:7 ... Location of other driving block
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
****************
|
||||
|
||||
+3
-5
@@ -1,7 +1,7 @@
|
||||
# pylint: disable=C0103,C0114,C0116,C0301,E0402,W0622
|
||||
#
|
||||
# Configuration file for Verilator's Sphinx documentation builder.
|
||||
# Copyright 2003-2024 by Wilson Snyder.
|
||||
# Copyright 2003-2025 by Wilson Snyder.
|
||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
#
|
||||
# This file only contains overridden options. For a full list:
|
||||
@@ -23,8 +23,7 @@ def get_vlt_version():
|
||||
filename = "../../Makefile"
|
||||
with open(filename, "r", encoding="utf8") as fh:
|
||||
for line in fh:
|
||||
match = re.search(r"PACKAGE_VERSION *= *([a-z0-9.]+) +([-0-9]+)",
|
||||
line)
|
||||
match = re.search(r"PACKAGE_VERSION *= *([a-z0-9.]+) +([-0-9]+)", line)
|
||||
if match:
|
||||
return match.group(1), match.group(2)
|
||||
match = re.search(r"PACKAGE_VERSION *= *([a-z0-9.]+) +devel", line)
|
||||
@@ -75,8 +74,7 @@ extensions = []
|
||||
# directories to ignore when looking for source files.
|
||||
# This pattern also affects html_static_path and html_extra_path.
|
||||
exclude_patterns = [
|
||||
'_build', 'Thumbs.db', '.DS_Store', 'internals.rst', 'xml.rst', 'gen/ex_*',
|
||||
'CONTRIBUTING.rst'
|
||||
'_build', 'Thumbs.db', '.DS_Store', 'internals.rst', 'xml.rst', 'gen/ex_*', 'CONTRIBUTING.rst'
|
||||
]
|
||||
|
||||
# Warn about refs
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Connecting:
|
||||
|
||||
+30
-12
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
*******************************
|
||||
@@ -23,24 +23,24 @@ Next, try the :vlopt:`--debug` option. This will enable additional
|
||||
internal assertions, and may help identify the problem.
|
||||
|
||||
Finally, reduce your code to the smallest possible routine that exhibits
|
||||
the bug. Even better, create a test in the :file:`test_regress/t`
|
||||
directory, as follows:
|
||||
the bug (see: :ref:`Minimizing bug-inducing code`). Even better, create
|
||||
a test in the :file:`test_regress/t` directory, as follows:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
cd test_regress
|
||||
cp -p t/t_EXAMPLE.pl t/t_BUG.pl
|
||||
cp -p t/t_EXAMPLE.py t/t_BUG.py
|
||||
cp -p t/t_EXAMPLE.v t/t_BUG.v
|
||||
|
||||
There are many hints on how to write a good test in the
|
||||
:file:`test_regress/driver.pl` documentation which can be seen by running:
|
||||
:file:`test_regress/driver.py` documentation which can be seen by running:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
cd $VERILATOR_ROOT # Need the original distribution kit
|
||||
test_regress/driver.pl --help
|
||||
test_regress/driver.py --help
|
||||
|
||||
Edit :file:`t/t_BUG.pl` to suit your example; you can do anything you want
|
||||
Edit :file:`t/t_BUG.py` to suit your example; you can do anything you want
|
||||
in the Verilog code there; just make sure it retains the single clk input
|
||||
and no outputs. Now, the following should fail:
|
||||
|
||||
@@ -48,20 +48,38 @@ and no outputs. Now, the following should fail:
|
||||
|
||||
cd $VERILATOR_ROOT # Need the original distribution kit
|
||||
cd test_regress
|
||||
t/t_BUG.pl # Run on Verilator
|
||||
t/t_BUG.pl --debug # Run on Verilator, passing --debug to Verilator
|
||||
t/t_BUG.pl --vcs # Run on VCS simulator
|
||||
t/t_BUG.pl --nc|--iv|--ghdl # Likewise on other simulators
|
||||
t/t_BUG.py # Run on Verilator
|
||||
t/t_BUG.py --debug # Run on Verilator, passing --debug to Verilator
|
||||
t/t_BUG.py --vcs # Run on VCS simulator
|
||||
t/t_BUG.py --nc|--iv|--ghdl # Likewise on other simulators
|
||||
|
||||
The test driver accepts a number of options, many of which mirror the main
|
||||
Verilator options. For example the previous test could have been run with
|
||||
debugging enabled. The full set of test options can be seen by running
|
||||
:command:`driver.pl --help` as shown above.
|
||||
:command:`driver.py --help` as shown above.
|
||||
|
||||
Finally, report the bug at `Verilator Issues
|
||||
<https://verilator.org/issues>`_. The bug will become publicly visible; if
|
||||
this is unacceptable, mail the bug report to ``[email protected]``.
|
||||
|
||||
.. _Minimizing bug-inducing code:
|
||||
|
||||
Minimizing bug-inducing code
|
||||
============================
|
||||
|
||||
In some cases, the part of the code that causes the bug is clearly visible
|
||||
and the design can be easily manually reduced. In other cases, the bug is
|
||||
caused by a complex interaction of many parts of the design, and it is not
|
||||
clear which parts are necessary to reproduce the bug. In these cases, an
|
||||
Open Source tool called `sv-bugpoint
|
||||
<https://github.com/antmicro/sv-bugpoint>_` can be used to automatically
|
||||
reduce a SystemVerilog design to the smallest possible reproducer.
|
||||
It can be used to automatically reduce a design with hundreds of thousands of
|
||||
lines to a minimal test case while preserving the bug-inducing behavior.
|
||||
|
||||
Please refer to the `README
|
||||
<https://github.com/antmicro/sv-bugpoint/blob/main/README.md>`_ file for more
|
||||
information on how to use `sv-bugpoint`.
|
||||
|
||||
.. Contributing
|
||||
.. ============
|
||||
|
||||
+123
-113
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
************************
|
||||
@@ -34,130 +34,140 @@ MicroTune Inc., picoChip Designs Ltd., Sun Microsystems Inc., Nauticus
|
||||
Networks Inc., SiCortex Inc, Shunyao CAD, and Western Digital Inc.
|
||||
|
||||
The contributors of major functionality are: Jeremy Bennett, Krzysztof
|
||||
Bieganski, Byron Bradley, Lane Brooks, John Coiner, Duane Galbi, Geza Lore,
|
||||
Todd Strader, Yutetsu Takatsukasa, Stefan Wallentowitz, Paul Wasson, Jie
|
||||
Xu, and Wilson Snyder.
|
||||
Bieganski, Byron Bradley, Lane Brooks, John Coiner, Duane Galbi, Arkadiusz
|
||||
Kozdra, Geza Lore, Todd Strader, Yutetsu Takatsukasa, Stefan Wallentowitz,
|
||||
Paul Wasson, Jie Xu, and Wilson Snyder.
|
||||
|
||||
Some of the people who have provided ideas, and feedback for Verilator
|
||||
include:
|
||||
|
||||
David Addison, Tariq B. Ahmad, Nikana Anastasiadis, John David Anglin,
|
||||
Frederic Antonin, Hans Van Antwerpen, Vasu Arasanipalai, Jens Arm, Rohan
|
||||
Arshid, Gökçe Aydos, Adam Bagley, Sharad Bagri, Robert Balas, Marco
|
||||
Balboni, Matthew Ballance, Andrew Bardsley, Ilya Barkov, Matthew Barr,
|
||||
Geoff Barrett, Kaleb Barrett, Daniel Bates, Julius Baxter, Michael Berman,
|
||||
Jean Berniolles, Victor Besyakov, Narayan Bhagavatula, Moinak
|
||||
Bhattacharyya, Kritik Bhimani, David Biancolin, David Binderman, Piotr
|
||||
Binkowski, Johan Björk, David Black, Tymoteusz Blazejczyk, Scott Bleiweiss,
|
||||
David van der Bokke, Daniel Bone, Guy Bonneau, Krzysztof Boroński, Gregg
|
||||
Bouchard, Christopher Boumenot, Nick Bowler, Bryan Brady, Maarten De
|
||||
Braekeleer, Charlie Brej, J Briquet, John Brownlee, KC Buckenmaier, Jeff
|
||||
Bush, Lawrence Butcher, Tony Bybell, Iru Cai, Ted Campbell, Anthony Campos,
|
||||
Chris Candler, Lauren Carlson, Gregory Carver, Donal Casey, Sebastien Van
|
||||
Cauwenberghe, Alex Chadwick, Greg Chadwick, Marcel Chang, Aliaksei
|
||||
Chapyzhenka, Chih-Mao Chen, Guokai Chen, Terry Chen, Yi-Chung Chen, Yurii
|
||||
Cherkasov, Hennadii Chernyshchyk, Enzo Chi, Robert A. Clark, Ryan Clarke,
|
||||
Allan Cochrane, Keith Colbert, Quentin Corradi, Nassim Corteggiani,
|
||||
Arshid, Valentin Atepalikhin, Philip Axer, Gökçe Aydos, Chris Bachhuber,
|
||||
Filip Badáň, Adam Bagley, Sharad Bagri, James Bailey, Robert Balas, Marco
|
||||
Balboni, Matthew Ballance, Ricardo Barbedo, Andrew Bardsley, Ilya Barkov,
|
||||
Matthew Barr, Geoff Barrett, Kaleb Barrett, Daniel Bates, Julius Baxter,
|
||||
Michael Berman, Jean Berniolles, Victor Besyakov, Narayan Bhagavatula,
|
||||
Moinak Bhattacharyya, Kritik Bhimani, David Biancolin, Krzysztof Bieganski,
|
||||
Michael Bikovitsky, David Binderman, Piotr Binkowski, Johan Björk, David
|
||||
Black, Tymoteusz Blazejczyk, Scott Bleiweiss, David van der Bokke, Daniel
|
||||
Bone, Guy Bonneau, Krzysztof Boroński, Gregg Bouchard, Christopher
|
||||
Boumenot, Paul Bowen-Huggett, Nick Bowler, Bryan Brady, Maarten De
|
||||
Braekeleer, Liam Braun, Charlie Brej, J Briquet, John Brownlee, KC
|
||||
Buckenmaier, Gijs Burghoorn, Jeff Bush, Lawrence Butcher, Tony Bybell, Iru
|
||||
Cai, Ted Campbell, Anthony Campos, Chris Candler, Lauren Carlson, Gregory
|
||||
Carver, Donal Casey, Sebastien Van Cauwenberghe, Alex Chadwick, Greg
|
||||
Chadwick, Marcel Chang, Aliaksei Chapyzhenka, Chih-Mao Chen, Guokai Chen,
|
||||
Kefa Chen, Terry Chen, Yangyu Chen, Yi-Chung Chen, Yurii Cherkasov,
|
||||
Hennadii Chernyshchyk, Enzo Chi, Bartłomiej Chmiel, Robert A. Clark, Ryan
|
||||
Clarke, Allan Cochrane, Keith Colbert, Quentin Corradi, Nassim Corteggiani,
|
||||
Gianfranco Costamagna, February Cozzocrea, Sean Cross, George Cuan, Michal
|
||||
Czyz, Joe DErrico, Jim Dai, Lukasz Dalek, Laurens van Dam, Gunter
|
||||
Dannoritzer, Ashutosh Das, Julian Daube, Bernard Deadman, Peter Debacker,
|
||||
John Demme, Mike Denio, John Deroo, Philip Derrick, Aadi Desai, John
|
||||
Dickol, Ruben Diez, Danny Ding, Jacko Dirks, Ivan Djordjevic, Brad Dobbie,
|
||||
Paul Donahue, Jonathon Donaldson, Anthony Donlon, Caleb Donovick, Larry
|
||||
Doolittle, Leendert van Doorn, Sebastian Dressler, Jonathan Drolet, Maciej
|
||||
Dudek, Alex Duller, Jeff Dutton, Tomas Dzetkulic, Usuario Eda, Charles
|
||||
Eddleston, Chandan Egbert, Joe Eiler, Ahmed El-Mahmoudy, Trevor Elbourne,
|
||||
Mats Engstrom, Robert Farrell, Julien Faucher, Olivier Faure, Eugen Fekete,
|
||||
Fabrizio Ferrandi, Udi Finkelstein, Brian Flachs, Bill Flynn, Andrea
|
||||
Foletto, Alex Forencich, Aurelien Francillon, Bob Fredieu, Manuel
|
||||
Freiberger, Mostafa Gamal, Vito Gamberini, Mostafa Garnal, Benjamin
|
||||
Gartner, Christian Gelinek, Richard E George, Peter Gerst, Glen Gibb,
|
||||
Michael Gielda, Barbara Gigerl, Nimrod Gileadi, Shankar Giri, Dan
|
||||
Gisselquist, Petr Gladkikh, Sam Gladstone, Mariusz Glebocki, Embedded Go,
|
||||
Andrew Goessling, Amir Gonnen, Chitlesh Goorah, Tomasz Gorochowik, Kai
|
||||
Gossner, Tarik Graba, Sergi Granell, Al Grant, Nathan Graybeal, Alexander
|
||||
Grobman, Qian Gu, Xuan Guo, Prabhat Gupta, Driss Hafdi, Neil Hamilton,
|
||||
James Hanlon, Tang Haojin, Øyvind Harboe, Jannis Harder, David Harris,
|
||||
Junji Hashimoto, Thomas Hawkins, Mitch Hayenga, Harald Heckmann, Robert
|
||||
Henry, Stephen Henry, Sebastian Hesselbarth, David Hewson, Jamey Hicks,
|
||||
Joel Holdsworth, Andrew Holme, Peter Holmes, Hiroki Honda, Alex Hornung,
|
||||
Dannoritzer, Ashutosh Das, Julian Daube, Greg Davill, Bernard Deadman,
|
||||
Peter Debacker, Josse Van Delm, John Demme, Mike Denio, John Deroo, Philip
|
||||
Derrick, Aadi Desai, John Dickol, Ruben Diez, Danny Ding, Jacko Dirks, Ivan
|
||||
Djordjevic, Brad Dobbie, Paul Donahue, Jonathon Donaldson, Anthony Donlon,
|
||||
Caleb Donovick, Larry Doolittle, Leendert van Doorn, Sebastian Dressler,
|
||||
Jonathan Drolet, Justin Yao Du, Maciej Dudek, Alex Duller, Jeff Dutton,
|
||||
Tomas Dzetkulic, Usuario Eda, Charles Eddleston, Chandan Egbert, Joe Eiler,
|
||||
Ahmed El-Mahmoudy, Trevor Elbourne, Mats Engstrom, Robert Farrell, Julien
|
||||
Faucher, Olivier Faure, Eugene Feinberg, Eugen Fekete, Fabrizio Ferrandi,
|
||||
Udi Finkelstein, Brian Flachs, Bill Flynn, Andrea Foletto, Alex Forencich,
|
||||
Aurelien Francillon, Bob Fredieu, Manuel Freiberger, Mostafa Gamal, Vito
|
||||
Gamberini, Mostafa Garnal, Benjamin Gartner, Christian Gelinek, Richard E
|
||||
George, Peter Gerst, Glen Gibb, Michael Gielda, Barbara Gigerl, Nimrod
|
||||
Gileadi, Shankar Giri, Dan Gisselquist, Szymon Gizler, Petr Gladkikh, Sam
|
||||
Gladstone, Mariusz Glebocki, Embedded Go, Andrew Goessling, Amir Gonnen,
|
||||
Chitlesh Goorah, Tomasz Gorochowik, Kai Gossner, Tarik Graba, Sergi
|
||||
Granell, Al Grant, Nathan Graybeal, Alexander Grobman, Qian Gu, Xuan Guo,
|
||||
Prabhat Gupta, Deniz Güzel, Driss Hafdi, Abdul Hameed, Neil Hamilton, James
|
||||
Hanlon, Tang Haojin, Øyvind Harboe, Jannis Harder, David Harris, Junji
|
||||
Hashimoto, Thomas Hawkins, Mitch Hayenga, Harald Heckmann, Robert Henry,
|
||||
Stephen Henry, Sebastian Hesselbarth, David Hewson, Jamey Hicks, Joel
|
||||
Holdsworth, Andrew Holme, Peter Holmes, Hiroki Honda, Alex Hornung,
|
||||
Pierre-Henri Horrein, David Horton, Peter Horvath, Jae Hossell, Kuoping
|
||||
Hsu, Teng Huang, Steven Hugg, Huanghuang Zhou, Alan Hunter, James
|
||||
Hutchinson, Tim Hutt, Ehab Ibrahim, Edgar E. Iglesias, Shahid Ikram, Jamie
|
||||
Iles, Vighnesh Iyer, Ben Jackson, Daniel Jacques, Shareef Jalloq, Marlon
|
||||
Hsu, Shou-Li Hsu, Teng Huang, Steven Hugg, Alan Hunter, James Hutchinson,
|
||||
Tim Hutt, Ehab Ibrahim, Edgar E. Iglesias, Shahid Ikram, Jamie Iles, Fuad
|
||||
Ismail, Vighnesh Iyer, Ben Jackson, Daniel Jacques, Shareef Jalloq, Marlon
|
||||
James, Krzysztof Jankowski, Eyck Jentzsch, HyungKi Jeong, Iztok Jeras,
|
||||
Alexandre Joannou, James Johnson, Christophe Joly, Justin Jones,
|
||||
William D. Jones, Larry Darryl Lee Jr., Franck Jullien, James Jung,
|
||||
Yoshitomo Kaneda, Mike Kagen, Arthur Kahlich, Kaalia Kahn, Guy-Armand
|
||||
Kamendje, Vasu Kandadi, Kanad Kanhere, Patricio Kaplan, Pieter Kapsenberg,
|
||||
Rafal Kapuscik, Ralf Karge, Per Karlsson, Dan Katz, Sol Katzman, Ian
|
||||
Kennedy, Ami Keren, Michael Killough, Sun Kim, Jonathan Kimmitt, Olof
|
||||
Kindgren, Kevin Kiningham, Cameron Kirk, Dan Kirkham, Aleksander Kiryk,
|
||||
Sobhan Klnv, Gernot Koch, Jack Koenig, Soon Koh, Nathan Kohagen, Steve
|
||||
Kolecki, Brett Koonce, Will Korteland, Andrei Kostovski, Wojciech Koszek,
|
||||
Varun Koyyalagunta, Arkadiusz Kozdra, Markus Krause, David Kravitz, Adam
|
||||
Krolnik, Roland Kruse, Mahesh Kumashikar, Andreas Kuster, Sergey Kvachonok,
|
||||
Charles Eric LaForest, Kevin Laeufer, Ed Lander, Steve Lang, Pierre
|
||||
Laroche, Stephane Laurent, Walter Lavino, Christian Leber, David Ledger,
|
||||
Alex Lee, Larry Lee, Yoda Lee, Michaël Lefebvre, Dag Lem, Igor Lesik, John
|
||||
Li, Kay Li, Zixi Li, Davide Libenzi, Nandor Licker, Eivind Liland, Ícaro
|
||||
Lima, Kevin Lin, Yu-Sheng Lin, Charlie Lind, Andrew Ling, Jiuyang Liu, Joey
|
||||
Liu, Paul Liu, Derek Lockhart, Jake Longo, Arthur Low, Jose Loyola, Stefan
|
||||
Ludwig, Dan Lussier, Konstantin Lübeck, Fred Ma, Liwei Ma, Duraid Madina,
|
||||
Oleh Maksymenko, Affe Mao, Julien Margetts, Chick Markley, Alexis Marquet,
|
||||
Mark Marshall, Alfonso Martinez, Unai Martinez-Corral, Adrien Le Masle,
|
||||
Yves Mathieu, Vladimir Matveyenko, Patrick Maupin, Stan Mayer, Conor
|
||||
McCullough, Jason McMullan, Elliot Mednick, Yuan Mei, Andy Meier,
|
||||
Pawel Jewstafjew, Alexandre Joannou, James Johnson, Christophe Joly, Justin
|
||||
Jones, William D. Jones, Abe Jordan, Larry Darryl Lee Jr., Franck Jullien,
|
||||
James Jung, Mike Kagen, Arthur Kahlich, Kaalia Kahn, Guy-Armand Kamendje,
|
||||
Vasu Kandadi, Yoshitomo Kaneda, Kanad Kanhere, Patricio Kaplan, Pieter
|
||||
Kapsenberg, Rafal Kapuscik, Ralf Karge, Per Karlsson, Dan Katz, Sol
|
||||
Katzman, Ian Kennedy, Ami Keren, Fabian Keßler, Michael Killough, Sun Kim,
|
||||
Jonathan Kimmitt, Olof Kindgren, Kevin Kiningham, Cameron Kirk, Dan
|
||||
Kirkham, Aleksander Kiryk, Sobhan Klnv, Gernot Koch, Jack Koenig, Soon Koh,
|
||||
Nathan Kohagen, Steve Kolecki, Brett Koonce, Will Korteland, Andrei
|
||||
Kostovski, Wojciech Koszek, Varun Koyyalagunta, Arkadiusz Kozdra, Markus
|
||||
Krause, David Kravitz, Adam Krolnik, Roland Kruse, Mahesh Kumashikar,
|
||||
Andreas Kuster, Sergey Kvachonok, Charles Eric LaForest, Kevin Laeufer, Ed
|
||||
Lander, Steve Lang, Pierre Laroche, Stephane Laurent, Walter Lavino,
|
||||
Christian Leber, David Ledger, Alex Lee, Larry Lee, Yoda Lee, Michaël
|
||||
Lefebvre, Dag Lem, Igor Lesik, John Li, Kay Li, Zixi Li, Davide Libenzi,
|
||||
Nandor Licker, Eivind Liland, Ícaro Lima, Kevin Lin, Yu-Sheng Lin, Charlie
|
||||
Lind, Andrew Ling, Jiuyang Liu, Joey Liu, Paul Liu, Derek Lockhart, Jake
|
||||
Longo, Geza Lore, Arthur Low, Jose Loyola, Stefan Ludwig, Dan Lussier,
|
||||
Konstantin Lübeck, Fred Ma, Liwei Ma, Duraid Madina, Oleh Maksymenko, Affe
|
||||
Mao, Julien Margetts, Chick Markley, Alexis Marquet, Mark Marshall, Alfonso
|
||||
Martinez, Unai Martinez-Corral, Adrien Le Masle, Yves Mathieu, Vladimir
|
||||
Matveyenko, Patrick Maupin, Stan Mayer, Jordan McConnon, Conor McCullough,
|
||||
Jason McMullan, Elliot Mednick, Yuan Mei, Andy Meier, Luiza de Melo,
|
||||
Rodrigo A. Melo, Benjamin Menküc, Jake Merdich, David Metz, Wim Michiels,
|
||||
Miodrag Milanović, Darryl Miles, Kevin Millis, Andrew Miloradovsky, Wai Sum
|
||||
Mong, Peter Monsson, Sean Moore, Stuart Morris, Dennis Muhlestein, John
|
||||
Murphy, Matt Myers, Nathan Myers, Richard Myers, Alex Mykyta, Dimitris
|
||||
Nalbantis, Peter Nelson, Felix Neumärker, Bob Newgard, Cong Van Nguyen,
|
||||
Rachit Nigam, Toru Niina, Paul Nitza, Yossi Nivin, Pete Nixon, Lisa Noack,
|
||||
Mark Nodine, Michael Nolan, Andrew Nolte, Joseph Nwabueze, Kuba Ober,
|
||||
Andreas Olofsson, Baltazar Ortiz, Aleksander Osman, Don Owen, Tim Paine,
|
||||
Deepa Palaniappan, James Pallister, Vassilis Papaefstathiou, Sanggyu Park,
|
||||
Brad Parker, Risto Pejašinović, Morten Borup Petersen, Dan Petrisko, Wesley
|
||||
Piard, Maciej Piechotka, David Pierce, Cody Piersall, T. Platz, Michael
|
||||
Platzer, Dominic Plunkett, David Poole, Michael Popoloski, Roman Popov,
|
||||
Aylon Chaim Porat, Oron Port, Rich Porter, Rick Porter, Stefan Post,
|
||||
Niranjan Prabhu, Damien Pretet, Harald Pretl, Bill Pringlemeir, Usha
|
||||
Priyadharshini, Mark Jackson Pulver, Prateek Puri, Jiacheng Qian, Marshal
|
||||
Qiao, Raynard Qiao, Yujia Qiao, Jasen Qin, Frank Qiu, Nandu Raj, Kamil
|
||||
Rakoczy, Danilo Ramos, Drew Ranck, Chris Randall, Anton Rapp, Josh Redford,
|
||||
Odd Magne Reitan, Frédéric Requin, Dustin Richmond, Samuel Riedel, Alberto
|
||||
Del Rio, Eric Rippey, Oleg Rodionov, Ludwig Rogiers, Paul Rolfe, Michail
|
||||
Rontionov, Arjen Roodselaar, Tobias Rosenkranz, Yernagula Roshit, Ryszard
|
||||
Miodrag Milanović, Darryl Miles, Kevin Millis, Andrew Miloradovsky, David
|
||||
Moberg, Wai Sum Mong, Peter Monsson, Anthony Moore, Sean Moore, Stuart
|
||||
Morris, Dennis Muhlestein, John Murphy, Matt Myers, Nathan Myers, Richard
|
||||
Myers, Alex Mykyta, Eric Müller, Dimitris Nalbantis, Peter Nelson, Felix
|
||||
Neumärker, Bob Newgard, Cong Van Nguyen, Rachit Nigam, Toru Niina, Paul
|
||||
Nitza, Yossi Nivin, Pete Nixon, Lisa Noack, Mark Nodine, Michael Nolan,
|
||||
Andrew Nolte, Joseph Nwabueze, Kevin Nygaard, Kuba Ober, Krzysztof
|
||||
Obłonczek, Andreas Olofsson, Baltazar Ortiz, Aleksander Osman, Don Owen,
|
||||
Tim Paine, Deepa Palaniappan, James Pallister, Vassilis Papaefstathiou,
|
||||
Sanggyu Park, Brad Parker, Risto Pejašinović, Seth Pellegrino, Morten Borup
|
||||
Petersen, Dan Petrisko, Wesley Piard, Maciej Piechotka, David Pierce, Cody
|
||||
Piersall, T. Platz, Michael Platzer, Dominic Plunkett, Nolan Poe, David
|
||||
Poole, Michael Popoloski, Roman Popov, Aylon Chaim Porat, Oron Port, Rich
|
||||
Porter, Rick Porter, Stefan Post, Niranjan Prabhu, Damien Pretet, Harald
|
||||
Pretl, Bill Pringlemeir, Usha Priyadharshini, Mark Jackson Pulver, Prateek
|
||||
Puri, Han Qi, Jiacheng Qian, Marshal Qiao, Raynard Qiao, Yujia Qiao, Jasen
|
||||
Qin, Frank Qiu, Nandu Raj, Kamil Rakoczy, Danilo Ramos, Drew Ranck, Chris
|
||||
Randall, Anton Rapp, Josh Redford, Odd Magne Reitan, Frédéric Requin,
|
||||
Dustin Richmond, Samuel Riedel, Alberto Del Rio, Eric Rippey, Narcis Rodas,
|
||||
Oleg Rodionov, Ludwig Rogiers, Paul Rolfe, Michail Rontionov, Arjen
|
||||
Roodselaar, Arthur Rosa, Tobias Rosenkranz, Yernagula Roshit, Ryszard
|
||||
Rozak, Huang Rui, Graham Rushton, Jan Egil Ruud, Denis Rystsov, Pawel
|
||||
Sagan, Robert Sammelson, John Sanguinetti, Josep Sans, Luca Sasselli,
|
||||
Martin Scharrer, Martin Schmidt, Julie Schwartz, Galen Seitz, Joseph
|
||||
Shaker, Mark Shaw, Salman Sheikh, Zhou Shen, Hao Shi, James Shi, Michael
|
||||
Shinkarovsky, Rafael Shirakawa, Jeffrey Short, S Shuba, Fan Shupei, Ethan
|
||||
Sifferman, Anderson Ignacio da Silva, Rodney Sinclair, Ameya Vikram Singh,
|
||||
Sanjay Singh, Frans Skarman, Nate Slager, Steven Slatter, Mladen
|
||||
Slijepcevic, Brian Small, Garrett Smith, Gus Smith, Tim Snyder, Maciej
|
||||
Sobkowski, Stan Sokorac, Alex Solomatnikov, Flavien Solt, Wei Song, Trefor
|
||||
Southwell, Martin Stadler, Art Stamness, David Stanford, John Stevenson,
|
||||
Pete Stevenson, Patrick Stewart, Rob Stoddard, Tood Strader, John Stroebel,
|
||||
Ray Strouble, Sven Stucki, Howard Su, Emerson Suguimoto, Gene Sullivan,
|
||||
Qingyao Sun, Renga Sundararajan, Kuba Sunderland-Ober, Gustav Svensk,
|
||||
Rupert Swarbrick, Jevin Sweval, Shinya T-Y, Thierry Tambe, Jesse Taube,
|
||||
Drew Taussig, Jose Tejada, Sören Tempel, Peter Tengstrand, Wesley Terpstra,
|
||||
Rui Terra, Stefan Thiede, Justin Thiel, Gary Thomas, Ian Thompson, Kevin
|
||||
Thompson, Mike Thyer, Hans Tichelaar, Tudor Timi, Viktor Tomov, Steve Tong,
|
||||
Topa Topino, Àlex Torregrosa, Topa Tota, Michael Tresidder, Lenny Truong,
|
||||
David Turner, Neil Turton, Hideto Ueno, Mike Urbach, Joel Vandergriendt,
|
||||
Srini Vemuri, Srinivasan Venkataramanan, Yuri Victorovich, Ivan Vnučec,
|
||||
Bogdan Vukobratovic, Holger Waechtler, Philipp Wagner, Johannes Walter, CY
|
||||
Wang, Chuxuan Wang, Shawn Wang, Zhanglei Wang, Greg Waters, Thomas Watts,
|
||||
Eugene Weber, John Wehle, Tianrui Wei, David Welch, Thomas J Whatson,
|
||||
Martin Whitaker, Marco Widmer, Leon Wildman, Daniel S. Wilkerson, Daniel
|
||||
Wilkerson, Gerald Williams, Trevor Williams, Don Williamson, Jan Van
|
||||
Winkel, Jeff Winston, Joshua Wise, Clifford Wolf, Johan Wouters, Paul
|
||||
Wright, Tobias Wölfel, Junyi Xi, Ding Xiaoliang, Liu Xiaoyi, Mandy Xu,
|
||||
Shanshan Xu, Yinan Xu, SU YANG, Felix Yan, Luke Yang, Amir Yazdanbakhsh,
|
||||
Chentai (Seven) Yuan, Florian Zaruba, Mat Zeno, Keyi Zhang, Xi Zhang, Yike
|
||||
Zhou, Jiamin Zhu.
|
||||
Sagan, Robert Sammelson, Adrian Sampson, John Sanguinetti, Josep Sans, Luca
|
||||
Sasselli, Martin Scharrer, Martin Schmidt, Jonathan Schröter, Julie
|
||||
Schwartz, Galen Seitz, Sam Shahrestani, Joseph Shaker, Mark Shaw, Salman
|
||||
Sheikh, Zhou Shen, Hao Shi, James Shi, Michael Shinkarovsky, Rafael
|
||||
Shirakawa, Jeffrey Short, S Shuba, Fan Shupei, Ethan Sifferman, Anderson
|
||||
Ignacio da Silva, Rodney Sinclair, Ameya Vikram Singh, Sanjay Singh, Frans
|
||||
Skarman, Nate Slager, Steven Slatter, Mladen Slijepcevic, Brian Small,
|
||||
Garrett Smith, Gus Smith, Tim Snyder, Maciej Sobkowski, Stan Sokorac, Alex
|
||||
Solomatnikov, Flavien Solt, Wei Song, Trefor Southwell, Martin Stadler, Art
|
||||
Stamness, David Stanford, Krzysztof Starecki, Baruch Sterin, John
|
||||
Stevenson, Pete Stevenson, Patrick Stewart, Rob Stoddard, Tood Strader,
|
||||
John Stroebel, Ray Strouble, Sven Stucki, Howard Su, Udaya Raj Subedi,
|
||||
Emerson Suguimoto, Gene Sullivan, Qingyao Sun, Renga Sundararajan, Kuba
|
||||
Sunderland-Ober, Gustav Svensk, Rupert Swarbrick, Jevin Sweval, Paul
|
||||
Swirhun, Shinya T-Y, Thierry Tambe, Jesse Taube, Drew Taussig, Christopher
|
||||
Taylor, Greg Taylor, Jose Tejada, Sören Tempel, Peter Tengstrand, Wesley
|
||||
Terpstra, Rui Terra, Stefan Thiede, Justin Thiel, Gary Thomas, Ian
|
||||
Thompson, Kevin Thompson, Mike Thyer, Hans Tichelaar, Tudor Timi, Viktor
|
||||
Tomov, Steve Tong, Topa Topino, Àlex Torregrosa, Topa Tota, Michael
|
||||
Tresidder, Lenny Truong, David Turner, Neil Turton, Hideto Ueno, Mike
|
||||
Urbach, Joel Vandergriendt, Srini Vemuri, Srinivasan Venkataramanan, Yuri
|
||||
Victorovich, Ivan Vnučec, Bogdan Vukobratovic, Holger Waechtler, Philipp
|
||||
Wagner, Stefan Wallentowitz, Johannes Walter, CY Wang, Chuxuan Wang, Shawn
|
||||
Wang, Yilou Wang, Zhanglei Wang, Greg Waters, Thomas Watts, Eugene Weber,
|
||||
John Wehle, Tianrui Wei, David Welch, Thomas J Whatson, Martin Whitaker,
|
||||
Marco Widmer, Leon Wildman, Daniel S. Wilkerson, Daniel Wilkerson, Gerald
|
||||
Williams, Trevor Williams, Don Williamson, Jan Van Winkel, Jeff Winston,
|
||||
Joshua Wise, Clifford Wolf, Johan Wouters, Paul Wright, Tobias Wölfel,
|
||||
Junyi Xi, Ding Xiaoliang, Liu Xiaoyi, Jinyan Xu, Mandy Xu, Pengcheng Xu,
|
||||
Shanshan Xu, Yan Xu, Yinan Xu, SU YANG, Felix Yan, Jiaxun Yang, Luke Yang,
|
||||
Amir Yazdanbakhsh, Chentai (Seven) Yuan, Florian Zaruba, Mat Zeno, Keyi
|
||||
Zhang, Xi Zhang, Huanghuang Zhou, Yike Zhou, Jiamin Zhu, Ryan Ziegler.
|
||||
|
||||
Thanks to them, and all those we've missed mentioning above, and to those
|
||||
whom have wished to remain anonymous.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
*********
|
||||
@@ -8,7 +8,7 @@ Copyright
|
||||
The latest version of Verilator is available from `https://verilator.org
|
||||
<https://verilator.org>`_.
|
||||
|
||||
Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
can redistribute it and/or modify the Verilator internals under the terms
|
||||
of either the GNU Lesser General Public License Version 3 or the Perl
|
||||
Artistic License Version 2.0.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
Deprecations
|
||||
@@ -12,8 +12,11 @@ C++14 compiler support
|
||||
Verilated models with --no-timing.
|
||||
|
||||
Verilator will require C++20 or newer compilers for both compiling
|
||||
Verilator and compiling all Verilated models no sooner than January 2025.
|
||||
Verilator and compiling all Verilated models no sooner than May 2025.
|
||||
(Likely to be removed shortly after GitHub removes Ubuntu 20.04
|
||||
continuous-integration action runners, which are used to test the older
|
||||
C++ standard).
|
||||
|
||||
XML output
|
||||
Verilator currently supports XML parser output (enabled with `--xml-only`).
|
||||
Support for `--xml-*` options will be deprecated no sooner than January 2025.
|
||||
Support for `--xml-*` options will be deprecated no sooner than January 2026.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
Environment
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Example Create-Binary Execution:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Example C++ Execution:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
First you need Verilator installed, see :ref:`Installation`. In brief, if
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Examples in the Distribution:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Example SystemC Execution:
|
||||
@@ -28,6 +28,7 @@ Now, let's create an example Verilog, and SystemC wrapper file:
|
||||
|
||||
cat >sc_main.cpp <<'EOF'
|
||||
#include "Vour.h"
|
||||
using namespace sc_core;
|
||||
int sc_main(int argc, char** argv) {
|
||||
Verilated::commandArgs(argc, argv);
|
||||
sc_clock clk{"clk", 10, SC_NS, 0.5, 3, SC_NS, true};
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Examples:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Simulation Runtime Arguments:
|
||||
@@ -40,8 +40,8 @@ Summary:
|
||||
.. option:: +verilator+error+limit+<value>
|
||||
|
||||
Set number of non-fatal errors (e.g. assertion failures) before exiting
|
||||
simulation runtime. Also affects number of $stop calls needed before
|
||||
exit. Defaults to 1.
|
||||
simulation runtime. Also affects number of `$stop` calls needed before
|
||||
exit. Does not affect `$fatal`. Defaults to 1.
|
||||
|
||||
.. option:: +verilator+help
|
||||
|
||||
|
||||
+163
-59
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
verilator Arguments
|
||||
@@ -237,7 +237,17 @@ Summary:
|
||||
.. option:: --coverage
|
||||
|
||||
Enables all forms of coverage, an alias for :vlopt:`--coverage-line`
|
||||
:vlopt:`--coverage-toggle` :vlopt:`--coverage-user`.
|
||||
:vlopt:`--coverage-toggle` :vlopt:`--coverage-expr` :vlopt:`--coverage-user`.
|
||||
|
||||
.. option:: --coverage-expr
|
||||
|
||||
Enables expression coverage analysis. See :ref:`Expression Coverage`.
|
||||
|
||||
.. option:: --coverage-expr-max <value>
|
||||
|
||||
Rarely needed. Specifies the maximum number of permutations able to be
|
||||
covered for a given expression. Defaults to 32. Increasing may slow
|
||||
coverage simulations and make analyzing the results unwieldy.
|
||||
|
||||
.. option:: --coverage-line
|
||||
|
||||
@@ -480,8 +490,8 @@ Summary:
|
||||
out. Beware of enabling debugging messages, as they will also go to
|
||||
standard out. See :vlopt:`--no-std`, which is implied by this.
|
||||
|
||||
See also :vlopt:`--dump-defines`, :vlopt:`-P`, and
|
||||
:vlopt:`--pp-comments` options.
|
||||
See also :vlopt:`--dump-defines`, :vlopt:`-P`, :vlopt:`--pp-comments`
|
||||
and :vlopt:`--preproc-resolve` options.
|
||||
|
||||
.. option:: --emit-accessors
|
||||
|
||||
@@ -589,10 +599,18 @@ Summary:
|
||||
|
||||
.. option:: -fno-expand
|
||||
|
||||
.. option:: -fno-func-opt
|
||||
|
||||
.. option:: -fno-func-opt-balance-cat
|
||||
|
||||
.. option:: -fno-func-opt-split-cat
|
||||
|
||||
.. option:: -fno-gate
|
||||
|
||||
.. option:: -fno-inline
|
||||
|
||||
.. option:: -fno-inline-funcs
|
||||
|
||||
.. option:: -fno-life
|
||||
|
||||
.. option:: -fno-life-post
|
||||
@@ -609,6 +627,8 @@ Summary:
|
||||
|
||||
.. option:: -fno-reorder
|
||||
|
||||
.. option:: -fno-slice
|
||||
|
||||
.. option:: -fno-split
|
||||
|
||||
.. option:: -fno-subst
|
||||
@@ -741,7 +761,10 @@ Summary:
|
||||
|
||||
.. option:: +incdir+<dir>
|
||||
|
||||
See :vlopt:`-y`.
|
||||
See :vlopt:`-y`. Unlike with :vlopt:`-y`, multiple directories may be
|
||||
specified separated with a `+` symbol; this is for Verilog-XL
|
||||
compatibility and is not recommended usage as this is not supported by
|
||||
some third-party tools.
|
||||
|
||||
.. option:: --inline-mult <value>
|
||||
|
||||
@@ -769,6 +792,38 @@ Summary:
|
||||
the number of threads in the current hardware. Otherwise, must be a
|
||||
positive integer specifying the maximum number of parallel build jobs.
|
||||
|
||||
.. option:: --json-only
|
||||
|
||||
Create JSON output only, do not create any other output.
|
||||
|
||||
The JSON format is intended to be used to leverage Verilator's parser and
|
||||
elaboration to feed to other downstream tools. For details on the format, see
|
||||
the Verilator Internals manual. Be aware that the JSON
|
||||
format is still evolving; there will be some changes in future versions.
|
||||
|
||||
This option disables some more aggressive transformations and dumps only
|
||||
the final state of the AST. For more granular and unaltered dumps, meant
|
||||
mainly for debugging see :vlopt:`--dump-tree-json`.
|
||||
|
||||
.. option:: --json-only-meta-output <filename>
|
||||
|
||||
Specifies the filename for the metadata output file (`.tree.meta.json`) of --json-only.
|
||||
Using this option automatically sets :vlopt:`--json-only`.
|
||||
|
||||
.. option:: --json-only-output <filename>
|
||||
|
||||
Specifies the filename for the main output file (`.tree.json`) of --json-only.
|
||||
Using this option automatically sets :vlopt:`--json-only`.
|
||||
|
||||
.. option:: --no-json-edit-nums
|
||||
|
||||
Don't dump edit number in .tree.json files. This may make the file more
|
||||
run-to-run stable for easier comparison.
|
||||
|
||||
.. option:: --no-json-ids
|
||||
|
||||
Don't use short identifiers instead of addresses/paths in .tree.json.
|
||||
|
||||
.. option:: --l2-name <value>
|
||||
|
||||
Instead of using the module name when showing Verilog scope, use the
|
||||
@@ -958,6 +1013,22 @@ Summary:
|
||||
delayed assignments. This option should only be used when suggested by
|
||||
the developers.
|
||||
|
||||
.. option:: --output-groups <numfiles>
|
||||
|
||||
Enables concatenating the output .cpp files into the given number of
|
||||
effective output .cpp files. This is useful if the compiler startup
|
||||
overhead from compiling many small files becomes unacceptable,
|
||||
which can happen in designs making extensive use of SystemVerilog classes,
|
||||
templates or generate blocks.
|
||||
|
||||
Using :vlopt:`--output-groups` can adversely impact caching and stability
|
||||
(as in reproducibility) of compiled code. Compilation of larger .cpp
|
||||
files also has higher memory requirements. Too low values might result in
|
||||
swap thrashing with large designs, high values give no benefits. The
|
||||
value should range from 2 to 20 for small to medium designs.
|
||||
|
||||
Default is zero, which disables this feature.
|
||||
|
||||
.. option:: --output-split <statements>
|
||||
|
||||
Enables splitting the output .cpp files into multiple outputs. When a
|
||||
@@ -1081,6 +1152,20 @@ Summary:
|
||||
prepended to the name of the :vlopt:`--top` option, or V prepended to
|
||||
the first Verilog filename passed on the command line.
|
||||
|
||||
.. option:: --preproc-resolve
|
||||
|
||||
With :vlopt:`-E`, resolve referenced instance modules, to include
|
||||
preprocessed output of submodules. Used to convert a multi-file design
|
||||
into a single output file.
|
||||
|
||||
See :vlopt:`-E`.
|
||||
|
||||
.. option:: --preproc-token-limit <value>
|
||||
|
||||
Rarely needed. Configure the limit of the number of tokens Verilator
|
||||
can process on a single line to prevent infinite loops and other hangs.
|
||||
Defaults to 40000 tokens.
|
||||
|
||||
.. option:: --private
|
||||
|
||||
Opposite of :vlopt:`--public`. This is the default; this option exists for
|
||||
@@ -1182,6 +1267,13 @@ Summary:
|
||||
module specifically enabled it with
|
||||
:option:`/*verilator&32;inline_module*/`.
|
||||
|
||||
|
||||
.. option:: --public-depth <level>
|
||||
|
||||
Enables public as with :vlopt:`--public-flat-rw`, but only to the specified depth of modules.
|
||||
It operates at the module maximum level, so if a module's cells are A.B.X and A.X, the
|
||||
a --public-depth 3 must be used to make module X public, and both A.B.X and A.X will be public.
|
||||
|
||||
.. option:: --public-flat-rw
|
||||
|
||||
Declares all variables, ports, and wires public as if they had
|
||||
@@ -1193,11 +1285,12 @@ Summary:
|
||||
marking only those signals that need public_flat_rw is typically
|
||||
significantly better performing.
|
||||
|
||||
.. option:: --public-depth <level>
|
||||
.. option:: --public-ignore
|
||||
|
||||
Enables public as with :vlopt:`--public-flat-rw`, but only to the specified depth of modules.
|
||||
It operates at the module maximum level, so if a module's cells are A.B.X and A.X, the
|
||||
a --public-depth 3 must be used to make module X public, and both A.B.X and A.X will be public.
|
||||
Ignore all :code:`/*verilator public* */` metacomments. This is useful
|
||||
for speed-optimizing VPI builds where VPI is not being used. This only
|
||||
affects metacomments; options such as :vlopt:`--public`,
|
||||
:vlopt:`--public-depth`, etc. work normally.
|
||||
|
||||
.. option:: --public-params
|
||||
|
||||
@@ -1205,6 +1298,7 @@ Summary:
|
||||
:code:`/*verilator public_flat_rd*/`
|
||||
metacomments.
|
||||
|
||||
|
||||
.. option:: -pvalue+<name>=<value>
|
||||
|
||||
Overwrites the given parameter(s) of the top-level module. See
|
||||
@@ -1341,7 +1435,17 @@ Summary:
|
||||
|
||||
.. option:: --no-std
|
||||
|
||||
Prevents parsing standard library.
|
||||
Prevents parsing standard input files, alias for
|
||||
:vlopt:`--no-std-package`, :vlopt:`--no-std-waiver`. This may be extended
|
||||
to prevent reading other standardized files in future versions.
|
||||
|
||||
.. option:: --no-std-package
|
||||
|
||||
Prevents parsing standard `std::` package file.
|
||||
|
||||
.. option:: --no-std-waiver
|
||||
|
||||
Prevents parsing standard lint waivers (`verilated_std_waiver.vlt`).
|
||||
|
||||
.. option:: --no-stop-fail
|
||||
|
||||
@@ -1621,6 +1725,15 @@ Summary:
|
||||
|
||||
Enable the use of VPI and linking against the :file:`verilated_vpi.cpp` files.
|
||||
|
||||
.. option:: --waiver-multiline
|
||||
|
||||
When using :vlopt:`--waiver-output \<filename\> <--waiver-output>`,
|
||||
include a match expression that includes the entire multiline error
|
||||
message as a match regular expression, as opposed to the default of only
|
||||
matching the first line of the error message. This provides a starting
|
||||
point for creating complex waivers, but such generated waivers will
|
||||
likely require editing for brevity before being reused.
|
||||
|
||||
.. option:: --waiver-output <filename>
|
||||
|
||||
Generate a waiver file that contains all waiver statements to suppress
|
||||
@@ -1725,18 +1838,19 @@ Summary:
|
||||
``-Wwarn-CASEX`` ``-Wwarn-CASTCONST`` ``-Wwarn-CMPCONST``
|
||||
``-Wwarn-COLONPLUS`` ``-Wwarn-IMPLICIT`` ``-Wwarn-IMPLICITSTATIC``
|
||||
``-Wwarn-LATCH`` ``-Wwarn-MISINDENT`` ``-Wwarn-NEWERSTD``
|
||||
``-Wwarn-PINMISSING`` ``-Wwarn-REALCVT`` ``-Wwarn-STATICVAR``
|
||||
``-Wwarn-UNSIGNED`` ``-Wwarn-WIDTHTRUNC`` ``-Wwarn-WIDTHEXPAND``
|
||||
``-Wwarn-WIDTHXZEXPAND``.
|
||||
``-Wwarn-PREPROCZERO`` ``-Wwarn-PINMISSING`` ``-Wwarn-REALCVT``
|
||||
``-Wwarn-STATICVAR`` ``-Wwarn-UNSIGNED`` ``-Wwarn-WIDTHTRUNC``
|
||||
``-Wwarn-WIDTHEXPAND`` ``-Wwarn-WIDTHXZEXPAND``.
|
||||
|
||||
.. option:: -Wwarn-style
|
||||
|
||||
Enable all code style-related warning messages. This is equivalent to
|
||||
``-Wwarn-ASSIGNDLY`` ``-Wwarn-DECLFILENAME`` ``-Wwarn-DEFPARAM``
|
||||
``-Wwarn-EOFNEWLINE`` ``-Wwarn-GENUNNAMED`` ``-Wwarn-INCABSPATH``
|
||||
``-Wwarn-ASSIGNDLY`` ``-Wwarn-BLKSEQ`` ``-Wwarn-DECLFILENAME``
|
||||
``-Wwarn-DEFPARAM`` ``-Wwarn-EOFNEWLINE`` ``-Wwarn-GENUNNAMED``
|
||||
``-Wwarn-IMPORTSTAR`` ``-Wwarn-INCABSPATH`` ``-Wwarn-PINCONNECTEMPTY``
|
||||
``-Wwarn-PINNOCONNECT`` ``-Wwarn-SYNCASYNCNET`` ``-Wwarn-UNDRIVEN``
|
||||
``-Wwarn-UNUSEDGENVAR`` ``-Wwarn-UNUSEDPARAM`` ``-Wwarn-UNUSEDSIGNAL``
|
||||
``-Wwarn-VARHIDDEN``.
|
||||
``-Wwarn-UNUSEDGENVAR`` ``-Wwarn-UNUSEDLOOP`` ``-Wwarn-UNUSEDPARAM``
|
||||
``-Wwarn-UNUSEDSIGNAL`` ``-Wwarn-VARHIDDEN``.
|
||||
|
||||
.. option:: --x-assign 0
|
||||
|
||||
@@ -1835,38 +1949,6 @@ Summary:
|
||||
iterations. This may be another indication of problems with the
|
||||
modeled design that should be addressed.
|
||||
|
||||
.. option:: --json-only
|
||||
|
||||
Create JSON output only, do not create any other output.
|
||||
|
||||
The JSON format is intended to be used to leverage Verilator's parser and
|
||||
elaboration to feed to other downstream tools. For details on the format, see
|
||||
the Verilator Internals manual. Be aware that the JSON
|
||||
format is still evolving; there will be some changes in future versions.
|
||||
|
||||
This option disables some more aggressive transformations and dumps only
|
||||
the final state of the AST. For more granular and unaltered dumps, meant
|
||||
mainly for debugging see :vlopt:`--dump-tree-json`.
|
||||
|
||||
.. option:: --json-only-meta-output <filename>
|
||||
|
||||
Specifies the filename for the metadata output file (`.tree.meta.json`) of --json-only.
|
||||
Using this option automatically sets :vlopt:`--json-only`.
|
||||
|
||||
.. option:: --json-only-output <filename>
|
||||
|
||||
Specifies the filename for the main output file (`.tree.json`) of --json-only.
|
||||
Using this option automatically sets :vlopt:`--json-only`.
|
||||
|
||||
.. option:: --no-json-edit-nums
|
||||
|
||||
Don't dump edit number in .tree.json files. This may make the file more
|
||||
run-to-run stable for easier comparison.
|
||||
|
||||
.. option:: --no-json-ids
|
||||
|
||||
Don't use short identifiers instead of addresses/paths in .tree.json.
|
||||
|
||||
.. option:: --xml-only
|
||||
|
||||
Create XML output only, do not create any other output.
|
||||
@@ -1909,8 +1991,12 @@ Configuration Files
|
||||
|
||||
In addition to the command line, warnings and other features for the
|
||||
:command:`verilator` command may be controlled with configuration files,
|
||||
typically named with the .vlt extension (what makes it a configuration file
|
||||
is the :option:`\`verilator_config` directive). An example:
|
||||
typically named with the `.vlt` extension (what makes it a configuration
|
||||
file is the :option:`\`verilator_config` directive). These files, when
|
||||
named `.vlt`, are read before source code files; if this behavior is
|
||||
undesired, name the config file with a `.v` suffix.
|
||||
|
||||
An example:
|
||||
|
||||
.. code-block:: sv
|
||||
|
||||
@@ -2047,7 +2133,7 @@ The grammar of configuration commands is as follows:
|
||||
|
||||
.. option:: lint_off [-rule <message>] [-file "<filename>" [-lines <line> [ - <line>]]]
|
||||
|
||||
.. option:: lint_off [-rule <message>] [-file "<filename>"] [-match "<string>"]
|
||||
.. option:: lint_off [-rule <message>] [-file "<filename>"] [-contents "<wildcard>"] [-match "<wildcard>"]
|
||||
|
||||
Enable/disables the specified lint warning, in the specified filename
|
||||
(or wildcard with '\*' or '?', or all files if omitted) and range of
|
||||
@@ -2056,17 +2142,28 @@ The grammar of configuration commands is as follows:
|
||||
With lint_off using "\*" will override any lint_on directives in the
|
||||
source, i.e. the warning will still not be printed.
|
||||
|
||||
If the -rule is omitted, all lint warnings (see list in
|
||||
If the :code:`-rule` is omitted, all lint warnings (see list in
|
||||
:vlopt:`-Wno-lint`) are enabled/disabled. This will override all later
|
||||
lint warning enables for the specified region.
|
||||
|
||||
If -match is set, the linter warnings are matched against this
|
||||
(wildcard) string and are waived in case they match, provided with the
|
||||
rule and file also match.
|
||||
If :code:`-contents` is provided, the input files must contain the given
|
||||
wildcard (with '\*' or '?'), and are waived in case they match, provided
|
||||
the :code:`-rule`, :code:`-file`, and :code:`-contents` also match. The
|
||||
wildcard should be designed to match a single line; it is unspecified if
|
||||
the wildcard is allowed to match across multiple lines. The input
|
||||
contents does not include :vlopt:`--std <--no-std>` standard files, nor
|
||||
configuration files (with :code:`verilator_config`). Typical use for
|
||||
this is to match a version number present in the Verilog sources, so
|
||||
that the waiver will only apply to that version of the sources.
|
||||
|
||||
In previous versions -rule was named -msg. The latter is deprecated, but
|
||||
still works with a deprecation info; it may be removed in future
|
||||
versions.
|
||||
If :code:`-match` is provided, the linter warnings are matched against
|
||||
the given wildcard (with '\*' or '?'), and are waived in case they
|
||||
match, provided the :code:`-rule`, :code:`-file`, and :code:`-contents`
|
||||
also match. The wildcard is compared across the entire multi-line
|
||||
message; see :vlopt:`--waiver-multiline`.
|
||||
|
||||
Before version 4.026, :code:`-rule` was named :code:`-msg`, and
|
||||
:code:`-msg` remained a deprecated alias until Version 5.000.
|
||||
|
||||
.. option:: public [-module "<modulename>"] [-task/-function "<taskname>"] -var "<signame>"
|
||||
|
||||
@@ -2081,6 +2178,13 @@ The grammar of configuration commands is as follows:
|
||||
:option:`/*verilator&32;public_flat*/`, etc., metacomments. See
|
||||
also :ref:`VPI Example`.
|
||||
|
||||
.. option:: profile_data -hier-dpi "<function_name>" -cost <cost_value>
|
||||
|
||||
Internal profiling data inserted during :vlopt:`--hierarchical`; specifies
|
||||
execution cost of a hierarchical DPI wrappers for modules with
|
||||
:option:`/*verilator&32;hier_block*/` metacomment. See
|
||||
:ref:`Hierarchical Verilation`.
|
||||
|
||||
.. option:: profile_data -mtask "<mtask_hash>" -cost <cost_value>
|
||||
|
||||
Feeds profile-guided optimization data into the Verilator algorithms in
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
verilator_coverage
|
||||
@@ -35,11 +35,11 @@ verilator_coverage Example Usage
|
||||
verilator_coverage --help
|
||||
verilator_coverage --version
|
||||
|
||||
verilator_coverage --annotate <obj>
|
||||
verilator_coverage --annotate obj_dir coverage.dat
|
||||
|
||||
verilator_coverage -write merged.dat <datafiles>...
|
||||
verilator_coverage --write merged.dat coverage.dat ...
|
||||
|
||||
verilator_coverage -write-info merged.info <datafiles>...
|
||||
verilator_coverage --write-info merged.info coverage.dat ...
|
||||
|
||||
|
||||
verilator_coverage Arguments
|
||||
@@ -58,32 +58,36 @@ to read multiple inputs. If no data file is specified, by default,
|
||||
Specifies the directory name to which source files with annotated coverage
|
||||
data should be written.
|
||||
|
||||
Converting from the Verilator coverage data format to the info format is
|
||||
lossy; the info will have all forms of coverage merged line coverage, and
|
||||
if there are multiple coverage points on a single line they will merge.
|
||||
The minimum coverage across all merged points will be used to report
|
||||
coverage of the line.
|
||||
Points are children of each line coverage- branches, expressions or toggle points.
|
||||
When point counts are aggregated into a line, the minimum and maximum counts
|
||||
are used to determine the status of the line (complete, partial, failing)
|
||||
The count is equal to the maximum of the points.
|
||||
|
||||
Coverage data is annotated at the beginning of the line and is formatted
|
||||
as a special character followed by the number of coverage hits. The special
|
||||
characters " ,%,+,-" indicate summary of the coverage, and allow use of grep
|
||||
characters " ,%,~,+,-" indicate summary of the coverage, and allow use of grep
|
||||
to filter the report.
|
||||
|
||||
* " " (whitespace) indicates that all points on the line are above the coverage limit.
|
||||
* "%" indicates at least one point on the line was below the coverage limit.
|
||||
* "+" coverage point was at or above the limit. Only used with :option:`--annotate-points`.
|
||||
* "-" coverage point was below the limit. Only used with :option:`--annotate-points`.
|
||||
* " " (whitespace) indicates that all points on the line are above the coverage min.
|
||||
* "%" indicates that all points on the line are below the coverage min.
|
||||
* "~" indicates that some points on the line are above the coverage min and some are below.
|
||||
* "+" coverage point was at or above the min. Only used with :option:`--annotate-points`.
|
||||
* "-" coverage point was below the min. Only used with :option:`--annotate-points`.
|
||||
|
||||
.. code-block::
|
||||
|
||||
100000 input logic a; // Begins with whitespace, because
|
||||
// number of hits (100000) is above the limit.
|
||||
+100000 point: comment=a // Begins with +, because
|
||||
// number of hits (100000) is above the limit.
|
||||
%000000 input logic b; // Begins with %, because
|
||||
// number of hits (0) is below the limit.
|
||||
-000000 point: comment=b // Begins with -, because
|
||||
// number of hits (0) is below the limit.
|
||||
100000 input logic a; // Begins with whitespace, because
|
||||
// number of hits (100000) is above the min.
|
||||
+100000 point: comment=a // Begins with +, because
|
||||
// number of hits (100000) is above the min.
|
||||
%000000 input logic b; // Begins with %, because
|
||||
// number of hits (0) is below the min.
|
||||
-000000 point: comment=b // Begins with -, because
|
||||
// number of hits (0) is below the min.
|
||||
~000010 if (cyc!=0) begin // Begins with ~, because
|
||||
// branches are below and above the min.
|
||||
+000010 point: comment=if // The if branch is above the min.
|
||||
-000000 point: comment=else // The else branch is below the min.
|
||||
|
||||
.. option:: --annotate-all
|
||||
|
||||
@@ -154,10 +158,7 @@ generated from random test runs) into one master coverage file.
|
||||
Specifies the aggregate coverage results, summed across all the files,
|
||||
should be written to the given filename in :command:`lcov` .info format.
|
||||
This may be used to feed into :command:`lcov` to aggregate or generate
|
||||
reports.
|
||||
|
||||
Converting from the Verilator coverage data format to the info format is
|
||||
lossy; the info will have all forms of coverage merged line coverage, and
|
||||
if there are multiple coverage points on a single line they will merge.
|
||||
The minimum coverage across all merged points will be used to report
|
||||
coverage of the line.
|
||||
reports. This format lacks the comments for cover points that the
|
||||
verilator_coverage format has. It can be used with :command:`genhtml`
|
||||
to generate an HTML report. :command:`genhtml --branch-coverage` will
|
||||
also display the branch coverage, analogous to :option:`--annotate-points`
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
verilator_gantt
|
||||
@@ -62,6 +62,17 @@ predicted_thread#_mtask
|
||||
executing.
|
||||
|
||||
|
||||
verilator_gantt Example Usage
|
||||
-----------------------------
|
||||
|
||||
..
|
||||
|
||||
verilator_gantt --help
|
||||
verilator_gantt --version
|
||||
|
||||
verilator_gantt profile_exec.dat
|
||||
|
||||
|
||||
verilator_gantt Arguments
|
||||
-------------------------
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
verilator_profcfunc
|
||||
@@ -15,6 +15,17 @@ reported as a rounding error.
|
||||
|
||||
For an overview of the use of verilator_profcfunc, see :ref:`Profiling`.
|
||||
|
||||
verilator_profcfunc Example Usage
|
||||
---------------------------------
|
||||
|
||||
..
|
||||
|
||||
verilator_profcfunc --help
|
||||
verilator_profcfunc --version
|
||||
|
||||
verilator_profcfunc gprof.out
|
||||
|
||||
|
||||
verilator_profcfunc Arguments
|
||||
-----------------------------
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
*********************************
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
*******************
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
******************************
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
*****
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
######################
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _CMakeInstallation:
|
||||
|
||||
+39
-20
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Installation:
|
||||
@@ -19,13 +19,33 @@ started. (Note packages are unlikely to have the most recent version, so
|
||||
:ref:`Git Install` might be a better alternative.) To install as a
|
||||
package:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
apt-get install verilator # On Ubuntu
|
||||
|
||||
For other distributions, refer to `Repology Verilator Distro Packages
|
||||
<https://repology.org/project/verilator>`__.
|
||||
|
||||
.. _pre-commit Quick Install:
|
||||
|
||||
pre-commit Quick Install
|
||||
=============================
|
||||
|
||||
You can use Verilator's `pre-commit <https://pre-commit.com/>`__ hook to
|
||||
lint your code before committing it. It encapsulates the :ref:`Verilator
|
||||
Build Docker Container`, so you need docker on your system to use it. The
|
||||
verilator image will be downloaded automatically.
|
||||
|
||||
To use the hook, add the following entry to your :code:`.pre-commit-config.yaml`:
|
||||
|
||||
.. code-block:: yaml
|
||||
|
||||
repos:
|
||||
- repo: https://github.com/verilator/verilator
|
||||
rev: v5.026 # or later
|
||||
hooks:
|
||||
- id: verilator
|
||||
|
||||
.. _Git Install:
|
||||
|
||||
Git Quick Install
|
||||
@@ -36,7 +56,7 @@ options and details, see :ref:`Detailed Build Instructions` below.
|
||||
|
||||
In brief, to install from git:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
# Prerequisites:
|
||||
#sudo apt-get install git help2man perl python3 make autoconf g++ flex bison ccache
|
||||
@@ -89,7 +109,7 @@ Install Prerequisites
|
||||
|
||||
To build or run Verilator, you need these standard packages:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
sudo apt-get install git help2man perl python3 make
|
||||
sudo apt-get install g++ # Alternatively, clang
|
||||
@@ -101,7 +121,7 @@ To build or run Verilator, you need these standard packages:
|
||||
To build or run Verilator, the following are optional but should be installed
|
||||
for good performance:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
sudo apt-get install ccache # If present at build, needed for run
|
||||
sudo apt-get install mold # If present at build, needed for run
|
||||
@@ -110,27 +130,26 @@ for good performance:
|
||||
The following is optional but is recommended for nicely rendered command line
|
||||
help when running Verilator:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
sudo apt-get install perl-doc
|
||||
|
||||
To build Verilator you will need to install these packages; these do not
|
||||
need to be present to run Verilator:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
sudo apt-get install git autoconf flex bison
|
||||
|
||||
Those developing Verilator itself may also want these (see internals.rst):
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
sudo apt-get install clang clang-format-14 cmake gdb gprof graphviz lcov
|
||||
sudo apt-get install python3-clang yapf3 bear jq
|
||||
sudo pip3 install sphinx sphinx_rtd_theme sphinxcontrib-spelling breathe ruff
|
||||
sudo pip3 install git+https://github.com/antmicro/astsee.git
|
||||
cpan install Pod::Perldoc
|
||||
cpan install Parallel::Forker
|
||||
|
||||
|
||||
Install SystemC
|
||||
@@ -171,14 +190,14 @@ Obtain Sources
|
||||
Get the sources from the git repository: (You need to do this only once,
|
||||
ever.)
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
git clone https://github.com/verilator/verilator # Only first time
|
||||
## Note the URL above is not a page you can see with a browser; it's for git only
|
||||
|
||||
Enter the checkout and determine what version/branch to use:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
cd verilator
|
||||
git pull # Make sure we're up-to-date
|
||||
@@ -193,7 +212,7 @@ Auto Configure
|
||||
|
||||
Create the configuration script:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
autoconf # Create ./configure script
|
||||
|
||||
@@ -219,7 +238,7 @@ directory (don't run ``make install``). This allows the easiest
|
||||
experimentation and upgrading, and allows many versions of Verilator to
|
||||
co-exist on a system.
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
export VERILATOR_ROOT=`pwd` # if your shell is bash
|
||||
setenv VERILATOR_ROOT `pwd` # if your shell is csh
|
||||
@@ -241,7 +260,7 @@ that may support multiple versions of every tool. Tell configure the
|
||||
eventual destination directory name. We recommend that the destination
|
||||
location include the Verilator version name:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
unset VERILATOR_ROOT # if your shell is bash
|
||||
unsetenv VERILATOR_ROOT # if your shell is csh
|
||||
@@ -253,7 +272,7 @@ the ``bin`` directory to your ``PATH``. Or, if you use `modulecmd
|
||||
<http://modules.sourceforge.net/>`__, you'll want a module file like the
|
||||
following:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
set install_root /CAD_DISK/verilator/{version-number-used-above}
|
||||
unsetenv VERILATOR_ROOT
|
||||
@@ -268,7 +287,7 @@ following:
|
||||
The final option is to eventually install Verilator globally, using
|
||||
configure's default system paths:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
unset VERILATOR_ROOT # if your shell is bash
|
||||
unsetenv VERILATOR_ROOT # if your shell is csh
|
||||
@@ -285,7 +304,7 @@ The command to configure the package was described in the previous step.
|
||||
Developers should configure to have more complete developer tests.
|
||||
Additional packages may be required for these tests.
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
export VERILATOR_AUTHOR_SITE=1 # Put in your .bashrc
|
||||
./configure --enable-longtests ...above options...
|
||||
@@ -296,7 +315,7 @@ Compile
|
||||
|
||||
Compile Verilator:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
make -j `nproc` # Or if error on `nproc`, the number of CPUs in system
|
||||
|
||||
@@ -306,7 +325,7 @@ Test
|
||||
|
||||
Check the compilation by running self-tests:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
make test
|
||||
|
||||
@@ -318,7 +337,7 @@ If you used any install option other than the `1. Run-in-Place from
|
||||
VERILATOR_ROOT <#_1_run_in_place_from_verilator_root>`__ scheme, install
|
||||
the files:
|
||||
|
||||
::
|
||||
.. code-block:: shell
|
||||
|
||||
make install
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
***************
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
********
|
||||
|
||||
+56
-10
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
.. _Simulating:
|
||||
@@ -18,7 +18,9 @@ Simulation Summary Report
|
||||
=========================
|
||||
|
||||
When simulation finishes, it will print a report to stdout summarizing the
|
||||
simulation. This requires the model being Verilated with :vlopt:`--main`.
|
||||
simulation. This requires the model being Verilated with :vlopt:`--main`,
|
||||
or the user's `main()` calling `VerilatedContext->statsPrintSummary()`.
|
||||
|
||||
The report may be disabled with :vlopt:`+verilator+quiet`.
|
||||
|
||||
For example:
|
||||
@@ -222,14 +224,6 @@ at branches). At each such branch, a counter is incremented. At the end
|
||||
of a test, the counters, filename, and line number corresponding to each
|
||||
counter are written into the coverage file.
|
||||
|
||||
Verilator automatically disables coverage of branches with a $stop in
|
||||
them, as it is assumed that $stop branches contain an error check that should
|
||||
not occur. A :option:`/*verilator&32;coverage_block_off*/` metacomment
|
||||
will perform a similar function on any code in that block or below, or
|
||||
:option:`/*verilator&32;coverage_off*/` and
|
||||
:option:`/*verilator&32;coverage_on*/` will disable and enable coverage
|
||||
respectively around a block of code.
|
||||
|
||||
Verilator may over-count combinatorial (non-clocked) blocks when those
|
||||
blocks receive signals which have had the :option:`UNOPTFLAT` warning
|
||||
disabled; for the most accurate results, do not disable this warning when
|
||||
@@ -276,6 +270,58 @@ A :option:`/*verilator&32;coverage_off*/`
|
||||
signals that do not need toggle analysis, such as RAMs and register files.
|
||||
|
||||
|
||||
.. _Expression Coverage:
|
||||
|
||||
Expression Coverage
|
||||
-------------------
|
||||
|
||||
With :vlopt:`--coverage` or :vlopt:`--coverage-expr`, Verilator will
|
||||
automatically add coverage analysis at each expression, indicating with a
|
||||
truth table how every Boolean truth-table possibility in the expression
|
||||
occurred.
|
||||
|
||||
Multi-bit expressions are ignored, but sub-expressions with are entirely
|
||||
Boolean are analyzed. Expression coverage does not fully explore the truth
|
||||
table of an expression, rather is looks at each term's contribution. E.g.
|
||||
an AND operation will check coverage for TT, XF and FX.
|
||||
|
||||
Some expressions may produce too many cover points. Verilator limits the
|
||||
maximum number of cover points per expression to 32, but this may be
|
||||
controlled with :vlopt:`--coverage-expr-max`.
|
||||
|
||||
Below is an example showing expression coverage produced from `verilator_coverage`
|
||||
as applied to the condition expression inside an if statement. Each line
|
||||
shows the minimum number of terms and their values (e.g. `(t1==0 && t2==1)`) needed
|
||||
to reach a result for the overall expression (e.g. `=> 1`). Each line also
|
||||
shows the number of times this combination was hit. Note that individual lines
|
||||
are not mutually exclusive.
|
||||
|
||||
.. code-block::
|
||||
|
||||
%000004 if ((~t1 && t2) || (~t3 && t4)) $write("");
|
||||
-000002 point: comment=(t1==0 && t2==1) => 1 hier=top.t
|
||||
-000002 point: comment=(t1==1 && t3==1) => 0 hier=top.t
|
||||
-000004 point: comment=(t1==1 && t4==0) => 0 hier=top.t
|
||||
-000002 point: comment=(t2==0 && t3==1) => 0 hier=top.t
|
||||
-000003 point: comment=(t2==0 && t4==0) => 0 hier=top.t
|
||||
-000002 point: comment=(t3==0 && t4==1) => 1 hier=top.t
|
||||
|
||||
.. _Suppressing Coverage:
|
||||
|
||||
Suppressing Coverage
|
||||
--------------------
|
||||
|
||||
Using :option:`/*verilator&32;coverage_off*/` and
|
||||
:option:`/*verilator&32;coverage_on*/` around a block of code will disable
|
||||
and enable coverage respectively around that block. Or, use the
|
||||
:option:`coverage_block_off` configuration file option.
|
||||
|
||||
Verilator automatically disables coverage of lines and branches with a
|
||||
$stop in them, as it is assumed that $stop branches contain an error check
|
||||
that should not occur. A :option:`/*verilator&32;coverage_block_off*/`
|
||||
metacomment will perform a similar function on any code in that block or
|
||||
below.
|
||||
|
||||
.. _Coverage Collection:
|
||||
|
||||
Coverage Collection
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
**********
|
||||
|
||||
+19
-4
@@ -1,4 +1,4 @@
|
||||
.. Copyright 2003-2024 by Wilson Snyder.
|
||||
.. Copyright 2003-2025 by Wilson Snyder.
|
||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
*******************
|
||||
@@ -44,7 +44,7 @@ Warnings may be disabled in multiple ways:
|
||||
|
||||
.. code-block:: sv
|
||||
|
||||
lint_off -rule UNSIGNED -file "*/example.v" -line 1
|
||||
lint_off -rule UNSIGNED -file "*/example.v" -lines 1
|
||||
|
||||
|
||||
Error And Warning Format
|
||||
@@ -445,6 +445,18 @@ List Of Warnings
|
||||
correctly.
|
||||
|
||||
|
||||
.. option:: COVERIGN
|
||||
|
||||
Warns that Verilator does not support certain forms of
|
||||
:code:`covergroup`, :code:`coverpoint`, and coverage options, and the
|
||||
construct was are ignored.
|
||||
|
||||
Disabling the :option:`UNSUPPORTED` error also disables this warning.
|
||||
|
||||
Ignoring this warning may make Verilator ignore lint checking on the
|
||||
construct, and collect coverage data differently from other simulators.
|
||||
|
||||
|
||||
.. option:: DECLFILENAME
|
||||
|
||||
.. TODO better example
|
||||
@@ -1692,6 +1704,9 @@ List Of Warnings
|
||||
Warning that a symbol matches a C++ reserved word, and using this as a
|
||||
symbol name would result in odd C++ compiler errors. You may disable
|
||||
this warning, but Verilator will rename the symbol to avoid conflict.
|
||||
If you are using `--vpi` and only mark things as public for VPI access
|
||||
(and not C++ access) then it is advisable to disable this warning with
|
||||
:code:`-Wno-SYMRSVDWORD`.
|
||||
|
||||
|
||||
.. option:: SYNCASYNCNET
|
||||
@@ -2006,12 +2021,12 @@ List Of Warnings
|
||||
|
||||
.. code-block:: sv
|
||||
|
||||
wire _unused_ok = &{1'b0,
|
||||
wire _unused_ok = 1'b0 && &{1'b0,
|
||||
sig_not_used_a,
|
||||
sig_not_used_yet_b, // To be fixed
|
||||
1'b0};
|
||||
|
||||
The reduction AND and constant zeros mean the net will always be zero,
|
||||
The AND with constant zero mean the net will always be zero,
|
||||
so won't use simulation runtime. The redundant leading and trailing
|
||||
zeros avoid syntax errors if there are no signals between them. The
|
||||
magic name "unused" (controlled by the :vlopt:`--unused-regexp` option)
|
||||
|
||||
+41
-58
@@ -1472,9 +1472,6 @@ For all tests to pass, you must install the following packages:
|
||||
|
||||
- SystemC to compile the SystemC outputs, see http://systemc.org
|
||||
|
||||
- Parallel::Forker from CPAN to run tests in parallel; you can install
|
||||
this with e.g. "sudo cpan install Parallel::Forker".
|
||||
|
||||
- vcddiff to find differences in VCD outputs. See the readme at
|
||||
https://github.com/veripool/vcddiff
|
||||
|
||||
@@ -1484,7 +1481,7 @@ For all tests to pass, you must install the following packages:
|
||||
Controlling the Test Driver
|
||||
---------------------------
|
||||
|
||||
The test driver script `driver.pl` runs tests; see the `Test Driver`
|
||||
The test driver script `driver.py` runs tests; see the `Test Driver`
|
||||
section. The individual test drivers are written in Perl; see `Test
|
||||
Language`.
|
||||
|
||||
@@ -1497,7 +1494,7 @@ A specific regression test can be executed manually. To start the
|
||||
|
||||
::
|
||||
|
||||
test_regress/t/t_EXAMPLE.pl
|
||||
test_regress/t/t_EXAMPLE.py
|
||||
|
||||
|
||||
Regression Testing for Developers
|
||||
@@ -1517,13 +1514,6 @@ Developers will also want to call ./configure with two extra flags:
|
||||
disabled by default, as SystemC installation problems would otherwise
|
||||
falsely indicate a Verilator problem.
|
||||
|
||||
When enabling the long tests, some additional Perl modules are needed,
|
||||
which you can install using cpan.
|
||||
|
||||
::
|
||||
|
||||
cpan install Parallel::Forker
|
||||
|
||||
There are some traps to avoid when running regression tests
|
||||
|
||||
- When checking the MANIFEST, the test will fail on unexpected code in the
|
||||
@@ -1666,7 +1656,7 @@ field in the section below.
|
||||
+---------------+--------------------------------------------------------+
|
||||
| ``1:2:`` | The hierarchy of the ``VAR`` is the ``op2p`` |
|
||||
| | pointer under the ``MODULE``, which in turn is the |
|
||||
| | ``op1p`` pointer under the ``NETLIST`` |
|
||||
| | ``op1p`` pointer under the ``NETLIST``. |
|
||||
+---------------+--------------------------------------------------------+
|
||||
| ``VAR`` | The AstNodeType (e.g. ``AstVar``). |
|
||||
+---------------+--------------------------------------------------------+
|
||||
@@ -1680,7 +1670,7 @@ field in the section below.
|
||||
| | and "aa" the 27th. Then line 22 in that file, then |
|
||||
| | column 8 (aa=0, az=25, ba=26, ...). |
|
||||
+---------------+--------------------------------------------------------+
|
||||
| ``@dt=0x...`` | The address of the data type this node contains. |
|
||||
| ``@dt=0x...`` | The address of the data type this node references. |
|
||||
+---------------+--------------------------------------------------------+
|
||||
| ``w32`` | The data-type width() is 32 bits. |
|
||||
+---------------+--------------------------------------------------------+
|
||||
@@ -1688,7 +1678,7 @@ field in the section below.
|
||||
| | variable. |
|
||||
+---------------+--------------------------------------------------------+
|
||||
| ``[O]`` | Flags which vary with the type of node, in this |
|
||||
| | case, it means the variable is an output. |
|
||||
| | case of a VAR, it means the variable is an output. |
|
||||
+---------------+--------------------------------------------------------+
|
||||
|
||||
In more detail, the following fields are dumped common to all nodes. They
|
||||
@@ -1871,7 +1861,7 @@ represent the pointers (``op1p``, ``op2p``, etc) between the nodes.
|
||||
Debugging with GDB
|
||||
------------------
|
||||
|
||||
The `driver.pl` script accepts ``--debug --gdb`` to start
|
||||
The `driver.py` script accepts ``--debug --gdb`` to start
|
||||
Verilator under gdb and break when an error is hit, or the program is about
|
||||
to exit. You can also use ``--debug --gdbbt`` to just backtrace and then
|
||||
exit gdb. To debug the Verilated executable, use ``--gdbsim``.
|
||||
@@ -1882,7 +1872,7 @@ can use ``--debug`` and look at the underlying invocation of
|
||||
|
||||
::
|
||||
|
||||
t/t_alw_dly.pl --debug
|
||||
t/t_alw_dly.py --debug
|
||||
|
||||
shows it invokes the command:
|
||||
|
||||
@@ -1979,7 +1969,7 @@ Generally, what would you do to add a new feature?
|
||||
Follow the convention described above about the AstNode type hierarchy.
|
||||
Ordering of definitions is enforced by ``astgen``.
|
||||
|
||||
5. Now you can run ``test_regress/t/t_<newtestcase>.pl --debug`` and it'll
|
||||
5. Now you can run ``test_regress/t/t_<newtestcase>.py --debug`` and it'll
|
||||
probably fail, but you'll see a
|
||||
``test_regress/obj_dir/t_<newtestcase>/*.tree`` file which you can examine
|
||||
to see if the parsing worked. See also the sections above on debugging.
|
||||
@@ -2028,7 +2018,7 @@ IEEE 1800-2023 33 Config
|
||||
Test Driver
|
||||
===========
|
||||
|
||||
This section documents the test driver script, `driver.pl`. driver.pl
|
||||
This section documents the test driver script, `driver.py`. driver.py
|
||||
invokes Verilator or another simulator on each test file. For test file
|
||||
contents description see `Test Language`.
|
||||
|
||||
@@ -2040,7 +2030,7 @@ the regression tests with OBJCACHE enabled and in parallel on a machine
|
||||
with many cores. See the -j option and OBJCACHE environment variable.
|
||||
|
||||
|
||||
driver.pl Non-Scenario Arguments
|
||||
driver.py Non-Scenario Arguments
|
||||
--------------------------------
|
||||
|
||||
--benchmark [<cycles>]
|
||||
@@ -2110,13 +2100,13 @@ driver.pl Non-Scenario Arguments
|
||||
memory leaks.
|
||||
|
||||
--site
|
||||
Run site specific tests also.
|
||||
Run site-specific tests also.
|
||||
|
||||
--stop
|
||||
Stop on the first error.
|
||||
|
||||
--trace
|
||||
Set the simulator specific flags to request waveform tracing.
|
||||
Set the simulator-specific flags to request waveform tracing.
|
||||
|
||||
--valgrind
|
||||
Same as ``verilator --valgrind``: Run Verilator under `Valgrind <https://valgrind.org/>`_.
|
||||
@@ -2129,7 +2119,7 @@ driver.pl Non-Scenario Arguments
|
||||
For tests using the standard C++ wrapper, enable runtime debug mode.
|
||||
|
||||
|
||||
driver.pl Scenario Arguments
|
||||
driver.py Scenario Arguments
|
||||
----------------------------
|
||||
|
||||
The following options control which simulator is used, and which tests are
|
||||
@@ -2171,7 +2161,7 @@ simultaneously.
|
||||
Run Xilinx XSim simulator tests.
|
||||
|
||||
|
||||
driver.pl Environment
|
||||
driver.py Environment
|
||||
---------------------
|
||||
|
||||
HARNESS_UPDATE_GOLDEN
|
||||
@@ -2231,30 +2221,30 @@ VERILATOR_XVLOG
|
||||
Test Language
|
||||
=============
|
||||
|
||||
This section describes the format of the ``test_regress/t/*.pl`` test
|
||||
language files, executed by `driver.pl`.
|
||||
This section describes the format of the ``test_regress/t/*.py`` test
|
||||
language files, executed by `driver.py`.
|
||||
|
||||
Test Language Summary
|
||||
---------------------
|
||||
|
||||
For convenience, a summary of the most commonly used features is provided
|
||||
here, with a reference in a later section. All test files typically have a
|
||||
call to the ``lint`` or ``compile`` subroutine to compile the test. For
|
||||
run-time tests, this is followed by a call to the ``execute``
|
||||
subroutine. Both of these functions can optionally be provided with
|
||||
arguments specifying additional options.
|
||||
call to the ``test.lint`` or ``test.compile`` methods to compile the
|
||||
test. For run-time tests, this is followed by a call to the
|
||||
``test.execute`` method. Both of these functions can optionally be provided
|
||||
with arguments specifying additional options.
|
||||
|
||||
If those complete, the script calls ``ok`` to increment the count of
|
||||
successful tests and then returns 1 as its result.
|
||||
If those complete, the script calls ``test.passes`` to increment the count
|
||||
of successful tests.
|
||||
|
||||
The driver.pl script assumes by default that the source Verilog file name
|
||||
The driver.py script assumes by default that the source Verilog file name
|
||||
matches the test script name. So a test whose driver is
|
||||
``t/t_mytest.pl`` will expect a Verilog source file ``t/t_mytest.v``.
|
||||
``t/t_mytest.py`` will expect a Verilog source file ``t/t_mytest.v``.
|
||||
This can be changed using the ``top_filename`` subroutine, for example
|
||||
|
||||
::
|
||||
|
||||
top_filename("t/t_myothertest.v");
|
||||
test.top_filename = "t/t_myothertest.v"
|
||||
|
||||
By default, all tests will run with major simulators (Icarus Verilog, NC,
|
||||
VCS, ModelSim, etc.) as well as Verilator, to allow results to be
|
||||
@@ -2263,26 +2253,25 @@ can use the following:
|
||||
|
||||
::
|
||||
|
||||
scenarios(vlt => 1);
|
||||
test.scenarios('vlt')
|
||||
|
||||
Of the many options that can be set through arguments to ``compiler`` and
|
||||
``execute``, the following are particularly useful:
|
||||
Of the many options that can be set through arguments to ``test.compiler``
|
||||
and ``test.execute``, the following are particularly useful:
|
||||
|
||||
``verilator_flags2``
|
||||
A list of flags to be passed to verilator when compiling.
|
||||
|
||||
``fails``
|
||||
Set to 1 to indicate that the compilation or execution is intended to fail.
|
||||
Set true to indicate that the compilation or execution is intended to fail.
|
||||
|
||||
For example, the following would specify that compilation requires two
|
||||
defines and is expected to fail.
|
||||
|
||||
::
|
||||
|
||||
compile(
|
||||
test.compile(
|
||||
verilator_flags2 => ["-DSMALL_CLOCK -DGATED_COMMENT"],
|
||||
fails => 1,
|
||||
);
|
||||
fails = True)
|
||||
|
||||
Hints On Writing Tests
|
||||
----------------------
|
||||
@@ -2295,10 +2284,10 @@ same name as the test, but with .cpp as suffix
|
||||
|
||||
::
|
||||
|
||||
compile(
|
||||
make_top_shell => 0,
|
||||
make_main => 0,
|
||||
verilator_flags2 => ["--exe $Self->{t_dir}/$Self->{name}.cpp"], );
|
||||
test.compile(
|
||||
make_top_shell=False,
|
||||
make_main=False,
|
||||
verilator_flags2=["--exe", test.t_dir + "/" + test.name + ".cpp"])
|
||||
|
||||
Tests should be self-checking, rather than producing lots of output. If a
|
||||
test succeeds it should print ``*-* All Finished *-*`` to standard output
|
||||
@@ -2338,9 +2327,8 @@ compile time, it is the only option. For example:
|
||||
::
|
||||
|
||||
compile(
|
||||
fails => 1,
|
||||
expect_filename => $Self->{golden_filename},
|
||||
);
|
||||
fails=True,
|
||||
expect_filename=test.golden_filename)
|
||||
|
||||
Note ``expect_filename`` strips some debugging information from the logfile
|
||||
when comparing.
|
||||
@@ -2349,9 +2337,9 @@ when comparing.
|
||||
Test Language Compile/Lint/Run Arguments
|
||||
----------------------------------------
|
||||
|
||||
This section describes common arguments to ``compile()``, ``lint()``, and
|
||||
``run()``. The full list of arguments can be found by looking at the
|
||||
``driver.pl`` source code.
|
||||
This section describes common arguments to ``test.compile``, ``test.lint``,
|
||||
and ``test.run``. The full list of arguments can be found by looking at
|
||||
the ``driver.py`` source code.
|
||||
|
||||
all_run_flags
|
||||
A list of flags to be passed when running the simulator (Verilated model
|
||||
@@ -2362,11 +2350,6 @@ check_finished
|
||||
string ``*-* All Finished *-*`` being printed on standard output. This is
|
||||
the normal way for successful tests to finish.
|
||||
|
||||
expect
|
||||
A quoted list of strings or regular expression to be matched in the
|
||||
output. See `Hints On Writing Tests` for more detail on how this argument
|
||||
should be used.
|
||||
|
||||
fails
|
||||
True to indicate this step is expected to fail. Tests that are expected
|
||||
to fail generally have _bad in their filename.
|
||||
@@ -2428,7 +2411,7 @@ xsim_flags / xsim_flags2 / xsim_run_flags
|
||||
Distribution
|
||||
============
|
||||
|
||||
Copyright 2008-2024 by Wilson Snyder. Verilator is free software; you can
|
||||
Copyright 2008-2025 by Wilson Snyder. Verilator is free software; you can
|
||||
redistribute it and/or modify it under the terms of either the GNU Lesser
|
||||
General Public License Version 3 or the Perl Artistic License Version 2.0.
|
||||
|
||||
|
||||
+24
-1
@@ -20,6 +20,7 @@ Ashutosh
|
||||
Ast
|
||||
Atmel
|
||||
Aurelien
|
||||
Badáň
|
||||
Bagri
|
||||
Balboni
|
||||
Baltazar
|
||||
@@ -74,6 +75,7 @@ Deepa
|
||||
Defparams
|
||||
Delm
|
||||
Denio
|
||||
Deniz
|
||||
Deprecations
|
||||
Deroo
|
||||
Desai
|
||||
@@ -102,6 +104,7 @@ Eiler
|
||||
Eivind
|
||||
El
|
||||
Elbourne
|
||||
Elzeftawi
|
||||
Embecosm
|
||||
Engstrom
|
||||
Enzo
|
||||
@@ -109,8 +112,10 @@ Eugen
|
||||
Fabrizio
|
||||
Faucher
|
||||
Faure
|
||||
Feinberg
|
||||
Fekete
|
||||
Ferrandi
|
||||
Filip
|
||||
Flachs
|
||||
Flavien
|
||||
Florian
|
||||
@@ -149,6 +154,7 @@ Grulfen
|
||||
Gu
|
||||
Gunter
|
||||
Guo
|
||||
Güzel
|
||||
Hameed
|
||||
Hao
|
||||
Haojin
|
||||
@@ -243,6 +249,7 @@ Liwei
|
||||
Lockhart
|
||||
Longo
|
||||
Luca
|
||||
Luiza
|
||||
Lussier
|
||||
Lübeck
|
||||
MMD
|
||||
@@ -273,6 +280,8 @@ MinW
|
||||
Mindspeed
|
||||
MingW
|
||||
Miodrag
|
||||
Moberg
|
||||
Mobert
|
||||
ModelSim
|
||||
Modport
|
||||
Moinak
|
||||
@@ -286,6 +295,7 @@ NaN
|
||||
Nalbantis
|
||||
Nandor
|
||||
Narayan
|
||||
Narcis
|
||||
Nassim
|
||||
Nauticus
|
||||
Newgard
|
||||
@@ -335,6 +345,7 @@ Redhat
|
||||
Reitan
|
||||
Renga
|
||||
Requin
|
||||
Rodas
|
||||
Rodionov
|
||||
Rohan
|
||||
Rolfe
|
||||
@@ -352,8 +363,10 @@ Sanguinetti
|
||||
Sanjay
|
||||
Sasselli
|
||||
Scharrer
|
||||
Schless
|
||||
Seitz
|
||||
Shahid
|
||||
Shahrestani
|
||||
Shankar
|
||||
Shanshan
|
||||
Sharad
|
||||
@@ -364,6 +377,7 @@ Shi
|
||||
Shinkarovsky
|
||||
Shinya
|
||||
Shirakawa
|
||||
Shou
|
||||
Shuba
|
||||
Shunyao
|
||||
Slager
|
||||
@@ -375,6 +389,7 @@ Solaris
|
||||
Solomatnikov
|
||||
Solt
|
||||
Southwell
|
||||
Spack
|
||||
Srini
|
||||
Srinivasan
|
||||
Stamness
|
||||
@@ -516,6 +531,7 @@ basename
|
||||
bbox
|
||||
benchmarking
|
||||
biguint
|
||||
bindir
|
||||
biops
|
||||
bisonpre
|
||||
bitOpTree
|
||||
@@ -585,6 +601,7 @@ datadir
|
||||
datafiles
|
||||
david
|
||||
ddd
|
||||
de
|
||||
deassign
|
||||
debugi
|
||||
defenv
|
||||
@@ -680,6 +697,7 @@ fno
|
||||
fopen
|
||||
forceable
|
||||
foreach
|
||||
fourstate
|
||||
fprintf
|
||||
fprofile
|
||||
fread
|
||||
@@ -865,6 +883,7 @@ phelter
|
||||
picoChip
|
||||
pinIndex
|
||||
pinout
|
||||
pkgdatadir
|
||||
plusargs
|
||||
pmos
|
||||
poping
|
||||
@@ -884,6 +903,7 @@ predefines
|
||||
prepareClone
|
||||
prepend
|
||||
prepended
|
||||
preproc
|
||||
preprocess
|
||||
preprocessed
|
||||
preprocessing
|
||||
@@ -929,6 +949,7 @@ redeclaring
|
||||
regs
|
||||
reloop
|
||||
replaceShiftOp
|
||||
reproducibility
|
||||
resetall
|
||||
respecified
|
||||
rodata
|
||||
@@ -1018,6 +1039,8 @@ traceEverOn
|
||||
tran
|
||||
treei
|
||||
tri
|
||||
triand
|
||||
trior
|
||||
tristate
|
||||
tristates
|
||||
trunc
|
||||
@@ -1093,6 +1116,7 @@ warmup
|
||||
waveforms
|
||||
whitespace
|
||||
widthed
|
||||
wor
|
||||
wreal
|
||||
writeb
|
||||
writeme
|
||||
@@ -1112,4 +1136,3 @@ zdave
|
||||
Øyvind
|
||||
Алексеевич
|
||||
Исаак
|
||||
|
||||
|
||||
+1
-1
@@ -70,7 +70,7 @@ The XML document consists of 4 sections within the top level
|
||||
Distribution
|
||||
============
|
||||
|
||||
Copyright 2020-2024 by Wilson Snyder. Verilator is free software; you can
|
||||
Copyright 2020-2025 by Wilson Snyder. Verilator is free software; you can
|
||||
redistribute it and/or modify it under the terms of either the GNU Lesser
|
||||
General Public License Version 3 or the Perl Artistic License Version 2.0.
|
||||
|
||||
|
||||
@@ -24,8 +24,11 @@ cmake_policy(SET CMP0074 NEW)
|
||||
project(cmake_hello_c)
|
||||
|
||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||
if (NOT verilator_FOUND)
|
||||
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
|
||||
if(NOT verilator_FOUND)
|
||||
message(
|
||||
FATAL_ERROR
|
||||
"Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable"
|
||||
)
|
||||
endif()
|
||||
|
||||
# Create a new executable target that will contain all your sources
|
||||
@@ -35,4 +38,5 @@ target_compile_features(example PUBLIC cxx_std_14)
|
||||
# Add the Verilated circuit to the target
|
||||
verilate(example
|
||||
INCLUDE_DIRS "../make_hello_c"
|
||||
SOURCES ../make_hello_c/top.v)
|
||||
SOURCES ../make_hello_c/top.v
|
||||
)
|
||||
|
||||
@@ -24,8 +24,11 @@ cmake_policy(SET CMP0074 NEW)
|
||||
project(cmake_hello_sc CXX)
|
||||
|
||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||
if (NOT verilator_FOUND)
|
||||
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
|
||||
if(NOT verilator_FOUND)
|
||||
message(
|
||||
FATAL_ERROR
|
||||
"Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable"
|
||||
)
|
||||
endif()
|
||||
|
||||
# SystemC dependencies
|
||||
@@ -39,14 +42,12 @@ find_package(SystemCLanguage QUIET)
|
||||
add_executable(example ../make_hello_sc/sc_main.cpp)
|
||||
target_compile_features(example PUBLIC cxx_std_14)
|
||||
|
||||
set_property(
|
||||
TARGET example
|
||||
PROPERTY CXX_STANDARD ${SystemC_CXX_STANDARD}
|
||||
)
|
||||
set_property(TARGET example PROPERTY CXX_STANDARD ${SystemC_CXX_STANDARD})
|
||||
|
||||
# Add the Verilated circuit to the target
|
||||
verilate(example SYSTEMC
|
||||
INCLUDE_DIRS "../make_hello_sc"
|
||||
SOURCES ../make_hello_sc/top.v)
|
||||
SOURCES ../make_hello_sc/top.v
|
||||
)
|
||||
|
||||
verilator_link_systemc(example)
|
||||
|
||||
@@ -24,8 +24,11 @@ cmake_policy(SET CMP0074 NEW)
|
||||
project(cmake_protect_lib)
|
||||
|
||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||
if (NOT verilator_FOUND)
|
||||
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
|
||||
if(NOT verilator_FOUND)
|
||||
message(
|
||||
FATAL_ERROR
|
||||
"Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable"
|
||||
)
|
||||
endif()
|
||||
|
||||
# Create the main executable target
|
||||
@@ -55,9 +58,11 @@ verilate(verilated_secret
|
||||
VERILATOR_ARGS --protect-lib verilated_secret
|
||||
--protect-key ${PROTECT_KEY}
|
||||
DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/verilated_secret
|
||||
SOURCES ../make_protect_lib/secret_impl.v)
|
||||
SOURCES ../make_protect_lib/secret_impl.v
|
||||
)
|
||||
|
||||
# Include location of verilated_secret.sv wrapper
|
||||
verilate(example
|
||||
VERILATOR_ARGS "-I${CMAKE_CURRENT_BINARY_DIR}/verilated_secret"
|
||||
SOURCES ../make_protect_lib/top.v)
|
||||
SOURCES ../make_protect_lib/top.v
|
||||
)
|
||||
|
||||
@@ -24,8 +24,11 @@ cmake_policy(SET CMP0074 NEW)
|
||||
project(cmake_tracing_c)
|
||||
|
||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||
if (NOT verilator_FOUND)
|
||||
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
|
||||
if(NOT verilator_FOUND)
|
||||
message(
|
||||
FATAL_ERROR
|
||||
"Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable"
|
||||
)
|
||||
endif()
|
||||
|
||||
# Create a new executable target that will contain all your sources
|
||||
@@ -36,4 +39,5 @@ target_compile_features(example PUBLIC cxx_std_14)
|
||||
verilate(example COVERAGE TRACE
|
||||
INCLUDE_DIRS "../make_tracing_c"
|
||||
VERILATOR_ARGS -f ../make_tracing_c/input.vc -x-assign fast
|
||||
SOURCES ../make_tracing_c/top.v)
|
||||
SOURCES ../make_tracing_c/top.v
|
||||
)
|
||||
|
||||
@@ -25,8 +25,11 @@ cmake_policy(SET CMP0074 NEW)
|
||||
project(cmake_tracing_sc_example CXX)
|
||||
|
||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||
if (NOT verilator_FOUND)
|
||||
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
|
||||
if(NOT verilator_FOUND)
|
||||
message(
|
||||
FATAL_ERROR
|
||||
"Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable"
|
||||
)
|
||||
endif()
|
||||
|
||||
# SystemC dependencies
|
||||
@@ -40,15 +43,13 @@ find_package(SystemCLanguage QUIET)
|
||||
add_executable(example ../make_tracing_sc/sc_main.cpp)
|
||||
target_compile_features(example PUBLIC cxx_std_14)
|
||||
|
||||
set_property(
|
||||
TARGET example
|
||||
PROPERTY CXX_STANDARD ${SystemC_CXX_STANDARD}
|
||||
)
|
||||
set_property(TARGET example PROPERTY CXX_STANDARD ${SystemC_CXX_STANDARD})
|
||||
|
||||
# Add the Verilated circuit to the target
|
||||
verilate(example SYSTEMC COVERAGE TRACE
|
||||
INCLUDE_DIRS "../make_tracing_sc"
|
||||
VERILATOR_ARGS -f ../make_tracing_sc/input.vc -x-assign fast
|
||||
SOURCES ../make_tracing_sc/top.v)
|
||||
SOURCES ../make_tracing_sc/top.v
|
||||
)
|
||||
|
||||
verilator_link_systemc(example)
|
||||
|
||||
@@ -13,6 +13,6 @@ module sub
|
||||
);
|
||||
|
||||
// Some simple logic
|
||||
always_comb out = ~ in;
|
||||
always_comb out = ~in;
|
||||
|
||||
endmodule
|
||||
|
||||
@@ -25,8 +25,7 @@ class VlFileCopy:
|
||||
|
||||
self.debug = debug
|
||||
|
||||
with NamedTemporaryFile() as tree_temp, NamedTemporaryFile(
|
||||
) as meta_temp:
|
||||
with NamedTemporaryFile() as tree_temp, NamedTemporaryFile() as meta_temp:
|
||||
vargs = [
|
||||
'--json-only-output',
|
||||
tree_temp.name,
|
||||
@@ -61,8 +60,7 @@ class VlFileCopy:
|
||||
print("\t%s " % command)
|
||||
status = subprocess.call(command, shell=True)
|
||||
if status != 0:
|
||||
raise RuntimeError("Command failed running Verilator with '" +
|
||||
command + "', stopped")
|
||||
raise RuntimeError("Command failed running Verilator with '" + command + "', stopped")
|
||||
|
||||
|
||||
#######################################################################
|
||||
@@ -71,8 +69,7 @@ if __name__ == '__main__':
|
||||
parser = argparse.ArgumentParser(
|
||||
allow_abbrev=False,
|
||||
formatter_class=argparse.RawTextHelpFormatter,
|
||||
description=
|
||||
"""Example of using Verilator JSON output to copy a list of files to an
|
||||
description="""Example of using Verilator JSON output to copy a list of files to an
|
||||
output directory (-odir, defaults to 'copied'), e.g. to easily create a
|
||||
tarball of the design to pass to others.
|
||||
|
||||
@@ -95,11 +92,7 @@ This file ONLY is placed under the Creative Commons Public Domain, for
|
||||
any use, without warranty, 2019 by Wilson Snyder.
|
||||
SPDX-License-Identifier: CC0-1.0
|
||||
""")
|
||||
parser.add_argument('-debug',
|
||||
'--debug',
|
||||
action='store_const',
|
||||
const=9,
|
||||
help='enable debug')
|
||||
parser.add_argument('-debug', '--debug', action='store_const', const=9, help='enable debug')
|
||||
parser.add_argument('-odir',
|
||||
'--odir',
|
||||
action='store',
|
||||
@@ -108,9 +101,7 @@ SPDX-License-Identifier: CC0-1.0
|
||||
help='target output directory')
|
||||
(args, rem) = parser.parse_known_args()
|
||||
|
||||
print(
|
||||
"NOTE: vl_file_copy is only an example starting point for writing your own tool."
|
||||
)
|
||||
print("NOTE: vl_file_copy is only an example starting point for writing your own tool.")
|
||||
# That is:
|
||||
# 1. We will accept basic patches
|
||||
# 2. We are not expecting to make this globally useful. (e.g. we don't cleanup obj_dir)
|
||||
|
||||
@@ -24,8 +24,7 @@ class VlHierGraph:
|
||||
self.next_vertex_number = 0
|
||||
self.addr_to_number = {}
|
||||
|
||||
with NamedTemporaryFile() as tree_temp, NamedTemporaryFile(
|
||||
) as meta_temp:
|
||||
with NamedTemporaryFile() as tree_temp, NamedTemporaryFile() as meta_temp:
|
||||
vargs = [
|
||||
'--json-only-output',
|
||||
tree_temp.name,
|
||||
@@ -45,9 +44,7 @@ class VlHierGraph:
|
||||
fh.write("digraph {\n")
|
||||
fh.write(" dpi=300;\n")
|
||||
fh.write(" order=LR;\n")
|
||||
fh.write(
|
||||
" node [fontsize=8 shape=\"box\" margin=0.01 width=0 height=0]"
|
||||
)
|
||||
fh.write(" node [fontsize=8 shape=\"box\" margin=0.01 width=0 height=0]")
|
||||
fh.write(" edge [fontsize=6]")
|
||||
# Find cells
|
||||
modules = self.flatten(self.tree, lambda n: n['type'] == "MODULE")
|
||||
@@ -101,8 +98,7 @@ class VlHierGraph:
|
||||
print("\t%s " % command)
|
||||
status = subprocess.call(command, shell=True)
|
||||
if status != 0:
|
||||
raise RuntimeError("Command failed running Verilator with '" +
|
||||
command + "', stopped")
|
||||
raise RuntimeError("Command failed running Verilator with '" + command + "', stopped")
|
||||
|
||||
|
||||
#######################################################################
|
||||
@@ -111,8 +107,7 @@ if __name__ == '__main__':
|
||||
parser = argparse.ArgumentParser(
|
||||
allow_abbrev=False,
|
||||
formatter_class=argparse.RawTextHelpFormatter,
|
||||
description=
|
||||
"""Example of using Verilator JSON output to create a .dot file showing the
|
||||
description="""Example of using Verilator JSON output to create a .dot file showing the
|
||||
design module hierarchy.
|
||||
|
||||
Example usage:
|
||||
@@ -134,11 +129,7 @@ This file ONLY is placed under the Creative Commons Public Domain, for
|
||||
any use, without warranty, 2019 by Wilson Snyder.
|
||||
SPDX-License-Identifier: CC0-1.0
|
||||
""")
|
||||
parser.add_argument('-debug',
|
||||
'--debug',
|
||||
action='store_const',
|
||||
const=9,
|
||||
help='enable debug')
|
||||
parser.add_argument('-debug', '--debug', action='store_const', const=9, help='enable debug')
|
||||
parser.add_argument('-o',
|
||||
'--o',
|
||||
action='store',
|
||||
@@ -147,18 +138,14 @@ SPDX-License-Identifier: CC0-1.0
|
||||
help='output filename')
|
||||
(args, rem) = parser.parse_known_args()
|
||||
|
||||
print(
|
||||
"NOTE: vl_hier_graph is only an example starting point for writing your own tool."
|
||||
)
|
||||
print("NOTE: vl_hier_graph is only an example starting point for writing your own tool.")
|
||||
# That is:
|
||||
# 1. We will accept basic patches
|
||||
# 2. We are not expecting to make this globally useful. (e.g. we don't cleanup obj_dir)
|
||||
# 3. "make install" will not install this.
|
||||
# 4. This has not had production-worthy validation.
|
||||
|
||||
fc = VlHierGraph(output_filename=args.o,
|
||||
debug=args.debug,
|
||||
verilator_args=rem)
|
||||
fc = VlHierGraph(output_filename=args.o, debug=args.debug, verilator_args=rem)
|
||||
|
||||
######################################################################
|
||||
# Local Variables:
|
||||
|
||||
@@ -13,7 +13,7 @@ module sub
|
||||
|
||||
// Example counter/flop
|
||||
reg [31:0] count_c;
|
||||
always_ff @ (posedge clk) begin
|
||||
always_ff @(posedge clk) begin
|
||||
if (!reset_l) begin
|
||||
/*AUTORESET*/
|
||||
// Beginning of autoreset for uninitialized flops
|
||||
@@ -32,11 +32,11 @@ module sub
|
||||
end
|
||||
|
||||
// An example assertion
|
||||
always_ff @ (posedge clk) begin
|
||||
AssertionExample: assert (!reset_l || count_c<100);
|
||||
always_ff @(posedge clk) begin
|
||||
AssertionExample : assert (!reset_l || count_c < 100);
|
||||
end
|
||||
|
||||
// And example coverage analysis
|
||||
cover property (@(posedge clk) count_c==3);
|
||||
cover property (@(posedge clk) count_c == 3);
|
||||
|
||||
endmodule
|
||||
|
||||
@@ -14,7 +14,7 @@ module sub
|
||||
|
||||
// Example counter/flop
|
||||
reg [31:0] count_f;
|
||||
always_ff @ (posedge fastclk) begin
|
||||
always_ff @(posedge fastclk) begin
|
||||
if (!reset_l) begin
|
||||
/*AUTORESET*/
|
||||
// Beginning of autoreset for uninitialized flops
|
||||
@@ -28,7 +28,7 @@ module sub
|
||||
|
||||
// Another example flop
|
||||
reg [31:0] count_c;
|
||||
always_ff @ (posedge clk) begin
|
||||
always_ff @(posedge clk) begin
|
||||
if (!reset_l) begin
|
||||
/*AUTORESET*/
|
||||
// Beginning of autoreset for uninitialized flops
|
||||
@@ -38,8 +38,7 @@ module sub
|
||||
else begin
|
||||
count_c <= count_c + 1;
|
||||
if (count_c >= 3) begin
|
||||
$display("[%0t] fastclk is %0d times faster than clk\n",
|
||||
$time, count_f/count_c);
|
||||
$display("[%0t] fastclk is %0d times faster than clk\n", $time, count_f / count_c);
|
||||
// This write is a magic value the Makefile uses to make sure the
|
||||
// test completes successfully.
|
||||
$write("*-* All Finished *-*\n");
|
||||
@@ -49,11 +48,11 @@ module sub
|
||||
end
|
||||
|
||||
// An example assertion
|
||||
always_ff @ (posedge clk) begin
|
||||
AssertionExample: assert(!reset_l || count_c<100);
|
||||
always_ff @(posedge clk) begin
|
||||
AssertionExample : assert (!reset_l || count_c < 100);
|
||||
end
|
||||
|
||||
// And example coverage analysis
|
||||
cover property (@(posedge clk) count_c==3);
|
||||
cover property (@(posedge clk) count_c == 3);
|
||||
|
||||
endmodule
|
||||
|
||||
@@ -550,8 +550,9 @@ return(rc);
|
||||
|
||||
static uint32_t fstReaderVarint32(FILE *f)
|
||||
{
|
||||
int chk_len = 5; /* TALOS-2023-1783 */
|
||||
unsigned char buf[chk_len];
|
||||
const int chk_len_max = 5; /* TALOS-2023-1783 */
|
||||
int chk_len = chk_len_max;
|
||||
unsigned char buf[chk_len_max];
|
||||
unsigned char *mem = buf;
|
||||
uint32_t rc = 0;
|
||||
int ch;
|
||||
@@ -582,8 +583,9 @@ return(rc);
|
||||
|
||||
static uint32_t fstReaderVarint32WithSkip(FILE *f, uint32_t *skiplen)
|
||||
{
|
||||
int chk_len = 5; /* TALOS-2023-1783 */
|
||||
unsigned char buf[chk_len];
|
||||
const int chk_len_max = 5; /* TALOS-2023-1783 */
|
||||
int chk_len = chk_len_max;
|
||||
unsigned char buf[chk_len_max];
|
||||
unsigned char *mem = buf;
|
||||
uint32_t rc = 0;
|
||||
int ch;
|
||||
@@ -615,8 +617,9 @@ return(rc);
|
||||
|
||||
static uint64_t fstReaderVarint64(FILE *f)
|
||||
{
|
||||
int chk_len = 16; /* TALOS-2023-1783 */
|
||||
unsigned char buf[chk_len];
|
||||
const int chk_len_max = 16; /* TALOS-2023-1783 */
|
||||
int chk_len = chk_len_max;
|
||||
unsigned char buf[chk_len_max];
|
||||
unsigned char *mem = buf;
|
||||
uint64_t rc = 0;
|
||||
int ch;
|
||||
@@ -3904,16 +3907,18 @@ while (value)
|
||||
static int fstVcdIDForFwrite(char *buf, unsigned int value)
|
||||
{
|
||||
char *pnt = buf;
|
||||
int len = 0;
|
||||
|
||||
/* zero is illegal for a value...it is assumed they start at one */
|
||||
while (value)
|
||||
while (value && len < 14)
|
||||
{
|
||||
value--;
|
||||
++len;
|
||||
*(pnt++) = (char)('!' + value % 94);
|
||||
value = value / 94;
|
||||
}
|
||||
|
||||
return(pnt - buf);
|
||||
return len;
|
||||
}
|
||||
|
||||
|
||||
|
||||
+30
-34
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2003-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -128,6 +128,7 @@ void vl_finish(const char* filename, int linenum, const char* hier) VL_MT_UNSAFE
|
||||
|
||||
#ifndef VL_USER_STOP ///< Define this to override the vl_stop function
|
||||
void vl_stop(const char* filename, int linenum, const char* hier) VL_MT_UNSAFE {
|
||||
// $stop or $fatal reporting; would break current API to add param as to which
|
||||
const char* const msg = "Verilog $stop";
|
||||
Verilated::threadContextp()->gotError(true);
|
||||
Verilated::threadContextp()->gotFinish(true);
|
||||
@@ -172,6 +173,7 @@ void vl_fatal(const char* filename, int linenum, const char* hier, const char* m
|
||||
|
||||
#ifndef VL_USER_STOP_MAYBE ///< Define this to override the vl_stop_maybe function
|
||||
void vl_stop_maybe(const char* filename, int linenum, const char* hier, bool maybe) VL_MT_UNSAFE {
|
||||
// $stop or $fatal
|
||||
Verilated::threadContextp()->errorCountInc();
|
||||
if (maybe
|
||||
&& Verilated::threadContextp()->errorCount() < Verilated::threadContextp()->errorLimit()) {
|
||||
@@ -1763,9 +1765,8 @@ IData VL_SYSTEM_IQ(QData lhs) VL_MT_SAFE {
|
||||
return VL_SYSTEM_IW(VL_WQ_WORDS_E, lhsw);
|
||||
}
|
||||
IData VL_SYSTEM_IW(int lhswords, const WDataInP lhsp) VL_MT_SAFE {
|
||||
char filenamez[VL_VALUE_STRING_MAX_CHARS + 1];
|
||||
_vl_vint_to_string(lhswords * VL_EDATASIZE, filenamez, lhsp);
|
||||
return VL_SYSTEM_IN(filenamez);
|
||||
const std::string lhs = VL_CVT_PACK_STR_NW(lhswords, lhsp);
|
||||
return VL_SYSTEM_IN(lhs);
|
||||
}
|
||||
IData VL_SYSTEM_IN(const std::string& lhs) VL_MT_SAFE {
|
||||
const int code = std::system(lhs.c_str()); // Yes, std::system() is threadsafe
|
||||
@@ -1897,7 +1898,7 @@ std::string VL_TO_STRING(CData lhs) { return VL_SFORMATF_N_NX("'h%0x", 0, 8, lhs
|
||||
std::string VL_TO_STRING(SData lhs) { return VL_SFORMATF_N_NX("'h%0x", 0, 16, lhs); }
|
||||
std::string VL_TO_STRING(IData lhs) { return VL_SFORMATF_N_NX("'h%0x", 0, 32, lhs); }
|
||||
std::string VL_TO_STRING(QData lhs) { return VL_SFORMATF_N_NX("'h%0x", 0, 64, lhs); }
|
||||
std::string VL_TO_STRING(double lhs) { return VL_SFORMATF_N_NX("%d", 0, 64, lhs); }
|
||||
std::string VL_TO_STRING(double lhs) { return VL_SFORMATF_N_NX("%g", 0, 64, lhs); }
|
||||
std::string VL_TO_STRING_W(int words, const WDataInP obj) {
|
||||
return VL_SFORMATF_N_NX("'h%0x", 0, words * VL_EDATASIZE, obj);
|
||||
}
|
||||
@@ -1915,20 +1916,16 @@ std::string VL_TOUPPER_NN(const std::string& ld) VL_PURE {
|
||||
|
||||
std::string VL_CVT_PACK_STR_NW(int lwords, const WDataInP lwp) VL_PURE {
|
||||
// See also _vl_vint_to_string
|
||||
char destout[VL_VALUE_STRING_MAX_CHARS + 1];
|
||||
std::string result;
|
||||
result.reserve((lwords * VL_EDATASIZE) / 8 + 1);
|
||||
const int obits = lwords * VL_EDATASIZE;
|
||||
int lsb = obits - 1;
|
||||
char* destp = destout;
|
||||
size_t len = 0;
|
||||
for (; lsb >= 0; --lsb) {
|
||||
lsb = (lsb / 8) * 8; // Next digit
|
||||
const IData charval = VL_BITRSHIFT_W(lwp, lsb) & 0xff;
|
||||
if (charval) {
|
||||
*destp++ = static_cast<char>(charval);
|
||||
++len;
|
||||
}
|
||||
if (charval) result += static_cast<char>(charval);
|
||||
}
|
||||
return std::string{destout, len};
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string VL_CVT_PACK_STR_ND(const VlQueue<std::string>& q) VL_PURE {
|
||||
@@ -2653,7 +2650,7 @@ const char* VerilatedContext::timeprecisionString() const VL_MT_SAFE {
|
||||
}
|
||||
|
||||
void VerilatedContext::threads(unsigned n) {
|
||||
if (n == 0) VL_FATAL_MT(__FILE__, __LINE__, "", "%Error: Simulation threads must be >= 1");
|
||||
if (n == 0) VL_FATAL_MT(__FILE__, __LINE__, "", "Simulation threads must be >= 1");
|
||||
|
||||
if (m_threadPool) {
|
||||
VL_FATAL_MT(
|
||||
@@ -3002,7 +2999,7 @@ const VerilatedScopeNameMap* VerilatedContext::scopeNameMap() VL_MT_SAFE {
|
||||
//======================================================================
|
||||
// VerilatedContext:: Methods - trace
|
||||
|
||||
void VerilatedContext::trace(VerilatedTraceBaseC* tfp, int levels, int options) VL_MT_SAFE {
|
||||
void VerilatedContext::trace(VerilatedTraceBaseC* tfp, int levels, int options) {
|
||||
VL_DEBUG_IF(VL_DBG_MSGF("+ VerilatedContext::trace\n"););
|
||||
if (tfp->isOpen()) {
|
||||
VL_FATAL_MT("", 0, "",
|
||||
@@ -3292,7 +3289,7 @@ uint32_t VerilatedVarProps::entSize() const VL_MT_SAFE {
|
||||
case VLVT_UINT16: size = sizeof(SData); break;
|
||||
case VLVT_UINT32: size = sizeof(IData); break;
|
||||
case VLVT_UINT64: size = sizeof(QData); break;
|
||||
case VLVT_WDATA: size = VL_WORDS_I(packed().elements()) * sizeof(IData); break;
|
||||
case VLVT_WDATA: size = VL_WORDS_I(entBits()) * sizeof(IData); break;
|
||||
default: size = 0; break; // LCOV_EXCL_LINE
|
||||
}
|
||||
return size;
|
||||
@@ -3311,7 +3308,7 @@ void* VerilatedVarProps::datapAdjustIndex(void* datap, int dim, int indx) const
|
||||
uint8_t* bytep = reinterpret_cast<uint8_t*>(datap);
|
||||
// If on index 1 of a 2 index array, then each index 1 is index2sz*entsz
|
||||
size_t slicesz = entSize();
|
||||
for (int d = dim + 1; d <= m_udims; ++d) slicesz *= elements(d);
|
||||
for (int d = dim + 1; d <= udims(); ++d) slicesz *= elements(d);
|
||||
bytep += indxAdj * slicesz;
|
||||
return bytep;
|
||||
}
|
||||
@@ -3329,7 +3326,7 @@ VerilatedScope::~VerilatedScope() {
|
||||
}
|
||||
|
||||
void VerilatedScope::configure(VerilatedSyms* symsp, const char* prefixp, const char* suffixp,
|
||||
const char* identifier, int8_t timeunit,
|
||||
const char* identifier, const char* defnamep, int8_t timeunit,
|
||||
const Type& type) VL_MT_UNSAFE {
|
||||
// Slowpath - called once/scope at construction
|
||||
// We don't want the space and reference-count access overhead of strings.
|
||||
@@ -3346,6 +3343,7 @@ void VerilatedScope::configure(VerilatedSyms* symsp, const char* prefixp, const
|
||||
m_namep = namep;
|
||||
}
|
||||
m_identifierp = identifier;
|
||||
m_defnamep = defnamep;
|
||||
Verilated::threadContextp()->impp()->scopeInsert(this);
|
||||
}
|
||||
|
||||
@@ -3371,32 +3369,30 @@ void VerilatedScope::exportInsert(int finalize, const char* namep, void* cb) VL_
|
||||
}
|
||||
|
||||
void VerilatedScope::varInsert(int finalize, const char* namep, void* datap, bool isParam,
|
||||
VerilatedVarType vltype, int vlflags, int dims, ...) VL_MT_UNSAFE {
|
||||
VerilatedVarType vltype, int vlflags, int udims,
|
||||
int pdims...) VL_MT_UNSAFE {
|
||||
// Grab dimensions
|
||||
// In the future we may just create a large table at emit time and
|
||||
// statically construct from that.
|
||||
if (!finalize) return;
|
||||
|
||||
if (!m_varsp) m_varsp = new VerilatedVarNameMap;
|
||||
VerilatedVar var(namep, datap, vltype, static_cast<VerilatedVarFlags>(vlflags), dims, isParam);
|
||||
VerilatedVar var(namep, datap, vltype, static_cast<VerilatedVarFlags>(vlflags), udims, pdims,
|
||||
isParam);
|
||||
|
||||
va_list ap;
|
||||
va_start(ap, dims);
|
||||
for (int i = 0; i < dims; ++i) {
|
||||
va_start(ap, pdims);
|
||||
for (int i = 0; i < udims; ++i) {
|
||||
const int msb = va_arg(ap, int);
|
||||
const int lsb = va_arg(ap, int);
|
||||
if (i == 0) {
|
||||
var.m_packed.m_left = msb;
|
||||
var.m_packed.m_right = lsb;
|
||||
} else if (i >= 1 && i <= var.udims()) {
|
||||
var.m_unpacked[i - 1].m_left = msb;
|
||||
var.m_unpacked[i - 1].m_right = lsb;
|
||||
} else {
|
||||
// We could have a linked list of ranges, but really this whole thing needs
|
||||
// to be generalized to support structs and unions, etc.
|
||||
const std::string msg = "Unsupported multi-dimensional public varInsert: "s + namep;
|
||||
VL_FATAL_MT(__FILE__, __LINE__, "", msg.c_str());
|
||||
}
|
||||
var.m_unpacked[i].m_left = msb;
|
||||
var.m_unpacked[i].m_right = lsb;
|
||||
}
|
||||
for (int i = 0; i < pdims; ++i) {
|
||||
const int msb = va_arg(ap, int);
|
||||
const int lsb = va_arg(ap, int);
|
||||
var.m_packed[i].m_left = msb;
|
||||
var.m_packed[i].m_right = lsb;
|
||||
}
|
||||
va_end(ap);
|
||||
|
||||
|
||||
+33
-40
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2003-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -100,7 +100,7 @@ class VerilatedFstC;
|
||||
class VerilatedFstSc;
|
||||
class VerilatedScope;
|
||||
class VerilatedScopeNameMap;
|
||||
template <class, class>
|
||||
template <typename, typename>
|
||||
class VerilatedTrace;
|
||||
class VerilatedTraceBaseC;
|
||||
class VerilatedTraceConfig;
|
||||
@@ -175,6 +175,9 @@ enum class VerilatedAssertDirectiveType : uint8_t {
|
||||
using VerilatedAssertType_t = std::underlying_type<VerilatedAssertType>::type;
|
||||
using VerilatedAssertDirectiveType_t = std::underlying_type<VerilatedAssertDirectiveType>::type;
|
||||
|
||||
// Type trait for custom struct
|
||||
template <typename>
|
||||
struct VlIsCustomStruct : public std::false_type {};
|
||||
//=============================================================================
|
||||
// Utility functions
|
||||
|
||||
@@ -221,19 +224,6 @@ public:
|
||||
void unlock() VL_RELEASE() VL_MT_SAFE { m_mutex.unlock(); }
|
||||
/// Try to acquire mutex. Returns true on success, and false on failure.
|
||||
bool try_lock() VL_TRY_ACQUIRE(true) VL_MT_SAFE { return m_mutex.try_lock(); }
|
||||
/// Acquire/lock mutex and check for stop request
|
||||
/// It tries to lock the mutex and if it fails, it check if stop request was send.
|
||||
/// It returns after locking mutex.
|
||||
/// This function should be extracted to V3ThreadPool, but due to clang thread-safety
|
||||
/// limitations it needs to be placed here.
|
||||
void lockCheckStopRequest(std::function<void()> checkStopRequestFunction)
|
||||
VL_ACQUIRE() VL_MT_SAFE {
|
||||
while (true) {
|
||||
checkStopRequestFunction();
|
||||
if (m_mutex.try_lock()) return;
|
||||
VL_CPU_RELAX();
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
/// Lock guard for mutex (ala std::unique_lock), wrapped to allow -fthread_safety checks
|
||||
@@ -313,7 +303,7 @@ public:
|
||||
|
||||
private:
|
||||
// The following are for use by Verilator internals only
|
||||
template <class, class>
|
||||
template <typename, typename>
|
||||
friend class VerilatedTrace;
|
||||
// Run-time trace configuration requested by this model
|
||||
virtual std::unique_ptr<VerilatedTraceConfig> traceConfig() const;
|
||||
@@ -559,9 +549,9 @@ public:
|
||||
/// 1 = Set all bits to one
|
||||
/// 2 = Randomize all bits
|
||||
void randReset(int val) VL_MT_SAFE;
|
||||
/// Set default random seed, 0 = seed it automatically
|
||||
int randSeed() const VL_MT_SAFE { return m_s.m_randSeed; }
|
||||
/// Return default random seed
|
||||
int randSeed() const VL_MT_SAFE { return m_s.m_randSeed; }
|
||||
/// Set default random seed, 0 = seed it automatically
|
||||
void randSeed(int val) VL_MT_SAFE;
|
||||
|
||||
/// Return statistic: CPU time delta from model created until now
|
||||
@@ -727,6 +717,7 @@ private:
|
||||
VerilatedVarNameMap* m_varsp = nullptr; // Variable map
|
||||
const char* m_namep = nullptr; // Scope name (Slowpath)
|
||||
const char* m_identifierp = nullptr; // Identifier of scope (with escapes removed)
|
||||
const char* m_defnamep = nullptr; // Definition name (SCOPE_MODULE only)
|
||||
int8_t m_timeunit = 0; // Timeunit in negative power-of-10
|
||||
Type m_type = SCOPE_OTHER; // Type of the scope
|
||||
|
||||
@@ -734,13 +725,15 @@ public: // But internals only - called from VerilatedModule's
|
||||
VerilatedScope() = default;
|
||||
~VerilatedScope();
|
||||
void configure(VerilatedSyms* symsp, const char* prefixp, const char* suffixp,
|
||||
const char* identifier, int8_t timeunit, const Type& type) VL_MT_UNSAFE;
|
||||
const char* identifier, const char* defnamep, int8_t timeunit,
|
||||
const Type& type) VL_MT_UNSAFE;
|
||||
void exportInsert(int finalize, const char* namep, void* cb) VL_MT_UNSAFE;
|
||||
void varInsert(int finalize, const char* namep, void* datap, bool isParam,
|
||||
VerilatedVarType vltype, int vlflags, int dims, ...) VL_MT_UNSAFE;
|
||||
VerilatedVarType vltype, int vlflags, int udims, int pdims, ...) VL_MT_UNSAFE;
|
||||
// ACCESSORS
|
||||
const char* name() const VL_MT_SAFE_POSTINIT { return m_namep; }
|
||||
const char* identifier() const VL_MT_SAFE_POSTINIT { return m_identifierp; }
|
||||
const char* defname() const VL_MT_SAFE_POSTINIT { return m_defnamep; }
|
||||
int8_t timeunit() const VL_MT_SAFE_POSTINIT { return m_timeunit; }
|
||||
VerilatedSyms* symsp() const VL_MT_SAFE_POSTINIT { return m_symsp; }
|
||||
VerilatedVar* varFind(const char* namep) const VL_MT_SAFE_POSTINIT;
|
||||
@@ -809,8 +802,6 @@ class Verilated final {
|
||||
public:
|
||||
// METHODS - User called
|
||||
|
||||
/// Enable debug of internal verilated code
|
||||
static void debug(int level) VL_MT_SAFE;
|
||||
#ifdef VL_DEBUG
|
||||
/// Return debug level
|
||||
/// When multithreaded this may not immediately react to another thread
|
||||
@@ -820,6 +811,8 @@ public:
|
||||
/// Return constant 0 debug level, so C++'s optimizer rips up
|
||||
static constexpr int debug() VL_PURE { return 0; }
|
||||
#endif
|
||||
/// Enable debug of internal verilated code
|
||||
static void debug(int level) VL_MT_SAFE;
|
||||
|
||||
/// Set the last VerilatedContext accessed
|
||||
/// Generally threadContextp(value) should be called instead
|
||||
@@ -878,44 +871,44 @@ public:
|
||||
static const char* commandArgsPlusMatch(const char* prefixp) VL_MT_SAFE {
|
||||
return Verilated::threadContextp()->commandArgsPlusMatch(prefixp);
|
||||
}
|
||||
/// Call VerilatedContext::errorLimit using current thread's VerilatedContext
|
||||
static void errorLimit(int val) VL_MT_SAFE { Verilated::threadContextp()->errorLimit(val); }
|
||||
/// Return VerilatedContext::errorLimit using current thread's VerilatedContext
|
||||
static int errorLimit() VL_MT_SAFE { return Verilated::threadContextp()->errorLimit(); }
|
||||
/// Call VerilatedContext::errorLimit using current thread's VerilatedContext
|
||||
static void errorLimit(int val) VL_MT_SAFE { Verilated::threadContextp()->errorLimit(val); }
|
||||
/// Return VerilatedContext::fatalOnError using current thread's VerilatedContext
|
||||
static bool fatalOnError() VL_MT_SAFE { return Verilated::threadContextp()->fatalOnError(); }
|
||||
/// Call VerilatedContext::fatalOnError using current thread's VerilatedContext
|
||||
static void fatalOnError(bool flag) VL_MT_SAFE {
|
||||
Verilated::threadContextp()->fatalOnError(flag);
|
||||
}
|
||||
/// Return VerilatedContext::fatalOnError using current thread's VerilatedContext
|
||||
static bool fatalOnError() VL_MT_SAFE { return Verilated::threadContextp()->fatalOnError(); }
|
||||
/// Call VerilatedContext::fatalOnVpiError using current thread's VerilatedContext
|
||||
static void fatalOnVpiError(bool flag) VL_MT_SAFE {
|
||||
Verilated::threadContextp()->fatalOnVpiError(flag);
|
||||
}
|
||||
/// Return VerilatedContext::fatalOnVpiError using current thread's VerilatedContext
|
||||
static bool fatalOnVpiError() VL_MT_SAFE {
|
||||
return Verilated::threadContextp()->fatalOnVpiError();
|
||||
}
|
||||
/// Call VerilatedContext::gotError using current thread's VerilatedContext
|
||||
static void gotError(bool flag) VL_MT_SAFE { Verilated::threadContextp()->gotError(flag); }
|
||||
/// Call VerilatedContext::fatalOnVpiError using current thread's VerilatedContext
|
||||
static void fatalOnVpiError(bool flag) VL_MT_SAFE {
|
||||
Verilated::threadContextp()->fatalOnVpiError(flag);
|
||||
}
|
||||
/// Return VerilatedContext::gotError using current thread's VerilatedContext
|
||||
static bool gotError() VL_MT_SAFE { return Verilated::threadContextp()->gotError(); }
|
||||
/// Call VerilatedContext::gotFinish using current thread's VerilatedContext
|
||||
static void gotFinish(bool flag) VL_MT_SAFE { Verilated::threadContextp()->gotFinish(flag); }
|
||||
/// Call VerilatedContext::gotError using current thread's VerilatedContext
|
||||
static void gotError(bool flag) VL_MT_SAFE { Verilated::threadContextp()->gotError(flag); }
|
||||
/// Return VerilatedContext::gotFinish using current thread's VerilatedContext
|
||||
static bool gotFinish() VL_MT_SAFE { return Verilated::threadContextp()->gotFinish(); }
|
||||
/// Call VerilatedContext::randReset using current thread's VerilatedContext
|
||||
static void randReset(int val) VL_MT_SAFE { Verilated::threadContextp()->randReset(val); }
|
||||
/// Call VerilatedContext::gotFinish using current thread's VerilatedContext
|
||||
static void gotFinish(bool flag) VL_MT_SAFE { Verilated::threadContextp()->gotFinish(flag); }
|
||||
/// Return VerilatedContext::randReset using current thread's VerilatedContext
|
||||
static int randReset() VL_MT_SAFE { return Verilated::threadContextp()->randReset(); }
|
||||
/// Call VerilatedContext::randSeed using current thread's VerilatedContext
|
||||
static void randSeed(int val) VL_MT_SAFE { Verilated::threadContextp()->randSeed(val); }
|
||||
/// Call VerilatedContext::randReset using current thread's VerilatedContext
|
||||
static void randReset(int val) VL_MT_SAFE { Verilated::threadContextp()->randReset(val); }
|
||||
/// Return VerilatedContext::randSeed using current thread's VerilatedContext
|
||||
static int randSeed() VL_MT_SAFE { return Verilated::threadContextp()->randSeed(); }
|
||||
/// Call VerilatedContext::time using current thread's VerilatedContext
|
||||
static void time(uint64_t val) VL_MT_SAFE { Verilated::threadContextp()->time(val); }
|
||||
/// Call VerilatedContext::randSeed using current thread's VerilatedContext
|
||||
static void randSeed(int val) VL_MT_SAFE { Verilated::threadContextp()->randSeed(val); }
|
||||
/// Return VerilatedContext::time using current thread's VerilatedContext
|
||||
static uint64_t time() VL_MT_SAFE { return Verilated::threadContextp()->time(); }
|
||||
/// Call VerilatedContext::time using current thread's VerilatedContext
|
||||
static void time(uint64_t val) VL_MT_SAFE { Verilated::threadContextp()->time(val); }
|
||||
/// Call VerilatedContext::timeInc using current thread's VerilatedContext
|
||||
static void timeInc(uint64_t add) VL_MT_UNSAFE { Verilated::threadContextp()->timeInc(add); }
|
||||
// Deprecated
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
######################################################################
|
||||
# DESCRIPTION: Makefile commands for all verilated target files
|
||||
#
|
||||
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||
# Copyright 2003-2025 by Wilson Snyder. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
@@ -23,6 +23,12 @@ PYTHON3 = @PYTHON3@
|
||||
CFG_WITH_CCWARN = @CFG_WITH_CCWARN@
|
||||
CFG_WITH_LONGTESTS = @CFG_WITH_LONGTESTS@
|
||||
|
||||
# Compiler version found during configure. This make variable is not used
|
||||
# here, but note that if this differs from what `$(CXX) --version` prints,
|
||||
# then there may be strange results such as unexpected warnings, as
|
||||
# configure determines compiler characteristics.
|
||||
CFG_CXX_VERSION = "@CFG_CXX_VERSION@"
|
||||
|
||||
# Compiler flags to enable profiling
|
||||
CFG_CXXFLAGS_PROFILE = @CFG_CXXFLAGS_PROFILE@
|
||||
# Select language required to compile (often empty)
|
||||
|
||||
+3
-3
@@ -2,7 +2,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2003-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -12,11 +12,11 @@
|
||||
//
|
||||
// DESCRIPTION: Verilator: Include in verilog files to hide verilator defines
|
||||
|
||||
`ifdef _VERILATED_V_ `else
|
||||
`ifndef _VERILATED_V_
|
||||
`define _VERILATED_V_ 1
|
||||
|
||||
// Hide verilator pragmas from other tools
|
||||
`ifdef VERILATOR `else
|
||||
`ifndef VERILATOR
|
||||
`define coverage_block_off
|
||||
`endif
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2003-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2001-2024 by Wilson Snyder. This program is free software; you
|
||||
// Copyright 2001-2025 by Wilson Snyder. This program is free software; you
|
||||
// can redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -71,7 +71,7 @@ public: // But only local to this file
|
||||
// This isn't in the header file for auto-magic conversion because it
|
||||
// inlines to too much code and makes compilation too slow.
|
||||
|
||||
template <class T>
|
||||
template <typename T>
|
||||
class VerilatedCoverItemSpec final : public VerilatedCovImpItem {
|
||||
private:
|
||||
// MEMBERS
|
||||
@@ -233,7 +233,7 @@ private:
|
||||
// Little selftest
|
||||
#define SELF_CHECK(got, exp) \
|
||||
do { \
|
||||
if ((got) != (exp)) VL_FATAL_MT(__FILE__, __LINE__, "", "%Error: selftest"); \
|
||||
if ((got) != (exp)) VL_FATAL_MT(__FILE__, __LINE__, "", "selftest"); \
|
||||
} while (0)
|
||||
SELF_CHECK(combineHier("a.b.c", "a.b.c"), "a.b.c");
|
||||
SELF_CHECK(combineHier("a.b.c", "a.b"), "a.b*");
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2001-2024 by Wilson Snyder. This program is free software; you
|
||||
// Copyright 2001-2025 by Wilson Snyder. This program is free software; you
|
||||
// can redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -92,8 +92,8 @@ public:
|
||||
std::string defaultFilename() VL_MT_SAFE;
|
||||
/// Make all data per_instance, overriding point's per_instance
|
||||
void forcePerInstance(bool flag) VL_MT_SAFE;
|
||||
void write() VL_MT_SAFE { write(defaultFilename()); }
|
||||
/// Write all coverage data to a file
|
||||
void write() VL_MT_SAFE { write(defaultFilename()); }
|
||||
void write(const std::string& filename) VL_MT_SAFE;
|
||||
/// Clear coverage points (and call delete on all items)
|
||||
void clear() VL_MT_SAFE;
|
||||
@@ -165,8 +165,8 @@ public:
|
||||
/// Return default filename for the current thread
|
||||
static std::string defaultFilename() VL_MT_SAFE { return threadCovp()->defaultFilename(); }
|
||||
/// Write all coverage data to a file for the current thread
|
||||
static void write(const std::string& filename) VL_MT_SAFE { threadCovp()->write(filename); }
|
||||
static void write() VL_MT_SAFE { write(defaultFilename()); }
|
||||
static void write(const std::string& filename) VL_MT_SAFE { threadCovp()->write(filename); }
|
||||
/// Clear coverage points (and call delete on all items) for the current thread
|
||||
static void clear() VL_MT_SAFE { threadCovp()->clear(); }
|
||||
/// Clear items not matching the provided string for the current thread
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2001-2024 by Wilson Snyder. This program is free software; you
|
||||
// Copyright 2001-2025 by Wilson Snyder. This program is free software; you
|
||||
// can redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2009-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2009-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -289,7 +289,7 @@ static void _vl_svGetBitArrElemVecVal(svBitVecVal* d, const svOpenArrayHandle s,
|
||||
}
|
||||
case VLVT_WDATA: {
|
||||
WDataOutP wdatap = (reinterpret_cast<WDataOutP>(datap));
|
||||
for (int i = 0; i < VL_WORDS_I(varp->packed().elements()); ++i) d[i] = wdatap[i];
|
||||
for (int i = 0; i < VL_WORDS_I(varp->entBits()); ++i) d[i] = wdatap[i];
|
||||
return;
|
||||
}
|
||||
default: // LCOV_EXCL_START // Errored earlier
|
||||
@@ -328,7 +328,7 @@ static void _vl_svGetLogicArrElemVecVal(svLogicVecVal* d, const svOpenArrayHandl
|
||||
}
|
||||
case VLVT_WDATA: {
|
||||
WDataOutP wdatap = (reinterpret_cast<WDataOutP>(datap));
|
||||
for (int i = 0; i < VL_WORDS_I(varp->packed().elements()); ++i) {
|
||||
for (int i = 0; i < VL_WORDS_I(varp->entBits()); ++i) {
|
||||
d[i].aval = wdatap[i];
|
||||
d[i].bval = 0;
|
||||
}
|
||||
@@ -354,7 +354,7 @@ static void _vl_svPutBitArrElemVecVal(const svOpenArrayHandle d, const svBitVecV
|
||||
case VLVT_UINT64: *(reinterpret_cast<QData*>(datap)) = VL_SET_QII(s[1], s[0]); break;
|
||||
case VLVT_WDATA: {
|
||||
WDataOutP wdatap = (reinterpret_cast<WDataOutP>(datap));
|
||||
for (int i = 0; i < VL_WORDS_I(varp->packed().elements()); ++i) wdatap[i] = s[i];
|
||||
for (int i = 0; i < VL_WORDS_I(varp->entBits()); ++i) wdatap[i] = s[i];
|
||||
return;
|
||||
}
|
||||
default: // LCOV_EXCL_START // Errored earlier
|
||||
@@ -376,7 +376,7 @@ static void _vl_svPutLogicArrElemVecVal(const svOpenArrayHandle d, const svLogic
|
||||
case VLVT_UINT64: *(reinterpret_cast<QData*>(datap)) = VL_SET_QII(s[1].aval, s[0].aval); break;
|
||||
case VLVT_WDATA: {
|
||||
WDataOutP wdatap = (reinterpret_cast<WDataOutP>(datap));
|
||||
for (int i = 0; i < VL_WORDS_I(varp->packed().elements()); ++i) wdatap[i] = s[i].aval;
|
||||
for (int i = 0; i < VL_WORDS_I(varp->entBits()); ++i) wdatap[i] = s[i].aval;
|
||||
return;
|
||||
}
|
||||
default: // LCOV_EXCL_START // Errored earlier
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2003-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2001-2024 by Wilson Snyder. This program is free software; you
|
||||
// Copyright 2001-2025 by Wilson Snyder. This program is free software; you
|
||||
// can redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -127,6 +127,7 @@ void VerilatedFst::declDTypeEnum(int dtypenum, const char* name, uint32_t elemen
|
||||
// TODO: should return std::optional<fstScopeType>, but I can't have C++17
|
||||
static std::pair<bool, fstScopeType> toFstScopeType(VerilatedTracePrefixType type) {
|
||||
switch (type) {
|
||||
case VerilatedTracePrefixType::ROOTIO_MODULE: return {true, FST_ST_VCD_MODULE};
|
||||
case VerilatedTracePrefixType::SCOPE_MODULE: return {true, FST_ST_VCD_MODULE};
|
||||
case VerilatedTracePrefixType::SCOPE_INTERFACE: return {true, FST_ST_VCD_INTERFACE};
|
||||
case VerilatedTracePrefixType::STRUCT_PACKED:
|
||||
@@ -137,7 +138,20 @@ static std::pair<bool, fstScopeType> toFstScopeType(VerilatedTracePrefixType typ
|
||||
}
|
||||
|
||||
void VerilatedFst::pushPrefix(const std::string& name, VerilatedTracePrefixType type) {
|
||||
const std::string newPrefix = m_prefixStack.back().first + name;
|
||||
assert(!m_prefixStack.empty()); // Constructor makes an empty entry
|
||||
std::string pname = name;
|
||||
// An empty name means this is the root of a model created with name()=="". The
|
||||
// tools get upset if we try to pass this as empty, so we put the signals under a
|
||||
// new scope, but the signals further down will be peers, not children (as usual
|
||||
// for name()!="")
|
||||
// Terminate earlier $root?
|
||||
if (m_prefixStack.back().second == VerilatedTracePrefixType::ROOTIO_MODULE) popPrefix();
|
||||
if (pname.empty()) { // Start new temporary root
|
||||
pname = "$rootio"; // VCD names are not backslash escaped
|
||||
m_prefixStack.emplace_back("", VerilatedTracePrefixType::ROOTIO_WRAPPER);
|
||||
type = VerilatedTracePrefixType::ROOTIO_MODULE;
|
||||
}
|
||||
const std::string newPrefix = m_prefixStack.back().first + pname;
|
||||
const auto pair = toFstScopeType(type);
|
||||
const bool properScope = pair.first;
|
||||
const fstScopeType scopeType = pair.second;
|
||||
@@ -149,10 +163,11 @@ void VerilatedFst::pushPrefix(const std::string& name, VerilatedTracePrefixType
|
||||
}
|
||||
|
||||
void VerilatedFst::popPrefix() {
|
||||
assert(!m_prefixStack.empty());
|
||||
const bool properScope = toFstScopeType(m_prefixStack.back().second).first;
|
||||
if (properScope) fstWriterSetUpscope(m_fst);
|
||||
m_prefixStack.pop_back();
|
||||
assert(!m_prefixStack.empty());
|
||||
assert(!m_prefixStack.empty()); // Always one left, the constructor's initial one
|
||||
}
|
||||
|
||||
void VerilatedFst::declare(uint32_t code, const char* name, int dtypenum,
|
||||
@@ -294,7 +309,7 @@ void VerilatedFst::configure(const VerilatedTraceConfig& config) {
|
||||
// so always inline them.
|
||||
|
||||
VL_ATTR_ALWINLINE
|
||||
void VerilatedFstBuffer::emitEvent(uint32_t code, const VlEventBase* newval) {
|
||||
void VerilatedFstBuffer::emitEvent(uint32_t code) {
|
||||
VL_DEBUG_IFDEF(assert(m_symbolp[code]););
|
||||
fstWriterEmitValueChange(m_fst, m_symbolp[code], "1");
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2001-2024 by Wilson Snyder. This program is free software; you
|
||||
// Copyright 2001-2025 by Wilson Snyder. This program is free software; you
|
||||
// can redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -47,7 +47,7 @@ private:
|
||||
friend VerilatedFstBuffer; // Give the buffer access to the private bits
|
||||
|
||||
//=========================================================================
|
||||
// FST specific internals
|
||||
// FST-specific internals
|
||||
|
||||
void* m_fst = nullptr;
|
||||
std::map<uint32_t, vlFstHandle> m_code2symbol;
|
||||
@@ -177,7 +177,7 @@ class VerilatedFstBuffer VL_NOT_FINAL {
|
||||
|
||||
// Implementations of duck-typed methods for VerilatedTraceBuffer. These are
|
||||
// called from only one place (the full* methods), so always inline them.
|
||||
VL_ATTR_ALWINLINE void emitEvent(uint32_t code, const VlEventBase* newval);
|
||||
VL_ATTR_ALWINLINE void emitEvent(uint32_t code);
|
||||
VL_ATTR_ALWINLINE void emitBit(uint32_t code, CData newval);
|
||||
VL_ATTR_ALWINLINE void emitCData(uint32_t code, CData newval, int bits);
|
||||
VL_ATTR_ALWINLINE void emitSData(uint32_t code, SData newval, int bits);
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// THIS MODULE IS PUBLICLY LICENSED
|
||||
//
|
||||
// Copyright 2001-2024 by Wilson Snyder. This program is free software; you
|
||||
// Copyright 2001-2025 by Wilson Snyder. This program is free software; you
|
||||
// can redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// -*- mode: C++; c-file-style: "cc-mode" -*-
|
||||
//=============================================================================
|
||||
//
|
||||
// Copyright 2001-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2001-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
|
||||
+117
-106
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2003-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -42,19 +42,20 @@ extern void vl_finish(const char* filename, int linenum, const char* hier) VL_MT
|
||||
/// Routine to call for $stop and non-fatal error
|
||||
/// User code may wish to replace this function, to do so, define VL_USER_STOP.
|
||||
/// This code does not have to be thread safe.
|
||||
/// Verilator internal code must call VL_FINISH_MT instead, which eventually calls this.
|
||||
/// Verilator internal code must call VL_STOP_MT instead, which eventually calls this.
|
||||
extern void vl_stop(const char* filename, int linenum, const char* hier) VL_MT_UNSAFE;
|
||||
|
||||
/// Routine to call for fatal messages
|
||||
/// User code may wish to replace this function, to do so, define VL_USER_FATAL.
|
||||
/// This code does not have to be thread safe.
|
||||
/// Verilator internal code must call VL_FINISH_MT instead, which eventually calls this.
|
||||
/// Verilator internal code must call VL_FATAL_MT instead, which eventually calls this.
|
||||
extern void vl_fatal(const char* filename, int linenum, const char* hier,
|
||||
const char* msg) VL_MT_UNSAFE;
|
||||
|
||||
/// Routine to call for warning messages
|
||||
/// User code may wish to replace this function, to do so, define VL_USER_WARN.
|
||||
/// This code does not have to be thread safe.
|
||||
/// Verilator internal code must call VL_WARN_MT instead, which eventually calls this.
|
||||
extern void vl_warn(const char* filename, int linenum, const char* hier,
|
||||
const char* msg) VL_MT_UNSAFE;
|
||||
|
||||
@@ -1603,26 +1604,26 @@ static inline IData VL_PACK_II(int obits, int lbits, const VlQueue<IData>& q) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline IData VL_PACK_II(int obits, int lbits, const VlUnpacked<CData, T_Depth>& q) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline IData VL_PACK_II(int obits, int lbits, const VlUnpacked<CData, N_Depth>& q) {
|
||||
IData ret = 0;
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
ret |= static_cast<IData>(q[T_Depth - 1 - i]) << (i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
ret |= static_cast<IData>(q[N_Depth - 1 - i]) << (i * lbits);
|
||||
return ret;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline IData VL_PACK_II(int obits, int lbits, const VlUnpacked<SData, T_Depth>& q) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline IData VL_PACK_II(int obits, int lbits, const VlUnpacked<SData, N_Depth>& q) {
|
||||
IData ret = 0;
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
ret |= static_cast<IData>(q[T_Depth - 1 - i]) << (i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
ret |= static_cast<IData>(q[N_Depth - 1 - i]) << (i * lbits);
|
||||
return ret;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline IData VL_PACK_II(int obits, int lbits, const VlUnpacked<IData, T_Depth>& q) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline IData VL_PACK_II(int obits, int lbits, const VlUnpacked<IData, N_Depth>& q) {
|
||||
IData ret = 0;
|
||||
for (size_t i = 0; i < T_Depth; ++i) ret |= q[T_Depth - 1 - i] << (i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i) ret |= q[N_Depth - 1 - i] << (i * lbits);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -1644,27 +1645,27 @@ static inline QData VL_PACK_QI(int obits, int lbits, const VlQueue<IData>& q) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline QData VL_PACK_QI(int obits, int lbits, const VlUnpacked<CData, T_Depth>& q) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline QData VL_PACK_QI(int obits, int lbits, const VlUnpacked<CData, N_Depth>& q) {
|
||||
QData ret = 0;
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
ret |= static_cast<QData>(q[T_Depth - 1 - i]) << (i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
ret |= static_cast<QData>(q[N_Depth - 1 - i]) << (i * lbits);
|
||||
return ret;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline QData VL_PACK_QI(int obits, int lbits, const VlUnpacked<SData, T_Depth>& q) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline QData VL_PACK_QI(int obits, int lbits, const VlUnpacked<SData, N_Depth>& q) {
|
||||
QData ret = 0;
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
ret |= static_cast<QData>(q[T_Depth - 1 - i]) << (i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
ret |= static_cast<QData>(q[N_Depth - 1 - i]) << (i * lbits);
|
||||
return ret;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline QData VL_PACK_QI(int obits, int lbits, const VlUnpacked<IData, T_Depth>& q) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline QData VL_PACK_QI(int obits, int lbits, const VlUnpacked<IData, N_Depth>& q) {
|
||||
QData ret = 0;
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
ret |= static_cast<QData>(q[T_Depth - 1 - i]) << (i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
ret |= static_cast<QData>(q[N_Depth - 1 - i]) << (i * lbits);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -1674,10 +1675,10 @@ static inline QData VL_PACK_QQ(int obits, int lbits, const VlQueue<QData>& q) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline QData VL_PACK_QQ(int obits, int lbits, const VlUnpacked<QData, T_Depth>& q) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline QData VL_PACK_QQ(int obits, int lbits, const VlUnpacked<QData, N_Depth>& q) {
|
||||
QData ret = 0;
|
||||
for (size_t i = 0; i < T_Depth; ++i) ret |= q[T_Depth - 1 - i] << (i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i) ret |= q[N_Depth - 1 - i] << (i * lbits);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -1702,30 +1703,30 @@ static inline WDataOutP VL_PACK_WI(int obits, int lbits, WDataOutP owp, const Vl
|
||||
return owp;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
template <std::size_t N_Depth>
|
||||
static inline WDataOutP VL_PACK_WI(int obits, int lbits, WDataOutP owp,
|
||||
const VlUnpacked<CData, T_Depth>& q) {
|
||||
const VlUnpacked<CData, N_Depth>& q) {
|
||||
VL_MEMSET_ZERO_W(owp + 1, VL_WORDS_I(obits) - 1);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
_vl_insert_WI(owp, q[T_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
_vl_insert_WI(owp, q[N_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
return owp;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
template <std::size_t N_Depth>
|
||||
static inline WDataOutP VL_PACK_WI(int obits, int lbits, WDataOutP owp,
|
||||
const VlUnpacked<SData, T_Depth>& q) {
|
||||
const VlUnpacked<SData, N_Depth>& q) {
|
||||
VL_MEMSET_ZERO_W(owp + 1, VL_WORDS_I(obits) - 1);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
_vl_insert_WI(owp, q[T_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
_vl_insert_WI(owp, q[N_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
return owp;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
template <std::size_t N_Depth>
|
||||
static inline WDataOutP VL_PACK_WI(int obits, int lbits, WDataOutP owp,
|
||||
const VlUnpacked<IData, T_Depth>& q) {
|
||||
const VlUnpacked<IData, N_Depth>& q) {
|
||||
VL_MEMSET_ZERO_W(owp + 1, VL_WORDS_I(obits) - 1);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
_vl_insert_WI(owp, q[T_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
_vl_insert_WI(owp, q[N_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
return owp;
|
||||
}
|
||||
|
||||
@@ -1736,30 +1737,30 @@ static inline WDataOutP VL_PACK_WQ(int obits, int lbits, WDataOutP owp, const Vl
|
||||
return owp;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
template <std::size_t N_Depth>
|
||||
static inline WDataOutP VL_PACK_WQ(int obits, int lbits, WDataOutP owp,
|
||||
const VlUnpacked<QData, T_Depth>& q) {
|
||||
const VlUnpacked<QData, N_Depth>& q) {
|
||||
VL_MEMSET_ZERO_W(owp + 1, VL_WORDS_I(obits) - 1);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
_vl_insert_WQ(owp, q[T_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
_vl_insert_WQ(owp, q[N_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
return owp;
|
||||
}
|
||||
|
||||
template <std::size_t N>
|
||||
template <std::size_t N_Words>
|
||||
static inline WDataOutP VL_PACK_WW(int obits, int lbits, WDataOutP owp,
|
||||
const VlQueue<VlWide<N>>& q) {
|
||||
const VlQueue<VlWide<N_Words>>& q) {
|
||||
VL_MEMSET_ZERO_W(owp + 1, VL_WORDS_I(obits) - 1);
|
||||
for (size_t i = 0; i < q.size(); ++i)
|
||||
_vl_insert_WW(owp, q.at(i), i * lbits + lbits - 1, i * lbits);
|
||||
return owp;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth, std::size_t N>
|
||||
template <std::size_t N_Depth, std::size_t N_Words>
|
||||
static inline WDataOutP VL_PACK_WW(int obits, int lbits, WDataOutP owp,
|
||||
const VlUnpacked<VlWide<N>, T_Depth>& q) {
|
||||
const VlUnpacked<VlWide<N_Words>, N_Depth>& q) {
|
||||
VL_MEMSET_ZERO_W(owp + 1, VL_WORDS_I(obits) - 1);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
_vl_insert_WW(owp, q[T_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
_vl_insert_WW(owp, q[N_Depth - 1 - i], i * lbits + lbits - 1, i * lbits);
|
||||
return owp;
|
||||
}
|
||||
|
||||
@@ -2206,165 +2207,175 @@ static inline void VL_UNPACK_II(int lbits, int rbits, VlQueue<CData>& q, IData f
|
||||
const size_t size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = (from >> (i * lbits)) & mask;
|
||||
for (size_t i = 0; i < size; ++i) q.atWrite(i) = (from >> (i * lbits)) & mask;
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_II(int lbits, int rbits, VlQueue<SData>& q, IData from) {
|
||||
const size_t size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = (from >> (i * lbits)) & mask;
|
||||
for (size_t i = 0; i < size; ++i) q.atWrite(i) = (from >> (i * lbits)) & mask;
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_II(int lbits, int rbits, VlQueue<IData>& q, IData from) {
|
||||
const size_t size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = (from >> (i * lbits)) & mask;
|
||||
for (size_t i = 0; i < size; ++i) q.atWrite(i) = (from >> (i * lbits)) & mask;
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlQueue<CData>& q, QData from) {
|
||||
const size_t size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = (from >> (i * lbits)) & mask;
|
||||
for (size_t i = 0; i < size; ++i) q.atWrite(i) = (from >> (i * lbits)) & mask;
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlQueue<SData>& q, QData from) {
|
||||
const size_t size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = (from >> (i * lbits)) & mask;
|
||||
for (size_t i = 0; i < size; ++i) q.atWrite(i) = (from >> (i * lbits)) & mask;
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlQueue<IData>& q, QData from) {
|
||||
const size_t size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = (from >> (i * lbits)) & mask;
|
||||
for (size_t i = 0; i < size; ++i) q.atWrite(i) = (from >> (i * lbits)) & mask;
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_QQ(int lbits, int rbits, VlQueue<QData>& q, QData from) {
|
||||
const size_t size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const QData mask = VL_MASK_Q(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = (from >> (i * lbits)) & mask;
|
||||
for (size_t i = 0; i < size; ++i) q.atWrite(i) = (from >> (i * lbits)) & mask;
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlQueue<CData>& q, WDataInP rwp) {
|
||||
const int size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = VL_SEL_IWII(rbits, rwp, i * lbits, lbits) & mask;
|
||||
for (size_t i = 0; i < size; ++i) {
|
||||
q.atWrite(i) = VL_SEL_IWII(rbits, rwp, i * lbits, lbits) & mask;
|
||||
}
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlQueue<SData>& q, WDataInP rwp) {
|
||||
const int size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = VL_SEL_IWII(rbits, rwp, i * lbits, lbits) & mask;
|
||||
for (size_t i = 0; i < size; ++i) {
|
||||
q.atWrite(i) = VL_SEL_IWII(rbits, rwp, i * lbits, lbits) & mask;
|
||||
}
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlQueue<IData>& q, WDataInP rwp) {
|
||||
const int size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = VL_SEL_IWII(rbits, rwp, i * lbits, lbits) & mask;
|
||||
for (size_t i = 0; i < size; ++i) {
|
||||
q.atWrite(i) = VL_SEL_IWII(rbits, rwp, i * lbits, lbits) & mask;
|
||||
}
|
||||
}
|
||||
|
||||
static inline void VL_UNPACK_QW(int lbits, int rbits, VlQueue<QData>& q, WDataInP rwp) {
|
||||
const int size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
const QData mask = VL_MASK_Q(lbits);
|
||||
for (size_t i = 0; i < size; ++i) q.at(i) = VL_SEL_QWII(rbits, rwp, i * lbits, lbits) & mask;
|
||||
for (size_t i = 0; i < size; ++i) {
|
||||
q.atWrite(i) = VL_SEL_QWII(rbits, rwp, i * lbits, lbits) & mask;
|
||||
}
|
||||
}
|
||||
|
||||
template <std::size_t N>
|
||||
static inline void VL_UNPACK_WW(int lbits, int rbits, VlQueue<VlWide<N>>& q, WDataInP rwp) {
|
||||
template <std::size_t N_Words>
|
||||
static inline void VL_UNPACK_WW(int lbits, int rbits, VlQueue<VlWide<N_Words>>& q, WDataInP rwp) {
|
||||
const int size = (rbits + lbits - 1) / lbits;
|
||||
q.renew(size);
|
||||
for (size_t i = 0; i < size; ++i) VL_SEL_WWII(lbits, rbits, q.at(i), rwp, i * lbits, lbits);
|
||||
for (size_t i = 0; i < size; ++i) {
|
||||
VL_SEL_WWII(lbits, rbits, q.atWrite(i), rwp, i * lbits, lbits);
|
||||
}
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_II(int lbits, int rbits, VlUnpacked<CData, T_Depth>& q, IData from) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_II(int lbits, int rbits, VlUnpacked<CData, N_Depth>& q, IData from) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i) q[i] = (from >> ((T_Depth - 1 - i) * lbits)) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i) q[i] = (from >> ((N_Depth - 1 - i) * lbits)) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_II(int lbits, int rbits, VlUnpacked<SData, T_Depth>& q, IData from) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_II(int lbits, int rbits, VlUnpacked<SData, N_Depth>& q, IData from) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i) q[i] = (from >> ((T_Depth - 1 - i) * lbits)) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i) q[i] = (from >> ((N_Depth - 1 - i) * lbits)) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_II(int lbits, int rbits, VlUnpacked<IData, T_Depth>& q, IData from) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_II(int lbits, int rbits, VlUnpacked<IData, N_Depth>& q, IData from) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i) q[i] = (from >> ((T_Depth - 1 - i) * lbits)) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i) q[i] = (from >> ((N_Depth - 1 - i) * lbits)) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlUnpacked<CData, T_Depth>& q, QData from) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlUnpacked<CData, N_Depth>& q, QData from) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i) q[i] = (from >> ((T_Depth - 1 - i) * lbits)) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i) q[i] = (from >> ((N_Depth - 1 - i) * lbits)) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlUnpacked<SData, T_Depth>& q, QData from) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlUnpacked<SData, N_Depth>& q, QData from) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i) q[i] = (from >> ((T_Depth - 1 - i) * lbits)) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i) q[i] = (from >> ((N_Depth - 1 - i) * lbits)) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlUnpacked<IData, T_Depth>& q, QData from) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_IQ(int lbits, int rbits, VlUnpacked<IData, N_Depth>& q, QData from) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i) q[i] = (from >> ((T_Depth - 1 - i) * lbits)) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i) q[i] = (from >> ((N_Depth - 1 - i) * lbits)) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_QQ(int lbits, int rbits, VlUnpacked<QData, T_Depth>& q, QData from) {
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_QQ(int lbits, int rbits, VlUnpacked<QData, N_Depth>& q, QData from) {
|
||||
const QData mask = VL_MASK_Q(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i) q[i] = (from >> ((T_Depth - 1 - i) * lbits)) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i) q[i] = (from >> ((N_Depth - 1 - i) * lbits)) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlUnpacked<CData, T_Depth>& q,
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlUnpacked<CData, N_Depth>& q,
|
||||
WDataInP rwp) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
q[i] = VL_SEL_IWII(rbits, rwp, (T_Depth - 1 - i) * lbits, lbits) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
q[i] = VL_SEL_IWII(rbits, rwp, (N_Depth - 1 - i) * lbits, lbits) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlUnpacked<SData, T_Depth>& q,
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlUnpacked<SData, N_Depth>& q,
|
||||
WDataInP rwp) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
q[i] = VL_SEL_IWII(rbits, rwp, (T_Depth - 1 - i) * lbits, lbits) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
q[i] = VL_SEL_IWII(rbits, rwp, (N_Depth - 1 - i) * lbits, lbits) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlUnpacked<IData, T_Depth>& q,
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_IW(int lbits, int rbits, VlUnpacked<IData, N_Depth>& q,
|
||||
WDataInP rwp) {
|
||||
const IData mask = VL_MASK_I(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
q[i] = VL_SEL_IWII(rbits, rwp, (T_Depth - 1 - i) * lbits, lbits) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
q[i] = VL_SEL_IWII(rbits, rwp, (N_Depth - 1 - i) * lbits, lbits) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth>
|
||||
static inline void VL_UNPACK_QW(int lbits, int rbits, VlUnpacked<QData, T_Depth>& q,
|
||||
template <std::size_t N_Depth>
|
||||
static inline void VL_UNPACK_QW(int lbits, int rbits, VlUnpacked<QData, N_Depth>& q,
|
||||
WDataInP rwp) {
|
||||
const QData mask = VL_MASK_Q(lbits);
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
q[i] = VL_SEL_QWII(rbits, rwp, (T_Depth - 1 - i) * lbits, lbits) & mask;
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
q[i] = VL_SEL_QWII(rbits, rwp, (N_Depth - 1 - i) * lbits, lbits) & mask;
|
||||
}
|
||||
|
||||
template <std::size_t T_Depth, std::size_t N>
|
||||
static inline void VL_UNPACK_WW(int lbits, int rbits, VlUnpacked<VlWide<N>, T_Depth>& q,
|
||||
template <std::size_t N_Depth, std::size_t N_Words>
|
||||
static inline void VL_UNPACK_WW(int lbits, int rbits, VlUnpacked<VlWide<N_Words>, N_Depth>& q,
|
||||
WDataInP rwp) {
|
||||
for (size_t i = 0; i < T_Depth; ++i)
|
||||
VL_SEL_WWII(lbits, rbits, q[i], rwp, (T_Depth - 1 - i) * lbits, lbits);
|
||||
for (size_t i = 0; i < N_Depth; ++i)
|
||||
VL_SEL_WWII(lbits, rbits, q[i], rwp, (N_Depth - 1 - i) * lbits, lbits);
|
||||
}
|
||||
|
||||
// Return QData from double (numeric)
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2009-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2009-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
//
|
||||
// Code available from: https://verilator.org
|
||||
//
|
||||
// Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||
// Copyright 2003-2025 by Wilson Snyder. This program is free software; you can
|
||||
// redistribute it and/or modify it under the terms of either the GNU
|
||||
// Lesser General Public License Version 3 or the Perl Artistic License
|
||||
// Version 2.0.
|
||||
@@ -12,13 +12,13 @@
|
||||
//*************************************************************************
|
||||
///
|
||||
/// \file
|
||||
/// \brief Verilator common target specific intrinsics header
|
||||
/// \brief Verilator common target-specific intrinsics header
|
||||
///
|
||||
/// This file is not part of the Verilated public-facing API.
|
||||
///
|
||||
/// It is only for internal use; code using machine specific intrinsics for
|
||||
/// It is only for internal use; code using machine-specific intrinsics for
|
||||
/// optimization should include this header rather than directly including
|
||||
/// he target specific headers. We provide macros to check for availability
|
||||
/// the target-specific headers. We provide macros to check for availability
|
||||
/// of instruction sets, and a common mechanism to disable them.
|
||||
///
|
||||
//*************************************************************************
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user