mirror of
https://github.com/verilator/verilator.git
synced 2026-10-06 01:54:01 +02:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
522bead374 | ||
|
|
030286142f | ||
|
|
8a4ceb5717 | ||
|
|
63fa6accc4 | ||
|
|
28718f964a | ||
|
|
1d486e3a59 | ||
|
|
9b396f7125 | ||
|
|
e16cbce52e | ||
|
|
840970e8f7 | ||
|
|
e390d6779d | ||
|
|
39ee522f92 | ||
|
|
9526efcf72 | ||
|
|
d397e0d838 | ||
|
|
8301fdc6d3 | ||
|
|
f645382f11 | ||
|
|
1ed5557d2d | ||
|
|
28b9216f8a | ||
|
|
0114cb67ca | ||
|
|
ea8f86dd30 | ||
|
|
0ff77fc352 | ||
|
|
341963e820 | ||
|
|
db60b92613 | ||
|
|
98206a4f04 | ||
|
|
4df9e2e0e5 | ||
|
|
34e4cffb62 | ||
|
|
71d76c993c | ||
|
|
e67bdb4c08 | ||
|
|
23f013f2d7 | ||
|
|
9b729b80e0 | ||
|
|
38ad328956 | ||
|
|
f767f0cfaa | ||
|
|
1c79df8630 | ||
|
|
248573205b | ||
|
|
88831ca21b | ||
|
|
26f15e11c4 | ||
|
|
5c0a7e06dc | ||
|
|
290b313dc0 | ||
|
|
93e5ca3f6d | ||
|
|
6ffff8565f | ||
|
|
494e05b326 | ||
|
|
a24f61403a | ||
|
|
292cc54768 | ||
|
|
e8a9662eb5 | ||
|
|
0262819c20 | ||
|
|
d3b93a1113 | ||
|
|
5f8c06c805 | ||
|
|
a5ad26cd28 | ||
|
|
5802818b9a | ||
|
|
df519ff16e | ||
|
|
bf8a88a0ad | ||
|
|
878204db73 | ||
|
|
08c76b1da6 | ||
|
|
e82c9db6da | ||
|
|
65c3cb4708 | ||
|
|
0cab076b86 | ||
|
|
3a28ed24ea | ||
|
|
71775eae4c | ||
|
|
953249aa43 | ||
|
|
229dbbb100 | ||
|
|
4a439beae5 | ||
|
|
49022c3e73 | ||
|
|
c92ced4ac7 | ||
|
|
ba47da6587 | ||
|
|
2c27f22900 | ||
|
|
c0391990ad | ||
|
|
2247e1e345 | ||
|
|
e4847464d4 | ||
|
|
7694a7bf41 | ||
|
|
a686e547cf | ||
|
|
1481d34959 | ||
|
|
04512e5d04 | ||
|
|
9a3aed57b1 | ||
|
|
5a69321be3 | ||
|
|
5ee938fd1c | ||
|
|
f78783e187 | ||
|
|
11bfe7a7bb | ||
|
|
8ba494c71f | ||
|
|
acb63c929b | ||
|
|
26dd5d4550 | ||
|
|
32f288084a | ||
|
|
6db149c588 | ||
|
|
0fed5f8b3e | ||
|
|
a30930bdcc | ||
|
|
3a1355fb54 | ||
|
|
97db128d66 | ||
|
|
3d57256070 | ||
|
|
5dc8fb5b4f | ||
|
|
3f0d434f82 | ||
|
|
2cdc5ea48b | ||
|
|
745605efe3 | ||
|
|
0fbd4313b2 | ||
|
|
9f8f61ef2f | ||
|
|
4b1f4938b8 | ||
|
|
5f1dc73a1b | ||
|
|
5e1fc6e24d | ||
|
|
0ec32ee404 | ||
|
|
97b21b3849 | ||
|
|
214173c6b8 | ||
|
|
3786f59e03 | ||
|
|
fa7234ff68 | ||
|
|
91dd3c5fac | ||
|
|
a378dbd9b2 | ||
|
|
da9521a351 | ||
|
|
af51107587 | ||
|
|
e60f652a64 | ||
|
|
a4813ec677 | ||
|
|
01dadb0a8d | ||
|
|
9dcb7ea6a9 | ||
|
|
adfe072b89 | ||
|
|
b12f8b3d73 | ||
|
|
f56f318217 | ||
|
|
3af0eb7fa0 | ||
|
|
a69cb9b044 | ||
|
|
b68a696859 | ||
|
|
e320b0b581 | ||
|
|
42041f2403 | ||
|
|
881c6ee655 | ||
|
|
d8b2993974 | ||
|
|
30e711aa5c | ||
|
|
51ae8e13fb | ||
|
|
0892b39ad2 | ||
|
|
5964d5cf63 | ||
|
|
2162a31d3a | ||
|
|
e00e4d4245 | ||
|
|
4b9532fe24 | ||
|
|
c3ff52208a | ||
|
|
cfb73923bd | ||
|
|
a951446f9b | ||
|
|
a187a16e56 | ||
|
|
d1dec38f38 | ||
|
|
65b632a7dd | ||
|
|
ec0787015e | ||
|
|
cbc76a7816 | ||
|
|
d667b73e8d | ||
|
|
248de2be2e | ||
|
|
365537d8e3 | ||
|
|
a23cf1ceea | ||
|
|
be471e9ccc | ||
|
|
d0e7eaafc9 | ||
|
|
13b7cce8be | ||
|
|
efff630763 | ||
|
|
e2e0795538 | ||
|
|
c20634e4f8 | ||
|
|
715dce546f | ||
|
|
07d86bf91d | ||
|
|
fe8c7c5a94 | ||
|
|
7ada5195d8 | ||
|
|
a6ad85244f | ||
|
|
f13f2296de | ||
|
|
b1d901f100 | ||
|
|
8ab576f7e6 | ||
|
|
6f92c9c974 | ||
|
|
7425037db6 | ||
|
|
6ca60429ce | ||
|
|
c702fc944e | ||
|
|
999c9ae21c | ||
|
|
c715cfc254 | ||
|
|
22687a6901 | ||
|
|
eecdf4b0f3 | ||
|
|
e3e5f30ba1 | ||
|
|
ce174743bb | ||
|
|
a84be1844f | ||
|
|
9ccef4180f | ||
|
|
3bf896f7db | ||
|
|
e4a0e5aad6 | ||
|
|
d6f8ccd20b | ||
|
|
94460867d3 | ||
|
|
5b70325e52 | ||
|
|
3aece189ac | ||
|
|
188f0eb4ad | ||
|
|
d4c8a15407 | ||
|
|
354a534d68 | ||
|
|
c8a40e0b52 | ||
|
|
771cb5f60b | ||
|
|
23836ee8d0 | ||
|
|
8a7f36c34b | ||
|
|
31262e81f9 | ||
|
|
3d006afacc | ||
|
|
74ec50f933 | ||
|
|
21e85f87bc | ||
|
|
0b8daf4ae4 | ||
|
|
6c0c88cfc4 | ||
|
|
f0d010d9c5 | ||
|
|
2989e54eaa | ||
|
|
1a2c9ca813 | ||
|
|
e3f3e3399f | ||
|
|
6b8531f0a6 | ||
|
|
50df902b54 | ||
|
|
3a5248a919 | ||
|
|
1a92502788 | ||
|
|
a38fea1f9e | ||
|
|
d595d4c7ac | ||
|
|
a43fd06f85 | ||
|
|
375a121377 | ||
|
|
fef0502d50 | ||
|
|
c30b9d04a8 | ||
|
|
89cfa0737f | ||
|
|
8b03f2d47b | ||
|
|
f80c167d65 | ||
|
|
db3ce29b36 | ||
|
|
6f96c6763d | ||
|
|
372cdf1fc8 | ||
|
|
54922c036a | ||
|
|
2e999a5441 | ||
|
|
5073f208af | ||
|
|
c9d7486d16 | ||
|
|
27d906a6b3 | ||
|
|
21bf2d62d2 | ||
|
|
fcdd8e5da6 | ||
|
|
ab47fc6656 | ||
|
|
5f52c066e5 | ||
|
|
19cb366e5d | ||
|
|
55d1b87b34 | ||
|
|
eec41fd039 | ||
|
|
69043549d6 | ||
|
|
68e4eeb53e | ||
|
|
0ca90257a5 | ||
|
|
7507c5f56c | ||
|
|
acbbb2594a | ||
|
|
5294140753 | ||
|
|
a36a07c297 | ||
|
|
47b129bf07 | ||
|
|
1a0c8f1573 | ||
|
|
2be6f03848 | ||
|
|
4172c0f29e | ||
|
|
ec01008fe3 | ||
|
|
8ea814e4b4 | ||
|
|
0195fe9dfd | ||
|
|
e430ea13f4 | ||
|
|
719954a24a | ||
|
|
3adb31f53b | ||
|
|
3eaed3b6f5 | ||
|
|
22de598456 | ||
|
|
5c5314b39c | ||
|
|
e76f29e5ba | ||
|
|
5a83209b9b | ||
|
|
4655ee014b | ||
|
|
12f0017d4a | ||
|
|
ca3b5fbe99 | ||
|
|
9de6612cde | ||
|
|
2d7e8b58e4 | ||
|
|
f3a97841bd | ||
|
|
40f0378136 | ||
|
|
17b6ce1379 | ||
|
|
14ac24cacc | ||
|
|
6bf253deda | ||
|
|
aa4346a0e3 | ||
|
|
8c541a6e4d | ||
|
|
1a43afe6f7 | ||
|
|
9882c4c761 | ||
|
|
54ad04b6e9 | ||
|
|
540cd772e4 | ||
|
|
621de301c7 | ||
|
|
8769c1a92b | ||
|
|
8e1c0b0852 | ||
|
|
56d6791205 | ||
|
|
016e630ecf | ||
|
|
69b779b4a8 | ||
|
|
7a537765bc | ||
|
|
21b2e874ce | ||
|
|
55ad950609 | ||
|
|
654ab117f2 | ||
|
|
5ec9bfc47d | ||
|
|
1066f06ec1 | ||
|
|
668dbb25ab | ||
|
|
fced4d6e57 | ||
|
|
c5ba6e22fa | ||
|
|
6012ec8eb7 | ||
|
|
75a44e5aa9 | ||
|
|
a811f2e17d | ||
|
|
b65f2509a2 | ||
|
|
b60117c713 | ||
|
|
d3142736c8 | ||
|
|
1ececf1127 | ||
|
|
a09f7713ce | ||
|
|
f3bace10ae | ||
|
|
39d9bd4d47 | ||
|
|
eb2cfe1d19 | ||
|
|
ca5a7d7656 | ||
|
|
ea2084392f | ||
|
|
5d99534d54 | ||
|
|
f048cff093 | ||
|
|
f571181d36 | ||
|
|
fc9b66b078 | ||
|
|
f039a94744 | ||
|
|
b4baa7ce02 | ||
|
|
bd38c8fe3c | ||
|
|
9a0748d8ed | ||
|
|
feae9ca4aa | ||
|
|
d1ee9827a0 | ||
|
|
1fe591ae20 | ||
|
|
b820e1b587 | ||
|
|
ebfc2a4942 | ||
|
|
7167d4bdc0 | ||
|
|
a022b672a0 | ||
|
|
a7a48221d3 | ||
|
|
e5118661a7 | ||
|
|
58d9a5ebac | ||
|
|
fae7f11222 | ||
|
|
1986e62477 | ||
|
|
0ee2a0e6d7 | ||
|
|
2b28ddd0c6 | ||
|
|
b15ef49c57 | ||
|
|
ed05caec93 | ||
|
|
25ca965938 | ||
|
|
ead27db9f0 | ||
|
|
4650105d90 | ||
|
|
b8417abee5 | ||
|
|
cc982ec7fe | ||
|
|
2dba76a7c2 | ||
|
|
9fd5634778 | ||
|
|
c8063e5732 | ||
|
|
ee3ba7c761 | ||
|
|
2882737bcd | ||
|
|
47588f343b | ||
|
|
1c0af6c7bc | ||
|
|
b07ffb3c78 | ||
|
|
bea82def10 | ||
|
|
671a857560 | ||
|
|
eff2d977c1 | ||
|
|
30a0d62436 | ||
|
|
91d0f25442 | ||
|
|
4a10c9ef6f | ||
|
|
9d7f5bdc26 | ||
|
|
99dbd23f1b | ||
|
|
673f086e87 | ||
|
|
4103925835 | ||
|
|
cad2780219 | ||
|
|
4636a7f14b | ||
|
|
a64bdf50fb | ||
|
|
706534ffe1 | ||
|
|
4286af3599 | ||
|
|
9a0254a118 | ||
|
|
f3ae4b8786 | ||
|
|
6566e853cd | ||
|
|
ab06ace1f6 | ||
|
|
9a65ed4ce2 | ||
|
|
5ba7084815 | ||
|
|
dc10118d3b | ||
|
|
27102ea0fb | ||
|
|
c563175ff0 | ||
|
|
b110c55993 | ||
|
|
dc346b7ffa | ||
|
|
88fcbf5f1d | ||
|
|
eace1d9c67 | ||
|
|
d0d39c13e7 | ||
|
|
2733d43ea7 | ||
|
|
ae6ec411d0 | ||
|
|
8a77af7a6d | ||
|
|
2a57ead7e3 | ||
|
|
839315b271 | ||
|
|
67dfa37c56 | ||
|
|
590188820d | ||
|
|
a764c70b4a | ||
|
|
a27abab65f | ||
|
|
c241ec90ec | ||
|
|
f789d28277 | ||
|
|
c1c8b30a35 | ||
|
|
15046c6c59 | ||
|
|
1da15181da | ||
|
|
3c6b755352 | ||
|
|
3c144ada53 | ||
|
|
7ba6647c4f | ||
|
|
e708670f9a | ||
|
|
de4c6065dc | ||
|
|
d60f180f43 | ||
|
|
30318a6654 | ||
|
|
d8420413b7 | ||
|
|
a5951babfc | ||
|
|
2cba167634 | ||
|
|
89743aae5d | ||
|
|
e6135981a5 | ||
|
|
739521333c | ||
|
|
64af83161a | ||
|
|
98252634fc | ||
|
|
a87fb57656 | ||
|
|
34708bbba1 | ||
|
|
f91259f46d | ||
|
|
cf6e362972 | ||
|
|
95c4ade718 | ||
|
|
84125d7c92 | ||
|
|
17721aff55 | ||
|
|
d1b6224c2b | ||
|
|
1bd31742b9 | ||
|
|
165a2ef1b8 | ||
|
|
774c10396c | ||
|
|
33c5b5feb8 | ||
|
|
b83b9974ee | ||
|
|
bcbe5059a9 | ||
|
|
5bda901146 | ||
|
|
82565690c7 | ||
|
|
978d900e36 | ||
|
|
d330100542 | ||
|
|
4c0edd2efb | ||
|
|
146cdc020d | ||
|
|
52f2b9ef58 | ||
|
|
a09506a0ad | ||
|
|
10d33238b9 | ||
|
|
b78ea06829 | ||
|
|
eae942b91c | ||
|
|
1075b006b5 | ||
|
|
afaa02709c | ||
|
|
332a687aef | ||
|
|
d1c7875406 | ||
|
|
cbc2f9eb32 | ||
|
|
26e3785963 | ||
|
|
f8b7fb72b8 | ||
|
|
7b12f6a1dd | ||
|
|
c7a0613c57 | ||
|
|
83a0085c4d | ||
|
|
05bb7fa821 | ||
|
|
4cc42133b5 | ||
|
|
a773a52559 | ||
|
|
5af271cf3a | ||
|
|
0c2bab1f69 | ||
|
|
b7233d063f | ||
|
|
8720841c48 | ||
|
|
263697e491 | ||
|
|
493f1da266 | ||
|
|
8b44a54bb2 | ||
|
|
b5828a7ce9 | ||
|
|
51a18225ad | ||
|
|
28625451dd | ||
|
|
3914176bc4 | ||
|
|
13989b965d | ||
|
|
770cd24f27 | ||
|
|
431bb1ed16 | ||
|
|
3bb9c7ee92 | ||
|
|
45edcbb03e | ||
|
|
e99fd2892b | ||
|
|
99ea16d7fd | ||
|
|
bc9ff6d1bf | ||
|
|
ad3bcbb1bb | ||
|
|
25dde58297 | ||
|
|
bba3487dc4 | ||
|
|
4fdaa46328 | ||
|
|
4427f03b08 | ||
|
|
4e2c63c8cb | ||
|
|
afecde87d8 | ||
|
|
c14eae6d56 | ||
|
|
684aba0e90 | ||
|
|
46f8a659b3 | ||
|
|
3940a214d0 | ||
|
|
411f563cbe | ||
|
|
b5a6b34968 | ||
|
|
fa8eaf7355 | ||
|
|
7eb09c3445 | ||
|
|
edfd3d7206 | ||
|
|
d699caf255 | ||
|
|
bd4eede6b4 | ||
|
|
1fd8e772b0 | ||
|
|
7ce0bd1181 | ||
|
|
a4b7c39a9a | ||
|
|
a5ee8b39ef | ||
|
|
5b06c60318 | ||
|
|
b306715b4a | ||
|
|
8d99bdac25 | ||
|
|
e114dfda6d | ||
|
|
472ad90d83 | ||
|
|
622f0c047c | ||
|
|
7f38414276 | ||
|
|
1d3d59243c | ||
|
|
e2343c03e0 | ||
|
|
0e0df1fb3b | ||
|
|
800a789f50 | ||
|
|
106664b942 | ||
|
|
1c738c6b83 | ||
|
|
25fa1d7c6a | ||
|
|
45162652de | ||
|
|
537650a2cd | ||
|
|
f849073137 | ||
|
|
a3c154dcd3 | ||
|
|
1b8228b642 | ||
|
|
732d03f4e5 | ||
|
|
33787c6add | ||
|
|
44e7d2ebe6 | ||
|
|
e49ae663a6 | ||
|
|
2385ab8294 | ||
|
|
84ccb23098 | ||
|
|
ad343f8260 | ||
|
|
018d766179 | ||
|
|
a948be184c | ||
|
|
72b4a74245 | ||
|
|
36c824d973 | ||
|
|
229ce1aecf | ||
|
|
be45a9b7d5 | ||
|
|
d2c72a7f21 | ||
|
|
60e9827ffe | ||
|
|
a9256d4758 | ||
|
|
750b5be5d3 | ||
|
|
28bd7e5b19 | ||
|
|
d64c023099 | ||
|
|
429cb1f7f7 | ||
|
|
9f75068059 | ||
|
|
4636e9cffb | ||
|
|
4b2bf556d8 | ||
|
|
a16ea94836 | ||
|
|
b9ea249f81 | ||
|
|
470f480bc1 | ||
|
|
24ff3155ae | ||
|
|
47b3f464a9 | ||
|
|
cd201f8eb8 | ||
|
|
016278a759 | ||
|
|
b68f101e81 | ||
|
|
ab13548018 | ||
|
|
f507ee56b0 | ||
|
|
761adf1cf0 | ||
|
|
cd1fe64e6c | ||
|
|
8f43e74288 | ||
|
|
cef3960a4e | ||
|
|
783b7ecdab | ||
|
|
8bd1c63b32 | ||
|
|
e6fb7e970d | ||
|
|
891cc0f9b6 | ||
|
|
10fbe74cef | ||
|
|
05d04a3959 | ||
|
|
19f7279542 | ||
|
|
aa608472ae | ||
|
|
26ed2a06a0 | ||
|
|
07013da13d | ||
|
|
d840c612d4 | ||
|
|
188cf85b3f | ||
|
|
c52ba28dd0 | ||
|
|
10c1653e72 | ||
|
|
2fbd41e13b | ||
|
|
96857c5f95 | ||
|
|
131eb319e0 | ||
|
|
6e589377f4 | ||
|
|
2c84b37bf7 | ||
|
|
0d67caff77 | ||
|
|
3dde57d539 | ||
|
|
ec2e3ec0e4 | ||
|
|
9fe459c820 | ||
|
|
823e0723fb | ||
|
|
8bd6d7c5b1 | ||
|
|
839a8fa4d9 | ||
|
|
24917a187a | ||
|
|
6c6f03cf7c | ||
|
|
5676443139 | ||
|
|
e77d847671 | ||
|
|
0baee84e96 | ||
|
|
c446cc2596 | ||
|
|
b66c4153b1 | ||
|
|
d72f1b89fc | ||
|
|
b5b278d072 | ||
|
|
cb5466a90b | ||
|
|
4de25369da | ||
|
|
cdd8953085 | ||
|
|
2f2f0164ff | ||
|
|
6e977e1024 | ||
|
|
70b11f91b4 | ||
|
|
014301587f | ||
|
|
139e93d371 | ||
|
|
fb1fc46b06 | ||
|
|
9882ab6c67 | ||
|
|
1a1f919882 | ||
|
|
91227d26bb | ||
|
|
11b5dae88d | ||
|
|
0c7d485417 | ||
|
|
c40e34b134 | ||
|
|
6cdf8da3f7 | ||
|
|
c65265477f | ||
|
|
de77f1ee5c | ||
|
|
c8c980c49d | ||
|
|
ad329612fd | ||
|
|
c324895cbc | ||
|
|
679a4314dc | ||
|
|
36932d31c4 | ||
|
|
ed25aaaad9 | ||
|
|
147aa41ba5 | ||
|
|
5b7e32581b | ||
|
|
2f90fb2bec | ||
|
|
8c480fd39e | ||
|
|
ffbbd438ae | ||
|
|
96ee81fa3f | ||
|
|
3d2399ea0f | ||
|
|
6d5dde8645 | ||
|
|
048c9f3fe2 | ||
|
|
373265752f | ||
|
|
5e6519c1b0 | ||
|
|
ccdb52c1d9 | ||
|
|
b4b74d72f0 | ||
|
|
ca6ab584d0 | ||
|
|
799a502cac | ||
|
|
8d1570db28 | ||
|
|
2a30bbe493 | ||
|
|
cf6566b9bc | ||
|
|
c3e19f2821 | ||
|
|
e24197fd16 | ||
|
|
63db60f646 | ||
|
|
e66b28823d | ||
|
|
77bd565ef6 | ||
|
|
00d63883f8 | ||
|
|
10dd675371 | ||
|
|
2daa32b98b | ||
|
|
e8e7912871 | ||
|
|
90079c2974 | ||
|
|
967a8530dd | ||
|
|
ef4794e36d | ||
|
|
7c7c92d2dd | ||
|
|
95f3dd0535 | ||
|
|
768b78e7d0 | ||
|
|
4370254e73 | ||
|
|
436f72582b | ||
|
|
af3aba7821 | ||
|
|
7479db6ffc | ||
|
|
e9cc2786b7 | ||
|
|
cbdee5a804 | ||
|
|
0f66262fa1 | ||
|
|
6c80457262 | ||
|
|
16008acdf1 | ||
|
|
5447ed2629 | ||
|
|
9eba61018a | ||
|
|
bc97319402 | ||
|
|
709db5c648 | ||
|
|
b752faa107 | ||
|
|
8d512c3187 | ||
|
|
2d9bc73709 | ||
|
|
b0942ed8c7 | ||
|
|
b1c1aa53a9 | ||
|
|
f79749e7b2 | ||
|
|
1a77030c9b | ||
|
|
817ade27fb | ||
|
|
4afa14b612 | ||
|
|
9caa79a7ea | ||
|
|
446f21d2a0 | ||
|
|
06521f6cf1 | ||
|
|
75336670d7 | ||
|
|
106a9fe67f | ||
|
|
a5eccc199b | ||
|
|
837d9f9d77 | ||
|
|
959387b69f | ||
|
|
fd0703b8c8 | ||
|
|
3ff608b9cb | ||
|
|
edc0a0e982 | ||
|
|
1549ff9185 | ||
|
|
3454641244 | ||
|
|
5dedf25e3b | ||
|
|
7214c180ae | ||
|
|
aa0ef554b3 | ||
|
|
a6015863d8 | ||
|
|
5a694ccb8a | ||
|
|
f7d09c671a | ||
|
|
4de1b22672 | ||
|
|
4bdda3f240 | ||
|
|
ced1dfeffd | ||
|
|
0774f825cf | ||
|
|
23fe5c1b93 | ||
|
|
bd4afeea69 | ||
|
|
3ee9b33f8a | ||
|
|
5be0813893 | ||
|
|
f94c1b32e5 | ||
|
|
ff4923cf67 | ||
|
|
5788bc8048 | ||
|
|
5749662194 | ||
|
|
d5d1cc47e0 | ||
|
|
da043ca16d | ||
|
|
9aa90569bf | ||
|
|
294d78e0e2 | ||
|
|
8182c3fe2c | ||
|
|
6f7bc38088 | ||
|
|
dcbc0ccfdc | ||
|
|
399319dc1c | ||
|
|
35d6da391b | ||
|
|
fcbd7c87af | ||
|
|
97feba6898 | ||
|
|
9249ffdb84 | ||
|
|
71df9e3381 | ||
|
|
3c964147be | ||
|
|
54b4b6b378 | ||
|
|
cff37f0775 | ||
|
|
8b1cc3b303 | ||
|
|
65b6121186 | ||
|
|
3d30527860 | ||
|
|
24a9f7c650 | ||
|
|
242f661644 | ||
|
|
32019d2bc4 | ||
|
|
b252bb048f | ||
|
|
ba47c01a01 | ||
|
|
51266898ec | ||
|
|
f9164ab0d2 | ||
|
|
c43e707f43 | ||
|
|
85b7f828b3 | ||
|
|
7005a65d32 | ||
|
|
776d4e6ac2 | ||
|
|
1c88c3083c | ||
|
|
4522834f7a | ||
|
|
9ee5fd0585 | ||
|
|
63b2dbb827 | ||
|
|
5bee8ef15b | ||
|
|
e7de3d368f | ||
|
|
d45deccc0a | ||
|
|
d5b03ab721 | ||
|
|
d1ff81a41c | ||
|
|
43fa6858f6 | ||
|
|
db7eb45433 | ||
|
|
21c01ba97b | ||
|
|
b517fb5ee3 | ||
|
|
9dbc669199 | ||
|
|
7d2d32420a | ||
|
|
48e98ea2bd | ||
|
|
01d0f0327b | ||
|
|
0dc887720d | ||
|
|
e08bbcdb07 | ||
|
|
70d26ec123 | ||
|
|
a06f260f42 | ||
|
|
d42f76c346 | ||
|
|
66c3d6d2d1 | ||
|
|
81affad2dc | ||
|
|
2488af9066 | ||
|
|
5cf9d78516 | ||
|
|
3a9eeabdb2 | ||
|
|
ac4315e145 | ||
|
|
5094e94df1 | ||
|
|
4b7b185d05 | ||
|
|
6cb0335d28 | ||
|
|
c248318958 | ||
|
|
c3e5db5f04 | ||
|
|
058233fc87 | ||
|
|
186c851695 | ||
|
|
5aa36357f6 | ||
|
|
191d30cf1c | ||
|
|
d8c2ecaaf8 | ||
|
|
a7b0551d23 | ||
|
|
dc34968fe7 | ||
|
|
45f064f7cb | ||
|
|
545caba720 | ||
|
|
0e24f36fef | ||
|
|
db7935faf3 | ||
|
|
9cc218db3e | ||
|
|
15f8ebc562 | ||
|
|
205cae963b | ||
|
|
df2746de71 | ||
|
|
7f471d862e | ||
|
|
338acabe2b | ||
|
|
4f1f487ae4 | ||
|
|
77502aeb97 | ||
|
|
ba82d43ca1 | ||
|
|
e9135598b3 | ||
|
|
1c0739db10 | ||
|
|
dfd3907787 | ||
|
|
1069652701 | ||
|
|
70b82f1aec | ||
|
|
5573bdb219 | ||
|
|
cf68578261 | ||
|
|
f407d442d4 | ||
|
|
7f12ad9d91 | ||
|
|
5efe9367d2 | ||
|
|
cfce92645f | ||
|
|
519792d02b | ||
|
|
bfa1f2d7ce | ||
|
|
42beaf467c | ||
|
|
8303938d0e | ||
|
|
0ece155418 | ||
|
|
4f7e155e59 | ||
|
|
ff324625e4 | ||
|
|
fd7515b046 | ||
|
|
607f853bc7 | ||
|
|
09fb1174f1 | ||
|
|
542eaab3dd | ||
|
|
a301a498f5 | ||
|
|
d66e749ec8 | ||
|
|
c8ca54ea31 | ||
|
|
5704552053 | ||
|
|
426069a4dd | ||
|
|
19d0aabe7a | ||
|
|
fb0d735f68 | ||
|
|
167a30be1c | ||
|
|
5982528274 | ||
|
|
de3095e3b4 | ||
|
|
8e0682f442 | ||
|
|
140994d2c4 | ||
|
|
950e29d56e | ||
|
|
65667356b6 | ||
|
|
6b393e9d7c | ||
|
|
4818130e4f | ||
|
|
9da3aacd08 | ||
|
|
729f8b9334 | ||
|
|
279216048b | ||
|
|
2ce7a348df | ||
|
|
46f719ceaa | ||
|
|
949be301de | ||
|
|
be429a5800 | ||
|
|
e7714e0902 | ||
|
|
4835ed6967 | ||
|
|
0198a3fc52 | ||
|
|
e095bf1af0 | ||
|
|
d5de67c6dc | ||
|
|
2267db093f | ||
|
|
5aecfa98a1 | ||
|
|
485e230dd8 | ||
|
|
befb415f27 | ||
|
|
c0490627bf | ||
|
|
d269fbb446 | ||
|
|
444020f7c7 | ||
|
|
6188083baa | ||
|
|
c2a524d80b | ||
|
|
e6f5a0495f | ||
|
|
0606a29f13 | ||
|
|
c6052830e1 | ||
|
|
4bb876aee5 | ||
|
|
a3640c1767 | ||
|
|
250c6950cf | ||
|
|
76f5de6e54 | ||
|
|
1a1c5c5d44 | ||
|
|
4ae80f9a9f | ||
|
|
8a3cb8daa8 | ||
|
|
64ab537b68 | ||
|
|
fdea386727 | ||
|
|
28944ed862 | ||
|
|
3250ee5707 | ||
|
|
d308a561e4 | ||
|
|
584f8cc9e7 | ||
|
|
61e1483b74 | ||
|
|
3bb4e34044 | ||
|
|
832b17d4d2 | ||
|
|
76c5875912 | ||
|
|
266dc7679a | ||
|
|
d693dc85e4 | ||
|
|
add68130b8 | ||
|
|
d9b5680a45 | ||
|
|
dc25be536c | ||
|
|
7708c88e32 | ||
|
|
707f230353 | ||
|
|
49d2eb9a08 | ||
|
|
128186ea68 | ||
|
|
949be9d0a1 | ||
|
|
3e986517c3 | ||
|
|
5d3a9eec7f | ||
|
|
3d21a79148 | ||
|
|
e15f5266a3 | ||
|
|
9130eb8b99 | ||
|
|
09e856d2f3 | ||
|
|
ee5c0a2902 | ||
|
|
621b7e63cf | ||
|
|
c6bf9fb89e | ||
|
|
f794180865 | ||
|
|
0e769d42a1 | ||
|
|
cbeb9d39ff | ||
|
|
5a98c1a3b1 | ||
|
|
cac634d39b | ||
|
|
08330bad0b | ||
|
|
84a46939b3 | ||
|
|
65a484e00b | ||
|
|
843fdd3e57 | ||
|
|
a10b51705f | ||
|
|
df86e39845 | ||
|
|
7f49b6c102 | ||
|
|
754a0b8320 | ||
|
|
7d3b3761b2 | ||
|
|
d1b80ffa29 | ||
|
|
f95ce886f1 | ||
|
|
fa16eff003 | ||
|
|
23f90b13f3 | ||
|
|
37e7b5dfc7 | ||
|
|
e1683afb31 | ||
|
|
e38b359d75 | ||
|
|
b6dcec2710 | ||
|
|
0307d59c1f | ||
|
|
3aa013c8db | ||
|
|
fc70876aa9 | ||
|
|
722ab9306a | ||
|
|
2ab34b5eeb | ||
|
|
e3bdae77a0 | ||
|
|
663d6a1c8d | ||
|
|
bf5cbb512e | ||
|
|
d4bb58630e | ||
|
|
fff0eb5d88 | ||
|
|
7ae0c5d546 | ||
|
|
114d93b212 | ||
|
|
13a87e5514 | ||
|
|
d67d75282c | ||
|
|
827cbf22c9 | ||
|
|
2530cda507 | ||
|
|
38000a3da0 | ||
|
|
6c21b21ecc | ||
|
|
8caf9be3e6 | ||
|
|
cdb61842d6 | ||
|
|
05660d1118 | ||
|
|
a3f9221a67 | ||
|
|
7e1980af7a | ||
|
|
921fd919b5 | ||
|
|
fc5a5ea53d | ||
|
|
86156dd05b | ||
|
|
3219ffddd4 | ||
|
|
3a01c32bf9 | ||
|
|
9ffd0a4e70 | ||
|
|
90e049c674 | ||
|
|
69121633cf | ||
|
|
28eadded87 | ||
|
|
93c598dd19 | ||
|
|
d012563ab1 | ||
|
|
0b96789e65 | ||
|
|
947402bc57 | ||
|
|
d4107dce52 | ||
|
|
990b19e048 | ||
|
|
2290e6ccf2 | ||
|
|
14c8f072f1 | ||
|
|
c55df02b1a | ||
|
|
5b86248b54 | ||
|
|
449ac44131 | ||
|
|
f439a7927f | ||
|
|
277bd67f72 | ||
|
|
5de8ccbf32 | ||
|
|
577e0700ba | ||
|
|
71a37484f5 | ||
|
|
daf157e6c0 | ||
|
|
2aa6a229ca | ||
|
|
9b869edd90 | ||
|
|
2b21697b86 | ||
|
|
895ab8789b | ||
|
|
5f02f95ce6 | ||
|
|
f2aac8c49a | ||
|
|
82e653a739 | ||
|
|
053f760e2a | ||
|
|
ba9e141fae | ||
|
|
d60a3e2b66 | ||
|
|
70c2d1eded | ||
|
|
80cbf81b3b | ||
|
|
798d7346cf | ||
|
|
d6c5d40f9b | ||
|
|
371b8310d9 | ||
|
|
1ac721af8f | ||
|
|
85fd88ace2 | ||
|
|
ed1e377bb1 | ||
|
|
4240c29f4b | ||
|
|
51ba4a1531 | ||
|
|
d1b55cb7aa | ||
|
|
bbf53bd5af | ||
|
|
b2ced6ff1d | ||
|
|
a9b07fe7d7 | ||
|
|
66e4656a8e | ||
|
|
8f4d4f07a4 | ||
|
|
8e55580cde | ||
|
|
8ae79066a2 | ||
|
|
36da6a3563 | ||
|
|
45690faea7 | ||
|
|
046fecbb35 | ||
|
|
0f6024ef3c | ||
|
|
2488b5a97f | ||
|
|
56de6f1a9f | ||
|
|
0fc5d37901 | ||
|
|
ea4cc4e076 | ||
|
|
9e25c21fed | ||
|
|
fc3fdcc71c | ||
|
|
80b7b8bbdb | ||
|
|
a8ce272e4a | ||
|
|
72963c4e20 | ||
|
|
4e5bd361e0 | ||
|
|
ed1a9309d4 | ||
|
|
1d0a06438c | ||
|
|
2c62714a30 | ||
|
|
f13e753b52 | ||
|
|
39a5bce8a6 | ||
|
|
ba953bfa94 | ||
|
|
1debd0405b | ||
|
|
1f1d9312d2 | ||
|
|
259201b352 | ||
|
|
bb45bd048e | ||
|
|
5489ec6eff | ||
|
|
e55e81bcd0 | ||
|
|
5c5c758718 | ||
|
|
b87669039e | ||
|
|
60a6ed2a20 | ||
|
|
81e8388c3f | ||
|
|
4532680e5f | ||
|
|
fc17ab280a | ||
|
|
621cd0f008 | ||
|
|
13c9877099 | ||
|
|
ff889fde18 | ||
|
|
f68c16a5e6 | ||
|
|
cc45f64280 | ||
|
|
725ec088ea | ||
|
|
87c3de5aab | ||
|
|
6d7c04a3de | ||
|
|
d0f5ce0cc4 | ||
|
|
cb89ef9885 | ||
|
|
90360d40fd | ||
|
|
15dcd326f8 | ||
|
|
ae1eb56695 | ||
|
|
a47fd07585 | ||
|
|
19bc257002 | ||
|
|
a1d4cd658e | ||
|
|
21093fd1bd | ||
|
|
329a933efd | ||
|
|
e21198cb2d | ||
|
|
ab502c5196 | ||
|
|
12728bc478 | ||
|
|
3fc684359a | ||
|
|
1e28387541 | ||
|
|
dd917d50eb | ||
|
|
0130c2bceb | ||
|
|
8a5804fc3a | ||
|
|
3df29085c8 | ||
|
|
976af0068b | ||
|
|
a85e6a9d8c | ||
|
|
463ea57b0a | ||
|
|
326a60d307 | ||
|
|
2c60c5f816 | ||
|
|
faf3804b9a | ||
|
|
08a433260c | ||
|
|
7fc278f6db | ||
|
|
b1a95f642f | ||
|
|
c6a569df49 | ||
|
|
06661ab676 | ||
|
|
d9a0e69597 | ||
|
|
a0997d0b98 | ||
|
|
a3ff375ce7 | ||
|
|
c03affa544 | ||
|
|
4703fc39be | ||
|
|
9bf0e54937 | ||
|
|
b039f246df | ||
|
|
a93b344096 | ||
|
|
191c71edea | ||
|
|
b4dd398af6 | ||
|
|
cfe0fdd5cc | ||
|
|
003a8cfe75 | ||
|
|
7559af5879 | ||
|
|
47a7e75841 | ||
|
|
adf1de45de | ||
|
|
45f955f175 | ||
|
|
063f9a7a4c | ||
|
|
c82a098f2e | ||
|
|
393b7714c4 | ||
|
|
43d8de4f80 | ||
|
|
026bbc306b | ||
|
|
f8b0e359b9 | ||
|
|
94ef1b76d0 | ||
|
|
50929e5d43 | ||
|
|
3f4b7af8a1 | ||
|
|
bc6a7787ed | ||
|
|
5064ec2806 | ||
|
|
4f19eeaffa | ||
|
|
10d0088f73 | ||
|
|
15d0ec317d | ||
|
|
260d58e47e | ||
|
|
d9c4d9316f | ||
|
|
e9441cff50 | ||
|
|
daa545774e | ||
|
|
dee2e45e27 | ||
|
|
4d29487e75 | ||
|
|
2bb2935924 | ||
|
|
aff3f7c4f6 | ||
|
|
5aa4f46101 | ||
|
|
8f87022496 | ||
|
|
d34aa10faf | ||
|
|
93d50c4499 | ||
|
|
4eb280601e | ||
|
|
b778784333 | ||
|
|
9121a81a74 | ||
|
|
d3cbb1e53f | ||
|
|
cf88700fc2 | ||
|
|
072d76fe8e | ||
|
|
3436d1780f | ||
|
|
1607225063 | ||
|
|
807e5b22a0 | ||
|
|
2c64b83c19 | ||
|
|
dfc98e77c0 | ||
|
|
936bb7b1ed | ||
|
|
88e5017564 | ||
|
|
508f6f7e5a | ||
|
|
70eceae3d8 | ||
|
|
eb5aad94f1 | ||
|
|
2d89c458f6 | ||
|
|
d33ded22f9 | ||
|
|
edc32ca82d | ||
|
|
dc9c81256d | ||
|
|
6908e471e7 | ||
|
|
e3558d9e1b | ||
|
|
11043aeb9b | ||
|
|
15c163c12e | ||
|
|
c7ed73e249 | ||
|
|
4aa3e72509 | ||
|
|
31130c4b4a | ||
|
|
00f0027c80 | ||
|
|
c8be50d40b | ||
|
|
e16e9b89cd | ||
|
|
80b291407b | ||
|
|
d2aff13402 | ||
|
|
82f450d838 | ||
|
|
f6d4f1ad02 | ||
|
|
645e1387e0 | ||
|
|
d3c14cc1ac | ||
|
|
33468fa0e7 | ||
|
|
0e955d503e | ||
|
|
18e317fb78 | ||
|
|
ef9f443532 | ||
|
|
6e3b957b30 | ||
|
|
aea1834ed8 | ||
|
|
7f3e178b68 | ||
|
|
87a7881d46 | ||
|
|
29f4821d78 | ||
|
|
9f9c84aa64 | ||
|
|
d80e0523cc | ||
|
|
164aa96953 | ||
|
|
6a12c4d02a | ||
|
|
6a7dfb7696 | ||
|
|
4208db7811 | ||
|
|
a19dddf05e | ||
|
|
7855a78a0f | ||
|
|
248bd173d3 | ||
|
|
8d2be855f5 | ||
|
|
ba8700f99d | ||
|
|
f20997a2f0 | ||
|
|
bea225e191 | ||
|
|
93517b8378 | ||
|
|
a39c7f7dac | ||
|
|
5125b94fd8 | ||
|
|
d118a739dc | ||
|
|
c2a8810eb1 | ||
|
|
91c44d7830 | ||
|
|
21aafe8f50 | ||
|
|
4a8cfe367d | ||
|
|
b56e7f6910 | ||
|
|
8a85cedaf5 | ||
|
|
be26e8da1b | ||
|
|
b2dd5de860 | ||
|
|
6ea725f479 | ||
|
|
665758a68b | ||
|
|
5b8941d717 | ||
|
|
f4865a4bb2 | ||
|
|
53835355b0 | ||
|
|
5cd3d831bb | ||
|
|
3069860fdf | ||
|
|
3a8288b0f6 | ||
|
|
30fd49e21f | ||
|
|
bc7048e8d1 | ||
|
|
a98eceb501 | ||
|
|
c2bdd06fcc | ||
|
|
8918f17c17 | ||
|
|
604af511fc | ||
|
|
5a39fc4ba9 | ||
|
|
30d6edd2e5 | ||
|
|
79f99dddf7 | ||
|
|
c3fa475096 | ||
|
|
5ef373500f | ||
|
|
be53eec5ca | ||
|
|
41e5f6b7d5 | ||
|
|
c1c0aa61f9 | ||
|
|
e94023367f | ||
|
|
317fe7a787 | ||
|
|
035bf13e4a | ||
|
|
6a60ace2c7 | ||
|
|
901d1d8087 | ||
|
|
6cd26edb64 | ||
|
|
956fd89b87 | ||
|
|
3fe81a3832 | ||
|
|
ff2f711d0c | ||
|
|
46cc7b5d07 | ||
|
|
4d453c6822 | ||
|
|
a1160a85a3 | ||
|
|
e5eb7d8930 | ||
|
|
83f6b11235 | ||
|
|
5fce23e90d | ||
|
|
7e4760a7e4 | ||
|
|
2d6d1235d6 | ||
|
|
520f6e5fdc | ||
|
|
30f6831be6 | ||
|
|
26e2f9e629 | ||
|
|
1d2293b783 | ||
|
|
4784daa7dc | ||
|
|
78fe77db0f | ||
|
|
c039a5229d | ||
|
|
2ab70ba452 | ||
|
|
4370490a71 | ||
|
|
816cff009a | ||
|
|
e004ea7ae2 | ||
|
|
6159a7dd8d | ||
|
|
be65030d61 | ||
|
|
a168d593eb | ||
|
|
6ab47f799b | ||
|
|
fd52f7f479 | ||
|
|
b24d7c83d3 | ||
|
|
bf4a844f2b | ||
|
|
5dbff89a90 | ||
|
|
9255707dd4 | ||
|
|
24198ef0ed | ||
|
|
8064b78d4f | ||
|
|
fde380868a | ||
|
|
be42dc906c | ||
|
|
bad4110b03 | ||
|
|
f6b101d98b | ||
|
|
80a144797d | ||
|
|
a86ded97c9 | ||
|
|
45abcb6107 | ||
|
|
1f58f48c05 | ||
|
|
d5a18c99fe | ||
|
|
c0499da28b | ||
|
|
3ccb2e0f2d | ||
|
|
afd7c2ae25 | ||
|
|
bb44d4e4f2 | ||
|
|
d64971ba35 | ||
|
|
71d29a235f | ||
|
|
65daf99bf4 | ||
|
|
299261714b | ||
|
|
c2b09e35f8 | ||
|
|
c3b4bc85fa | ||
|
|
3340f7b0b4 | ||
|
|
cb413aa264 | ||
|
|
982fa3d7bb | ||
|
|
51de2c9194 | ||
|
|
a15cd76a28 | ||
|
|
7a15457511 | ||
|
|
4f7df4a915 | ||
|
|
a554dd7c8d | ||
|
|
073af8e1f2 | ||
|
|
2eafd82696 | ||
|
|
7d93952a0d | ||
|
|
1ddb2dd5e7 | ||
|
|
2770ddf071 | ||
|
|
bae60ab8ea | ||
|
|
4cefccf5d2 | ||
|
|
925fb921a2 | ||
|
|
fcd1306ef3 | ||
|
|
9d2f1c607a | ||
|
|
f331c192b4 | ||
|
|
d192372c7e | ||
|
|
7b073fec7d | ||
|
|
424faa883e | ||
|
|
61d6546400 | ||
|
|
972a11537c | ||
|
|
609bfa46e8 | ||
|
|
01b521a0ea | ||
|
|
0a3c90e517 | ||
|
|
afc66f6a85 | ||
|
|
722e38f532 | ||
|
|
86b07423a9 | ||
|
|
3f4d4dec77 | ||
|
|
86e3c02339 | ||
|
|
b6cdae30f6 | ||
|
|
a9ff0a0f32 | ||
|
|
a0e7930036 | ||
|
|
d61ad04f32 | ||
|
|
0824ef377f | ||
|
|
fc2654f1f6 | ||
|
|
5aa935d170 | ||
|
|
bcf58defe0 | ||
|
|
2dc0053ea4 | ||
|
|
4b6e15d0eb | ||
|
|
87bb32fde1 | ||
|
|
ea1b141d13 | ||
|
|
84c7368621 | ||
|
|
675cc891a5 | ||
|
|
0809c17ce1 | ||
|
|
f27cf4c804 | ||
|
|
701d2277cd | ||
|
|
338e875b70 | ||
|
|
87135d0b2d | ||
|
|
e465a30eee | ||
|
|
889a1211f1 | ||
|
|
31d8b4cb8e | ||
|
|
d87ef8394a | ||
|
|
4f4c26383c | ||
|
|
42e4e18ec8 | ||
|
|
355c4f76d0 | ||
|
|
073dc03adc | ||
|
|
468a33b61c | ||
|
|
8ff607f679 | ||
|
|
6143892619 | ||
|
|
b51bb4d0e7 | ||
|
|
f0a7abcef8 | ||
|
|
faedcc755b | ||
|
|
ff9596bb23 | ||
|
|
7d807a7e0e | ||
|
|
e569ff2752 | ||
|
|
68e1b473e2 | ||
|
|
4452a9b10f | ||
|
|
6349e76abd | ||
|
|
f4be3d5d2b | ||
|
|
054b792021 | ||
|
|
c303ba7f0a | ||
|
|
2c7f1ef40f | ||
|
|
5f583b0680 | ||
|
|
fa4270b551 | ||
|
|
d8071819fc | ||
|
|
833780fac1 | ||
|
|
4b3731d318 | ||
|
|
68f8617f79 | ||
|
|
a83ed6b06f | ||
|
|
821dd070bf | ||
|
|
06fdf7be58 | ||
|
|
e97e6c2213 | ||
|
|
508e937164 | ||
|
|
57975c82b7 | ||
|
|
66d85b3381 | ||
|
|
73d6de4471 | ||
|
|
0af02563ca | ||
|
|
b82ce5743b | ||
|
|
d3c1f4353e | ||
|
|
62bdd3ab49 | ||
|
|
2eed4452ad | ||
|
|
f44cd9cd48 | ||
|
|
25f970eac2 | ||
|
|
3abb65d732 | ||
|
|
352d0b4582 | ||
|
|
a60e273c29 | ||
|
|
47253450a4 | ||
|
|
278d532368 | ||
|
|
6297650fef | ||
|
|
5634e96bb6 | ||
|
|
e266b2cb03 | ||
|
|
0af3efda5c | ||
|
|
d3e1c40238 | ||
|
|
aacb38b776 | ||
|
|
21d80cdfa1 | ||
|
|
d0e7177d8e | ||
|
|
cd2208ea3f | ||
|
|
3a27e3d67b | ||
|
|
09dff9c3a7 | ||
|
|
f266b02bc7 | ||
|
|
de9c92fd14 | ||
|
|
0322e9da7e | ||
|
|
b2d92b7c25 | ||
|
|
ef72b73a59 | ||
|
|
749aab0a56 | ||
|
|
cd8528e83b | ||
|
|
e8a1e4745c | ||
|
|
96306b7630 | ||
|
|
d41efb189d | ||
|
|
3c77c7bb92 | ||
|
|
3ddfa214e3 | ||
|
|
a58cd66358 | ||
|
|
79e0fa3327 | ||
|
|
f782496092 | ||
|
|
dc28e7f3e2 | ||
|
|
e6da59eecd | ||
|
|
04f68cbd99 | ||
|
|
8c6d1e53ca | ||
|
|
c6ecd60993 | ||
|
|
ee26dddfa1 | ||
|
|
d1658b9e82 | ||
|
|
818347f99b | ||
|
|
201419c646 | ||
|
|
d25834e57b | ||
|
|
4f50073feb | ||
|
|
218dd4322b | ||
|
|
eaf09ba0e7 | ||
|
|
8291d8bcc1 | ||
|
|
0a045a7bf6 | ||
|
|
dbcaad99c5 | ||
|
|
6736e92cdb | ||
|
|
a427860825 | ||
|
|
41d2ebe288 | ||
|
|
227e61f891 | ||
|
|
b2e61425d6 | ||
|
|
9d7c4d9af3 | ||
|
|
0c75d4eaca | ||
|
|
528a73a492 | ||
|
|
fbf2e59c85 | ||
|
|
16586d1d37 | ||
|
|
441b5da5ce | ||
|
|
207bc2b18a | ||
|
|
e64295e92b | ||
|
|
cbf9cc8e5f | ||
|
|
a29d9469da | ||
|
|
2a3eabff73 | ||
|
|
454efbe3fc | ||
|
|
fb9ec03c3f | ||
|
|
21926eeb6b | ||
|
|
6ae6b16223 | ||
|
|
167f4ebbd4 | ||
|
|
d6126c4b32 | ||
|
|
8d61cea366 | ||
|
|
65e08f4dbf | ||
|
|
cf4c00e3b4 | ||
|
|
bac98df46b | ||
|
|
0b0b642241 | ||
|
|
52d29d238c | ||
|
|
0675510eb9 | ||
|
|
99791ac8b3 | ||
|
|
ee26378394 | ||
|
|
54c4351c39 | ||
|
|
e504e9aced | ||
|
|
ef2776034e | ||
|
|
5c658f8cd5 | ||
|
|
0ed7aaeabd | ||
|
|
5f9b0929b4 | ||
|
|
65290afe0a | ||
|
|
ed93a111c2 | ||
|
|
3487701b04 | ||
|
|
d33a3d09f7 | ||
|
|
0716a28816 | ||
|
|
8e1901da10 | ||
|
|
ecfa385f13 | ||
|
|
63df87e220 | ||
|
|
495d52d30f | ||
|
|
2df886b2b0 | ||
|
|
fcf0d03cd4 | ||
|
|
4154584c4b | ||
|
|
a57a3579c0 | ||
|
|
203993b018 | ||
|
|
347e9b4ec8 | ||
|
|
9d02082801 | ||
|
|
785c51dd0b | ||
|
|
2e4f5c863f | ||
|
|
196f3292d5 | ||
|
|
627a144b83 | ||
|
|
5688d1a935 | ||
|
|
8b0d71994d | ||
|
|
79682e6072 | ||
|
|
7e1b92fa75 | ||
|
|
ca8ef7ce73 | ||
|
|
23d538fdaf | ||
|
|
aaadc3def7 | ||
|
|
444a4a760c | ||
|
|
b42799f3b5 | ||
|
|
7b07cf912e | ||
|
|
6a3ec17887 | ||
|
|
8c3ca30c91 | ||
|
|
0e4da3b0bf | ||
|
|
e6add5e0b8 | ||
|
|
22243d1e49 | ||
|
|
bec0b7d4d0 | ||
|
|
f6f13c7fda | ||
|
|
e7068369fe | ||
|
|
b930d0731a | ||
|
|
2723223884 | ||
|
|
b6c116d4bf | ||
|
|
54e3f15dce | ||
|
|
c057847760 | ||
|
|
46c5764383 | ||
|
|
22ce36012e | ||
|
|
5c65e0cfa1 | ||
|
|
840e26b69a | ||
|
|
5e79652922 | ||
|
|
cb7b024e8f | ||
|
|
f3292a3651 | ||
|
|
76ccd332a6 | ||
|
|
3cd2c8532d | ||
|
|
c0739e908c | ||
|
|
379a947379 | ||
|
|
916a3d9066 | ||
|
|
b16b607b98 | ||
|
|
732d5bea10 | ||
|
|
d9a0d0ade2 | ||
|
|
e32ff0e1a6 | ||
|
|
5957156dee | ||
|
|
14f58ed6c7 | ||
|
|
038d57070b | ||
|
|
8a347248f5 | ||
|
|
caed086516 | ||
|
|
68927d4fd3 | ||
|
|
b2070a9407 | ||
|
|
8dacbdec3a | ||
|
|
2a110c91cf | ||
|
|
ba052beccd | ||
|
|
6f9c585452 | ||
|
|
18c26b90af | ||
|
|
ff49f797e5 | ||
|
|
c033a0d7c8 | ||
|
|
461f3c1004 | ||
|
|
90447d54d1 | ||
|
|
439d30a953 | ||
|
|
a972230b3a | ||
|
|
29a080dd9b | ||
|
|
0570cb8d9f | ||
|
|
6fa14bf029 | ||
|
|
4f0158b5e0 | ||
|
|
97add4d57a | ||
|
|
5b742571d3 | ||
|
|
a83043d735 | ||
|
|
22fcd616aa | ||
|
|
1a8188e1b4 | ||
|
|
f87fe4c3b4 | ||
|
|
f23f3ca907 | ||
|
|
965d99f1bc | ||
|
|
56ac054fb2 | ||
|
|
ced82cbac4 | ||
|
|
2fc1746ef5 | ||
|
|
10fc1f757c | ||
|
|
90009b9ec7 | ||
|
|
4367e03e46 | ||
|
|
c9634695a7 | ||
|
|
2a12b052f2 | ||
|
|
84b9502af4 | ||
|
|
694bdbc130 | ||
|
|
880cac2fdd | ||
|
|
a204b24fcf | ||
|
|
526e6b9fc7 | ||
|
|
f1ba6cb517 | ||
|
|
159cf0429c | ||
|
|
46b8dca360 | ||
|
|
4db998d357 | ||
|
|
0b843ada03 | ||
|
|
746c7ea8f7 | ||
|
|
5ed882faf2 | ||
|
|
fa4b10b4d9 | ||
|
|
cc51966ad1 | ||
|
|
c9d6344f2f | ||
|
|
acebafcbc2 | ||
|
|
4a1a2def95 | ||
|
|
09e352ef66 | ||
|
|
17976d7401 | ||
|
|
f25a9a4c80 | ||
|
|
cd2a5771b8 | ||
|
|
9c2ead90d5 | ||
|
|
a999c73ce0 | ||
|
|
b92173bf3d | ||
|
|
91823c41c5 | ||
|
|
c6bce636ee | ||
|
|
75a70bee6d | ||
|
|
1b1907af49 | ||
|
|
1b18eee5dc | ||
|
|
4931e48016 | ||
|
|
1b17acdb01 | ||
|
|
9c1cc5465d | ||
|
|
d8b5359fcb | ||
|
|
f96454adcc | ||
|
|
9da012568c | ||
|
|
9a20a258f5 | ||
|
|
10796457d2 | ||
|
|
78e659a142 | ||
|
|
2f50642ecb | ||
|
|
47bce4157d | ||
|
|
3a8a314566 | ||
|
|
050060b139 | ||
|
|
ddb678cc5b | ||
|
|
63c694f65f | ||
|
|
12093e6939 | ||
|
|
9949a6cd17 | ||
|
|
4600932d8c | ||
|
|
79ded3bb61 | ||
|
|
95145038b4 | ||
|
|
ce03293128 | ||
|
|
72e7271a14 | ||
|
|
0a8cfb8d2c | ||
|
|
0b07679ff2 | ||
|
|
550a5111b7 | ||
|
|
d162619bd3 | ||
|
|
5df14627fd | ||
|
|
fc3ce29845 | ||
|
|
bba800f2d6 | ||
|
|
fe2a1e1749 | ||
|
|
fc4ffd454e | ||
|
|
8dae4ad93a | ||
|
|
8da261f302 | ||
|
|
7bc7b5372e | ||
|
|
7d88e63bab | ||
|
|
a214fd1f78 | ||
|
|
79be097e34 | ||
|
|
11b0d36ba2 | ||
|
|
1234ee5fd2 | ||
|
|
80b73859a2 | ||
|
|
a548a77f26 | ||
|
|
d6bfb37e6a | ||
|
|
af305bf280 | ||
|
|
38a8d7fb2e | ||
|
|
0c70a0dcbf | ||
|
|
d16619fe86 | ||
|
|
ab6e1c2399 | ||
|
|
2dc85a5acd | ||
|
|
dbe1348b4c | ||
|
|
22846df03e | ||
|
|
d74536a4dc | ||
|
|
da20da264b | ||
|
|
22b9dfb9c9 | ||
|
|
27031ed688 | ||
|
|
e43c089ab8 | ||
|
|
d85b909054 | ||
|
|
75fd71d7e5 | ||
|
|
9efd64ab98 | ||
|
|
7aa01625d8 | ||
|
|
a3c58d7b70 | ||
|
|
ae466b1703 | ||
|
|
2564484429 | ||
|
|
93a044f587 | ||
|
|
81fe35ee2e | ||
|
|
08b6bdddf9 | ||
|
|
4d49db48a3 | ||
|
|
9b2266f68c | ||
|
|
752f425025 | ||
|
|
47262cd4ec | ||
|
|
47e64535d6 | ||
|
|
45d622e4bc | ||
|
|
249feaae7c | ||
|
|
9a27004ae5 | ||
|
|
42283150d7 | ||
|
|
5a1bcf9794 | ||
|
|
361cef4633 | ||
|
|
90ab746a42 | ||
|
|
e94cdcf29c | ||
|
|
1af046986d | ||
|
|
1c9263a25b | ||
|
|
fd6275a62b | ||
|
|
6b6790fc50 | ||
|
|
fb931087ab | ||
|
|
a2e1b32a1c | ||
|
|
54f89bce42 | ||
|
|
8b19d02e3b | ||
|
|
da7ad35577 | ||
|
|
937e893b6d | ||
|
|
d42a2d6494 | ||
|
|
8e8f4b1e5c | ||
|
|
298f71f2b1 | ||
|
|
2ba39b25f1 | ||
|
|
5c828b7e60 | ||
|
|
4640bea31a | ||
|
|
875361d7ce | ||
|
|
849bb5590a | ||
|
|
8d0c06e570 | ||
|
|
5b2fbf4f37 | ||
|
|
592dab2bdb | ||
|
|
51daa64e9a | ||
|
|
c0f9b0d8f6 | ||
|
|
505bba14eb | ||
|
|
ebbe24966c | ||
|
|
881c3f6e40 | ||
|
|
546aeab9f2 | ||
|
|
8de21e9bb7 | ||
|
|
2ecda74471 | ||
|
|
2136afde6b | ||
|
|
ea55db7286 | ||
|
|
819e8741cc | ||
|
|
6a5f77b278 | ||
|
|
8658a0d7dc | ||
|
|
c335aad25f | ||
|
|
9d9d647c1f | ||
|
|
d47a37fb76 | ||
|
|
24ec84851a | ||
|
|
0a3a15a66e | ||
|
|
2358ced061 | ||
|
|
2af5304884 | ||
|
|
5869fdf7f6 | ||
|
|
1a1d2ecfd9 | ||
|
|
5c356a4680 | ||
|
|
39af5d020e | ||
|
|
9ac64d0b92 | ||
|
|
7cc89b8b42 | ||
|
|
c6607724cb | ||
|
|
ebb37b0156 | ||
|
|
90dc04cf93 | ||
|
|
10cf492946 | ||
|
|
4d81eb021d | ||
|
|
83475008d9 | ||
|
|
03ac7ad730 | ||
|
|
cd50949a7e | ||
|
|
f0040c7b9a | ||
|
|
f8a0389e73 | ||
|
|
b436794773 | ||
|
|
1404319b28 | ||
|
|
90d22cbec6 | ||
|
|
33e2acfe61 | ||
|
|
db5fdfb0ee | ||
|
|
951cd73fe0 | ||
|
|
0eeb40b975 | ||
|
|
93272c13fd | ||
|
|
43abaeb055 | ||
|
|
18b9e661c9 | ||
|
|
f435d96241 | ||
|
|
d32e3f042f | ||
|
|
df5f95a5bd | ||
|
|
b0c475205b | ||
|
|
1e2219347e | ||
|
|
cbe1b8e266 | ||
|
|
2b12fe5773 | ||
|
|
a4fd6d38fb | ||
|
|
d20f22beb1 | ||
|
|
f4fe10844b | ||
|
|
122e89ffde | ||
|
|
c266739e9f | ||
|
|
96a4b3e5a5 | ||
|
|
7403226a97 | ||
|
|
fac8e76923 | ||
|
|
b864f5f5ba | ||
|
|
f9f66d787e | ||
|
|
bd211c87aa | ||
|
|
6c33e6e889 | ||
|
|
6fc25dae9e | ||
|
|
cfb6fd8b34 | ||
|
|
39d1a62f9e | ||
|
|
ba66fa7200 | ||
|
|
cb60663d49 | ||
|
|
0d2bf23d82 | ||
|
|
682a60e325 | ||
|
|
2ab6272cc7 | ||
|
|
152a6cd886 | ||
|
|
3c54d5df70 | ||
|
|
f91793e931 | ||
|
|
12925cd8b0 | ||
|
|
daac7cb90d | ||
|
|
a2d26b45bb | ||
|
|
dce8f3d25d | ||
|
|
38e5b6c1ad | ||
|
|
4859f5e1fa | ||
|
|
b9d7819faa | ||
|
|
ad2fbfe62d | ||
|
|
1f9323d086 | ||
|
|
574dbfded1 | ||
|
|
2a87387eb3 | ||
|
|
a5ddd10e31 | ||
|
|
e871cd8a44 | ||
|
|
7b431b37c7 | ||
|
|
eeef5ab4de | ||
|
|
ac4ec87942 | ||
|
|
290c2e0388 | ||
|
|
89924bda51 | ||
|
|
60eab3eb8c | ||
|
|
386401da60 | ||
|
|
31abe537a0 | ||
|
|
e0b61ceabd | ||
|
|
f9ecbdc70b | ||
|
|
30e3edb81d | ||
|
|
542e324869 | ||
|
|
1c5e5704f5 | ||
|
|
1d400dd98c | ||
|
|
a4ed3c2086 | ||
|
|
efb5caad22 | ||
|
|
3a002b6cf2 | ||
|
|
f8b7981be4 | ||
|
|
b55ee79d86 | ||
|
|
af70db88db | ||
|
|
7ef033f876 | ||
|
|
db59c07f27 | ||
|
|
9085e34d70 | ||
|
|
0dfa7d3af5 | ||
|
|
c28bf9ce24 | ||
|
|
5a1f1796d7 | ||
|
|
ffc95fcf0e | ||
|
|
b0e796ca83 | ||
|
|
3773e2ef95 | ||
|
|
00c1f67c57 | ||
|
|
3f19ba1554 | ||
|
|
f37cc2353d | ||
|
|
6a7bda6910 | ||
|
|
ff1b9930fc | ||
|
|
582da6df9a | ||
|
|
3bd830eacf | ||
|
|
f4efcbde5c | ||
|
|
658819bb71 | ||
|
|
3fc8249429 | ||
|
|
e0a38ce2c2 | ||
|
|
178e1789b5 | ||
|
|
108c900387 | ||
|
|
63507e8e29 | ||
|
|
87f1e06c41 | ||
|
|
7e8bafd217 | ||
|
|
457ad07ade | ||
|
|
c9ac9a75a6 | ||
|
|
79c901c220 | ||
|
|
b61d819fcb | ||
|
|
f4038e3674 | ||
|
|
8377514127 | ||
|
|
d8ea989eda | ||
|
|
5f3316d3dc | ||
|
|
a4fddb3fbe | ||
|
|
3d71716a8a | ||
|
|
9f37cef1bb | ||
|
|
0de1bbc85b | ||
|
|
3aa8624658 | ||
|
|
42b711b862 | ||
|
|
b25b798dbe | ||
|
|
2873dbe154 | ||
|
|
31a83cb0d8 | ||
|
|
383e384739 | ||
|
|
1bb6433649 | ||
|
|
ced39d0982 | ||
|
|
fc4d6a62af | ||
|
|
fa99cbbc73 | ||
|
|
49455721a3 | ||
|
|
11032b1936 | ||
|
|
e7ca4a69e3 | ||
|
|
f2fba51fe2 | ||
|
|
7c79f0d431 | ||
|
|
41b9b30b9b | ||
|
|
1fa82ffb7b | ||
|
|
4f93ac6477 | ||
|
|
f7533010c6 | ||
|
|
47b650d821 | ||
|
|
0c2c097377 | ||
|
|
d721f70690 | ||
|
|
ea8aaa21e8 | ||
|
|
660d1059b0 | ||
|
|
e7dc2de14b | ||
|
|
aca9fd3bed | ||
|
|
09f3f40462 | ||
|
|
e2525d8440 | ||
|
|
6769106881 | ||
|
|
32100a3c91 | ||
|
|
0f324c8309 | ||
|
|
67f7432dd7 | ||
|
|
59dc2853e3 | ||
|
|
ada58465b2 | ||
|
|
173f57c636 | ||
|
|
1f3e8640f7 | ||
|
|
6039e9dcc3 | ||
|
|
d64f979f99 | ||
|
|
0c53d19113 | ||
|
|
c64a07fd09 | ||
|
|
694919b9d1 | ||
|
|
606b35853b | ||
|
|
26b7452178 | ||
|
|
b51f887567 | ||
|
|
c4b8675d77 | ||
|
|
a7cd7a1ed9 | ||
|
|
a48c779367 | ||
|
|
cf1eccc24f | ||
|
|
d45caca011 | ||
|
|
0722f47539 | ||
|
|
3af5e7e8da | ||
|
|
160f3ee4a7 | ||
|
|
3a310f19f0 | ||
|
|
d7a75dc026 | ||
|
|
a372e010bd | ||
|
|
530817191e | ||
|
|
1282548a1c | ||
|
|
c7610ed044 | ||
|
|
ffc1c51526 | ||
|
|
b130a8cfeb | ||
|
|
551bd284dd | ||
|
|
f0a2c98376 | ||
|
|
9edccfdffa | ||
|
|
1a056f6db9 | ||
|
|
e018eb7bac | ||
|
|
0a91ddf38a | ||
|
|
67bb2c640e | ||
|
|
561eaa311d | ||
|
|
282887d9c6 | ||
|
|
3f7a248ed4 | ||
|
|
ecaa07a72a | ||
|
|
0e62cd11da | ||
|
|
99bdc27be3 | ||
|
|
c3c46967dc | ||
|
|
7f1a9239ab | ||
|
|
599d23697d | ||
|
|
c8102c8ffe | ||
|
|
5aa12e9b51 | ||
|
|
829437b20b | ||
|
|
3c4131d45d | ||
|
|
ae8d8ee1ac | ||
|
|
39b7c47e7b | ||
|
|
89ec3d16dc | ||
|
|
f6f03bc261 | ||
|
|
7602c983c5 | ||
|
|
560efb2c9e | ||
|
|
c2328ef46a | ||
|
|
766fb56651 | ||
|
|
f6035447ae | ||
|
|
38438b3373 | ||
|
|
71dedccbbe | ||
|
|
cddbe4642f | ||
|
|
bdfdc737a0 | ||
|
|
3d045c3aee | ||
|
|
9583f152ee | ||
|
|
5b2755d28d | ||
|
|
bec4610e12 | ||
|
|
9378259779 | ||
|
|
3d762282b9 | ||
|
|
184ebe72a2 | ||
|
|
30783e6a79 | ||
|
|
aa86c777f4 | ||
|
|
a2792785fe | ||
|
|
267315e7d4 | ||
|
|
2ad0bcbba9 | ||
|
|
99d39cb6ff | ||
|
|
915ceb2d04 | ||
|
|
88bb7cdca6 | ||
|
|
49c90ecbce | ||
|
|
8395004d25 | ||
|
|
5de1c619c8 | ||
|
|
a6d678d41d | ||
|
|
2b91d764b5 | ||
|
|
46de9460a6 | ||
|
|
62337bb6ac | ||
|
|
9abab2c366 | ||
|
|
b22e368b25 | ||
|
|
a9cd2998e5 | ||
|
|
f1ea30f257 | ||
|
|
0b74e9b354 | ||
|
|
8189416d0c | ||
|
|
5f0e1fae7f | ||
|
|
880a9be3b1 | ||
|
|
7bfc1a00a7 | ||
|
|
92f64de115 | ||
|
|
f4baa86b71 | ||
|
|
baff64a43d | ||
|
|
b7f2bb0e80 | ||
|
|
08e0a397d3 | ||
|
|
5f333be947 | ||
|
|
f5f4e15ce2 | ||
|
|
fbd568dc47 | ||
|
|
c79ea88576 | ||
|
|
9be4e7b576 | ||
|
|
33105f017c | ||
|
|
e02f97854c | ||
|
|
960d0de361 | ||
|
|
31ce1fdfd3 | ||
|
|
9821381059 | ||
|
|
3f7bf3d2dc | ||
|
|
f9e69984ff | ||
|
|
b1b5b5dfe2 | ||
|
|
c7440b250f | ||
|
|
bab8462789 | ||
|
|
4eaa6fdd06 | ||
|
|
38b2845e2a | ||
|
|
14d24213a8 | ||
|
|
c61258c0d0 | ||
|
|
47226236f4 | ||
|
|
e744c21f56 | ||
|
|
89a0632ecc | ||
|
|
dcc05db7f1 | ||
|
|
90fb2e5487 | ||
|
|
b5ce7d5982 | ||
|
|
f211616a4c | ||
|
|
a9cb9bac21 | ||
|
|
ae005434e4 | ||
|
|
ef87d057fc | ||
|
|
181b9a5795 | ||
|
|
9baf9c55c2 | ||
|
|
e29132377e | ||
|
|
999751c422 | ||
|
|
22656d6fdd | ||
|
|
ef0c5fd772 | ||
|
|
90c61c79d6 | ||
|
|
4ba3bff87f | ||
|
|
c3dd6f5344 | ||
|
|
321880f5a6 | ||
|
|
3737d209f6 | ||
|
|
29c4b0a141 | ||
|
|
956f64c6ba | ||
|
|
c2d18d8ae4 | ||
|
|
5b9806ae6d | ||
|
|
665fa140a8 | ||
|
|
32f843a214 | ||
|
|
72a3c756ad | ||
|
|
47069dfe52 | ||
|
|
43a84d7ad8 | ||
|
|
b6ca2a42f2 | ||
|
|
e52a4ac74f | ||
|
|
decfa6bd7a | ||
|
|
8931bd37e2 | ||
|
|
4b79d23d00 | ||
|
|
77fe7c426e | ||
|
|
331c2244fc | ||
|
|
5a3eab634a | ||
|
|
77e68acf54 | ||
|
|
7a355d448a | ||
|
|
3b7ad1820d | ||
|
|
d3b63b2653 | ||
|
|
046896e60a | ||
|
|
fb9119ff49 | ||
|
|
818aaa8b89 | ||
|
|
26bdfc3474 | ||
|
|
0e91d8a10e | ||
|
|
434c3c3ef3 | ||
|
|
21e05c43dd | ||
|
|
0e154b35ef | ||
|
|
e6554e061c | ||
|
|
0f004c8e7b | ||
|
|
f5b1a5cd58 | ||
|
|
48a098b041 | ||
|
|
f8c0169e82 | ||
|
|
539c9d4c63 | ||
|
|
b4d8220cbb | ||
|
|
5eded789aa | ||
|
|
e931c6230a | ||
|
|
64a6e1ac8b | ||
|
|
50094ca296 | ||
|
|
15b32dc140 | ||
|
|
441ecfedc9 | ||
|
|
78147ee8d7 | ||
|
|
8c58612a3b | ||
|
|
56f9d244de | ||
|
|
2ba9eb4228 | ||
|
|
9a8c878f2d | ||
|
|
41a563bdc8 | ||
|
|
4e5f30858b | ||
|
|
b989ac6db5 | ||
|
|
4d1f4bbf49 | ||
|
|
e9ad665d32 | ||
|
|
78052f87bd | ||
|
|
ebf5c11e03 | ||
|
|
7e355e211c | ||
|
|
f36461e696 | ||
|
|
88d7ca01b0 | ||
|
|
2e2b82c052 | ||
|
|
f1bb0544be | ||
|
|
3b1371124e | ||
|
|
e6857df5c6 | ||
|
|
73374a0303 | ||
|
|
e334740dd6 | ||
|
|
84ee833ea7 | ||
|
|
b7ad1e6d61 | ||
|
|
340efe3a3a | ||
|
|
2342549caf | ||
|
|
028737cde8 | ||
|
|
bf972963f4 | ||
|
|
9bda91b3bf | ||
|
|
e4c5eb5e69 | ||
|
|
2e8cc22c54 | ||
|
|
655910d486 | ||
|
|
2a0ec88379 | ||
|
|
80859a609a | ||
|
|
d679d50eca | ||
|
|
65de118e51 | ||
|
|
4cd56b1fb9 | ||
|
|
f3945e7c02 | ||
|
|
5ef982b4b5 | ||
|
|
f96d336b97 | ||
|
|
a68a4fc888 | ||
|
|
0c3ffa1841 | ||
|
|
24a0d2a0c9 | ||
|
|
ca42be982c | ||
|
|
ffc31e2efa | ||
|
|
8952aa59ff | ||
|
|
2966f03042 | ||
|
|
d15e9e2b7a | ||
|
|
fd45be3def | ||
|
|
0658a7654f | ||
|
|
7526151670 | ||
|
|
560b59f97f | ||
|
|
b2ca89c185 | ||
|
|
1de2de4bde | ||
|
|
4135867e53 | ||
|
|
ff425369ac | ||
|
|
30ccccdb67 | ||
|
|
5e3016f34a | ||
|
|
f775feb7f0 | ||
|
|
0a94ea5386 | ||
|
|
aa8423ba46 | ||
|
|
d753f36ebc | ||
|
|
55976dbc25 | ||
|
|
77c005835d | ||
|
|
6b0601fd54 | ||
|
|
c1652979d5 | ||
|
|
740fee660e | ||
|
|
984ee624ed | ||
|
|
00ef0519f5 | ||
|
|
59d170c6f8 | ||
|
|
9a722ccf62 | ||
|
|
748fa4cb80 | ||
|
|
694cf371f9 | ||
|
|
8696e38e6f | ||
|
|
706162ecc6 | ||
|
|
c3f17ce2c4 | ||
|
|
41f29d2ce3 | ||
|
|
7b119a594f | ||
|
|
b7d20b102b | ||
|
|
ac05a779ae |
+26
-11
@@ -17,7 +17,7 @@ AllowShortLoopsOnASingleLine: true
|
|||||||
AlwaysBreakAfterDefinitionReturnType: None
|
AlwaysBreakAfterDefinitionReturnType: None
|
||||||
AlwaysBreakAfterReturnType: None
|
AlwaysBreakAfterReturnType: None
|
||||||
AlwaysBreakBeforeMultilineStrings: false
|
AlwaysBreakBeforeMultilineStrings: false
|
||||||
AlwaysBreakTemplateDeclarations: false
|
AlwaysBreakTemplateDeclarations: true
|
||||||
BinPackArguments: true
|
BinPackArguments: true
|
||||||
BinPackParameters: true
|
BinPackParameters: true
|
||||||
BraceWrapping:
|
BraceWrapping:
|
||||||
@@ -56,18 +56,31 @@ DisableFormat: false
|
|||||||
ExperimentalAutoDetectBinPacking: false
|
ExperimentalAutoDetectBinPacking: false
|
||||||
FixNamespaceComments: true
|
FixNamespaceComments: true
|
||||||
ForEachMacros:
|
ForEachMacros:
|
||||||
- foreach
|
|
||||||
- Q_FOREACH
|
- Q_FOREACH
|
||||||
- BOOST_FOREACH
|
- BOOST_FOREACH
|
||||||
IncludeBlocks: Preserve
|
|
||||||
|
# Include grouping/sorting
|
||||||
|
SortIncludes: true
|
||||||
|
IncludeBlocks: Regroup
|
||||||
IncludeCategories:
|
IncludeCategories:
|
||||||
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
|
- Regex: '"V3Pch.*\.h"'
|
||||||
Priority: 2
|
Priority: -2 # Precompiled headers
|
||||||
- Regex: '^(<|"(gtest|gmock|isl|json)/)'
|
- Regex: '"(config_build|verilated_config|verilatedos)\.h"'
|
||||||
Priority: 3
|
Priority: -1 # Sepecials before main header
|
||||||
- Regex: '.*'
|
- Regex: '(<|")verilated.*'
|
||||||
Priority: 1
|
Priority: 1 # Runtime headers
|
||||||
IncludeIsMainRegex: '(Test)?$'
|
- Regex: '"V3.*__gen.*\.h"'
|
||||||
|
Priority: 3 # Generated internal headers separately
|
||||||
|
- Regex: '"V3.*"'
|
||||||
|
Priority: 2 # Internal header
|
||||||
|
- Regex: '".*"'
|
||||||
|
Priority: 4 # Other non-system headers
|
||||||
|
- Regex: '<[[:alnum:]_.]+>'
|
||||||
|
Priority: 5 # Simple system headers next
|
||||||
|
- Regex: '<.*>'
|
||||||
|
Priority: 6 # Other system headers next
|
||||||
|
IncludeIsMainRegex: '$'
|
||||||
|
|
||||||
IndentCaseLabels: false
|
IndentCaseLabels: false
|
||||||
IndentPPDirectives: None
|
IndentPPDirectives: None
|
||||||
IndentWidth: 4
|
IndentWidth: 4
|
||||||
@@ -91,7 +104,6 @@ PenaltyExcessCharacter: 1000000
|
|||||||
PenaltyReturnTypeOnItsOwnLine: 60
|
PenaltyReturnTypeOnItsOwnLine: 60
|
||||||
PointerAlignment: Left
|
PointerAlignment: Left
|
||||||
ReflowComments: true
|
ReflowComments: true
|
||||||
SortIncludes: false
|
|
||||||
SortUsingDeclarations: true
|
SortUsingDeclarations: true
|
||||||
SpaceAfterCStyleCast: false
|
SpaceAfterCStyleCast: false
|
||||||
SpaceAfterTemplateKeyword: true
|
SpaceAfterTemplateKeyword: true
|
||||||
@@ -102,6 +114,9 @@ SpacesBeforeTrailingComments: 2
|
|||||||
SpacesInAngles: false
|
SpacesInAngles: false
|
||||||
SpacesInContainerLiterals: true
|
SpacesInContainerLiterals: true
|
||||||
SpacesInCStyleCastParentheses: false
|
SpacesInCStyleCastParentheses: false
|
||||||
|
SpacesInLineCommentPrefix:
|
||||||
|
Minimum: 0
|
||||||
|
Maximum: -1
|
||||||
SpacesInParentheses: false
|
SpacesInParentheses: false
|
||||||
SpacesInSquareBrackets: false
|
SpacesInSquareBrackets: false
|
||||||
Standard: Cpp11
|
Standard: Cpp11
|
||||||
|
|||||||
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "Verilator Build Environment",
|
||||||
|
|
||||||
|
"build": {
|
||||||
|
"dockerfile": "../ci/docker/buildenv/Dockerfile"
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: Bug report
|
name: Bug report
|
||||||
about: Something isn't working as expected, and it isn't "Unsupported." (Note our contributor agreement at https://github.com/verilator/verilator/blob/master/docs/CONTRIBUTING.rst)
|
about: Use this to report that something isn't working as expected, and it isn't "Unsupported." (Note our contributor agreement at https://github.com/verilator/verilator/blob/master/docs/CONTRIBUTING.rst)
|
||||||
title: ''
|
title: ''
|
||||||
labels: new
|
labels: new
|
||||||
assignees: ''
|
assignees: ''
|
||||||
@@ -11,8 +11,10 @@ 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, ideally in test_regress format.)
|
||||||
|
|
||||||
|
What 'verilator' command line do we use to run your example?
|
||||||
|
|
||||||
What 'verilator --version' are you using? Did you try it with the git master version?
|
What 'verilator --version' are you using? Did you try it with the git master version?
|
||||||
|
|
||||||
What OS and distribution are you using?
|
What OS and distribution are you using?
|
||||||
|
|
||||||
Would you be willing to try to fix Verilator yourself with assistance?
|
May we assist you in trying to fix this in Verilator yourself?
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: Feature Request
|
name: Feature Request
|
||||||
about: Request something should be supported, or a new feature added. (Note our contributor agreement at https://github.com/verilator/verilator/blob/master/docs/CONTRIBUTING.rst)
|
about: Use this to request something should be supported, or a new feature added. (Note our contributor agreement at https://github.com/verilator/verilator/blob/master/docs/CONTRIBUTING.rst)
|
||||||
title: ''
|
title: ''
|
||||||
labels: new
|
labels: new
|
||||||
assignees: ''
|
assignees: ''
|
||||||
@@ -13,4 +13,4 @@ What would you like added/supported?
|
|||||||
|
|
||||||
Can you attach an example that runs on other simulators? (Must be openly licensed, ideally in test_regress format.)
|
Can you attach an example that runs on other simulators? (Must be openly licensed, ideally in test_regress format.)
|
||||||
|
|
||||||
May we assist you in trying to fix this yourself?
|
May we assist you in trying to fix this in Verilator yourself?
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: Q and A, or Other
|
name: Q and A, or Other
|
||||||
about: Ask a question, not related to a specific bug or feature request. (Note our contributor agreement at https://github.com/verilator/verilator/blob/master/docs/CONTRIBUTING.rst)
|
about: Use this to ask a question, not related to a specific bug nor feature request. (Note our contributor agreement at https://github.com/verilator/verilator/blob/master/docs/CONTRIBUTING.rst)
|
||||||
title: ''
|
title: ''
|
||||||
labels: new
|
labels: new
|
||||||
assignees: ''
|
assignees: ''
|
||||||
|
|||||||
+70
-33
@@ -17,49 +17,51 @@ env:
|
|||||||
CCACHE_COMPRESS: 1
|
CCACHE_COMPRESS: 1
|
||||||
CCACHE_DIR: ${{ github.workspace }}/.ccache
|
CCACHE_DIR: ${{ github.workspace }}/.ccache
|
||||||
CCACHE_LIMIT_MULTIPLE: 0.95
|
CCACHE_LIMIT_MULTIPLE: 0.95
|
||||||
|
INSTALL_DIR: ${{ github.workspace }}/install
|
||||||
|
RELOC_DIR: ${{ github.workspace }}/relloc
|
||||||
|
|
||||||
defaults:
|
defaults:
|
||||||
run:
|
run:
|
||||||
shell: bash
|
shell: bash
|
||||||
working-directory: repo
|
working-directory: repo
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.ref || github.run_id }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
build:
|
build:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os: [ubuntu-20.04, ubuntu-18.04]
|
os: [ubuntu-22.04, ubuntu-20.04]
|
||||||
compiler:
|
compiler:
|
||||||
- { cc: clang, cxx: clang++ }
|
- { cc: clang, cxx: clang++ }
|
||||||
- { cc: gcc, cxx: g++ }
|
- { cc: gcc, cxx: g++ }
|
||||||
m32: [0, 1]
|
include:
|
||||||
exclude:
|
# Build GCC 10 on ubuntu-20.04
|
||||||
# Build pull requests only with ubuntu-20.04 and without m32
|
- os: ubuntu-20.04
|
||||||
- os: ${{ github.event_name == 'pull_request' && 'ubuntu-18.04' || 'do-not-exclude' }}
|
compiler: { cc: gcc-10, cxx: g++-10 }
|
||||||
- m32: ${{ github.event_name == 'pull_request' && 1 || 'do-not-exclude' }}
|
|
||||||
# Build -m32 only on ubuntu-20.04
|
|
||||||
- {os: ubuntu-18.04, m32: 1}
|
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
name: Build | ${{ matrix.os }} | ${{ matrix.compiler.cc }} ${{ matrix.m32 && '| -m32' || '' }}
|
name: Build | ${{ matrix.os }} | ${{ matrix.compiler.cc }}
|
||||||
env:
|
env:
|
||||||
CI_BUILD_STAGE_NAME: build
|
CI_BUILD_STAGE_NAME: build
|
||||||
CI_RUNS_ON: ${{ matrix.os }}
|
CI_RUNS_ON: ${{ matrix.os }}
|
||||||
CI_M32: ${{ matrix.m32 }}
|
|
||||||
CC: ${{ matrix.compiler.cc }}
|
CC: ${{ matrix.compiler.cc }}
|
||||||
CXX: ${{ matrix.compiler.cxx }}
|
CXX: ${{ matrix.compiler.cxx }}
|
||||||
CACHE_BASE_KEY: build-${{ matrix.os }}-${{ matrix.compiler.cc }}-m32=${{ matrix.m32 }}
|
CACHE_BASE_KEY: build-${{ matrix.os }}-${{ matrix.compiler.cc }}
|
||||||
CCACHE_MAXSIZE: 250M # Per build matrix entry (2000M in total)
|
CCACHE_MAXSIZE: 1000M # Per build matrix entry (* 5 = 5000M in total)
|
||||||
VERILATOR_ARCHIVE: verilator-${{ github.sha }}-${{ matrix.os }}-${{ matrix.compiler.cc }}${{ matrix.m32 && '-m32' || '' }}.tar.gz
|
VERILATOR_ARCHIVE: verilator-${{ github.sha }}-${{ matrix.os }}-${{ matrix.compiler.cc }}.tar.gz
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
path: repo
|
path: repo
|
||||||
|
|
||||||
- name: Cache $CCACHE_DIR
|
- name: Cache $CCACHE_DIR
|
||||||
uses: actions/cache@v2
|
uses: actions/cache@v4
|
||||||
env:
|
env:
|
||||||
CACHE_KEY: ${{ env.CACHE_BASE_KEY }}-ccache
|
CACHE_KEY: ${{ env.CACHE_BASE_KEY }}-ccache
|
||||||
with:
|
with:
|
||||||
@@ -79,7 +81,7 @@ jobs:
|
|||||||
run: tar --posix -c -z -f ${{ env.VERILATOR_ARCHIVE }} repo
|
run: tar --posix -c -z -f ${{ env.VERILATOR_ARCHIVE }} repo
|
||||||
|
|
||||||
- name: Upload tar archive
|
- name: Upload tar archive
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
path: ${{ github.workspace }}/${{ env.VERILATOR_ARCHIVE }}
|
path: ${{ github.workspace }}/${{ env.VERILATOR_ARCHIVE }}
|
||||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||||
@@ -90,33 +92,42 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os: [ubuntu-20.04, ubuntu-18.04]
|
os: [ubuntu-22.04, ubuntu-20.04]
|
||||||
compiler:
|
compiler:
|
||||||
- { cc: clang, cxx: clang++ }
|
- { cc: clang, cxx: clang++ }
|
||||||
- { cc: gcc, cxx: g++ }
|
- { cc: gcc, cxx: g++ }
|
||||||
m32: [0, 1]
|
reloc: [0]
|
||||||
suite: [dist-vlt-0, dist-vlt-1, dist-vlt-2, vltmt-0, vltmt-1]
|
suite: [dist-vlt-0, dist-vlt-1, dist-vlt-2, dist-vlt-3, vltmt-0, vltmt-1]
|
||||||
exclude:
|
include:
|
||||||
# Build pull requests only with ubuntu-20.04 and without m32
|
# Test with GCC 10 on ubuntu-20.04
|
||||||
- os: ${{ github.event_name == 'pull_request' && 'ubuntu-18.04' || 'do-not-exclude' }}
|
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: dist-vlt-0}
|
||||||
- m32: ${{ github.event_name == 'pull_request' && 1 || 'do-not-exclude' }}
|
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: dist-vlt-1}
|
||||||
# Build -m32 only on ubuntu-20.04
|
- {os: ubuntu-20.04, compiler: { cc: gcc-10, cxx: g++-10 }, suite: dist-vlt-2}
|
||||||
- {os: ubuntu-18.04, m32: 1}
|
- {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}
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
name: Test | ${{ matrix.os }} | ${{ matrix.compiler.cc }} | ${{ matrix.suite }} ${{ matrix.m32 && '| -m32' || '' }}
|
name: Test | ${{ matrix.os }} | ${{ matrix.compiler.cc }} | ${{ matrix.reloc && 'reloc | ' || '' }} ${{ matrix.suite }}
|
||||||
env:
|
env:
|
||||||
CI_BUILD_STAGE_NAME: test
|
CI_BUILD_STAGE_NAME: test
|
||||||
CI_RUNS_ON: ${{ matrix.os }}
|
CI_RUNS_ON: ${{ matrix.os }}
|
||||||
CI_M32: ${{ matrix.m32 }}
|
CI_RELOC: ${{ matrix.reloc }}
|
||||||
CC: ${{ matrix.compiler.cc }}
|
CC: ${{ matrix.compiler.cc }}
|
||||||
CXX: ${{ matrix.compiler.cxx }}
|
CXX: ${{ matrix.compiler.cxx }}
|
||||||
CACHE_BASE_KEY: test-${{ matrix.os }}-${{ matrix.compiler.cc }}-m32=${{ matrix.m32 }}-${ matrix.suite }}
|
CACHE_BASE_KEY: test-${{ matrix.os }}-${{ matrix.compiler.cc }}-${{ matrix.reloc }}-${{ matrix.suite }}
|
||||||
CCACHE_MAXSIZE: 64M # Per build matrix entry (2160M in total)
|
CCACHE_MAXSIZE: 100M # Per build per suite (* 5 * 5 = 2500M in total)
|
||||||
VERILATOR_ARCHIVE: verilator-${{ github.sha }}-${{ matrix.os }}-${{ matrix.compiler.cc }}${{ matrix.m32 && '-m32' || '' }}.tar.gz
|
VERILATOR_ARCHIVE: verilator-${{ github.sha }}-${{ matrix.os }}-${{ matrix.compiler.cc }}.tar.gz
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: Download tar archive
|
- name: Download tar archive
|
||||||
uses: actions/download-artifact@v2
|
uses: actions/download-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||||
path: ${{ github.workspace }}
|
path: ${{ github.workspace }}
|
||||||
@@ -126,9 +137,9 @@ jobs:
|
|||||||
run: tar -x -z -f ${{ env.VERILATOR_ARCHIVE }}
|
run: tar -x -z -f ${{ env.VERILATOR_ARCHIVE }}
|
||||||
|
|
||||||
- name: Cache $CCACHE_DIR
|
- name: Cache $CCACHE_DIR
|
||||||
uses: actions/cache@v2
|
uses: actions/cache@v4
|
||||||
env:
|
env:
|
||||||
CACHE_KEY: ${{ env.CACHE_BASE_KEY }}-ccache
|
CACHE_KEY: ${{ env.CACHE_BASE_KEY }}-ccache2
|
||||||
with:
|
with:
|
||||||
path: ${{ env.CCACHE_DIR }}
|
path: ${{ env.CCACHE_DIR }}
|
||||||
key: ${{ env.CACHE_KEY }}-${{ github.sha }}
|
key: ${{ env.CACHE_KEY }}-${{ github.sha }}
|
||||||
@@ -142,3 +153,29 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
TESTS: ${{ matrix.suite }}
|
TESTS: ${{ matrix.suite }}
|
||||||
run: ./ci/ci-script.bash
|
run: ./ci/ci-script.bash
|
||||||
|
|
||||||
|
lint-py:
|
||||||
|
runs-on: ubuntu-22.04
|
||||||
|
name: Lint Python
|
||||||
|
env:
|
||||||
|
CI_BUILD_STAGE_NAME: build
|
||||||
|
CI_RUNS_ON: ubuntu-22.04
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
path: repo
|
||||||
|
|
||||||
|
- 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: Configure
|
||||||
|
run: autoconf && ./configure --enable-longtests --enable-ccwarn
|
||||||
|
|
||||||
|
- name: Lint
|
||||||
|
run: make -k lint-py
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
Test:
|
Test:
|
||||||
name: "'docs/CONTRIBUTORS' was signed"
|
name: "'docs/CONTRIBUTORS' was signed"
|
||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-22.04
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v4
|
||||||
- run: test_regress/t/t_dist_contributors.pl
|
- run: test_regress/t/t_dist_contributors.pl
|
||||||
|
|||||||
@@ -11,7 +11,6 @@ on:
|
|||||||
env:
|
env:
|
||||||
CI_OS_NAME: linux
|
CI_OS_NAME: linux
|
||||||
CI_COMMIT: ${{ github.sha }}
|
CI_COMMIT: ${{ github.sha }}
|
||||||
CI_M32: 0
|
|
||||||
COVERAGE: 1
|
COVERAGE: 1
|
||||||
VERILATOR_ARCHIVE: verilator-coverage-${{ github.sha }}.tar.gz
|
VERILATOR_ARCHIVE: verilator-coverage-${{ github.sha }}.tar.gz
|
||||||
|
|
||||||
@@ -24,14 +23,14 @@ jobs:
|
|||||||
|
|
||||||
|
|
||||||
Build:
|
Build:
|
||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-22.04
|
||||||
env:
|
env:
|
||||||
CI_BUILD_STAGE_NAME: build
|
CI_BUILD_STAGE_NAME: build
|
||||||
CI_RUNS_ON: ubuntu-20.04
|
CI_RUNS_ON: ubuntu-22.04
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
path: repo
|
path: repo
|
||||||
|
|
||||||
@@ -46,7 +45,7 @@ jobs:
|
|||||||
run: tar --posix -c -z -f ${{ env.VERILATOR_ARCHIVE }} repo
|
run: tar --posix -c -z -f ${{ env.VERILATOR_ARCHIVE }} repo
|
||||||
|
|
||||||
- name: Upload tar archive
|
- name: Upload tar archive
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
path: ${{ github.workspace }}/${{ env.VERILATOR_ARCHIVE }}
|
path: ${{ github.workspace }}/${{ env.VERILATOR_ARCHIVE }}
|
||||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||||
@@ -73,15 +72,15 @@ jobs:
|
|||||||
- 9
|
- 9
|
||||||
include:
|
include:
|
||||||
- { test: dist, num: '' }
|
- { test: dist, num: '' }
|
||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-22.04
|
||||||
name: test-${{ matrix.test }}${{ matrix.num }}
|
name: test-${{ matrix.test }}${{ matrix.num }}
|
||||||
env:
|
env:
|
||||||
CI_BUILD_STAGE_NAME: test
|
CI_BUILD_STAGE_NAME: test
|
||||||
CI_RUNS_ON: ubuntu-20.04
|
CI_RUNS_ON: ubuntu-22.04
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: Download tar archive
|
- name: Download tar archive
|
||||||
uses: actions/download-artifact@v2
|
uses: actions/download-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ${{ env.VERILATOR_ARCHIVE }}
|
name: ${{ env.VERILATOR_ARCHIVE }}
|
||||||
path: ${{ github.workspace }}
|
path: ${{ github.workspace }}
|
||||||
|
|||||||
@@ -0,0 +1,85 @@
|
|||||||
|
# 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.
|
||||||
|
# The following secrets must be configured in the github repository:
|
||||||
|
# DOCKER_HUB_USER: user name for logging into docker hub
|
||||||
|
# DOCKER_HUB_ACCESS_TOKEN: docker hub access token.
|
||||||
|
name: Build Verilator Container
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags: [ 'v*' ]
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
manual_tag:
|
||||||
|
description: 'Git tag to use for image build'
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
add_latest_tag:
|
||||||
|
description: 'Tag workflow_dispatch docker image as "latest"'
|
||||||
|
required: true
|
||||||
|
type: boolean
|
||||||
|
default: false
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build:
|
||||||
|
|
||||||
|
runs-on: ubuntu-22.04
|
||||||
|
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
contexts:
|
||||||
|
- "ci/docker/run:verilator"
|
||||||
|
# - "ci/docker/buildenv:verilator-buildenv"
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- 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: 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: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v2
|
||||||
|
|
||||||
|
- 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: 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 }}
|
||||||
@@ -10,16 +10,15 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
format:
|
format:
|
||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-22.04
|
||||||
name: Ubuntu 20.04 | format
|
name: Ubuntu 22.04 | format
|
||||||
env:
|
env:
|
||||||
CI_OS_NAME: linux
|
CI_OS_NAME: linux
|
||||||
CI_RUNS_ON: ubuntu-20.04
|
CI_RUNS_ON: ubuntu-22.04
|
||||||
CI_COMMIT: ${{ github.sha }}
|
CI_COMMIT: ${{ github.sha }}
|
||||||
CI_M32: 0
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
- name: Install packages for build
|
- name: Install packages for build
|
||||||
@@ -27,14 +26,14 @@ jobs:
|
|||||||
CI_BUILD_STAGE_NAME: build
|
CI_BUILD_STAGE_NAME: build
|
||||||
run: |
|
run: |
|
||||||
bash ci/ci-install.bash &&
|
bash ci/ci-install.bash &&
|
||||||
sudo apt-get install clang-format-11 yapf3 &&
|
sudo apt-get install clang-format-14 yapf3 &&
|
||||||
git config --global user.email "[email protected]" &&
|
git config --global user.email "[email protected]" &&
|
||||||
git config --global user.name "github action"
|
git config --global user.name "github action"
|
||||||
- name: Format code
|
- name: Format code
|
||||||
run: |
|
run: |
|
||||||
autoconf &&
|
autoconf &&
|
||||||
./configure &&
|
./configure &&
|
||||||
make -j 2 format CLANGFORMAT=clang-format-11 &&
|
make -j 2 format CLANGFORMAT=clang-format-14 &&
|
||||||
git status
|
git status
|
||||||
- name: Push
|
- name: Push
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
@@ -0,0 +1,55 @@
|
|||||||
|
# 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
|
||||||
|
|
||||||
|
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:
|
||||||
|
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
|
||||||
@@ -1,5 +1,6 @@
|
|||||||
\#*
|
\#*
|
||||||
.#*
|
.#*
|
||||||
|
.gdb_history
|
||||||
.nfs*
|
.nfs*
|
||||||
*~
|
*~
|
||||||
*.tidy
|
*.tidy
|
||||||
@@ -40,3 +41,8 @@ verilator-config-version.cmake
|
|||||||
**/_build/*
|
**/_build/*
|
||||||
**/obj_dir/*
|
**/obj_dir/*
|
||||||
/.vscode/
|
/.vscode/
|
||||||
|
/.idea/
|
||||||
|
/cmake-build-*/
|
||||||
|
/test_regress/snapshot/
|
||||||
|
xmverilog.*
|
||||||
|
xrun.history
|
||||||
|
|||||||
+139
@@ -0,0 +1,139 @@
|
|||||||
|
#*****************************************************************************
|
||||||
|
#
|
||||||
|
# DESCRIPTION: Script for build tool cmake on both unix and windows
|
||||||
|
#
|
||||||
|
#*****************************************************************************
|
||||||
|
#
|
||||||
|
# Copyright 2003-2024 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
|
||||||
|
#
|
||||||
|
#****************************************************************************/
|
||||||
|
|
||||||
|
cmake_minimum_required(VERSION 3.15)
|
||||||
|
cmake_policy(SET CMP0091 NEW) # Use MSVC_RUNTIME_LIBRARY to select the runtime
|
||||||
|
project(Verilator
|
||||||
|
VERSION 5.024
|
||||||
|
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.")
|
||||||
|
|
||||||
|
find_package(Python3 COMPONENTS Interpreter)
|
||||||
|
set(PYTHON3 Python3::Interpreter)
|
||||||
|
set(CMAKE_INSTALL_DATADIR ${CMAKE_INSTALL_PREFIX})
|
||||||
|
include(GNUInstallDirs)
|
||||||
|
include(CMakePackageConfigHelpers)
|
||||||
|
include(CheckStructHasMember)
|
||||||
|
include(ExternalProject)
|
||||||
|
|
||||||
|
if (NOT WIN32)
|
||||||
|
message(WARNING "CMake support on Linux/OSX is experimental.")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
if (DEFINED ENV{WIN_FLEX_BISON})
|
||||||
|
set(WIN_FLEX_BISON "$ENV{WIN_FLEX_BISON}")
|
||||||
|
endif()
|
||||||
|
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.")
|
||||||
|
endif()
|
||||||
|
set(CMAKE_CXX_STANDARD 20)
|
||||||
|
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 "")
|
||||||
|
find_program(OBJCACHE_PATH ccache)
|
||||||
|
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)
|
||||||
|
string(REGEX MATCH "[^\n\r]+" objcache_version "${objcache_version}")
|
||||||
|
message(STATUS "Found ccache: ${OBJCACHE_PATH} (\"${objcache_version}\")")
|
||||||
|
set(CMAKE_CXX_COMPILER_LAUNCHER "${OBJCACHE_PATH}")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
find_package(BISON)
|
||||||
|
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 ")
|
||||||
|
error("%Error: The DEBUG_AND_RELEASE_AND_COVERAGE option is not supported in MSBuild-based builds.")
|
||||||
|
endif()
|
||||||
|
set(saved_build_type ${CMAKE_BUILD_TYPE})
|
||||||
|
set(CMAKE_BUILD_TYPE Debug)
|
||||||
|
add_subdirectory(src build-Debug)
|
||||||
|
set(CMAKE_BUILD_TYPE Release)
|
||||||
|
add_subdirectory(src build-Release)
|
||||||
|
set(CMAKE_BUILD_TYPE Coverage)
|
||||||
|
add_subdirectory(src build-Coverage)
|
||||||
|
set(CMAKE_BUILD_TYPE ${saved_build_type})
|
||||||
|
else()
|
||||||
|
add_subdirectory(src)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# Configuration and Installation
|
||||||
|
|
||||||
|
set(PACKAGE_NAME ${PROJECT_NAME})
|
||||||
|
set(PACKAGE_VERSION ${PROJECT_VERSION})
|
||||||
|
|
||||||
|
configure_file(include/verilated_config.h.in include/verilated_config.h @ONLY)
|
||||||
|
|
||||||
|
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/include/verilated_config.h 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}/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}
|
||||||
|
)
|
||||||
|
|
||||||
|
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/verilator-config-version.cmake DESTINATION ${CMAKE_INSTALL_PREFIX})
|
||||||
|
|
||||||
|
foreach (program
|
||||||
|
verilator
|
||||||
|
verilator_gantt
|
||||||
|
verilator_ccache_report
|
||||||
|
verilator_difftree
|
||||||
|
verilator_profcfunc
|
||||||
|
)
|
||||||
|
install(PROGRAMS bin/${program} TYPE BIN)
|
||||||
|
endforeach()
|
||||||
|
|
||||||
|
install(DIRECTORY examples TYPE DATA FILES_MATCHING
|
||||||
|
PATTERN "examples/*/*.[chv]*"
|
||||||
|
PATTERN "examples/*/Makefile*"
|
||||||
|
PATTERN "examples/*/CMakeLists.txt"
|
||||||
|
)
|
||||||
|
|
||||||
|
install(DIRECTORY include TYPE DATA FILES_MATCHING
|
||||||
|
PATTERN "include/verilated_config.h"
|
||||||
|
PATTERN "include/verilated.mk"
|
||||||
|
PATTERN "include/*.[chv]"
|
||||||
|
PATTERN "include/*.cpp"
|
||||||
|
PATTERN "include/*.sv"
|
||||||
|
PATTERN "include/gtkwave/*.[chv]*"
|
||||||
|
PATTERN "include/vltstd/*.[chv]*"
|
||||||
|
)
|
||||||
+17
@@ -0,0 +1,17 @@
|
|||||||
|
set noparent
|
||||||
|
linelength=100
|
||||||
|
filter=-build/c++11
|
||||||
|
filter=-build/header_guard
|
||||||
|
filter=-build/include_order
|
||||||
|
filter=-build/include_subdir
|
||||||
|
filter=-readability/inheritance
|
||||||
|
filter=-readability/nolint
|
||||||
|
filter=-readability/todo
|
||||||
|
filter=-runtime/references
|
||||||
|
filter=-whitespace/blank_line
|
||||||
|
filter=-whitespace/empty_if_body
|
||||||
|
filter=-whitespace/indent
|
||||||
|
filter=-whitespace/newline
|
||||||
|
filter=-whitespace/braces
|
||||||
|
filter=-whitespace/parens
|
||||||
|
filter=-whitespace/todo
|
||||||
+143
-67
@@ -7,7 +7,7 @@
|
|||||||
#
|
#
|
||||||
#*****************************************************************************
|
#*****************************************************************************
|
||||||
#
|
#
|
||||||
# Copyright 2003-2021 by Wilson Snyder. This program is free software; you
|
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||||
# can redistribute it and/or modify it under the terms of either the GNU
|
# 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
|
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
# Version 2.0.
|
# Version 2.0.
|
||||||
@@ -15,13 +15,13 @@
|
|||||||
#
|
#
|
||||||
#****************************************************************************/
|
#****************************************************************************/
|
||||||
#
|
#
|
||||||
# make all to compile and build Verilator.
|
# make all to compile and build Verilator.
|
||||||
# make install to install it.
|
# make install to install it.
|
||||||
# make TAGS to update tags tables.
|
# make TAGS to update tags tables.
|
||||||
#
|
#
|
||||||
# make clean or make mostlyclean
|
# make clean or make mostlyclean
|
||||||
# Delete all files from the current directory that are normally
|
# Delete all files from the current directory that are normally
|
||||||
# created by building the program. Don't delete the files that
|
# created by building the program. Don't delete the files that
|
||||||
# record the configuration. Also preserve files that could be made
|
# record the configuration. Also preserve files that could be made
|
||||||
# by building, but normally aren't because the distribution comes
|
# by building, but normally aren't because the distribution comes
|
||||||
# with them.
|
# with them.
|
||||||
@@ -53,7 +53,6 @@ INSTALL_DATA = @INSTALL_DATA@
|
|||||||
MAKEINFO = makeinfo
|
MAKEINFO = makeinfo
|
||||||
POD2TEXT = pod2text
|
POD2TEXT = pod2text
|
||||||
MKINSTALLDIRS = $(SHELL) $(srcdir)/src/mkinstalldirs
|
MKINSTALLDIRS = $(SHELL) $(srcdir)/src/mkinstalldirs
|
||||||
PERL = @PERL@
|
|
||||||
|
|
||||||
# Version (for docs/guide/conf.py)
|
# Version (for docs/guide/conf.py)
|
||||||
PACKAGE_VERSION_NUMBER = @PACKAGE_VERSION_NUMBER@
|
PACKAGE_VERSION_NUMBER = @PACKAGE_VERSION_NUMBER@
|
||||||
@@ -107,12 +106,13 @@ SUBDIRS = docs src test_regress \
|
|||||||
examples/cmake_tracing_c \
|
examples/cmake_tracing_c \
|
||||||
examples/cmake_tracing_sc \
|
examples/cmake_tracing_sc \
|
||||||
examples/cmake_protect_lib \
|
examples/cmake_protect_lib \
|
||||||
|
examples/make_hello_binary \
|
||||||
examples/make_hello_c \
|
examples/make_hello_c \
|
||||||
examples/make_hello_sc \
|
examples/make_hello_sc \
|
||||||
examples/make_tracing_c \
|
examples/make_tracing_c \
|
||||||
examples/make_tracing_sc \
|
examples/make_tracing_sc \
|
||||||
examples/make_protect_lib \
|
examples/make_protect_lib \
|
||||||
examples/xml_py \
|
examples/json_py \
|
||||||
|
|
||||||
INFOS = verilator.html verilator.pdf
|
INFOS = verilator.html verilator.pdf
|
||||||
|
|
||||||
@@ -125,7 +125,12 @@ EXAMPLES_FIRST = \
|
|||||||
EXAMPLES = $(EXAMPLES_FIRST) $(filter-out $(EXAMPLES_FIRST), $(sort $(wildcard examples/*)))
|
EXAMPLES = $(EXAMPLES_FIRST) $(filter-out $(EXAMPLES_FIRST), $(sort $(wildcard examples/*)))
|
||||||
|
|
||||||
# See uninstall also - don't put wildcards in this variable, it might uninstall other stuff
|
# See uninstall also - don't put wildcards in this variable, it might uninstall other stuff
|
||||||
VL_INST_MAN_FILES = verilator.1 verilator_coverage.1
|
# No verilator_ccache_report.1, verilator_difftree.1 as those are not bin/ installed
|
||||||
|
VL_INST_MAN_FILES = \
|
||||||
|
verilator.1 \
|
||||||
|
verilator_coverage.1 \
|
||||||
|
verilator_gantt.1 \
|
||||||
|
verilator_profcfunc.1 \
|
||||||
|
|
||||||
default: all
|
default: all
|
||||||
all: all_nomsg msg_test
|
all: all_nomsg msg_test
|
||||||
@@ -148,7 +153,7 @@ msg_test: all_nomsg
|
|||||||
@echo
|
@echo
|
||||||
|
|
||||||
.PHONY: test
|
.PHONY: test
|
||||||
ifeq ($(CFG_WITH_LONGTESTS),yes) # Local... Else don't burden users
|
ifeq ($(CFG_WITH_LONGTESTS),yes) # Local... Else don't burden users
|
||||||
test: smoke-test test_regress
|
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.pl
|
||||||
# (because that allows it to run in parallel with other test_regress's)
|
# (because that allows it to run in parallel with other test_regress's)
|
||||||
@@ -168,6 +173,10 @@ smoke-test: all_nomsg
|
|||||||
test_regress: all_nomsg
|
test_regress: all_nomsg
|
||||||
$(MAKE) -C test_regress
|
$(MAKE) -C test_regress
|
||||||
|
|
||||||
|
.PHONY: test-snap test-diff
|
||||||
|
test-snap test-diff:
|
||||||
|
$(MAKE) -C test_regress $@
|
||||||
|
|
||||||
examples: all_nomsg
|
examples: all_nomsg
|
||||||
for p in $(EXAMPLES) ; do \
|
for p in $(EXAMPLES) ; do \
|
||||||
$(MAKE) -C $$p VERILATOR_ROOT=`pwd` || exit 10; \
|
$(MAKE) -C $$p VERILATOR_ROOT=`pwd` || exit 10; \
|
||||||
@@ -178,8 +187,12 @@ docs: info
|
|||||||
|
|
||||||
info: $(INFOS)
|
info: $(INFOS)
|
||||||
|
|
||||||
%.1: ${srcdir}/bin/%
|
verilator.1: ${srcdir}/bin/verilator
|
||||||
pod2man $< $@
|
pod2man $< $@
|
||||||
|
verilator_coverage.1: ${srcdir}/bin/verilator_coverage
|
||||||
|
pod2man $< $@
|
||||||
|
%.1: ${srcdir}/bin/%
|
||||||
|
help2man --no-info --no-discard-stderr --version-string=- $< -o $@
|
||||||
|
|
||||||
.PHONY: verilator.html
|
.PHONY: verilator.html
|
||||||
verilator.html:
|
verilator.html:
|
||||||
@@ -190,11 +203,21 @@ verilator.html:
|
|||||||
verilator.pdf: Makefile
|
verilator.pdf: Makefile
|
||||||
$(MAKE) -C docs verilator.pdf
|
$(MAKE) -C docs verilator.pdf
|
||||||
|
|
||||||
# See uninstall also - don't put wildcards in this variable, it might uninstall other stuff
|
# Public executables intended to be invoked directly by the user
|
||||||
VL_INST_BIN_FILES = verilator verilator_bin$(EXEEXT) verilator_bin_dbg$(EXEEXT) verilator_coverage_bin_dbg$(EXEEXT) \
|
# Don't put wildcards in these variables, it might cause an uninstall of other stuff
|
||||||
verilator_ccache_report verilator_coverage verilator_gantt verilator_includer verilator_profcfunc
|
VL_INST_PUBLIC_SCRIPT_FILES = verilator \
|
||||||
# Some scripts go into both the search path and pkgdatadir,
|
verilator_coverage \
|
||||||
# so they can be found by the user, and under $VERILATOR_ROOT.
|
verilator_gantt \
|
||||||
|
verilator_profcfunc \
|
||||||
|
|
||||||
|
VL_INST_PUBLIC_BIN_FILES = verilator_bin$(EXEEXT) \
|
||||||
|
verilator_bin_dbg$(EXEEXT) \
|
||||||
|
verilator_coverage_bin_dbg$(EXEEXT) \
|
||||||
|
|
||||||
|
# Private executabels intended to be invoked by internals
|
||||||
|
# Don't put wildcards in these variables, it might cause an uninstall of other stuff
|
||||||
|
VL_INST_PRIVATE_SCRIPT_FILES = verilator_ccache_report \
|
||||||
|
verilator_includer \
|
||||||
|
|
||||||
VL_INST_INC_BLDDIR_FILES = \
|
VL_INST_INC_BLDDIR_FILES = \
|
||||||
include/verilated_config.h \
|
include/verilated_config.h \
|
||||||
@@ -203,6 +226,7 @@ VL_INST_INC_BLDDIR_FILES = \
|
|||||||
# Files under srcdir, instead of build time
|
# Files under srcdir, instead of build time
|
||||||
VL_INST_INC_SRCDIR_FILES = \
|
VL_INST_INC_SRCDIR_FILES = \
|
||||||
include/*.[chv]* \
|
include/*.[chv]* \
|
||||||
|
include/*.sv \
|
||||||
include/gtkwave/*.[chv]* \
|
include/gtkwave/*.[chv]* \
|
||||||
include/vltstd/*.[chv]* \
|
include/vltstd/*.[chv]* \
|
||||||
|
|
||||||
@@ -212,18 +236,34 @@ VL_INST_DATA_SRCDIR_FILES = \
|
|||||||
examples/*/Makefile* \
|
examples/*/Makefile* \
|
||||||
examples/*/vl_* \
|
examples/*/vl_* \
|
||||||
|
|
||||||
installbin:
|
mkbindirs:
|
||||||
$(MKINSTALLDIRS) $(DESTDIR)$(bindir)
|
|
||||||
( cd ${srcdir}/bin ; $(INSTALL_PROGRAM) verilator $(DESTDIR)$(bindir)/verilator )
|
|
||||||
( cd ${srcdir}/bin ; $(INSTALL_PROGRAM) verilator_coverage $(DESTDIR)$(bindir)/verilator_coverage )
|
|
||||||
( cd ${srcdir}/bin ; $(INSTALL_PROGRAM) verilator_gantt $(DESTDIR)$(bindir)/verilator_gantt )
|
|
||||||
( cd ${srcdir}/bin ; $(INSTALL_PROGRAM) verilator_profcfunc $(DESTDIR)$(bindir)/verilator_profcfunc )
|
|
||||||
( cd bin ; $(INSTALL_PROGRAM) verilator_bin$(EXEEXT) $(DESTDIR)$(bindir)/verilator_bin$(EXEEXT) )
|
|
||||||
( cd bin ; $(INSTALL_PROGRAM) verilator_bin_dbg$(EXEEXT) $(DESTDIR)$(bindir)/verilator_bin_dbg$(EXEEXT) )
|
|
||||||
( cd bin ; $(INSTALL_PROGRAM) verilator_coverage_bin_dbg$(EXEEXT) $(DESTDIR)$(bindir)/verilator_coverage_bin_dbg$(EXEEXT) )
|
|
||||||
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/bin
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/bin
|
||||||
( cd ${srcdir}/bin ; $(INSTALL_PROGRAM) verilator_includer $(DESTDIR)$(pkgdatadir)/bin/verilator_includer )
|
$(MKINSTALLDIRS) $(DESTDIR)$(bindir)
|
||||||
( cd ${srcdir}/bin ; $(INSTALL_PROGRAM) verilator_ccache_report $(DESTDIR)$(pkgdatadir)/bin/verilator_ccache_report )
|
|
||||||
|
installbin: | mkbindirs
|
||||||
|
cd $(srcdir)/bin; \
|
||||||
|
for p in $(VL_INST_PUBLIC_SCRIPT_FILES) ; do \
|
||||||
|
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkgdatadir)/bin/$$p; \
|
||||||
|
done
|
||||||
|
cd bin; \
|
||||||
|
for p in $(VL_INST_PUBLIC_BIN_FILES) ; do \
|
||||||
|
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkgdatadir)/bin/$$p; \
|
||||||
|
done
|
||||||
|
cd $(srcdir)/bin; \
|
||||||
|
for p in $(VL_INST_PRIVATE_SCRIPT_FILES) ; do \
|
||||||
|
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkgdatadir)/bin/$$p; \
|
||||||
|
done
|
||||||
|
|
||||||
|
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 '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; \
|
||||||
|
done
|
||||||
|
rm ${srcdir}/bin/redirect.tmp
|
||||||
|
|
||||||
# Man files can either be part of the original kit, or built in current directory
|
# Man files can either be part of the original kit, or built in current directory
|
||||||
# So important we use $^ so VPATH is searched
|
# So important we use $^ so VPATH is searched
|
||||||
@@ -243,6 +283,7 @@ installdata:
|
|||||||
; for p in $(VL_INST_INC_SRCDIR_FILES) ; do \
|
; for p in $(VL_INST_INC_SRCDIR_FILES) ; do \
|
||||||
$(INSTALL_DATA) $$p $(DESTDIR)$(pkgdatadir)/$$p; \
|
$(INSTALL_DATA) $$p $(DESTDIR)$(pkgdatadir)/$$p; \
|
||||||
done
|
done
|
||||||
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_hello_binary
|
||||||
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_hello_c
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_hello_c
|
||||||
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_hello_sc
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_hello_sc
|
||||||
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_tracing_c
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_tracing_c
|
||||||
@@ -253,7 +294,7 @@ installdata:
|
|||||||
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_c
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_c
|
||||||
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_sc
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_sc
|
||||||
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_protect_lib
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_protect_lib
|
||||||
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/xml_py
|
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/json_py
|
||||||
cd $(srcdir) \
|
cd $(srcdir) \
|
||||||
; for p in $(VL_INST_DATA_SRCDIR_FILES) ; do \
|
; for p in $(VL_INST_DATA_SRCDIR_FILES) ; do \
|
||||||
$(INSTALL_DATA) $$p $(DESTDIR)$(pkgdatadir)/$$p; \
|
$(INSTALL_DATA) $$p $(DESTDIR)$(pkgdatadir)/$$p; \
|
||||||
@@ -265,8 +306,11 @@ installdata:
|
|||||||
|
|
||||||
# We don't trust rm -rf, so rmdir instead as it will fail if user put in other files
|
# We don't trust rm -rf, so rmdir instead as it will fail if user put in other files
|
||||||
uninstall:
|
uninstall:
|
||||||
-cd $(DESTDIR)$(bindir) && rm -f $(VL_INST_BIN_FILES)
|
-cd $(DESTDIR)$(bindir) && rm -f $(VL_INST_PUBLIC_SCRIPT_FILES)
|
||||||
-cd $(DESTDIR)$(pkgdatadir)/bin && rm -f $(VL_INST_BIN_FILES)
|
-cd $(DESTDIR)$(bindir) && rm -f $(VL_INST_PUBLIC_BIN_FILES)
|
||||||
|
-cd $(DESTDIR)$(pkgdatadir)/bin && rm -f $(VL_INST_PUBLIC_SCRIPT_FILES)
|
||||||
|
-cd $(DESTDIR)$(pkgdatadir)/bin && rm -f $(VL_INST_PUBLIC_BIN_FILES)
|
||||||
|
-cd $(DESTDIR)$(pkgdatadir)/bin && rm -f $(VL_INST_PRIVATE_SCRIPT_FILES)
|
||||||
-cd $(DESTDIR)$(mandir)/man1 && rm -f $(VL_INST_MAN_FILES)
|
-cd $(DESTDIR)$(mandir)/man1 && rm -f $(VL_INST_MAN_FILES)
|
||||||
-cd $(DESTDIR)$(pkgdatadir) && rm -f $(VL_INST_INC_BLDDIR_FILES)
|
-cd $(DESTDIR)$(pkgdatadir) && rm -f $(VL_INST_INC_BLDDIR_FILES)
|
||||||
-cd $(DESTDIR)$(pkgdatadir) && rm -f $(VL_INST_INC_SRCDIR_FILES)
|
-cd $(DESTDIR)$(pkgdatadir) && rm -f $(VL_INST_INC_SRCDIR_FILES)
|
||||||
@@ -278,6 +322,7 @@ uninstall:
|
|||||||
-rmdir $(DESTDIR)$(pkgdatadir)/include/gtkwave
|
-rmdir $(DESTDIR)$(pkgdatadir)/include/gtkwave
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/include/vltstd
|
-rmdir $(DESTDIR)$(pkgdatadir)/include/vltstd
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/include
|
-rmdir $(DESTDIR)$(pkgdatadir)/include
|
||||||
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_hello_binary
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_hello_c
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_hello_c
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_hello_sc
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_hello_sc
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_tracing_c
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_tracing_c
|
||||||
@@ -288,50 +333,74 @@ uninstall:
|
|||||||
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_c
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_c
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_sc
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_sc
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_protect_lib
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_protect_lib
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/examples/xml_py
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples/json_py
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)/examples
|
-rmdir $(DESTDIR)$(pkgdatadir)/examples
|
||||||
-rmdir $(DESTDIR)$(pkgdatadir)
|
-rmdir $(DESTDIR)$(pkgdatadir)
|
||||||
-rmdir $(DESTDIR)$(pkgconfigdir)
|
-rmdir $(DESTDIR)$(pkgconfigdir)
|
||||||
|
|
||||||
install: all_nomsg install-all
|
install: all_nomsg install-all
|
||||||
install-all: installbin installman installdata install-msg
|
install-all: installbin installredirect installman installdata install-msg
|
||||||
|
|
||||||
install-here: installman info
|
install-here: installman info
|
||||||
|
|
||||||
# Use --xml flag to see the cppcheck code to use for suppression
|
# Use --xml flag to see the cppcheck code to use for suppression
|
||||||
CPPCHECK_CPP = $(wildcard \
|
CPPCHECK1_CPP = $(wildcard $(srcdir)/include/*.cpp)
|
||||||
$(srcdir)/examples/*/*.cpp \
|
CPPCHECK2_CPP = $(wildcard $(srcdir)/examples/*/*.cpp)
|
||||||
$(srcdir)/include/*.cpp \
|
CPPCHECK3_CPP = $(wildcard $(srcdir)/src/Vlc*.cpp)
|
||||||
$(srcdir)/src/*.cpp )
|
CPPCHECK4_CPP = $(wildcard $(srcdir)/src/V3[A-D]*.cpp $(srcdir)/src/Verilator*.cpp)
|
||||||
CPPCHECK_H = $(wildcard \
|
CPPCHECK5_CPP = $(wildcard $(srcdir)/src/V3[E-I]*.cpp)
|
||||||
|
CPPCHECK6_CPP = $(wildcard $(srcdir)/src/V3[P-Z]*.cpp)
|
||||||
|
CPPCHECK7_CPP = $(wildcard $(srcdir)/src/V3[L-R]*.cpp)
|
||||||
|
CPPCHECK8_CPP = $(wildcard $(srcdir)/src/V3[S-Z]*.cpp)
|
||||||
|
CHECK_CPP = $(CPPCHECK1_CPP) $(CPPCHECK2_CPP) $(CPPCHECK3_CPP) $(CPPCHECK4_CPP) \
|
||||||
|
$(CPPCHECK5_CPP) $(CPPCHECK6_CPP) $(CPPCHECK7_CPP) $(CPPCHECK8_CPP)
|
||||||
|
CHECK_H = $(wildcard \
|
||||||
$(srcdir)/include/*.h \
|
$(srcdir)/include/*.h \
|
||||||
$(srcdir)/src/*.h )
|
$(srcdir)/src/*.h )
|
||||||
CPPCHECK_YL = $(wildcard \
|
CHECK_YL = $(wildcard \
|
||||||
$(srcdir)/src/*.y \
|
$(srcdir)/src/*.y \
|
||||||
$(srcdir)/src/*.l )
|
$(srcdir)/src/*.l )
|
||||||
CPPCHECK = src/cppcheck_filtered cppcheck
|
CPPCHECK = src/cppcheck_filtered cppcheck
|
||||||
CPPCHECK_FLAGS = --enable=all --inline-suppr \
|
CPPCHECK_FLAGS = --enable=all --inline-suppr \
|
||||||
--suppress=unusedScopedObject --suppress=cstyleCast --suppress=useInitializationList \
|
--suppress=cstyleCast --suppress=useInitializationList \
|
||||||
--suppress=nullPointerRedundantCheck
|
--suppress=nullPointer --suppress=nullPointerRedundantCheck --suppress=ctunullpointer \
|
||||||
|
--suppress=unusedFunction --suppress=unusedScopedObject \
|
||||||
|
--suppress=useStlAlgorithm
|
||||||
CPPCHECK_FLAGS += --xml
|
CPPCHECK_FLAGS += --xml
|
||||||
CPPCHECK_DEP = $(subst .cpp,.cppcheck,$(CPPCHECK_CPP))
|
CPPCHECK_DEP = $(subst .cpp,.cppcheck,$(CHECK_CPP))
|
||||||
CPPCHECK_INC = -I$(srcdir)/include -I$(srcdir)/src/obj_dbg -I$(srcdir)/src
|
CPPCHECK_INC = -I$(srcdir)/include -I$(srcdir)/include/gtkwave -I$(srcdir)/include/vltstd -I$(srcdir)/src/obj_dbg -I$(srcdir)/src
|
||||||
|
|
||||||
cppcheck: $(CPPCHECK_DEP)
|
cppcheck: cppcheck-1 cppcheck-2 cppcheck-3 cppcheck-4 cppcheck-5 cppcheck-6 cppcheck-7 cppcheck-8
|
||||||
%.cppcheck: %.cpp
|
cppcheck-1:
|
||||||
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 -DVL_THREADED=1 $(CPPCHECK_INC) $<
|
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $(CPPCHECK1_CPP)
|
||||||
|
cppcheck-2:
|
||||||
|
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $(CPPCHECK2_CPP)
|
||||||
|
cppcheck-3:
|
||||||
|
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $(CPPCHECK3_CPP)
|
||||||
|
cppcheck-4:
|
||||||
|
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $(CPPCHECK4_CPP)
|
||||||
|
cppcheck-5:
|
||||||
|
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $(CPPCHECK5_CPP)
|
||||||
|
cppcheck-6:
|
||||||
|
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $(CPPCHECK6_CPP)
|
||||||
|
cppcheck-7:
|
||||||
|
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $(CPPCHECK7_CPP)
|
||||||
|
cppcheck-8:
|
||||||
|
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $(CPPCHECK8_CPP)
|
||||||
|
|
||||||
CLANGTIDY = clang-tidy
|
CLANGTIDY = clang-tidy
|
||||||
CLANGTIDY_FLAGS = -config='' -checks='-fuchsia-*,-cppcoreguidelines-avoid-c-arrays,-cppcoreguidelines-init-variables'
|
CLANGTIDY_FLAGS = -config='' \
|
||||||
CLANGTIDY_DEP = $(subst .h,.h.tidy,$(CPPCHECK_H)) \
|
-header-filter='.*' \
|
||||||
$(subst .cpp,.cpp.tidy,$(CPPCHECK_CPP))
|
-checks='-fuchsia-*,-cppcoreguidelines-avoid-c-arrays,-cppcoreguidelines-init-variables,-cppcoreguidelines-avoid-goto,-modernize-avoid-c-arrays,-readability-magic-numbers,-readability-simplify-boolean-expr,-cppcoreguidelines-macro-usage' \
|
||||||
CLANGTIDY_DEFS = -DVL_DEBUG=1 -DVL_THREADED=1 -DVL_CPPCHECK=1
|
|
||||||
|
CLANGTIDY_DEP = $(subst .cpp,.cpp.tidy,$(CHECK_CPP))
|
||||||
|
CLANGTIDY_DEFS = -DVL_DEBUG=1 -DVL_CPPCHECK=1
|
||||||
|
|
||||||
clang-tidy: $(CLANGTIDY_DEP)
|
clang-tidy: $(CLANGTIDY_DEP)
|
||||||
%.cpp.tidy: %.cpp
|
%.cpp.tidy: %.cpp
|
||||||
$(CLANGTIDY) $(CLANGTIDY_FLAGS) $< -- $(CLANGTIDY_DEFS) $(CPPCHECK_INC) | 2>&1 tee $@
|
$(CLANGTIDY) $(CLANGTIDY_FLAGS) $< -- $(CLANGTIDY_DEFS) $(CPPCHECK_INC) | 2>&1 tee $@
|
||||||
%.h.tidy: %.h
|
%.h.tidy: %.h
|
||||||
$(CLANGTIDY) $(CLANGTIDY_FLAGS) $< -- $(CLANGTIDY_DEFS) $(CPPCHECK_INC) | 2>&1 tee $@
|
$(CLANGTIDY) $(CLANGTIDY_FLAGS) $< -- $(CLANGTIDY_DEFS) $(CPPCHECK_INC) -x c++-header | 2>&1 tee $@
|
||||||
|
|
||||||
analyzer-src:
|
analyzer-src:
|
||||||
-rm -rf src/obj_dbg
|
-rm -rf src/obj_dbg
|
||||||
@@ -343,22 +412,23 @@ analyzer-include:
|
|||||||
|
|
||||||
format: clang-format yapf format-pl-exec
|
format: clang-format yapf format-pl-exec
|
||||||
|
|
||||||
CLANGFORMAT = clang-format-11
|
CLANGFORMAT = clang-format-14
|
||||||
CLANGFORMAT_FLAGS = -i
|
CLANGFORMAT_FLAGS = -i
|
||||||
CLANGFORMAT_FILES = $(CPPCHECK_CPP) $(CPPCHECK_H) $(CPPCHECK_YL) test_regress/t/*.c* test_regress/t/*.h
|
CLANGFORMAT_FILES = $(CHECK_CPP) $(CHECK_H) $(CHECK_YL) test_regress/t/*.c* test_regress/t/*.h
|
||||||
|
|
||||||
clang-format:
|
clang-format:
|
||||||
@$(CLANGFORMAT) --version | egrep 11.0 > /dev/null \
|
@$(CLANGFORMAT) --version | egrep 14.0 > /dev/null \
|
||||||
|| echo "*** You are not using clang-format 11.0, indents may differ from master's ***"
|
|| echo "*** You are not using clang-format-14, indents may differ from master's ***"
|
||||||
$(CLANGFORMAT) $(CLANGFORMAT_FLAGS) $(CLANGFORMAT_FILES)
|
$(CLANGFORMAT) $(CLANGFORMAT_FLAGS) $(CLANGFORMAT_FILES)
|
||||||
|
|
||||||
PY_PROGRAMS = \
|
PY_PROGRAMS = \
|
||||||
bin/verilator_ccache_report \
|
bin/verilator_ccache_report \
|
||||||
bin/verilator_difftree \
|
bin/verilator_difftree \
|
||||||
bin/verilator_gantt \
|
bin/verilator_gantt \
|
||||||
|
bin/verilator_includer \
|
||||||
bin/verilator_profcfunc \
|
bin/verilator_profcfunc \
|
||||||
examples/xml_py/vl_file_copy \
|
examples/json_py/vl_file_copy \
|
||||||
examples/xml_py/vl_hier_graph \
|
examples/json_py/vl_hier_graph \
|
||||||
docs/guide/conf.py \
|
docs/guide/conf.py \
|
||||||
docs/bin/vl_sphinx_extract \
|
docs/bin/vl_sphinx_extract \
|
||||||
docs/bin/vl_sphinx_fix \
|
docs/bin/vl_sphinx_fix \
|
||||||
@@ -368,7 +438,9 @@ PY_PROGRAMS = \
|
|||||||
src/cppcheck_filtered \
|
src/cppcheck_filtered \
|
||||||
src/flexfix \
|
src/flexfix \
|
||||||
src/vlcovgen \
|
src/vlcovgen \
|
||||||
|
src/.gdbinit.py \
|
||||||
test_regress/t/*.pf \
|
test_regress/t/*.pf \
|
||||||
|
nodist/clang_check_attributes \
|
||||||
nodist/code_coverage \
|
nodist/code_coverage \
|
||||||
nodist/dot_importer \
|
nodist/dot_importer \
|
||||||
nodist/fuzzer/actual_fail \
|
nodist/fuzzer/actual_fail \
|
||||||
@@ -385,17 +457,21 @@ YAPF_FLAGS = -i
|
|||||||
yapf:
|
yapf:
|
||||||
$(YAPF) $(YAPF_FLAGS) $(PY_FILES)
|
$(YAPF) $(YAPF_FLAGS) $(PY_FILES)
|
||||||
|
|
||||||
FLAKE8 = flake8
|
|
||||||
FLAKE8_FLAGS = \
|
|
||||||
--extend-exclude=fastcov.py \
|
|
||||||
--ignore=E123,E129,E251,E501,W503,W504,E701
|
|
||||||
|
|
||||||
PYLINT = pylint
|
PYLINT = pylint
|
||||||
PYLINT_FLAGS = --disable=R0801
|
PYLINT_FLAGS = --score=n --disable=R0801
|
||||||
|
|
||||||
|
RUFF = ruff
|
||||||
|
RUFF_FLAGS = check --ignore=E402,E501,E701
|
||||||
|
|
||||||
|
# "make -k" so can see all tool result errors
|
||||||
lint-py:
|
lint-py:
|
||||||
-$(FLAKE8) $(FLAKE8_FLAGS) $(PY_PROGRAMS)
|
$(MAKE) -k lint-py-pylint lint-py-ruff
|
||||||
-$(PYLINT) $(PYLINT_FLAGS) $(PY_PROGRAMS)
|
|
||||||
|
lint-py-pylint:
|
||||||
|
$(PYLINT) $(PYLINT_FLAGS) $(PY_PROGRAMS)
|
||||||
|
|
||||||
|
lint-py-ruff:
|
||||||
|
$(RUFF) $(RUFF_FLAGS) $(PY_PROGRAMS)
|
||||||
|
|
||||||
format-pl-exec:
|
format-pl-exec:
|
||||||
-chmod a+x test_regress/t/*.pl
|
-chmod a+x test_regress/t/*.pl
|
||||||
@@ -412,8 +488,8 @@ install-msg:
|
|||||||
|
|
||||||
IN_WILD := ${srcdir}/*.in ${srcdir}/*/*.in
|
IN_WILD := ${srcdir}/*.in ${srcdir}/*/*.in
|
||||||
|
|
||||||
# autoheader might not change config_build.h.in, so touch it
|
# autoheader might not change config_package.h.in, so touch it
|
||||||
${srcdir}/config_build.h: ${srcdir}/config_build.h.in configure
|
${srcdir}/config_package.h: ${srcdir}/config_package.h.in configure
|
||||||
cd ${srcdir} && autoheader
|
cd ${srcdir} && autoheader
|
||||||
touch $@
|
touch $@
|
||||||
Makefile: Makefile.in config.status $(IN_WILD)
|
Makefile: Makefile.in config.status $(IN_WILD)
|
||||||
@@ -423,7 +499,7 @@ config.status: configure
|
|||||||
./config.status --recheck
|
./config.status --recheck
|
||||||
|
|
||||||
configure: configure.ac
|
configure: configure.ac
|
||||||
ifeq ($(CFG_WITH_CCWARN),yes) # Local... Else don't burden users
|
ifeq ($(CFG_WITH_CCWARN),yes) # Local... Else don't burden users
|
||||||
autoconf --warnings=all
|
autoconf --warnings=all
|
||||||
else
|
else
|
||||||
autoconf
|
autoconf
|
||||||
@@ -462,7 +538,7 @@ distclean maintainer-clean::
|
|||||||
TAGFILES=${srcdir}/*/*.cpp ${srcdir}/*/*.h ${srcdir}/*/*.in \
|
TAGFILES=${srcdir}/*/*.cpp ${srcdir}/*/*.h ${srcdir}/*/*.in \
|
||||||
${srcdir}/*.in ${srcdir}/*.pod
|
${srcdir}/*.in ${srcdir}/*.pod
|
||||||
|
|
||||||
TAGS: $(TAGFILES)
|
TAGS: $(TAGFILES)
|
||||||
etags $(TAGFILES)
|
etags $(TAGFILES)
|
||||||
|
|
||||||
.PHONY: doxygen
|
.PHONY: doxygen
|
||||||
|
|||||||
+33
-28
@@ -1,12 +1,16 @@
|
|||||||
.. Github doesn't render images unless absolute URL
|
.. Github doesn't render images unless absolute URL
|
||||||
.. Do not know of a conditional tag, "only: github" nor "github display" works
|
.. Do not know of a conditional tag, "only: github" nor "github display" works
|
||||||
|
|
||||||
|
.. image:: https://img.shields.io/badge/Website-Verilator.org-181717.svg
|
||||||
|
:target: https://verilator.org
|
||||||
.. image:: https://img.shields.io/badge/License-LGPL%20v3-blue.svg
|
.. image:: https://img.shields.io/badge/License-LGPL%20v3-blue.svg
|
||||||
:target: https://www.gnu.org/licenses/lgpl-3.0]
|
:target: https://www.gnu.org/licenses/lgpl-3.0
|
||||||
.. image:: https://img.shields.io/badge/License-Artistic%202.0-0298c3.svg
|
.. image:: https://img.shields.io/badge/License-Artistic%202.0-0298c3.svg
|
||||||
:target: https://opensource.org/licenses/Artistic-2.0
|
:target: https://opensource.org/licenses/Artistic-2.0
|
||||||
.. image:: https://repology.org/badge/tiny-repos/verilator.svg?header=distro%20packages
|
.. image:: https://repology.org/badge/tiny-repos/verilator.svg?header=distro%20packages
|
||||||
:target: https://repology.org/project/verilator/versions
|
:target: https://repology.org/project/verilator/versions
|
||||||
|
.. image:: https://img.shields.io/docker/pulls/verilator/verilator
|
||||||
|
:target: https://hub.docker.com/r/verilator/verilator
|
||||||
.. image:: https://api.codacy.com/project/badge/Grade/fa78caa433c84a4ab9049c43e9debc6f
|
.. image:: https://api.codacy.com/project/badge/Grade/fa78caa433c84a4ab9049c43e9debc6f
|
||||||
:target: https://www.codacy.com/gh/verilator/verilator
|
:target: https://www.codacy.com/gh/verilator/verilator
|
||||||
.. image:: https://codecov.io/gh/verilator/verilator/branch/master/graph/badge.svg
|
.. image:: https://codecov.io/gh/verilator/verilator/branch/master/graph/badge.svg
|
||||||
@@ -21,18 +25,18 @@ Welcome to Verilator
|
|||||||
.. list-table::
|
.. list-table::
|
||||||
|
|
||||||
* - **Welcome to Verilator, the fastest Verilog/SystemVerilog simulator.**
|
* - **Welcome to Verilator, the fastest Verilog/SystemVerilog simulator.**
|
||||||
* Accepts synthesizable Verilog or SystemVerilog
|
* Accepts Verilog or SystemVerilog
|
||||||
* Performs lint code-quality checks
|
* Performs lint code-quality checks
|
||||||
* Compiles into multithreaded C++, or SystemC
|
* Compiles into multithreaded C++, or SystemC
|
||||||
* Creates XML to front-end your own tools
|
* Creates XML to front-end your own tools
|
||||||
- |Logo|
|
- |Logo|
|
||||||
* - |verilator multithreaded performance|
|
* - |verilator multithreaded performance|
|
||||||
- **Fast**
|
- **Fast**
|
||||||
* Outperforms many commercial simulators
|
* Outperforms many closed-source commercial simulators
|
||||||
* Single- and multi-threaded output models
|
* Single- and multithreaded output models
|
||||||
* - **Widely Used**
|
* - **Widely Used**
|
||||||
* Wide industry and academic deployment
|
* Wide industry and academic deployment
|
||||||
* Out-of-the-box support from Arm, and RISC-V vendor IP
|
* Out-of-the-box support from Arm and RISC-V vendor IP
|
||||||
- |verilator usage|
|
- |verilator usage|
|
||||||
* - |verilator community|
|
* - |verilator community|
|
||||||
- **Community Driven & Openly Licensed**
|
- **Community Driven & Openly Licensed**
|
||||||
@@ -52,41 +56,42 @@ What Verilator Does
|
|||||||
Verilator is invoked with parameters similar to GCC or Synopsys's VCS. It
|
Verilator is invoked with parameters similar to GCC or Synopsys's VCS. It
|
||||||
"Verilates" the specified Verilog or SystemVerilog code by reading it,
|
"Verilates" the specified Verilog or SystemVerilog code by reading it,
|
||||||
performing lint checks, and optionally inserting assertion checks and
|
performing lint checks, and optionally inserting assertion checks and
|
||||||
coverage-analysis points. It outputs single- or multi-threaded .cpp and .h
|
coverage-analysis points. It outputs single- or multithreaded .cpp and .h
|
||||||
files, the "Verilated" code.
|
files, the "Verilated" code.
|
||||||
|
|
||||||
The user writes a little C++/SystemC wrapper file, which instantiates the
|
These Verilated C++/SystemC files are then compiled by a C++ compiler
|
||||||
"Verilated" model of the user's top level module. These C++/SystemC files
|
(gcc/clang/MSVC++), optionally along with a user's own C++/SystemC wrapper
|
||||||
are then compiled by a C++ compiler (gcc/clang/MSVC++). The resulting
|
file, to instantiate the Verilated model. Executing the resulting
|
||||||
executable performs the design simulation. Verilator also supports linking
|
executable performs the design simulation. Verilator also supports linking
|
||||||
its generated libraries, optionally encrypted, into other simulators.
|
Verilated generated libraries, optionally encrypted, into other simulators.
|
||||||
|
|
||||||
Verilator may not be the best choice if you are expecting a full featured
|
Verilator may not be the best choice if you are expecting a full-featured
|
||||||
replacement for NC-Verilog, VCS or another commercial Verilog simulator, or
|
replacement for a closed-source Verilog simulator, need SDF annotation,
|
||||||
if you are looking for a behavioral Verilog simulator e.g. for a quick
|
mixed-signal simulation, or are doing a quick class project (we recommend
|
||||||
class project (we recommend `Icarus Verilog`_ for this.) However, if you
|
`Icarus Verilog`_ for classwork). However, if you are looking for a path
|
||||||
are looking for a path to migrate SystemVerilog to C++ or SystemC, or your
|
to migrate SystemVerilog to C++/SystemC, or want high-speed simulation of
|
||||||
team is comfortable writing just a touch of C++ code, Verilator is the tool
|
designs, Verilator is the tool for you.
|
||||||
for you.
|
|
||||||
|
|
||||||
|
|
||||||
Performance
|
Performance
|
||||||
===========
|
===========
|
||||||
|
|
||||||
Verilator does not simply convert Verilog HDL to C++ or SystemC. Rather,
|
Verilator does not directly translate Verilog HDL to C++ or SystemC. Rather,
|
||||||
Verilator compiles your code into a much faster optimized and optionally
|
Verilator compiles your code into a much faster optimized and optionally
|
||||||
thread-partitioned model, which is in turn wrapped inside a C++/SystemC
|
thread-partitioned model, which is in turn wrapped inside a C++/SystemC
|
||||||
module. The results are a compiled Verilog model that executes even on a
|
module. The results are a compiled Verilog model that executes even on a
|
||||||
single-thread over 10x faster than standalone SystemC, and on a single
|
single thread over 10x faster than standalone SystemC, and on a single
|
||||||
thread is about 100 times faster than interpreted Verilog simulators such
|
thread is about 100 times faster than interpreted Verilog simulators such
|
||||||
as `Icarus Verilog`_. Another 2-10x speedup might be gained from
|
as `Icarus Verilog`_. Another 2-10x speedup might be gained from
|
||||||
multithreading (yielding 200-1000x total over interpreted simulators).
|
multithreading (yielding 200-1000x total over interpreted simulators).
|
||||||
|
|
||||||
Verilator has typically similar or better performance versus the
|
Verilator has typically similar or better performance versus
|
||||||
closed-source Verilog simulators (Carbon Design Systems Carbonator,
|
closed-source Verilog simulators (e.g., Carbon Design Systems Carbonator,
|
||||||
Modelsim, Cadence Incisive/NC-Verilog, Synopsys VCS, VTOC, and Pragmatic
|
Modelsim/Questa, Cadence Incisive/NC-Verilog, Synopsys VCS, VTOC, and
|
||||||
CVer/CVC). But, Verilator is open-sourced, so you can spend on computes
|
Pragmatic CVer/CVC). But, Verilator is open-sourced, so you can spend on
|
||||||
rather than licenses. Thus Verilator gives you the best cycles/dollar.
|
computes rather than licenses. Thus, Verilator gives you the best
|
||||||
|
simulation cycles/dollar.
|
||||||
|
|
||||||
|
|
||||||
Installation & Documentation
|
Installation & Documentation
|
||||||
============================
|
============================
|
||||||
@@ -99,7 +104,7 @@ For more information:
|
|||||||
- `Verilator manual (HTML) <https://verilator.org/verilator_doc.html>`_,
|
- `Verilator manual (HTML) <https://verilator.org/verilator_doc.html>`_,
|
||||||
or `Verilator manual (PDF) <https://verilator.org/verilator_doc.pdf>`_
|
or `Verilator manual (PDF) <https://verilator.org/verilator_doc.pdf>`_
|
||||||
|
|
||||||
- `Subscribe to verilator announcements
|
- `Subscribe to Verilator announcements
|
||||||
<https://github.com/verilator/verilator-announce>`_
|
<https://github.com/verilator/verilator-announce>`_
|
||||||
|
|
||||||
- `Verilator forum <https://verilator.org/forum>`_
|
- `Verilator forum <https://verilator.org/forum>`_
|
||||||
@@ -130,14 +135,14 @@ Related Projects
|
|||||||
- `GTKwave <http://gtkwave.sourceforge.net/>`_ - Waveform viewer for
|
- `GTKwave <http://gtkwave.sourceforge.net/>`_ - Waveform viewer for
|
||||||
Verilator traces.
|
Verilator traces.
|
||||||
|
|
||||||
- `Icarus Verilog`_ - Icarus is a full featured interpreted Verilog
|
- `Icarus Verilog`_ - Icarus is a full-featured interpreted Verilog
|
||||||
simulator. If Verilator does not support your needs, perhaps Icarus may.
|
simulator. If Verilator does not support your needs, perhaps Icarus may.
|
||||||
|
|
||||||
|
|
||||||
Open License
|
Open License
|
||||||
============
|
============
|
||||||
|
|
||||||
Verilator is Copyright 2003-2021 by Wilson Snyder. (Report bugs to
|
Verilator is Copyright 2003-2024 by Wilson Snyder. (Report bugs to
|
||||||
`Verilator Issues <https://verilator.org/issues>`_.)
|
`Verilator Issues <https://verilator.org/issues>`_.)
|
||||||
|
|
||||||
Verilator is free software; you can redistribute it and/or modify it under
|
Verilator is free software; you can redistribute it and/or modify it under
|
||||||
@@ -145,7 +150,7 @@ the terms of either the GNU Lesser General Public License Version 3 or the
|
|||||||
Perl Artistic License Version 2.0. See the documentation for more details.
|
Perl Artistic License Version 2.0. See the documentation for more details.
|
||||||
|
|
||||||
.. _CHIPS Alliance: https://chipsalliance.org
|
.. _CHIPS Alliance: https://chipsalliance.org
|
||||||
.. _Icarus Verilog: http://iverilog.icarus.com
|
.. _Icarus Verilog: https://steveicarus.github.io/iverilog
|
||||||
.. _Linux Foundation: https://www.linuxfoundation.org
|
.. _Linux Foundation: https://www.linuxfoundation.org
|
||||||
.. |Logo| image:: https://www.veripool.org/img/verilator_256_200_min.png
|
.. |Logo| image:: https://www.veripool.org/img/verilator_256_200_min.png
|
||||||
.. |verilator multithreaded performance| image:: https://www.veripool.org/img/verilator_multithreaded_performance_bg-min.png
|
.. |verilator multithreaded performance| image:: https://www.veripool.org/img/verilator_multithreaded_performance_bg-min.png
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
#!/usr/bin/env perl
|
||||||
|
######################################################################
|
||||||
|
#
|
||||||
|
# Copyright 2003-2024 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
|
||||||
|
#
|
||||||
|
######################################################################
|
||||||
|
|
||||||
|
require 5.006_001;
|
||||||
|
use warnings;
|
||||||
|
use FindBin qw($RealBin $RealScript);
|
||||||
|
use strict;
|
||||||
|
|
||||||
|
my $relpath = RELPATH; # Substituted during Verilator 'make install'
|
||||||
|
|
||||||
|
unshift @ARGV, $RealScript;
|
||||||
|
|
||||||
|
exec { "$RealBin/$relpath/$RealScript" } @ARGV;
|
||||||
|
die "%Error: Exec failed,";
|
||||||
+156
-84
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env perl
|
#!/usr/bin/env perl
|
||||||
######################################################################
|
######################################################################
|
||||||
#
|
#
|
||||||
# Copyright 2003-2021 by Wilson Snyder. This program is free software; you
|
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||||
# can redistribute it and/or modify it under the terms of either the GNU
|
# 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
|
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
# Version 2.0.
|
# Version 2.0.
|
||||||
@@ -15,6 +15,7 @@ use Getopt::Long;
|
|||||||
use FindBin qw($RealBin $RealScript);
|
use FindBin qw($RealBin $RealScript);
|
||||||
use IO::File;
|
use IO::File;
|
||||||
use Pod::Usage;
|
use Pod::Usage;
|
||||||
|
use Cwd qw(realpath);
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
use vars qw($Debug @Opt_Verilator_Sw);
|
use vars qw($Debug @Opt_Verilator_Sw);
|
||||||
@@ -31,6 +32,8 @@ my $opt_gdb;
|
|||||||
my $opt_rr;
|
my $opt_rr;
|
||||||
my $opt_gdbbt;
|
my $opt_gdbbt;
|
||||||
my $opt_quiet_exit;
|
my $opt_quiet_exit;
|
||||||
|
my $opt_unlimited_stack = 1;
|
||||||
|
my $opt_valgrind;
|
||||||
|
|
||||||
# No arguments can't do anything useful. Give help
|
# No arguments can't do anything useful. Give help
|
||||||
if ($#ARGV < 0) {
|
if ($#ARGV < 0) {
|
||||||
@@ -49,20 +52,35 @@ foreach my $sw (@ARGV) {
|
|||||||
Getopt::Long::config("no_auto_abbrev", "pass_through");
|
Getopt::Long::config("no_auto_abbrev", "pass_through");
|
||||||
if (! GetOptions(
|
if (! GetOptions(
|
||||||
# Major operating modes
|
# Major operating modes
|
||||||
"help" => \&usage,
|
"help" => \&usage,
|
||||||
"debug" => \&debug,
|
"debug" => \&debug,
|
||||||
# "version!" => \&version, # Also passthru'ed
|
# "version!" => \&version, # Also passthru'ed
|
||||||
# Switches
|
# Switches
|
||||||
"gdb!" => \$opt_gdb,
|
"gdb!" => \$opt_gdb,
|
||||||
"gdbbt!" => \$opt_gdbbt,
|
"gdbbt!" => \$opt_gdbbt,
|
||||||
"quiet-exit!" => \$opt_quiet_exit,
|
"quiet!" => \$opt_quiet_exit, # As -quiet implies -quiet-exit
|
||||||
"rr!" => \$opt_rr,
|
"quiet-exit!" => \$opt_quiet_exit,
|
||||||
|
"rr!" => \$opt_rr,
|
||||||
|
"unlimited-stack!" => \$opt_unlimited_stack,
|
||||||
|
"valgrind!" => \$opt_valgrind,
|
||||||
# Additional parameters
|
# Additional parameters
|
||||||
"<>" => sub {}, # Ignored
|
"<>" => sub {}, # Ignored
|
||||||
)) {
|
)) {
|
||||||
pod2usage(-exitstatus => 2, -verbose => 0);
|
pod2usage(-exitstatus => 2, -verbose => 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
my $verilator_root = realpath("$RealBin/..");
|
||||||
|
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";
|
||||||
|
warn "%Error: VERILATOR_ROOT=$ENV{VERILATOR_ROOT}\n";
|
||||||
|
exit 1;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
print "export VERILATOR_ROOT='$verilator_root'\n" if $Debug;
|
||||||
|
$ENV{VERILATOR_ROOT} = $verilator_root;
|
||||||
|
}
|
||||||
|
|
||||||
if ($opt_gdbbt && !gdb_works()) {
|
if ($opt_gdbbt && !gdb_works()) {
|
||||||
warn "-Info: --gdbbt ignored: gdb doesn't seem to be working\n" if $Debug;
|
warn "-Info: --gdbbt ignored: gdb doesn't seem to be working\n" if $Debug;
|
||||||
$opt_gdbbt = 0;
|
$opt_gdbbt = 0;
|
||||||
@@ -76,7 +94,8 @@ if ($opt_gdbbt && !gdb_works()) {
|
|||||||
my @quoted_sw = map { sh_escape($_) } @Opt_Verilator_Sw;
|
my @quoted_sw = map { sh_escape($_) } @Opt_Verilator_Sw;
|
||||||
if ($opt_gdb) {
|
if ($opt_gdb) {
|
||||||
# Generic GDB interactive
|
# Generic GDB interactive
|
||||||
run (aslr_off()
|
run (ulimit_stack_unlimited()
|
||||||
|
. aslr_off()
|
||||||
. ($ENV{VERILATOR_GDB} || "gdb")
|
. ($ENV{VERILATOR_GDB} || "gdb")
|
||||||
. " " . verilator_bin()
|
. " " . verilator_bin()
|
||||||
# Note, uncomment to set breakpoints before running:
|
# Note, uncomment to set breakpoints before running:
|
||||||
@@ -92,24 +111,41 @@ if ($opt_gdb) {
|
|||||||
. " -ex 'bt'");
|
. " -ex 'bt'");
|
||||||
} elsif ($opt_rr) {
|
} elsif ($opt_rr) {
|
||||||
# Record with rr
|
# Record with rr
|
||||||
run (aslr_off()
|
run (ulimit_stack_unlimited()
|
||||||
|
. aslr_off()
|
||||||
. "rr record " . verilator_bin()
|
. "rr record " . verilator_bin()
|
||||||
. " " . join(' ', @quoted_sw));
|
. " " . join(' ', @quoted_sw));
|
||||||
} elsif ($opt_gdbbt && $Debug) {
|
} elsif ($opt_gdbbt && $Debug) {
|
||||||
# Run under GDB to get gdbbt
|
# Run under GDB to get gdbbt
|
||||||
run (aslr_off()
|
run (ulimit_stack_unlimited()
|
||||||
|
. aslr_off()
|
||||||
. "gdb"
|
. "gdb"
|
||||||
. " " . verilator_bin()
|
. " " . verilator_bin()
|
||||||
. " --batch --quiet --return-child-result"
|
. " --batch --quiet --return-child-result"
|
||||||
. " -ex \"run " . join(' ', @quoted_sw)."\""
|
. " -ex \"run " . join(' ', @quoted_sw)."\""
|
||||||
. " -ex 'set width 0'"
|
. " -ex 'set width 0'"
|
||||||
. " -ex 'bt' -ex 'quit'");
|
. " -ex 'bt' -ex 'quit'");
|
||||||
|
} elsif ($opt_valgrind) {
|
||||||
|
# Run under valgrind
|
||||||
|
my $valgrind_bin = ($ENV{VERILATOR_VALGRIND} || "valgrind --error-exitcode=1 --max-stackframe=2815880"
|
||||||
|
# Magic number sugested by valgrind, may need to be increased in future
|
||||||
|
# if you get warnings. See: https://valgrind.org/docs/manual/manual-core.html#opt.max-stackframe
|
||||||
|
);
|
||||||
|
|
||||||
|
run (ulimit_stack_unlimited()
|
||||||
|
. aslr_off()
|
||||||
|
. $valgrind_bin
|
||||||
|
. " " . verilator_bin()
|
||||||
|
. " " . join(' ', @quoted_sw));
|
||||||
} elsif ($Debug) {
|
} elsif ($Debug) {
|
||||||
# Debug
|
# Debug
|
||||||
run(aslr_off() . verilator_bin() . " " . join(' ', @quoted_sw));
|
run(ulimit_stack_unlimited()
|
||||||
|
. aslr_off()
|
||||||
|
. verilator_bin()
|
||||||
|
. " " . join(' ', @quoted_sw));
|
||||||
} else {
|
} else {
|
||||||
# Normal, non gdb
|
# Normal, non gdb
|
||||||
run(verilator_bin() . " " . join(' ', @quoted_sw));
|
run(ulimit_stack_unlimited() . verilator_bin() . " " . join(' ', @quoted_sw));
|
||||||
}
|
}
|
||||||
|
|
||||||
#----------------------------------------------------------------------
|
#----------------------------------------------------------------------
|
||||||
@@ -129,30 +165,13 @@ sub debug {
|
|||||||
# Builds
|
# Builds
|
||||||
|
|
||||||
sub verilator_bin {
|
sub verilator_bin {
|
||||||
my $bin = "";
|
|
||||||
# Use VERILATOR_ROOT if defined, else assume verilator_bin is in the search path
|
|
||||||
my $basename = ($ENV{VERILATOR_BIN}
|
my $basename = ($ENV{VERILATOR_BIN}
|
||||||
|| ($Debug ? "verilator_bin_dbg" : "verilator_bin"));
|
|| ($Debug ? "verilator_bin_dbg" : "verilator_bin"));
|
||||||
if (defined($ENV{VERILATOR_ROOT})) {
|
if (-x "$RealBin/$basename" || -x "$RealBin/$basename.exe") {
|
||||||
my $dir = $ENV{VERILATOR_ROOT};
|
return "$RealBin/$basename";
|
||||||
if (-x "$dir/bin/$basename"
|
|
||||||
|| -x "$dir/bin/$basename.exe") { # From a "make install" into VERILATOR_ROOT
|
|
||||||
$bin = "$dir/bin/$basename";
|
|
||||||
} else {
|
|
||||||
$bin = "$dir/$basename"; # From pointing to kit directory
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
if (-x "$RealBin/$basename"
|
return $basename; # Find in PATH
|
||||||
|| -x "$RealBin/$basename.exe") {
|
|
||||||
$bin = "$RealBin/$basename"; # From path/to/verilator with verilator_bin installed
|
|
||||||
} else {
|
|
||||||
$bin = $basename; # Find in PATH
|
|
||||||
}
|
|
||||||
# Note we don't look under bin/$basename which would be right if running
|
|
||||||
# in the kit dir. Running that would likely break, since
|
|
||||||
# VERILATOR_ROOT wouldn't be set and Verilator won't find internal files.
|
|
||||||
}
|
}
|
||||||
return $bin;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
@@ -180,6 +199,17 @@ sub aslr_off {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub ulimit_stack_unlimited {
|
||||||
|
return "" if !$opt_unlimited_stack;
|
||||||
|
system("ulimit -s unlimited 2>/dev/null");
|
||||||
|
my $status = $?;
|
||||||
|
if ($status == 0) {
|
||||||
|
return "ulimit -s unlimited 2>/dev/null; exec ";
|
||||||
|
} else {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
sub run {
|
sub run {
|
||||||
# Run command, check errors
|
# Run command, check errors
|
||||||
my $command = shift;
|
my $command = shift;
|
||||||
@@ -244,6 +274,7 @@ Verilator - Translate and simulate SystemVerilog code using C++/SystemC
|
|||||||
|
|
||||||
verilator --help
|
verilator --help
|
||||||
verilator --version
|
verilator --version
|
||||||
|
verilator --binary -j 0 [options] [source_files.v]... [opt_c_files.cpp/c/cc/a/o/so]
|
||||||
verilator --cc [options] [source_files.v]... [opt_c_files.cpp/c/cc/a/o/so]
|
verilator --cc [options] [source_files.v]... [opt_c_files.cpp/c/cc/a/o/so]
|
||||||
verilator --sc [options] [source_files.v]... [opt_c_files.cpp/c/cc/a/o/so]
|
verilator --sc [options] [source_files.v]... [opt_c_files.cpp/c/cc/a/o/so]
|
||||||
verilator --lint-only -Wall [source_files.v]...
|
verilator --lint-only -Wall [source_files.v]...
|
||||||
@@ -267,7 +298,7 @@ detailed descriptions of these arguments.
|
|||||||
|
|
||||||
=for VL_SPHINX_EXTRACT "_build/gen/args_verilator.rst"
|
=for VL_SPHINX_EXTRACT "_build/gen/args_verilator.rst"
|
||||||
|
|
||||||
<file.v> Verilog package, module and top module filenames
|
<file.v> Verilog package, module, and top module filenames
|
||||||
<file.c/cc/cpp> Optional C++ files to compile in
|
<file.c/cc/cpp> Optional C++ files to compile in
|
||||||
<file.a/o/so> Optional C++ files to link in
|
<file.a/o/so> Optional C++ files to link in
|
||||||
|
|
||||||
@@ -278,39 +309,52 @@ detailed descriptions of these arguments.
|
|||||||
+1800-2009ext+<ext> Use SystemVerilog 2009 with file extension <ext>
|
+1800-2009ext+<ext> Use SystemVerilog 2009 with file extension <ext>
|
||||||
+1800-2012ext+<ext> Use SystemVerilog 2012 with file extension <ext>
|
+1800-2012ext+<ext> Use SystemVerilog 2012 with file extension <ext>
|
||||||
+1800-2017ext+<ext> Use SystemVerilog 2017 with file extension <ext>
|
+1800-2017ext+<ext> Use SystemVerilog 2017 with file extension <ext>
|
||||||
|
+1800-2023ext+<ext> Use SystemVerilog 2023 with file extension <ext>
|
||||||
--assert Enable all assertions
|
--assert Enable all assertions
|
||||||
|
--assert-case Enable unique/unique0/priority case related checks
|
||||||
--autoflush Flush streams after all $displays
|
--autoflush Flush streams after all $displays
|
||||||
--bbox-sys Blackbox unknown $system calls
|
--bbox-sys Blackbox unknown $system calls
|
||||||
--bbox-unsup Blackbox unsupported language features
|
--bbox-unsup Blackbox unsupported language features
|
||||||
--bin <filename> Override Verilator binary
|
--binary Build model binary
|
||||||
--build Build model executable/library after Verilation
|
--build Build model executable/library after Verilation
|
||||||
-CFLAGS <flags> C++ compiler arguments for makefile
|
--build-dep-bin <filename> Override build dependency Verilator binary
|
||||||
|
--build-jobs <jobs> Parallelism for --build
|
||||||
--cc Create C++ output
|
--cc Create C++ output
|
||||||
--cdc Clock domain crossing analysis
|
-CFLAGS <flags> C++ compiler arguments for makefile
|
||||||
--clk <signal-name> Mark specified signal as clock
|
--clk <signal-name> Mark specified signal as clock
|
||||||
--make <build-tool> Generate scripts for specified build tool
|
--no-clk <signal-name> Prevent marking specified signal as clock
|
||||||
--compiler <compiler-name> Tune for specified C++ compiler
|
--compiler <compiler-name> Tune for specified C++ compiler
|
||||||
--converge-limit <loops> Tune convergence settle time
|
--converge-limit <loops> Tune convergence settle time
|
||||||
--coverage Enable all coverage
|
--coverage Enable all coverage
|
||||||
--coverage-line Enable line coverage
|
--coverage-line Enable line coverage
|
||||||
--coverage-max-width <width> Maximum array depth for coverage
|
--coverage-max-width <width> Maximum array depth for coverage
|
||||||
--coverage-toggle Enable toggle coverage
|
--coverage-toggle Enable toggle coverage
|
||||||
--coverage-user Enable SVL user coverage
|
|
||||||
--coverage-underscore Enable coverage of _signals
|
--coverage-underscore Enable coverage of _signals
|
||||||
|
--coverage-user Enable SVL user coverage
|
||||||
-D<var>[=<value>] Set preprocessor define
|
-D<var>[=<value>] Set preprocessor define
|
||||||
--debug Enable debugging
|
--debug Enable debugging
|
||||||
--debug-check Enable debugging assertions
|
--debug-check Enable debugging assertions
|
||||||
--no-debug-leak Disable leaking memory in --debug mode
|
--no-debug-leak Disable leaking memory in --debug mode
|
||||||
--debugi <level> Enable debugging at a specified level
|
--debugi <level> Enable debugging at a specified level
|
||||||
--debugi-<srcfile> <level> Enable debugging a source file at a level
|
--debugi-<srcfile> <level> Enable debugging a source file at a level
|
||||||
|
--decorations <level> Set output comment and spacing level
|
||||||
|
--no-decoration Disable comments and lower spacing level
|
||||||
--default-language <lang> Default language to parse
|
--default-language <lang> Default language to parse
|
||||||
+define+<var>=<value> Set preprocessor define
|
+define+<var>=<value> Set preprocessor define
|
||||||
--dpi-hdr-only Only produce the DPI header file
|
--dpi-hdr-only Only produce the DPI header file
|
||||||
--dump-defines Show preprocessor defines with -E
|
--dump-defines Show preprocessor defines with -E
|
||||||
--dump-tree Enable dumping .tree files
|
--dump-dfg Enable dumping DfgGraphs to .dot files
|
||||||
--dump-treei <level> Enable dumping .tree files at a level
|
--dump-graph Enable dumping V3Graphs to .dot files
|
||||||
--dump-treei-<srcfile> <level> Enable dumping .tree file at a source file at a level
|
--dump-tree Enable dumping Ast .tree files
|
||||||
--dump-tree-addrids Use short identifiers instead of addresses
|
--dump-tree-addrids Use short identifiers instead of addresses
|
||||||
|
--dump-tree-dot Enable dumping Ast .tree.dot debug files
|
||||||
|
--dump-tree-json Enable dumping Ast .tree.json files and .tree.meta.json file
|
||||||
|
--dump-<srcfile> Enable dumping everything in source file
|
||||||
|
--dumpi-dfg <level> Enable dumping DfgGraphs to .dot files at level
|
||||||
|
--dumpi-graph <level> Enable dumping V3Graphs to .dot files at level
|
||||||
|
--dumpi-tree <level> Enable dumping Ast .tree files at level
|
||||||
|
--dumpi-tree-json <level> Enable dumping Ast .tree.json files at level
|
||||||
|
--dumpi-<srcfile> <level> Enable dumping everything in source file at level
|
||||||
-E Preprocess, but do not compile
|
-E Preprocess, but do not compile
|
||||||
--error-limit <value> Abort after this number of errors
|
--error-limit <value> Abort after this number of errors
|
||||||
--exe Link to create executable
|
--exe Link to create executable
|
||||||
@@ -319,83 +363,96 @@ detailed descriptions of these arguments.
|
|||||||
-f <file> Parse arguments from a file
|
-f <file> Parse arguments from a file
|
||||||
-FI <file> Force include of a file
|
-FI <file> Force include of a file
|
||||||
--flatten Force inlining of all modules, tasks and functions
|
--flatten Force inlining of all modules, tasks and functions
|
||||||
|
--future0 <option> Ignore an option for compatibility
|
||||||
|
--future1 <option> Ignore an option with argument for compatibility
|
||||||
|
-fno-<optimization> Disable internal optimization stage
|
||||||
-G<name>=<value> Overwrite top-level parameter
|
-G<name>=<value> Overwrite top-level parameter
|
||||||
|
--gate-stmts <value> Tune gate optimizer depth
|
||||||
--gdb Run Verilator under GDB interactively
|
--gdb Run Verilator under GDB interactively
|
||||||
--gdbbt Run Verilator under GDB for backtrace
|
--gdbbt Run Verilator under GDB for backtrace
|
||||||
--generate-key Create random key for --protect-key
|
--generate-key Create random key for --protect-key
|
||||||
--getenv <var> Get environment variable with defaults
|
--getenv <var> Get environment variable with defaults
|
||||||
--help Display this help
|
--get-supported <feature> Get if feature is supported
|
||||||
|
--help Show this help
|
||||||
--hierarchical Enable hierarchical Verilation
|
--hierarchical Enable hierarchical Verilation
|
||||||
-I<dir> Directory to search for includes
|
-I<dir> Directory to search for includes
|
||||||
-j <jobs> Parallelism for --build
|
|
||||||
--gate-stmts <value> Tune gate optimizer depth
|
|
||||||
--if-depth <value> Tune IFDEPTH warning
|
--if-depth <value> Tune IFDEPTH warning
|
||||||
+incdir+<dir> Directory to search for includes
|
+incdir+<dir> Directory to search for includes
|
||||||
--inline-mult <value> Tune module inlining
|
--inline-mult <value> Tune module inlining
|
||||||
--instr-count-dpi <value> Assumed dynamic instruction count of DPI imports
|
--instr-count-dpi <value> Assumed dynamic instruction count of DPI imports
|
||||||
-LDFLAGS <flags> Linker pre-object arguments for makefile
|
-j <jobs> Parallelism for --build-jobs/--verilate-jobs
|
||||||
--l2-name <value> Verilog scope name of the top module
|
--l2-name <value> Verilog scope name of the top module
|
||||||
--language <lang> Default language standard to parse
|
--language <lang> Default language standard to parse
|
||||||
|
-LDFLAGS <flags> Linker pre-object arguments for makefile
|
||||||
--lib-create <name> Create a DPI library
|
--lib-create <name> Create a DPI library
|
||||||
+libext+<ext>+[ext]... Extensions for finding modules
|
+libext+<ext>+[ext]... Extensions for finding modules
|
||||||
--lint-only Lint, but do not make output
|
--lint-only Lint, but do not make output
|
||||||
|
--make <build-tool> Generate scripts for specified build tool
|
||||||
-MAKEFLAGS <flags> Arguments to pass to make during --build
|
-MAKEFLAGS <flags> Arguments to pass to make during --build
|
||||||
|
--main Generate C++ main() file
|
||||||
|
--main-top-name Specify top name passed to Verilated model in generated C++ main
|
||||||
--max-num-width <value> Maximum number width (default: 64K)
|
--max-num-width <value> Maximum number width (default: 64K)
|
||||||
--MMD Create .d dependency files
|
|
||||||
--MP Create phony dependency targets
|
|
||||||
--Mdir <directory> Name of output object directory
|
--Mdir <directory> Name of output object directory
|
||||||
--no-merge-const-pool Disable merging of different types in const pool
|
--MMD Create .d dependency files
|
||||||
--mod-prefix <topname> Name to prepend to lower classes
|
--mod-prefix <topname> Name to prepend to lower classes
|
||||||
--no-clk <signal-name> Prevent marking specified signal as clock
|
--MP Create phony dependency targets
|
||||||
--no-decoration Disable comments and symbol decorations
|
|
||||||
--no-pins64 Don't use vluint64_t's for 33-64 bit sigs
|
|
||||||
--no-skip-identical Disable skipping identical output
|
|
||||||
+notimingchecks Ignored
|
+notimingchecks Ignored
|
||||||
-O0 Disable optimizations
|
-O0 Disable optimizations
|
||||||
-O3 High performance optimizations
|
-O3 High-performance optimizations
|
||||||
-O<optimization-letter> Selectable optimizations
|
-O<optimization-letter> Selectable optimizations
|
||||||
-o <executable> Name of final executable
|
-o <executable> Name of final executable
|
||||||
--no-order-clock-delay Disable ordering clock enable assignments
|
|
||||||
--no-verilate Skip verilation and just compile previously Verilated code.
|
|
||||||
--output-split <statements> Split .cpp files into pieces
|
--output-split <statements> Split .cpp files into pieces
|
||||||
--output-split-cfuncs <statements> Split model functions
|
--output-split-cfuncs <statements> Split model functions
|
||||||
--output-split-ctrace <statements> Split tracing functions
|
--output-split-ctrace <statements> Split tracing functions
|
||||||
-P Disable line numbers and blanks with -E
|
-P Disable line numbers and blanks with -E
|
||||||
--pins-bv <bits> Specify types for top level ports
|
--pins-bv <bits> Specify types for top-level ports
|
||||||
--pins-sc-uint Specify types for top level ports
|
--pins-sc-biguint Specify types for top-level ports
|
||||||
--pins-sc-biguint Specify types for top level ports
|
--pins-sc-uint Specify types for top-level ports
|
||||||
--pins-uint8 Specify types for top level ports
|
--pins-uint8 Specify types for top-level ports
|
||||||
|
--no-pins64 Don't use uint64_t's for 33-64 bit sigs
|
||||||
--pipe-filter <command> Filter all input through a script
|
--pipe-filter <command> Filter all input through a script
|
||||||
--pp-comments Show preprocessor comments with -E
|
--pp-comments Show preprocessor comments with -E
|
||||||
--prefix <topname> Name of top level class
|
--prefix <topname> Name of top-level class
|
||||||
|
--private Debugging; see docs
|
||||||
--prof-c Compile C++ code with profiling
|
--prof-c Compile C++ code with profiling
|
||||||
--prof-cfuncs Name functions for profiling
|
--prof-cfuncs Name functions for profiling
|
||||||
--prof-threads Enable generating gantt chart data for threads
|
--prof-exec Enable generating execution profile for gantt chart
|
||||||
--protect-key <key> Key for symbol protection
|
--prof-pgo Enable generating profiling data for PGO
|
||||||
--protect-ids Hash identifier names for obscurity
|
--protect-ids Hash identifier names for obscurity
|
||||||
|
--protect-key <key> Key for symbol protection
|
||||||
--protect-lib <name> Create a DPI protected library
|
--protect-lib <name> Create a DPI protected library
|
||||||
--private Debugging; see docs
|
--public Mark signals as public; see docs
|
||||||
--public Debugging; 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-flat-rw Mark all variables, etc as public_flat_rw
|
||||||
-pvalue+<name>=<value> Overwrite toplevel parameter
|
-pvalue+<name>=<value> Overwrite toplevel parameter
|
||||||
|
--quiet Minimize additional printing
|
||||||
--quiet-exit Don't print the command on failure
|
--quiet-exit Don't print the command on failure
|
||||||
|
--quiet-stats Don't print statistics
|
||||||
--relative-includes Resolve includes relative to current file
|
--relative-includes Resolve includes relative to current file
|
||||||
--reloop-limit Minimum iterations for forming loops
|
--reloop-limit Minimum iterations for forming loops
|
||||||
--report-unoptflat Extra diagnostics for UNOPTFLAT
|
--report-unoptflat Extra diagnostics for UNOPTFLAT
|
||||||
--rr Run Verilator and record with rr
|
--rr Run Verilator and record with rr
|
||||||
|
--runtime-debug Enable model runtime debugging
|
||||||
--savable Enable model save-restore
|
--savable Enable model save-restore
|
||||||
--sc Create SystemC output
|
--sc Create SystemC output
|
||||||
|
--no-skip-identical Disable skipping identical output
|
||||||
--stats Create statistics file
|
--stats Create statistics file
|
||||||
--stats-vars Provide statistics on variables
|
--stats-vars Provide statistics on variables
|
||||||
|
--no-std Prevent parsing standard library
|
||||||
|
--no-stop-fail Do not call $stop when assertion fails
|
||||||
|
--structs-packed Convert all unpacked structures to packed structures
|
||||||
-sv Enable SystemVerilog parsing
|
-sv Enable SystemVerilog parsing
|
||||||
+systemverilogext+<ext> Synonym for +1800-2017ext+<ext>
|
+systemverilogext+<ext> Synonym for +1800-2023ext+<ext>
|
||||||
--threads <threads> Enable multithreading
|
--threads <threads> Enable multithreading
|
||||||
--threads-dpi <mode> Enable multithreaded DPI
|
--threads-dpi <mode> Enable multithreaded DPI
|
||||||
--threads-max-mtasks <mtasks> Tune maximum mtask partitioning
|
--threads-max-mtasks <mtasks> Tune maximum mtask partitioning
|
||||||
|
--timing Enable timing support
|
||||||
|
--no-timing Disable timing support
|
||||||
--timescale <timescale> Sets default timescale
|
--timescale <timescale> Sets default timescale
|
||||||
--timescale-override <timescale> Overrides all timescales
|
--timescale-override <timescale> Overrides all timescales
|
||||||
--top <topname> Alias of --top-module
|
--top <topname> Alias of --top-module
|
||||||
--top-module <topname> Name of top level input module
|
--top-module <topname> Name of top-level input module
|
||||||
--trace Enable waveform creation
|
--trace Enable waveform creation
|
||||||
--trace-coverage Enable tracing of coverage
|
--trace-coverage Enable tracing of coverage
|
||||||
--trace-depth <levels> Depth of tracing
|
--trace-depth <levels> Depth of tracing
|
||||||
@@ -404,17 +461,22 @@ detailed descriptions of these arguments.
|
|||||||
--trace-max-width <width> Maximum array depth for tracing
|
--trace-max-width <width> Maximum array depth for tracing
|
||||||
--trace-params Enable tracing of parameters
|
--trace-params Enable tracing of parameters
|
||||||
--trace-structs Enable tracing structure names
|
--trace-structs Enable tracing structure names
|
||||||
--trace-threads <threads> Enable waveform creation on separate threads
|
--trace-threads <threads> Enable FST waveform creation on separate threads
|
||||||
|
--no-trace-top Do not emit traces for signals in the top module generated by verilator
|
||||||
--trace-underscore Enable tracing of _signals
|
--trace-underscore Enable tracing of _signals
|
||||||
-U<var> Undefine preprocessor define
|
-U<var> Undefine preprocessor define
|
||||||
|
--no-unlimited-stack Don't disable stack size limit
|
||||||
--unroll-count <loops> Tune maximum loop iterations
|
--unroll-count <loops> Tune maximum loop iterations
|
||||||
--unroll-stmts <stmts> Tune maximum loop body size
|
--unroll-stmts <stmts> Tune maximum loop body size
|
||||||
--unused-regexp <regexp> Tune UNUSED lint signals
|
--unused-regexp <regexp> Tune UNUSED lint signals
|
||||||
-V Verbose version and config
|
-V Verbose version and config
|
||||||
-v <filename> Verilog library
|
-v <filename> Verilog library
|
||||||
|
--valgrind Run Verilator under valgrind
|
||||||
|
--verilate-jobs Job threads for Verilation stage
|
||||||
|
--no-verilate Skip Verilation and just compile previously Verilated code
|
||||||
+verilog1995ext+<ext> Synonym for +1364-1995ext+<ext>
|
+verilog1995ext+<ext> Synonym for +1364-1995ext+<ext>
|
||||||
+verilog2001ext+<ext> Synonym for +1364-2001ext+<ext>
|
+verilog2001ext+<ext> Synonym for +1364-2001ext+<ext>
|
||||||
--version Displays program version and exits
|
--version Show program version and exits
|
||||||
--vpi Enable VPI compiles
|
--vpi Enable VPI compiles
|
||||||
--waiver-output <filename> Create a waiver file based on the linter warnings
|
--waiver-output <filename> Create a waiver file based on the linter warnings
|
||||||
-Wall Enable all style warnings
|
-Wall Enable all style warnings
|
||||||
@@ -426,9 +488,17 @@ detailed descriptions of these arguments.
|
|||||||
-Wno-lint Disable all lint warnings
|
-Wno-lint Disable all lint warnings
|
||||||
-Wno-style Disable all style warnings
|
-Wno-style Disable all style warnings
|
||||||
-Wpedantic Warn on compliance-test issues
|
-Wpedantic Warn on compliance-test issues
|
||||||
|
-Wwarn-<message> Enable specified warning message
|
||||||
|
-Wwarn-lint Enable lint warning message
|
||||||
|
-Wwarn-style Enable style warning message
|
||||||
--x-assign <mode> Assign non-initial Xs to this value
|
--x-assign <mode> Assign non-initial Xs to this value
|
||||||
--x-initial <mode> Assign 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
|
--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-only Create XML parser output
|
||||||
--xml-output XML output filename
|
--xml-output XML output filename
|
||||||
-y <dir> Directory to search for modules
|
-y <dir> Directory to search for modules
|
||||||
@@ -440,26 +510,28 @@ description of these arguments.
|
|||||||
|
|
||||||
=for VL_SPHINX_EXTRACT "_build/gen/args_verilated.rst"
|
=for VL_SPHINX_EXTRACT "_build/gen/args_verilated.rst"
|
||||||
|
|
||||||
+verilator+debug Enable debugging
|
+verilator+debug Enable debugging
|
||||||
+verilator+debugi+<value> Enable debugging at a level
|
+verilator+debugi+<value> Enable debugging at a level
|
||||||
+verilator+error+limit+<value> Set error limit
|
+verilator+coverage+file+<filename> Set coverage output filename
|
||||||
+verilator+help Display help
|
+verilator+error+limit+<value> Set error limit
|
||||||
+verilator+noassert Disable assert checking
|
+verilator+help Show help
|
||||||
+verilator+prof+threads+file+<filename> Set profile filename
|
+verilator+noassert Disable assert checking
|
||||||
+verilator+prof+threads+start+<value> Set profile starting point
|
+verilator+prof+exec+file+<filename> Set execution profile filename
|
||||||
+verilator+prof+threads+window+<value> Set profile duration
|
+verilator+prof+exec+start+<value> Set execution profile starting point
|
||||||
+verilator+prof+vlt+file+<filename> Set profile guided filename
|
+verilator+prof+exec+window+<value> Set execution profile duration
|
||||||
+verilator+rand+reset+<value> Set random reset technique
|
+verilator+prof+vlt+file+<filename> Set PGO profile filename
|
||||||
+verilator+seed+<value> Set random seed
|
+verilator+quiet Minimize additional printing
|
||||||
+verilator+V Verbose version and config
|
+verilator+rand+reset+<value> Set random reset technique
|
||||||
+verilator+version Show version and exit
|
+verilator+seed+<value> Set random seed
|
||||||
|
+verilator+V Show verbose version and config
|
||||||
|
+verilator+version Show version and exit
|
||||||
|
|
||||||
|
|
||||||
=head1 DISTRIBUTION
|
=head1 DISTRIBUTION
|
||||||
|
|
||||||
The latest version is available from L<https://verilator.org>.
|
The latest version is available from L<https://verilator.org>.
|
||||||
|
|
||||||
Copyright 2003-2021 by Wilson Snyder. This program is free software; you can
|
Copyright 2003-2024 by Wilson Snyder. This program is free software; you can
|
||||||
redistribute it and/or modify the Verilator internals under the terms of
|
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
|
either the GNU Lesser General Public License Version 3 or the Perl Artistic
|
||||||
License Version 2.0.
|
License Version 2.0.
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# pylint: disable=C0103,C0114,C0115,C0116,C0123,C0301,R0902,R0913,R0914,R0912,R0915,W0621
|
# pylint: disable=C0103,C0114,C0115,C0116,C0123,C0209,C0301,R0902,R0913,R0914,R0912,R0915,W0621
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
@@ -12,9 +12,12 @@ from datetime import datetime
|
|||||||
parser = argparse.ArgumentParser(
|
parser = argparse.ArgumentParser(
|
||||||
allow_abbrev=False,
|
allow_abbrev=False,
|
||||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||||
description="""Report ccache behavior of a Verilated model build.""",
|
description="""Report ccache behavior of a Verilated model build.
|
||||||
|
|
||||||
|
For documentation see
|
||||||
|
https://verilator.org/guide/latest/exe_verilator_ccache_report.html""",
|
||||||
epilog=
|
epilog=
|
||||||
"""Copyright 2002-2021 by Wilson Snyder. This program is free software; you
|
"""Copyright 2002-2024 by Wilson Snyder. This program is free software; you
|
||||||
can redistribute it and/or modify it under the terms of either the GNU
|
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
|
Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
Version 2.0.
|
Version 2.0.
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env perl
|
#!/usr/bin/env perl
|
||||||
######################################################################
|
######################################################################
|
||||||
#
|
#
|
||||||
# Copyright 2003-2021 by Wilson Snyder. This program is free software; you
|
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||||
# can redistribute it and/or modify it under the terms of either the GNU
|
# 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
|
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
# Version 2.0.
|
# Version 2.0.
|
||||||
@@ -169,6 +169,7 @@ L<https://verilator.org/guide/latest/exe_verilator_coverage.html>.
|
|||||||
--annotate <output_dir> Directory name for source annotation.
|
--annotate <output_dir> Directory name for source annotation.
|
||||||
--annotate-all All files should be shown.
|
--annotate-all All files should be shown.
|
||||||
--annotate-min <count> Minimum occurrence count for uncovered.
|
--annotate-min <count> Minimum occurrence count for uncovered.
|
||||||
|
--annotate-points Annotates info from each coverage point.
|
||||||
--help Displays this message and version and exits.
|
--help Displays this message and version and exits.
|
||||||
--rank Compute relative importance of tests.
|
--rank Compute relative importance of tests.
|
||||||
--unlink With --write, unlink all inputs
|
--unlink With --write, unlink all inputs
|
||||||
@@ -176,18 +177,18 @@ L<https://verilator.org/guide/latest/exe_verilator_coverage.html>.
|
|||||||
--write <filename> Write aggregate coverage results.
|
--write <filename> Write aggregate coverage results.
|
||||||
--write-info <filename.info> Write lcov .info.
|
--write-info <filename.info> Write lcov .info.
|
||||||
|
|
||||||
+libext+I<ext>+I<ext>... Extensions for Verilog files.
|
+libext+<ext>+<ext>... Extensions for Verilog files.
|
||||||
+define+I<var>+I<value> Defines the given variable.
|
+define+<var>+<value> Defines the given variable.
|
||||||
-DI<var>=I<value> Defines the given variable.
|
-D<var>=<value> Defines the given variable.
|
||||||
+incdir+I<dir> Add directory for finding include files.
|
+incdir+<dir> Add directory for finding include files.
|
||||||
-II<dir> Add directory for finding include files.
|
-I<dir> Add directory for finding include files.
|
||||||
-y I<dir> Specifies module search directory.
|
-y <dir> Specifies module search directory.
|
||||||
|
|
||||||
=head1 DISTRIBUTION
|
=head1 DISTRIBUTION
|
||||||
|
|
||||||
The latest version is available from L<https://verilator.org>.
|
The latest version is available from L<https://verilator.org>.
|
||||||
|
|
||||||
Copyright 2003-2021 by Wilson Snyder. This program is free software; you
|
Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||||
can redistribute it and/or modify the Verilator internals under the terms
|
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
|
of either the GNU Lesser General Public License Version 3 or the Perl
|
||||||
Artistic License Version 2.0.
|
Artistic License Version 2.0.
|
||||||
|
|||||||
+14
-17
@@ -1,5 +1,5 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# pylint: disable=C0103,C0114,C0116
|
# pylint: disable=C0103,C0114,C0116,C0209
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
@@ -38,12 +38,12 @@ def diff_dir(a, b):
|
|||||||
|
|
||||||
anyfile = False
|
anyfile = False
|
||||||
for base in sorted(files.keys()):
|
for base in sorted(files.keys()):
|
||||||
|
if ('a' not in files[base]) or ('b' not in files[base]):
|
||||||
|
continue
|
||||||
a = files[base]['a']
|
a = files[base]['a']
|
||||||
b = files[base]['b']
|
b = files[base]['b']
|
||||||
if not a or not b:
|
print("=" * 70, flush=True)
|
||||||
continue
|
print("= %s <-> %s" % (a, b), flush=True)
|
||||||
print("=" * 70)
|
|
||||||
print("= %s <-> %s" % (a, b))
|
|
||||||
diff_file(a, b)
|
diff_file(a, b)
|
||||||
anyfile = True
|
anyfile = True
|
||||||
if not anyfile:
|
if not anyfile:
|
||||||
@@ -73,7 +73,7 @@ def diff_file(a, b):
|
|||||||
|
|
||||||
def version_from(filename):
|
def version_from(filename):
|
||||||
# Return dump format
|
# Return dump format
|
||||||
with open(filename) as fh:
|
with open(filename, "r", encoding="utf8") as fh:
|
||||||
lineno = 0
|
lineno = 0
|
||||||
for line in fh:
|
for line in fh:
|
||||||
if lineno > 10:
|
if lineno > 10:
|
||||||
@@ -86,8 +86,8 @@ def version_from(filename):
|
|||||||
|
|
||||||
def filterf(fn1, fn2):
|
def filterf(fn1, fn2):
|
||||||
# Remove hex numbers before diffing
|
# Remove hex numbers before diffing
|
||||||
with open(fn1) as fh1:
|
with open(fn1, "r", encoding="utf8") as fh1:
|
||||||
with open(fn2, "w") as fh2:
|
with open(fn2, "w", encoding="utf8") as fh2:
|
||||||
for line in fh1:
|
for line in fh1:
|
||||||
if re.search(r' This=', line):
|
if re.search(r' This=', line):
|
||||||
continue
|
continue
|
||||||
@@ -104,16 +104,13 @@ def filterf(fn1, fn2):
|
|||||||
parser = argparse.ArgumentParser(
|
parser = argparse.ArgumentParser(
|
||||||
allow_abbrev=False,
|
allow_abbrev=False,
|
||||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||||
description="""Compare two Verilator debugging trees""",
|
description="""Compare two Verilator debugging trees.
|
||||||
epilog=
|
|
||||||
"""Verilator_difftree is used for debugging Verilator tree output files.
|
Verilator_difftree is used for debugging Verilator tree output files.
|
||||||
It performs a diff between two files, or all files common between two
|
It performs a diff between two files, or all files common between two
|
||||||
directories, ignoring irrelevant pointer differences.
|
directories, ignoring irrelevant pointer differences.""",
|
||||||
|
epilog=
|
||||||
For documentation see
|
"""Copyright 2005-2024 by Wilson Snyder. This program is free software; you
|
||||||
https://verilator.org/guide/latest/exe_verilator_difftree.html
|
|
||||||
|
|
||||||
Copyright 2005-2021 by Wilson Snyder. This program is free software; you
|
|
||||||
can redistribute it and/or modify it under the terms of either the GNU
|
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
|
Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
Version 2.0.
|
Version 2.0.
|
||||||
|
|||||||
+346
-262
@@ -1,89 +1,113 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# pylint: disable=C0103,C0114,C0116,C0301,R0914,R0912,R0915,W0511,eval-used
|
# pylint: disable=C0103,C0114,C0116,C0209,C0301,R0914,R0912,R0915,W0511,W0603,eval-used
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
|
import bisect
|
||||||
import collections
|
import collections
|
||||||
import math
|
import math
|
||||||
import re
|
import re
|
||||||
import statistics
|
import statistics
|
||||||
# from pprint import pprint
|
# from pprint import pprint
|
||||||
|
|
||||||
Threads = collections.defaultdict(lambda: {})
|
Sections = []
|
||||||
Mtasks = collections.defaultdict(lambda: {})
|
LongestVcdStrValueLength = 0
|
||||||
Evals = collections.defaultdict(lambda: {})
|
Threads = collections.defaultdict(lambda: []) # List of records per thread id
|
||||||
EvalLoops = collections.defaultdict(lambda: {})
|
Mtasks = collections.defaultdict(lambda: {'elapsed': 0, 'end': 0})
|
||||||
|
Cpus = collections.defaultdict(lambda: {'mtask_time': 0})
|
||||||
Global = {
|
Global = {
|
||||||
'args': {},
|
'args': {},
|
||||||
'cpuinfo': collections.defaultdict(lambda: {}),
|
'cpuinfo': collections.defaultdict(lambda: {}),
|
||||||
'rdtsc_cycle_time': 0,
|
|
||||||
'stats': {}
|
'stats': {}
|
||||||
}
|
}
|
||||||
|
ElapsedTime = None # total elapsed time
|
||||||
|
ExecGraphTime = 0 # total elapsed time excuting an exec graph
|
||||||
|
ExecGraphIntervals = [] # list of (start, end) pairs
|
||||||
|
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
|
|
||||||
def process(filename):
|
|
||||||
read_data(filename)
|
|
||||||
report()
|
|
||||||
|
|
||||||
|
|
||||||
def read_data(filename):
|
def read_data(filename):
|
||||||
with open(filename) as fh:
|
with open(filename, "r", encoding="utf8") as fh:
|
||||||
re_prof = re.compile(
|
re_thread = re.compile(r'^VLPROFTHREAD (\d+)$')
|
||||||
r'^VLPROF mtask\s(\d+)\sstart\s(\d+)\selapsed\s(\d+)\spredict_start\s(\d+)\spredict_cost\s(\d+)\scpu\s(\d+)\son thread (\d+)'
|
re_record = re.compile(r'^VLPROFEXEC (\S+) (\d+)(.*)$')
|
||||||
)
|
re_payload_mtaskBegin = re.compile(
|
||||||
re_eval = re.compile(r'^VLPROF eval\sstart\s(\d+)\selapsed\s(\d+)')
|
r'id (\d+) predictStart (\d+) cpu (\d+)')
|
||||||
re_loop = re.compile(
|
re_payload_mtaskEnd = re.compile(r'id (\d+) predictCost (\d+)')
|
||||||
r'^VLPROF eval_loop\sstart\s(\d+)\selapsed\s(\d+)')
|
|
||||||
re_arg1 = re.compile(r'VLPROF arg\s+(\S+)\+([0-9.]*)\s*')
|
re_arg1 = re.compile(r'VLPROF arg\s+(\S+)\+([0-9.]*)\s*')
|
||||||
re_arg2 = re.compile(r'VLPROF arg\s+(\S+)\s+([0-9.]*)\s*$')
|
re_arg2 = re.compile(r'VLPROF arg\s+(\S+)\s+([0-9.]*)\s*$')
|
||||||
re_stat = re.compile(r'VLPROF stat\s+(\S+)\s+([0-9.]+)')
|
re_stat = re.compile(r'VLPROF stat\s+(\S+)\s+([0-9.]+)')
|
||||||
re_time = re.compile(r'rdtsc time = (\d+) ticks')
|
|
||||||
re_proc_cpu = re.compile(r'VLPROFPROC processor\s*:\s*(\d+)\s*$')
|
re_proc_cpu = re.compile(r'VLPROFPROC processor\s*:\s*(\d+)\s*$')
|
||||||
re_proc_dat = re.compile(r'VLPROFPROC ([a-z_ ]+)\s*:\s*(.*)$')
|
re_proc_dat = re.compile(r'VLPROFPROC ([a-z_ ]+)\s*:\s*(.*)$')
|
||||||
cpu = None
|
cpu = None
|
||||||
|
thread = None
|
||||||
|
execGraphStart = None
|
||||||
|
|
||||||
|
global LongestVcdStrValueLength
|
||||||
|
global ExecGraphTime
|
||||||
|
|
||||||
|
SectionStack = []
|
||||||
|
mTaskThread = {}
|
||||||
|
|
||||||
for line in fh:
|
for line in fh:
|
||||||
if re_prof.match(line):
|
recordMatch = re_record.match(line)
|
||||||
match = re_prof.match(line)
|
if recordMatch:
|
||||||
mtask = int(match.group(1))
|
kind, tick, payload = recordMatch.groups()
|
||||||
start = int(match.group(2))
|
tick = int(tick)
|
||||||
elapsed_time = int(match.group(3))
|
payload = payload.strip()
|
||||||
end = start + elapsed_time
|
if kind == "SECTION_PUSH":
|
||||||
predict_start = int(match.group(4))
|
LongestVcdStrValueLength = max(LongestVcdStrValueLength,
|
||||||
predict_cost = int(match.group(5))
|
len(payload))
|
||||||
cpu = int(match.group(6))
|
SectionStack.append(payload)
|
||||||
thread = int(match.group(7))
|
Sections.append((tick, tuple(SectionStack)))
|
||||||
if start not in Threads[thread]:
|
elif kind == "SECTION_POP":
|
||||||
Threads[thread][start] = {}
|
assert SectionStack, "SECTION_POP without SECTION_PUSH"
|
||||||
Threads[thread][start]['mtask'] = mtask
|
SectionStack.pop()
|
||||||
Threads[thread][start]['end'] = end
|
Sections.append((tick, tuple(SectionStack)))
|
||||||
Threads[thread][start]['cpu'] = cpu
|
elif kind == "MTASK_BEGIN":
|
||||||
Threads[thread][start]['predict_start'] = predict_start
|
mtask, predict_start, ecpu = re_payload_mtaskBegin.match(
|
||||||
Threads[thread][start]['predict_cost'] = predict_cost
|
payload).groups()
|
||||||
|
mtask = int(mtask)
|
||||||
if 'elapsed' not in Mtasks[mtask]:
|
predict_start = int(predict_start)
|
||||||
Mtasks[mtask] = {'end': 0, 'elapsed': 0}
|
ecpu = int(ecpu)
|
||||||
Mtasks[mtask]['thread'] = thread
|
mTaskThread[mtask] = thread
|
||||||
Mtasks[mtask]['elapsed'] += elapsed_time
|
records = Threads[thread]
|
||||||
Mtasks[mtask]['predict_start'] = predict_start
|
assert not records or records[-1]['start'] <= records[-1][
|
||||||
Mtasks[mtask]['predict_cost'] = predict_cost
|
'end'] <= tick
|
||||||
Mtasks[mtask]['end'] = max(Mtasks[mtask]['end'], end)
|
records.append({
|
||||||
elif re_eval.match(line):
|
'start': tick,
|
||||||
match = re_eval.match(line)
|
'mtask': mtask,
|
||||||
start = int(match.group(1))
|
'predict_start': predict_start,
|
||||||
elapsed_time = int(match.group(2))
|
'cpu': ecpu
|
||||||
Evals[start]['start'] = start
|
})
|
||||||
Evals[start]['end'] = start + elapsed_time
|
Mtasks[mtask]['begin'] = tick
|
||||||
elif re_loop.match(line):
|
Mtasks[mtask]['thread'] = thread
|
||||||
match = re_loop.match(line)
|
Mtasks[mtask]['predict_start'] = predict_start
|
||||||
start = int(match.group(1))
|
elif kind == "MTASK_END":
|
||||||
elapsed_time = int(match.group(2))
|
mtask, predict_cost = re_payload_mtaskEnd.match(
|
||||||
EvalLoops[start]['start'] = start
|
payload).groups()
|
||||||
EvalLoops[start]['end'] = start + elapsed_time
|
mtask = int(mtask)
|
||||||
elif re.match(r'^VLPROFTHREAD', line):
|
predict_cost = int(predict_cost)
|
||||||
None # pylint: disable=pointless-statement
|
begin = Mtasks[mtask]['begin']
|
||||||
|
record = Threads[mTaskThread[mtask]][-1]
|
||||||
|
record['end'] = tick
|
||||||
|
record['predict_cost'] = predict_cost
|
||||||
|
Mtasks[mtask]['elapsed'] += tick - begin
|
||||||
|
Mtasks[mtask]['predict_cost'] = predict_cost
|
||||||
|
Mtasks[mtask]['end'] = max(Mtasks[mtask]['end'], tick)
|
||||||
|
elif kind == "EXEC_GRAPH_BEGIN":
|
||||||
|
execGraphStart = tick
|
||||||
|
elif kind == "EXEC_GRAPH_END":
|
||||||
|
ExecGraphTime += tick - execGraphStart
|
||||||
|
ExecGraphIntervals.append((execGraphStart, tick))
|
||||||
|
execGraphStart = None
|
||||||
|
elif Args.debug:
|
||||||
|
print("-Unknown execution trace record: %s" % line)
|
||||||
|
elif re_thread.match(line):
|
||||||
|
thread = int(re_thread.match(line).group(1))
|
||||||
|
elif re.match(r'^VLPROF(THREAD|VERSION)', line):
|
||||||
|
pass
|
||||||
elif re_arg1.match(line):
|
elif re_arg1.match(line):
|
||||||
match = re_arg1.match(line)
|
match = re_arg1.match(line)
|
||||||
Global['args'][match.group(1)] = match.group(2)
|
Global['args'][match.group(1)] = match.group(2)
|
||||||
@@ -96,7 +120,7 @@ def read_data(filename):
|
|||||||
elif re_proc_cpu.match(line):
|
elif re_proc_cpu.match(line):
|
||||||
match = re_proc_cpu.match(line)
|
match = re_proc_cpu.match(line)
|
||||||
cpu = int(match.group(1))
|
cpu = int(match.group(1))
|
||||||
elif cpu and re_proc_dat.match(line):
|
elif cpu is not None and re_proc_dat.match(line):
|
||||||
match = re_proc_dat.match(line)
|
match = re_proc_dat.match(line)
|
||||||
term = match.group(1)
|
term = match.group(1)
|
||||||
value = match.group(2)
|
value = match.group(2)
|
||||||
@@ -105,14 +129,9 @@ def read_data(filename):
|
|||||||
value = re.sub(r'\s+$', '', value)
|
value = re.sub(r'\s+$', '', value)
|
||||||
Global['cpuinfo'][cpu][term] = value
|
Global['cpuinfo'][cpu][term] = value
|
||||||
elif re.match(r'^#', line):
|
elif re.match(r'^#', line):
|
||||||
None # pylint: disable=pointless-statement
|
pass
|
||||||
elif Args.debug:
|
elif Args.debug:
|
||||||
print("-Unk: %s" % line)
|
print("-Unk: %s" % line)
|
||||||
# TODO -- this is parsing text printed by a client.
|
|
||||||
# Really, verilator proper should generate this
|
|
||||||
# if it's useful...
|
|
||||||
if re_time.match(line):
|
|
||||||
Global['rdtsc_cycle_time'] = re_time.group(1)
|
|
||||||
|
|
||||||
|
|
||||||
def re_match_result(regexp, line, result_to):
|
def re_match_result(regexp, line, result_to):
|
||||||
@@ -131,32 +150,54 @@ def report():
|
|||||||
plus = "+" if re.match(r'^\+', arg) else " "
|
plus = "+" if re.match(r'^\+', arg) else " "
|
||||||
print(" %s%s%s" % (arg, plus, Global['args'][arg]))
|
print(" %s%s%s" % (arg, plus, Global['args'][arg]))
|
||||||
|
|
||||||
nthreads = len(Threads)
|
for records in Threads.values():
|
||||||
Global['cpus'] = {}
|
for record in records:
|
||||||
for thread in Threads:
|
cpu = record['cpu']
|
||||||
# Make potentially multiple characters per column
|
elapsed = record['end'] - record['start']
|
||||||
for start in Threads[thread]:
|
Cpus[cpu]['mtask_time'] += elapsed
|
||||||
cpu = Threads[thread][start]['cpu']
|
|
||||||
elapsed = Threads[thread][start]['end'] - start
|
|
||||||
if cpu not in Global['cpus']:
|
|
||||||
Global['cpus'][cpu] = {'cpu_time': 0}
|
|
||||||
Global['cpus'][cpu]['cpu_time'] += elapsed
|
|
||||||
|
|
||||||
measured_mt_mtask_time = 0
|
global ElapsedTime
|
||||||
predict_mt_mtask_time = 0
|
ElapsedTime = int(Global['stats']['ticks'])
|
||||||
long_mtask_time = 0
|
nthreads = int(Global['stats']['threads'])
|
||||||
measured_last_end = 0
|
ncpus = max(len(Cpus), 1)
|
||||||
predict_last_end = 0
|
|
||||||
for mtask in Mtasks:
|
print("\nSummary:")
|
||||||
measured_mt_mtask_time += Mtasks[mtask]['elapsed']
|
print(" Total elapsed time = {} rdtsc ticks".format(ElapsedTime))
|
||||||
predict_mt_mtask_time += Mtasks[mtask]['predict_cost']
|
print(" Parallelized code = {:.2%} of elapsed time".format(
|
||||||
measured_last_end = max(measured_last_end, Mtasks[mtask]['end'])
|
ExecGraphTime / ElapsedTime))
|
||||||
predict_last_end = max(
|
print(" Total threads = %d" % nthreads)
|
||||||
predict_last_end,
|
print(" Total CPUs used = %d" % ncpus)
|
||||||
Mtasks[mtask]['predict_start'] + Mtasks[mtask]['predict_cost'])
|
print(" Total mtasks = %d" % len(Mtasks))
|
||||||
long_mtask_time = max(long_mtask_time, Mtasks[mtask]['elapsed'])
|
print(" Total yields = %d" % int(Global['stats'].get('yields', 0)))
|
||||||
Global['measured_last_end'] = measured_last_end
|
|
||||||
Global['predict_last_end'] = predict_last_end
|
report_mtasks()
|
||||||
|
report_cpus()
|
||||||
|
report_sections()
|
||||||
|
|
||||||
|
if nthreads > ncpus:
|
||||||
|
print()
|
||||||
|
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(" : See docs on use of numactl.")
|
||||||
|
if 'cpu_sockets_warning' in Global:
|
||||||
|
print()
|
||||||
|
print("%Warning: Threads scheduled on multiple sockets.")
|
||||||
|
print(" : See docs on use of numactl.")
|
||||||
|
print()
|
||||||
|
|
||||||
|
|
||||||
|
def report_mtasks():
|
||||||
|
if not Mtasks:
|
||||||
|
return
|
||||||
|
|
||||||
|
nthreads = int(Global['stats']['threads'])
|
||||||
|
|
||||||
# If we know cycle time in the same (rdtsc) units,
|
# If we know cycle time in the same (rdtsc) units,
|
||||||
# this will give us an actual utilization number,
|
# this will give us an actual utilization number,
|
||||||
@@ -166,38 +207,44 @@ def report():
|
|||||||
# serial mode, to estimate the overhead of data sharing,
|
# serial mode, to estimate the overhead of data sharing,
|
||||||
# which will show up in the total elapsed time. (Overhead
|
# which will show up in the total elapsed time. (Overhead
|
||||||
# of synchronization and scheduling should not.)
|
# of synchronization and scheduling should not.)
|
||||||
print("\nAnalysis:")
|
total_mtask_time = 0
|
||||||
print(" Total threads = %d" % nthreads)
|
thread_mtask_time = collections.defaultdict(lambda: 0)
|
||||||
print(" Total mtasks = %d" % len(Mtasks))
|
long_mtask_time = 0
|
||||||
ncpus = len(Global['cpus'])
|
long_mtask = None
|
||||||
print(" Total cpus used = %d" % ncpus)
|
predict_mtask_time = 0
|
||||||
print(" Total yields = %d" % int(Global['stats']['yields']))
|
predict_elapsed = 0
|
||||||
print(" Total evals = %d" % len(Evals))
|
for mtaskId in Mtasks:
|
||||||
print(" Total eval loops = %d" % len(EvalLoops))
|
record = Mtasks[mtaskId]
|
||||||
print(" Total eval time = %d rdtsc ticks" %
|
predict_mtask_time += record['predict_cost']
|
||||||
Global['measured_last_end'])
|
total_mtask_time += record['elapsed']
|
||||||
print(" Longest mtask time = %d rdtsc ticks" % long_mtask_time)
|
thread_mtask_time[record['thread']] += record['elapsed']
|
||||||
print(" All-thread mtask time = %d rdtsc ticks" %
|
predict_end = record['predict_start'] + record['predict_cost']
|
||||||
measured_mt_mtask_time)
|
predict_elapsed = max(predict_elapsed, predict_end)
|
||||||
long_efficiency = long_mtask_time / (Global.get('measured_last_end', 1)
|
if record['elapsed'] > long_mtask_time:
|
||||||
or 1)
|
long_mtask_time = record['elapsed']
|
||||||
print(" Longest-thread efficiency = %0.1f%%" % (long_efficiency * 100.0))
|
long_mtask = mtaskId
|
||||||
mt_efficiency = measured_mt_mtask_time / (
|
Global['predict_last_end'] = predict_elapsed
|
||||||
Global.get('measured_last_end', 1) * nthreads or 1)
|
|
||||||
print(" All-thread efficiency = %0.1f%%" % (mt_efficiency * 100.0))
|
|
||||||
print(" All-thread speedup = %0.1f" % (mt_efficiency * nthreads))
|
|
||||||
if Global['rdtsc_cycle_time'] > 0:
|
|
||||||
ut = measured_mt_mtask_time / Global['rdtsc_cycle_time']
|
|
||||||
print("tot_mtask_cpu=" + measured_mt_mtask_time + " cyc=" +
|
|
||||||
Global['rdtsc_cycle_time'] + " ut=" + ut)
|
|
||||||
|
|
||||||
predict_mt_efficiency = predict_mt_mtask_time / (
|
serialTime = ElapsedTime - ExecGraphTime
|
||||||
Global.get('predict_last_end', 1) * nthreads or 1)
|
|
||||||
print("\nPrediction (what Verilator used for scheduling):")
|
def subReport(elapsed, work):
|
||||||
print(" All-thread efficiency = %0.1f%%" %
|
print(" Thread utilization = {:7.2%}".format(work /
|
||||||
(predict_mt_efficiency * 100.0))
|
(elapsed * nthreads)))
|
||||||
print(" All-thread speedup = %0.1f" %
|
print(" Speedup = {:6.3}x".format(work / elapsed))
|
||||||
(predict_mt_efficiency * nthreads))
|
|
||||||
|
print("\nParallelized code, measured:")
|
||||||
|
subReport(ExecGraphTime, total_mtask_time)
|
||||||
|
|
||||||
|
print("\nParallelized code, predicted during static scheduling:")
|
||||||
|
subReport(predict_elapsed, predict_mtask_time)
|
||||||
|
|
||||||
|
print("\nAll code, measured:")
|
||||||
|
subReport(ElapsedTime, serialTime + total_mtask_time)
|
||||||
|
|
||||||
|
print("\nAll code, measured, scaled by predicted speedup:")
|
||||||
|
expectedParallelSpeedup = predict_mtask_time / predict_elapsed
|
||||||
|
scaledElapsed = serialTime + total_mtask_time / expectedParallelSpeedup
|
||||||
|
subReport(scaledElapsed, serialTime + total_mtask_time)
|
||||||
|
|
||||||
p2e_ratios = []
|
p2e_ratios = []
|
||||||
min_p2e = 1000000
|
min_p2e = 1000000
|
||||||
@@ -220,8 +267,12 @@ def report():
|
|||||||
min_p2e = p2e_ratio
|
min_p2e = p2e_ratio
|
||||||
min_mtask = mtask
|
min_mtask = mtask
|
||||||
|
|
||||||
print("\nStatistics:")
|
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(" min log(p2e) = %0.3f" % min_p2e, end="")
|
print(" min log(p2e) = %0.3f" % min_p2e, end="")
|
||||||
|
|
||||||
print(" from mtask %d (predict %d," %
|
print(" from mtask %d (predict %d," %
|
||||||
(min_mtask, Mtasks[min_mtask]['predict_cost']),
|
(min_mtask, Mtasks[min_mtask]['predict_cost']),
|
||||||
end="")
|
end="")
|
||||||
@@ -238,53 +289,34 @@ def report():
|
|||||||
print(" stddev = %0.3f" % stddev)
|
print(" stddev = %0.3f" % stddev)
|
||||||
print(" e ^ stddev = %0.3f" % math.exp(stddev))
|
print(" e ^ stddev = %0.3f" % math.exp(stddev))
|
||||||
|
|
||||||
report_cpus()
|
|
||||||
|
|
||||||
if nthreads > ncpus:
|
|
||||||
print()
|
|
||||||
print("%%Warning: There were fewer CPUs (%d) then 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(" : See docs on use of numactl.")
|
|
||||||
if 'cpu_sockets_warning' in Global:
|
|
||||||
print()
|
|
||||||
print("%Warning: Threads scheduled on multiple sockets.")
|
|
||||||
print(" : See docs on use of numactl.")
|
|
||||||
print()
|
|
||||||
|
|
||||||
|
|
||||||
def report_cpus():
|
def report_cpus():
|
||||||
print("\nCPUs:")
|
print("\nCPU info:")
|
||||||
|
|
||||||
Global['cpu_sockets'] = collections.defaultdict(lambda: 0)
|
Global['cpu_sockets'] = collections.defaultdict(lambda: 0)
|
||||||
Global['cpu_socket_cores'] = collections.defaultdict(lambda: 0)
|
Global['cpu_socket_cores'] = collections.defaultdict(lambda: 0)
|
||||||
|
|
||||||
for cpu in sorted(Global['cpus'].keys()):
|
print(" Id | Time spent executing MTask | Socket | Core | Model")
|
||||||
print(" cpu %d: " % cpu, end='')
|
print(" | % of elapsed ticks / ticks | | |")
|
||||||
print("cpu_time=%d" % Global['cpus'][cpu]['cpu_time'], end='')
|
print(" ====|============================|========|======|======")
|
||||||
|
for cpu in sorted(Cpus):
|
||||||
socket = None
|
socket = ""
|
||||||
|
core = ""
|
||||||
|
model = ""
|
||||||
if cpu in Global['cpuinfo']:
|
if cpu in Global['cpuinfo']:
|
||||||
cpuinfo = Global['cpuinfo'][cpu]
|
cpuinfo = Global['cpuinfo'][cpu]
|
||||||
if 'physical_id' in cpuinfo and 'core_id' in cpuinfo:
|
if 'physical_id' in cpuinfo and 'core_id' in cpuinfo:
|
||||||
socket = int(cpuinfo['physical_id'])
|
socket = cpuinfo['physical_id']
|
||||||
Global['cpu_sockets'][socket] += 1
|
Global['cpu_sockets'][socket] += 1
|
||||||
print(" socket=%d" % socket, end='')
|
core = cpuinfo['core_id']
|
||||||
|
Global['cpu_socket_cores'][socket + "__" + core] += 1
|
||||||
core = int(cpuinfo['core_id'])
|
|
||||||
Global['cpu_socket_cores'][str(socket) + "__" + str(core)] += 1
|
|
||||||
print(" core=%d" % core, end='')
|
|
||||||
|
|
||||||
if 'model_name' in cpuinfo:
|
if 'model_name' in cpuinfo:
|
||||||
model = cpuinfo['model_name']
|
model = cpuinfo['model_name']
|
||||||
print(" %s" % model, end='')
|
|
||||||
print()
|
print(" {:3d} | {:7.2%} / {:16d} | {:>6s} | {:>4s} | {}".format(
|
||||||
|
cpu, Cpus[cpu]['mtask_time'] / ElapsedTime,
|
||||||
|
Cpus[cpu]['mtask_time'], socket, core, model))
|
||||||
|
|
||||||
if len(Global['cpu_sockets']) > 1:
|
if len(Global['cpu_sockets']) > 1:
|
||||||
Global['cpu_sockets_warning'] = True
|
Global['cpu_sockets_warning'] = True
|
||||||
@@ -293,25 +325,68 @@ def report_cpus():
|
|||||||
Global['cpu_socket_cores_warning'] = True
|
Global['cpu_socket_cores_warning'] = True
|
||||||
|
|
||||||
|
|
||||||
|
def report_sections():
|
||||||
|
if not Sections:
|
||||||
|
return
|
||||||
|
print("\nSection profile:")
|
||||||
|
|
||||||
|
totalTime = collections.defaultdict(lambda: 0)
|
||||||
|
selfTime = collections.defaultdict(lambda: 0)
|
||||||
|
|
||||||
|
sectionTree = [0, {}, 1] # [selfTime, childTrees, numberOfTimesEntered]
|
||||||
|
prevTime = 0
|
||||||
|
prevStack = ()
|
||||||
|
for time, stack in Sections:
|
||||||
|
if len(stack) > len(prevStack):
|
||||||
|
scope = sectionTree
|
||||||
|
for item in stack:
|
||||||
|
scope = scope[1].setdefault(item, [0, {}, 0])
|
||||||
|
scope[2] += 1
|
||||||
|
dt = time - prevTime
|
||||||
|
scope = sectionTree
|
||||||
|
for item in prevStack:
|
||||||
|
scope = scope[1].setdefault(item, [0, {}, 0])
|
||||||
|
scope[0] += dt
|
||||||
|
|
||||||
|
if prevStack:
|
||||||
|
for name in prevStack:
|
||||||
|
totalTime[name] += dt
|
||||||
|
selfTime[prevStack[-1]] += dt
|
||||||
|
prevTime = time
|
||||||
|
prevStack = stack
|
||||||
|
|
||||||
|
def treeSum(tree):
|
||||||
|
n = tree[0]
|
||||||
|
for subTree in tree[1].values():
|
||||||
|
n += treeSum(subTree)
|
||||||
|
return n
|
||||||
|
|
||||||
|
# Make sure the tree sums to the elapsed time
|
||||||
|
sectionTree[0] += ElapsedTime - treeSum(sectionTree)
|
||||||
|
|
||||||
|
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))
|
||||||
|
for k in sorted(tree[1], key=lambda _: -treeSum(tree[1][_])):
|
||||||
|
printTree(prefix + " ", k, tree[2], tree[1][k])
|
||||||
|
|
||||||
|
print(" Total | Self | Total | Relative | Section")
|
||||||
|
print(" time | time | entries | entries | name ")
|
||||||
|
print("==========|=========|==========|============|========")
|
||||||
|
printTree("", "*TOTAL*", 1, sectionTree)
|
||||||
|
|
||||||
|
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
|
|
||||||
def write_vcd(filename):
|
def write_vcd(filename):
|
||||||
print("Writing %s" % filename)
|
print("Writing %s" % filename)
|
||||||
with open(filename, "w") as fh:
|
with open(filename, "w", encoding="utf8") as fh:
|
||||||
vcd = {
|
# dict of dicts of hierarchy elements/signal name -> (code, width)
|
||||||
'values':
|
scopeSigs = {}
|
||||||
collections.defaultdict(lambda: {}), # {<time>}{<code>} = value
|
# map from time -> code -> value
|
||||||
'sigs': {
|
values = collections.defaultdict(lambda: {})
|
||||||
'predicted_threads': {},
|
|
||||||
'measured_threads': {},
|
|
||||||
'cpus': {},
|
|
||||||
'evals': {},
|
|
||||||
'mtasks': {},
|
|
||||||
'Stats': {}
|
|
||||||
} # {<module>}{<sig}} = code
|
|
||||||
}
|
|
||||||
code = 0
|
|
||||||
|
|
||||||
parallelism = {
|
parallelism = {
|
||||||
'measured': collections.defaultdict(lambda: 0),
|
'measured': collections.defaultdict(lambda: 0),
|
||||||
@@ -320,131 +395,139 @@ def write_vcd(filename):
|
|||||||
parallelism['measured'][0] = 0
|
parallelism['measured'][0] = 0
|
||||||
parallelism['predicted'][0] = 0
|
parallelism['predicted'][0] = 0
|
||||||
|
|
||||||
# Measured graph
|
nextFreeCode = 0
|
||||||
for thread in sorted(Threads.keys()):
|
|
||||||
sig = "thread%d_mtask" % thread
|
|
||||||
if sig not in vcd['sigs']['measured_threads']:
|
|
||||||
vcd['sigs']['measured_threads'][sig] = code
|
|
||||||
code += 1
|
|
||||||
mcode = vcd['sigs']['measured_threads'][sig]
|
|
||||||
|
|
||||||
for start in sorted(Threads[thread]):
|
def getCode(width, *names):
|
||||||
mtask = Threads[thread][start]['mtask']
|
nonlocal nextFreeCode
|
||||||
end = Threads[thread][start]['end']
|
scope = scopeSigs
|
||||||
cpu = Threads[thread][start]['cpu']
|
*path, name = names
|
||||||
vcd['values'][start][mcode] = mtask
|
for item in path:
|
||||||
vcd['values'][end][mcode] = None
|
scope = scope.setdefault(item, {})
|
||||||
|
code, oldWidth = scope.setdefault(name, (nextFreeCode, width))
|
||||||
|
assert oldWidth == width
|
||||||
|
if code == nextFreeCode:
|
||||||
|
nextFreeCode += 1
|
||||||
|
return code
|
||||||
|
|
||||||
|
def addValue(code, time, val):
|
||||||
|
if isinstance(val, str):
|
||||||
|
buf = ""
|
||||||
|
for c in val:
|
||||||
|
buf += bin(ord(c))[2:].rjust(8, "0")
|
||||||
|
val = buf.ljust(LongestVcdStrValueLength * 8, "0")
|
||||||
|
values[time][code] = val
|
||||||
|
|
||||||
|
# Measured graph
|
||||||
|
for thread in sorted(Threads):
|
||||||
|
mcode = getCode(32, 'measured', 't%d_mtask' % thread)
|
||||||
|
for record in Threads[thread]:
|
||||||
|
start = record['start']
|
||||||
|
mtask = record['mtask']
|
||||||
|
end = record['end']
|
||||||
|
cpu = record['cpu']
|
||||||
|
addValue(mcode, start, mtask)
|
||||||
|
addValue(mcode, end, None)
|
||||||
parallelism['measured'][start] += 1
|
parallelism['measured'][start] += 1
|
||||||
parallelism['measured'][end] -= 1
|
parallelism['measured'][end] -= 1
|
||||||
|
|
||||||
sig = "cpu%d_thread" % cpu
|
code = getCode(32, 'measured', 'cpu%d_thread' % cpu)
|
||||||
if sig not in vcd['sigs']['cpus']:
|
addValue(code, start, thread)
|
||||||
vcd['sigs']['cpus'][sig] = code
|
addValue(code, end, None)
|
||||||
code += 1
|
|
||||||
ccode = vcd['sigs']['cpus'][sig]
|
|
||||||
vcd['values'][start][ccode] = thread
|
|
||||||
vcd['values'][end][ccode] = None
|
|
||||||
|
|
||||||
sig = "mtask%d_cpu" % mtask
|
code = getCode(32, 'measured', 'cpu%d_mtask' % cpu)
|
||||||
if sig not in vcd['sigs']['mtasks']:
|
addValue(code, start, mtask)
|
||||||
vcd['sigs']['mtasks'][sig] = code
|
addValue(code, end, None)
|
||||||
code += 1
|
|
||||||
ccode = vcd['sigs']['mtasks'][sig]
|
|
||||||
vcd['values'][start][ccode] = cpu
|
|
||||||
vcd['values'][end][ccode] = None
|
|
||||||
|
|
||||||
# Eval graph
|
tStart = sorted(_['start'] for records in Threads.values()
|
||||||
vcd['sigs']['evals']["eval"] = code
|
for _ in records)
|
||||||
elcode = code
|
tEnd = sorted(_['end'] for records in Threads.values()
|
||||||
code += 1
|
for _ in records)
|
||||||
n = 0
|
|
||||||
for eval_start in Evals:
|
|
||||||
eval_end = Evals[eval_start]['end']
|
|
||||||
n += 1
|
|
||||||
vcd['values'][eval_start][elcode] = n
|
|
||||||
vcd['values'][eval_end][elcode] = None
|
|
||||||
|
|
||||||
# Eval_loop graph
|
|
||||||
vcd['sigs']['evals']["eval_loop"] = code
|
|
||||||
elcode = code
|
|
||||||
code += 1
|
|
||||||
n = 0
|
|
||||||
for eval_start in EvalLoops:
|
|
||||||
eval_end = EvalLoops[eval_start]['end']
|
|
||||||
n += 1
|
|
||||||
vcd['values'][eval_start][elcode] = n
|
|
||||||
vcd['values'][eval_end][elcode] = None
|
|
||||||
|
|
||||||
# Predicted graph
|
# Predicted graph
|
||||||
for eval_start in EvalLoops:
|
for start, end in ExecGraphIntervals:
|
||||||
eval_end = EvalLoops[eval_start]['end']
|
# Find the earliest MTask start after the start point, and the
|
||||||
# Compute scale so predicted graph is of same width as eval
|
# latest MTask end before the end point, so we can scale to the
|
||||||
measured_scaling = (eval_end -
|
# same range
|
||||||
eval_start) / Global['predict_last_end']
|
start = tStart[bisect.bisect_left(tStart, start)]
|
||||||
# Predict mtasks that fill the time the eval occupied
|
end = tEnd[bisect.bisect_right(tEnd, end) - 1]
|
||||||
|
# Compute scale so predicted graph is of same width as interval
|
||||||
|
measured_scaling = (end - start) / Global['predict_last_end']
|
||||||
|
# Predict mtasks that fill the time the execution occupied
|
||||||
for mtask in Mtasks:
|
for mtask in Mtasks:
|
||||||
thread = Mtasks[mtask]['thread']
|
thread = Mtasks[mtask]['thread']
|
||||||
pred_scaled_start = eval_start + int(
|
pred_scaled_start = start + int(
|
||||||
Mtasks[mtask]['predict_start'] * measured_scaling)
|
Mtasks[mtask]['predict_start'] * measured_scaling)
|
||||||
pred_scaled_end = eval_start + int(
|
pred_scaled_end = start + int(
|
||||||
(Mtasks[mtask]['predict_start'] +
|
(Mtasks[mtask]['predict_start'] +
|
||||||
Mtasks[mtask]['predict_cost']) * measured_scaling)
|
Mtasks[mtask]['predict_cost']) * measured_scaling)
|
||||||
if pred_scaled_start == pred_scaled_end:
|
if pred_scaled_start == pred_scaled_end:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
sig = "predicted_thread%d_mtask" % thread
|
mcode = getCode(32, 'predicted', 't%d_mtask' % thread)
|
||||||
if sig not in vcd['sigs']['predicted_threads']:
|
addValue(mcode, pred_scaled_start, mtask)
|
||||||
vcd['sigs']['predicted_threads'][sig] = code
|
addValue(mcode, pred_scaled_end, None)
|
||||||
code += 1
|
|
||||||
mcode = vcd['sigs']['predicted_threads'][sig]
|
|
||||||
|
|
||||||
vcd['values'][pred_scaled_start][mcode] = mtask
|
|
||||||
vcd['values'][pred_scaled_end][mcode] = None
|
|
||||||
|
|
||||||
parallelism['predicted'][pred_scaled_start] += 1
|
parallelism['predicted'][pred_scaled_start] += 1
|
||||||
parallelism['predicted'][pred_scaled_end] -= 1
|
parallelism['predicted'][pred_scaled_end] -= 1
|
||||||
|
|
||||||
# Parallelism graph
|
# Parallelism graph
|
||||||
for measpred in ('measured', 'predicted'):
|
for measpred in ('measured', 'predicted'):
|
||||||
vcd['sigs']['Stats']["%s_parallelism" % measpred] = code
|
pcode = getCode(32, 'stats', '%s_parallelism' % measpred)
|
||||||
pcode = code
|
|
||||||
code += 1
|
|
||||||
value = 0
|
value = 0
|
||||||
for time in sorted(parallelism[measpred].keys()):
|
for time in sorted(parallelism[measpred].keys()):
|
||||||
value += parallelism[measpred][time]
|
value += parallelism[measpred][time]
|
||||||
vcd['values'][time][pcode] = value
|
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))
|
||||||
|
|
||||||
# Create output file
|
# Create output file
|
||||||
fh.write("$version Generated by verilator_gantt $end\n")
|
fh.write("$version Generated by verilator_gantt $end\n")
|
||||||
fh.write("$timescale 1ns $end\n")
|
fh.write("$timescale 1ns $end\n")
|
||||||
fh.write("\n")
|
fh.write("\n")
|
||||||
|
|
||||||
all_codes = {}
|
all_codes = set()
|
||||||
|
|
||||||
|
def writeScope(scope):
|
||||||
|
assert isinstance(scope, dict)
|
||||||
|
for key in sorted(scope):
|
||||||
|
val = scope[key]
|
||||||
|
if isinstance(val, dict):
|
||||||
|
fh.write(" $scope module %s $end\n" % key)
|
||||||
|
writeScope(val)
|
||||||
|
fh.write(" $upscope $end\n")
|
||||||
|
else:
|
||||||
|
(code, width) = val
|
||||||
|
all_codes.add(code)
|
||||||
|
fh.write(" $var wire %d v%x %s [%d:0] $end\n" %
|
||||||
|
(width, code, key, width - 1))
|
||||||
|
|
||||||
fh.write(" $scope module gantt $end\n")
|
fh.write(" $scope module gantt $end\n")
|
||||||
for module in sorted(vcd['sigs'].keys()):
|
writeScope(scopeSigs)
|
||||||
fh.write(" $scope module %s $end\n" % module)
|
|
||||||
for sig in sorted(vcd['sigs'][module].keys()):
|
|
||||||
code = vcd['sigs'][module][sig]
|
|
||||||
fh.write(" $var wire 32 v%x %s [31:0] $end\n" % (code, sig))
|
|
||||||
all_codes[code] = 1
|
|
||||||
fh.write(" $upscope $end\n")
|
|
||||||
fh.write(" $upscope $end\n")
|
fh.write(" $upscope $end\n")
|
||||||
fh.write("$enddefinitions $end\n")
|
fh.write("$enddefinitions $end\n")
|
||||||
fh.write("\n")
|
fh.write("\n")
|
||||||
|
|
||||||
first = True
|
first = True
|
||||||
for time in sorted(vcd['values']):
|
for time in sorted(values):
|
||||||
if first:
|
if first:
|
||||||
first = False
|
first = False
|
||||||
# Start with Z for any signals without time zero data
|
# Start with Z for any signals without time zero data
|
||||||
for code in sorted(all_codes.keys()):
|
for code in sorted(all_codes):
|
||||||
if code not in vcd['values'][time]:
|
if code not in values[time]:
|
||||||
vcd['values'][time][code] = None
|
addValue(code, time, None)
|
||||||
fh.write("#%d\n" % time)
|
fh.write("#%d\n" % time)
|
||||||
for code in sorted(vcd['values'][time].keys()):
|
for code in sorted(values[time]):
|
||||||
value = vcd['values'][time][code]
|
value = values[time][code]
|
||||||
if value is None:
|
if value is None:
|
||||||
fh.write("bz v%x\n" % code)
|
fh.write("bz v%x\n" % code)
|
||||||
|
elif isinstance(value, str):
|
||||||
|
fh.write("b%s v%x\n" % (value, code))
|
||||||
else:
|
else:
|
||||||
fh.write("b%s v%x\n" % (format(value, 'b'), code))
|
fh.write("b%s v%x\n" % (format(value, 'b'), code))
|
||||||
|
|
||||||
@@ -454,16 +537,16 @@ def write_vcd(filename):
|
|||||||
parser = argparse.ArgumentParser(
|
parser = argparse.ArgumentParser(
|
||||||
allow_abbrev=False,
|
allow_abbrev=False,
|
||||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||||
description="""Create Gantt chart of multi-threaded execution""",
|
description="""Create Gantt chart of multi-threaded execution.
|
||||||
epilog=
|
|
||||||
"""Verilator_gantt creates a visual representation to help analyze Verilator
|
Verilator_gantt creates a visual representation to help analyze Verilator
|
||||||
#xmultithreaded simulation performance, by showing when each macro-task
|
#xmultithreaded simulation performance, by showing when each macro-task
|
||||||
#xstarts and ends, and showing when each thread is busy or idle.
|
#xstarts and ends, and showing when each thread is busy or idle.
|
||||||
|
|
||||||
For documentation see
|
For documentation see
|
||||||
https://verilator.org/guide/latest/exe_verilator_gantt.html
|
https://verilator.org/guide/latest/exe_verilator_gantt.html""",
|
||||||
|
epilog=
|
||||||
Copyright 2018-2021 by Wilson Snyder. This program is free software; you
|
"""Copyright 2018-2024 by Wilson Snyder. This program is free software; you
|
||||||
can redistribute it and/or modify it under the terms of either the GNU
|
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
|
Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
Version 2.0.
|
Version 2.0.
|
||||||
@@ -476,14 +559,15 @@ parser.add_argument('--no-vcd',
|
|||||||
action='store_true')
|
action='store_true')
|
||||||
parser.add_argument('--vcd',
|
parser.add_argument('--vcd',
|
||||||
help='filename for vcd outpue',
|
help='filename for vcd outpue',
|
||||||
default='profile_threads.vcd')
|
default='profile_exec.vcd')
|
||||||
parser.add_argument('filename',
|
parser.add_argument('filename',
|
||||||
help='input profile_threads.dat filename to process',
|
help='input profile_exec.dat filename to process',
|
||||||
default='profile_threads.dat')
|
default='profile_exec.dat')
|
||||||
|
|
||||||
Args = parser.parse_args()
|
Args = parser.parse_args()
|
||||||
|
|
||||||
process(Args.filename)
|
read_data(Args.filename)
|
||||||
|
report()
|
||||||
if not Args.no_vcd:
|
if not Args.no_vcd:
|
||||||
write_vcd(Args.vcd)
|
write_vcd(Args.vcd)
|
||||||
|
|
||||||
|
|||||||
+25
-16
@@ -1,20 +1,29 @@
|
|||||||
#!/usr/bin/env perl
|
#!/usr/bin/env python3
|
||||||
# DESCRIPTION: Print include statements for each ARGV
|
# pylint: disable=C0114,C0209
|
||||||
|
#
|
||||||
|
# Copyright 2003-2024 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.
|
||||||
#
|
#
|
||||||
# Copyright 2003-2021 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
|
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
require 5.005;
|
import re
|
||||||
use warnings;
|
import sys
|
||||||
print "// DESCR" . "IPTION: Generated by verilator_includer via makefile\n";
|
|
||||||
foreach my $param (@ARGV) {
|
print("// DESCR" + "IPTION: Generated by verilator_includer via makefile")
|
||||||
if ($param =~ /^-D([^=]+)=(.*)/) {
|
|
||||||
print "#define $1 $2\n";
|
re_arg_d = re.compile(r'^-D([^=]+)=(.*)')
|
||||||
} else {
|
|
||||||
print "#include \"$param\"\n";
|
for arg in sys.argv[1:]:
|
||||||
}
|
match_d = re_arg_d.match(arg)
|
||||||
}
|
if match_d:
|
||||||
|
print("#define %s %s" % (match_d.group(1), match_d.group(2)))
|
||||||
|
else:
|
||||||
|
print("#include \"%s\"" % (arg))
|
||||||
|
|
||||||
|
######################################################################
|
||||||
|
# Local Variables:
|
||||||
|
# compile-command: "./verilator_includer -Ddef=value -Ddef2=value2 file1.h file2.h"
|
||||||
|
# End:
|
||||||
|
|||||||
+19
-20
@@ -1,5 +1,5 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# pylint: disable=C0103,C0114,C0116,R0914,R0912,R0915,eval-used
|
# pylint: disable=C0103,C0114,C0116,C0209,R0914,R0912,R0915,eval-used
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
@@ -13,7 +13,7 @@ import re
|
|||||||
def profcfunc(filename):
|
def profcfunc(filename):
|
||||||
funcs = {}
|
funcs = {}
|
||||||
|
|
||||||
with open(filename) as fh:
|
with open(filename, "r", encoding="utf8") as fh:
|
||||||
|
|
||||||
for line in fh:
|
for line in fh:
|
||||||
# %time cumesec selfsec calls {stuff} name
|
# %time cumesec selfsec calls {stuff} name
|
||||||
@@ -67,16 +67,15 @@ def profcfunc(filename):
|
|||||||
groups['design'] = collections.defaultdict(lambda: 0)
|
groups['design'] = collections.defaultdict(lambda: 0)
|
||||||
groups['module'] = collections.defaultdict(lambda: 0)
|
groups['module'] = collections.defaultdict(lambda: 0)
|
||||||
|
|
||||||
for func in funcs:
|
for func, func_item in funcs.items():
|
||||||
pct = funcs[func]['pct']
|
pct = func_item['pct']
|
||||||
vfunc = func
|
vfunc = func
|
||||||
|
|
||||||
funcarg = re.sub(r'^.*\(', '', func)
|
funcarg = re.sub(r'^.*\(', '', func)
|
||||||
|
|
||||||
design = None
|
design = None
|
||||||
for vde in verilated_mods:
|
for vde, vde_item in verilated_mods.items():
|
||||||
if verilated_mods[vde].match(func) or verilated_mods[vde].match(
|
if vde_item.match(func) or vde_item.match(funcarg):
|
||||||
funcarg):
|
|
||||||
design = vde
|
design = vde
|
||||||
break
|
break
|
||||||
|
|
||||||
@@ -114,12 +113,12 @@ def profcfunc(filename):
|
|||||||
groups['module']['C++'] += pct
|
groups['module']['C++'] += pct
|
||||||
|
|
||||||
if vfunc not in vfuncs:
|
if vfunc not in vfuncs:
|
||||||
vfuncs[vfunc] = funcs[func]
|
vfuncs[vfunc] = func_item
|
||||||
vfuncs[vfunc]['design'] = vdesign
|
vfuncs[vfunc]['design'] = vdesign
|
||||||
else:
|
else:
|
||||||
vfuncs[vfunc]['pct'] += funcs[func]['pct']
|
vfuncs[vfunc]['pct'] += func_item['pct']
|
||||||
vfuncs[vfunc]['calls'] += funcs[func]['calls']
|
vfuncs[vfunc]['calls'] += func_item['calls']
|
||||||
vfuncs[vfunc]['sec'] += funcs[func]['sec']
|
vfuncs[vfunc]['sec'] += func_item['sec']
|
||||||
|
|
||||||
for ftype in ['type', 'design', 'module']:
|
for ftype in ['type', 'design', 'module']:
|
||||||
missing = 100
|
missing = 100
|
||||||
@@ -136,9 +135,9 @@ def profcfunc(filename):
|
|||||||
print()
|
print()
|
||||||
|
|
||||||
design_width = 1
|
design_width = 1
|
||||||
for func in vfuncs:
|
for func, func_item in vfuncs.items():
|
||||||
if design_width < len(vfuncs[func]['design']):
|
if design_width < len(func_item['design']):
|
||||||
design_width = len(vfuncs[func]['design'])
|
design_width = len(func_item['design'])
|
||||||
|
|
||||||
print("Verilog code profile:")
|
print("Verilog code profile:")
|
||||||
print(" These are split into three categories:")
|
print(" These are split into three categories:")
|
||||||
@@ -172,17 +171,17 @@ def profcfunc(filename):
|
|||||||
parser = argparse.ArgumentParser(
|
parser = argparse.ArgumentParser(
|
||||||
allow_abbrev=False,
|
allow_abbrev=False,
|
||||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||||
description="""Read gprof report created with --prof-cfuncs""",
|
description="""Read gprof report created with --prof-cfuncs.
|
||||||
epilog=
|
|
||||||
"""Verilator_profcfunc reads a profile report created by gprof. The names of
|
Verilator_profcfunc reads a profile report created by gprof. The names of
|
||||||
the functions are then transformed, assuming the user used Verilator's
|
the functions are then transformed, assuming the user used Verilator's
|
||||||
--prof-cfuncs, and a report printed showing the percentage of time, etc,
|
--prof-cfuncs, and a report printed showing the percentage of time, etc,
|
||||||
in each Verilog block.
|
in each Verilog block.
|
||||||
|
|
||||||
For documentation see
|
For documentation see
|
||||||
https://verilator.org/guide/latest/exe_verilator_profcfunc.html
|
https://verilator.org/guide/latest/exe_verilator_profcfunc.html""",
|
||||||
|
epilog=
|
||||||
Copyright 2002-2021 by Wilson Snyder. This program is free software; you
|
"""Copyright 2002-2024 by Wilson Snyder. This program is free software; you
|
||||||
can redistribute it and/or modify it under the terms of either the GNU
|
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
|
Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
Version 2.0.
|
Version 2.0.
|
||||||
|
|||||||
@@ -26,4 +26,5 @@ if git log --format=%B -n 1 "$COMMIT" | grep -q -i '\[CI\s\+ccache\s\+clear\]';
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Dump stats, then zero stats
|
# Dump stats, then zero stats
|
||||||
|
# 22.04: ccache -s -v -z
|
||||||
ccache -s -z
|
ccache -s -z
|
||||||
|
|||||||
+31
-17
@@ -19,16 +19,14 @@ set -x
|
|||||||
|
|
||||||
cd $(dirname "$0")/..
|
cd $(dirname "$0")/..
|
||||||
|
|
||||||
|
# Avoid occasional cpan failures "Issued certificate has expired."
|
||||||
|
export PERL_LWP_SSL_VERIFY_HOSTNAME=0
|
||||||
|
echo "check_certificate = off" >> ~/.wgetrc
|
||||||
|
|
||||||
fatal() {
|
fatal() {
|
||||||
echo "ERROR: $(basename "$0"): $1" >&2; exit 1;
|
echo "ERROR: $(basename "$0"): $1" >&2; exit 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if [ "$CI_M32" = "0" ]; then
|
|
||||||
unset CI_M32
|
|
||||||
elif [ "$CI_M32" != "1" ]; then
|
|
||||||
fatal "\$CI_M32 must be '0' or '1'";
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$CI_OS_NAME" = "linux" ]; then
|
if [ "$CI_OS_NAME" = "linux" ]; then
|
||||||
MAKE=make
|
MAKE=make
|
||||||
elif [ "$CI_OS_NAME" = "osx" ]; then
|
elif [ "$CI_OS_NAME" = "osx" ]; then
|
||||||
@@ -53,17 +51,26 @@ if [ "$CI_BUILD_STAGE_NAME" = "build" ]; then
|
|||||||
# build Verilator
|
# build Verilator
|
||||||
|
|
||||||
if [ "$CI_OS_NAME" = "linux" ]; then
|
if [ "$CI_OS_NAME" = "linux" ]; then
|
||||||
|
sudo apt-get update ||
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install libfl-dev libgoogle-perftools-dev ccache
|
sudo apt-get install ccache help2man libfl-dev ||
|
||||||
|
sudo apt-get install ccache help2man libfl-dev
|
||||||
if [ "$CI_RUNS_ON" = "ubuntu-20.04" ]; then
|
if [ "$CI_RUNS_ON" = "ubuntu-20.04" ]; then
|
||||||
|
# Some conflict of libunwind verison on 22.04, can live without it for now
|
||||||
|
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
|
||||||
|
sudo apt-get install libsystemc libsystemc-dev ||
|
||||||
sudo apt-get install libsystemc libsystemc-dev
|
sudo apt-get install libsystemc libsystemc-dev
|
||||||
fi
|
fi
|
||||||
|
if [ "$CI_RUNS_ON" = "ubuntu-22.04" ]; then
|
||||||
|
sudo apt-get install bear mold ||
|
||||||
|
sudo apt-get install bear mold
|
||||||
|
fi
|
||||||
if [ "$COVERAGE" = 1 ]; then
|
if [ "$COVERAGE" = 1 ]; then
|
||||||
yes yes | sudo cpan -fi Parallel::Forker
|
yes yes | sudo cpan -fi Parallel::Forker
|
||||||
fi
|
fi
|
||||||
if [ "$CI_M32" = 1 ]; then
|
|
||||||
sudo apt-get install gcc-multilib g++-multilib
|
|
||||||
fi
|
|
||||||
elif [ "$CI_OS_NAME" = "osx" ]; then
|
elif [ "$CI_OS_NAME" = "osx" ]; then
|
||||||
brew update
|
brew update
|
||||||
brew install ccache perl gperftools
|
brew install ccache perl gperftools
|
||||||
@@ -82,22 +89,27 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
|||||||
# run the tests
|
# run the tests
|
||||||
|
|
||||||
if [ "$CI_OS_NAME" = "linux" ]; then
|
if [ "$CI_OS_NAME" = "linux" ]; then
|
||||||
|
sudo apt-get update ||
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
# libfl-dev needed for internal coverage's test runs
|
# libfl-dev needed for internal coverage's test runs
|
||||||
sudo apt-get install gdb gtkwave lcov libfl-dev ccache
|
sudo apt-get install gdb gtkwave lcov libfl-dev ccache jq ||
|
||||||
if [ "$CI_RUNS_ON" = "ubuntu-20.04" ]; then
|
sudo apt-get install gdb gtkwave lcov libfl-dev ccache jq
|
||||||
sudo apt-get install libsystemc-dev
|
# Required for test_regress/t/t_dist_attributes.pl
|
||||||
|
if [ "$CI_RUNS_ON" = "ubuntu-22.04" ]; then
|
||||||
|
sudo apt-get install python3-clang mold ||
|
||||||
|
sudo apt-get install python3-clang mold
|
||||||
fi
|
fi
|
||||||
if [ "$CI_M32" = 1 ]; then
|
if [ "$CI_RUNS_ON" = "ubuntu-20.04" ] || [ "$CI_RUNS_ON" = "ubuntu-22.04" ]; then
|
||||||
sudo apt-get install lib32z1-dev gcc-multilib g++-multilib
|
sudo apt-get install libsystemc-dev ||
|
||||||
|
sudo apt-get install libsystemc-dev
|
||||||
fi
|
fi
|
||||||
elif [ "$CI_OS_NAME" = "osx" ]; then
|
elif [ "$CI_OS_NAME" = "osx" ]; then
|
||||||
brew update
|
brew update
|
||||||
# brew cask install gtkwave # fst2vcd hangs at launch, so don't bother
|
# brew cask install gtkwave # fst2vcd hangs at launch, so don't bother
|
||||||
brew install ccache perl
|
brew install ccache perl jq
|
||||||
elif [ "$CI_OS_NAME" = "freebsd" ]; then
|
elif [ "$CI_OS_NAME" = "freebsd" ]; then
|
||||||
# fst2vcd fails with "Could not open '<input file>', exiting."
|
# fst2vcd fails with "Could not open '<input file>', exiting."
|
||||||
sudo pkg install -y ccache gmake perl5 python3
|
sudo pkg install -y ccache gmake perl5 python3 jq
|
||||||
else
|
else
|
||||||
fatal "Unknown os: '$CI_OS_NAME'"
|
fatal "Unknown os: '$CI_OS_NAME'"
|
||||||
fi
|
fi
|
||||||
@@ -107,6 +119,8 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
|||||||
fi
|
fi
|
||||||
yes yes | sudo cpan -M $CI_CPAN_REPO -fi Parallel::Forker
|
yes yes | sudo cpan -M $CI_CPAN_REPO -fi Parallel::Forker
|
||||||
install-vcddiff
|
install-vcddiff
|
||||||
|
# Workaround -fsanitize=address crash
|
||||||
|
sudo sysctl -w vm.mmap_rnd_bits=28
|
||||||
else
|
else
|
||||||
##############################################################################
|
##############################################################################
|
||||||
# Unknown build stage
|
# Unknown build stage
|
||||||
|
|||||||
+29
-16
@@ -21,12 +21,6 @@ fatal() {
|
|||||||
echo "ERROR: $(basename "$0"): $1" >&2; exit 1;
|
echo "ERROR: $(basename "$0"): $1" >&2; exit 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if [ "$CI_M32" = "0" ]; then
|
|
||||||
unset CI_M32
|
|
||||||
elif [ "$CI_M32" != "1" ]; then
|
|
||||||
fatal "\$CI_M32 must be '0' or '1'";
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$CI_OS_NAME" = "linux" ]; then
|
if [ "$CI_OS_NAME" = "linux" ]; then
|
||||||
export MAKE=make
|
export MAKE=make
|
||||||
NPROC=$(nproc)
|
NPROC=$(nproc)
|
||||||
@@ -46,9 +40,10 @@ if [ "$CI_BUILD_STAGE_NAME" = "build" ]; then
|
|||||||
|
|
||||||
if [ "$COVERAGE" != 1 ]; then
|
if [ "$COVERAGE" != 1 ]; then
|
||||||
autoconf
|
autoconf
|
||||||
./configure --enable-longtests --enable-ccwarn ${CI_M32:+--enable-m32}
|
./configure --enable-longtests --enable-ccwarn --prefix="$INSTALL_DIR"
|
||||||
ccache -z
|
ccache -z
|
||||||
"$MAKE" -j "$NPROC" -k
|
"$MAKE" -j "$NPROC" -k
|
||||||
|
# 22.04: ccache -s -v
|
||||||
ccache -s
|
ccache -s
|
||||||
if [ "$CI_OS_NAME" = "osx" ]; then
|
if [ "$CI_OS_NAME" = "osx" ]; then
|
||||||
file bin/verilator_bin
|
file bin/verilator_bin
|
||||||
@@ -69,7 +64,7 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
|||||||
|
|
||||||
if [ "$CI_OS_NAME" = "osx" ]; then
|
if [ "$CI_OS_NAME" = "osx" ]; then
|
||||||
export VERILATOR_TEST_NO_GDB=1 # Pain to get GDB to work on OS X
|
export VERILATOR_TEST_NO_GDB=1 # Pain to get GDB to work on OS X
|
||||||
# TODO below may no longer be requried as configure checks for -pg
|
# TODO below may no longer be required as configure checks for -pg
|
||||||
export VERILATOR_TEST_NO_GPROF=1 # Apple Clang has no -pg
|
export VERILATOR_TEST_NO_GPROF=1 # Apple Clang has no -pg
|
||||||
# export PATH="/Applications/gtkwave.app/Contents/Resources/bin:$PATH" # fst2vcd
|
# export PATH="/Applications/gtkwave.app/Contents/Resources/bin:$PATH" # fst2vcd
|
||||||
file bin/verilator_bin
|
file bin/verilator_bin
|
||||||
@@ -85,30 +80,47 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
|||||||
"$MAKE" -j "$NPROC" -k
|
"$MAKE" -j "$NPROC" -k
|
||||||
elif [ "$CI_OS_NAME" = "freebsd" ]; then
|
elif [ "$CI_OS_NAME" = "freebsd" ]; then
|
||||||
export VERILATOR_TEST_NO_GDB=1 # Disable for now, ideally should run
|
export VERILATOR_TEST_NO_GDB=1 # Disable for now, ideally should run
|
||||||
# TODO below may no longer be requried as configure checks for -pg
|
# TODO below may no longer be required as configure checks for -pg
|
||||||
export VERILATOR_TEST_NO_GPROF=1 # gprof is a bit different on FreeBSD, disable
|
export VERILATOR_TEST_NO_GPROF=1 # gprof is a bit different on FreeBSD, disable
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Run sanitize on Ubuntu 20.04 only
|
# Run sanitize on Ubuntu 22.04 only
|
||||||
[ "$CI_RUNS_ON" = 'ubuntu-20.04' ] && [ "$CI_M32" = "" ] && sanitize='--sanitize' || sanitize=''
|
[ "$CI_RUNS_ON" = 'ubuntu-22.04' ] && sanitize='--sanitize' || sanitize=''
|
||||||
|
|
||||||
|
TEST_REGRESS=test_regress
|
||||||
|
if [ "$CI_RELOC" == 1 ]; then
|
||||||
|
# Testing that the installation is relocatable.
|
||||||
|
"$MAKE" install
|
||||||
|
mkdir -p "$RELOC_DIR"
|
||||||
|
mv "$INSTALL_DIR" "$RELOC_DIR/relocated-install"
|
||||||
|
export VERILATOR_ROOT="$RELOC_DIR/relocated-install/share/verilator"
|
||||||
|
TEST_REGRESS="$RELOC_DIR/test_regress"
|
||||||
|
mv test_regress "$TEST_REGRESS"
|
||||||
|
# Feeling brave?
|
||||||
|
find . -delete
|
||||||
|
ls -la .
|
||||||
|
fi
|
||||||
|
|
||||||
# Run the specified test
|
# Run the specified test
|
||||||
ccache -z
|
ccache -z
|
||||||
case $TESTS in
|
case $TESTS in
|
||||||
dist-vlt-0)
|
dist-vlt-0)
|
||||||
"$MAKE" -C test_regress SCENARIOS="--dist --vlt $sanitize" DRIVER_HASHSET=--hashset=0/3
|
"$MAKE" -C "$TEST_REGRESS" SCENARIOS="--dist --vlt $sanitize" DRIVER_HASHSET=--hashset=0/4
|
||||||
;;
|
;;
|
||||||
dist-vlt-1)
|
dist-vlt-1)
|
||||||
"$MAKE" -C test_regress SCENARIOS="--dist --vlt $sanitize" DRIVER_HASHSET=--hashset=1/3
|
"$MAKE" -C "$TEST_REGRESS" SCENARIOS="--dist --vlt $sanitize" DRIVER_HASHSET=--hashset=1/4
|
||||||
;;
|
;;
|
||||||
dist-vlt-2)
|
dist-vlt-2)
|
||||||
"$MAKE" -C test_regress SCENARIOS="--dist --vlt $sanitize" DRIVER_HASHSET=--hashset=2/3
|
"$MAKE" -C "$TEST_REGRESS" SCENARIOS="--dist --vlt $sanitize" DRIVER_HASHSET=--hashset=2/4
|
||||||
|
;;
|
||||||
|
dist-vlt-3)
|
||||||
|
"$MAKE" -C "$TEST_REGRESS" SCENARIOS="--dist --vlt $sanitize" DRIVER_HASHSET=--hashset=3/4
|
||||||
;;
|
;;
|
||||||
vltmt-0)
|
vltmt-0)
|
||||||
"$MAKE" -C test_regress SCENARIOS=--vltmt DRIVER_HASHSET=--hashset=0/2
|
"$MAKE" -C "$TEST_REGRESS" SCENARIOS=--vltmt DRIVER_HASHSET=--hashset=0/2
|
||||||
;;
|
;;
|
||||||
vltmt-1)
|
vltmt-1)
|
||||||
"$MAKE" -C test_regress SCENARIOS=--vltmt DRIVER_HASHSET=--hashset=1/2
|
"$MAKE" -C "$TEST_REGRESS" SCENARIOS=--vltmt DRIVER_HASHSET=--hashset=1/2
|
||||||
;;
|
;;
|
||||||
coverage-all)
|
coverage-all)
|
||||||
nodist/code_coverage --stages 1-
|
nodist/code_coverage --stages 1-
|
||||||
@@ -180,6 +192,7 @@ elif [ "$CI_BUILD_STAGE_NAME" = "test" ]; then
|
|||||||
fatal "Unknown test: $TESTS"
|
fatal "Unknown test: $TESTS"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
# 22.04: ccache -s -v
|
||||||
ccache -s
|
ccache -s
|
||||||
|
|
||||||
# Upload coverage data
|
# Upload coverage data
|
||||||
|
|||||||
@@ -0,0 +1,15 @@
|
|||||||
|
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 ../..
|
||||||
|
}
|
||||||
|
mkdir build
|
||||||
|
cd build
|
||||||
|
cmake .. --install-prefix $PWD/../install
|
||||||
|
cmake --build . --config Release -j 3
|
||||||
|
cmake --install . --prefix $PWD/../install
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
cd install
|
||||||
|
$Env:VERILATOR_ROOT=$PWD
|
||||||
|
cd examples/cmake_tracing_c
|
||||||
|
mkdir build
|
||||||
|
cd build
|
||||||
|
cmake ..
|
||||||
|
cmake --build . --config Release -j 3
|
||||||
|
Release/example.exe
|
||||||
|
cd ..
|
||||||
|
Remove-Item -path build -recurse
|
||||||
@@ -6,7 +6,17 @@
|
|||||||
# Version 2.0.
|
# Version 2.0.
|
||||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
FROM ubuntu:20.04
|
FROM ubuntu:22.04
|
||||||
|
|
||||||
|
# Create the user
|
||||||
|
RUN groupadd verilator \
|
||||||
|
&& useradd -g verilator -m verilator -s /bin/bash \
|
||||||
|
&& apt-get update \
|
||||||
|
&& apt-get install --no-install-recommends -y sudo \
|
||||||
|
&& apt-get clean \
|
||||||
|
&& rm -rf /var/lib/apt/lists/* \
|
||||||
|
&& echo verilator ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/verilator \
|
||||||
|
&& chmod 0440 /etc/sudoers.d/verilator
|
||||||
|
|
||||||
RUN apt-get update \
|
RUN apt-get update \
|
||||||
&& DEBIAN_FRONTEND=noninteractive \
|
&& DEBIAN_FRONTEND=noninteractive \
|
||||||
@@ -23,6 +33,7 @@ RUN apt-get update \
|
|||||||
gdb \
|
gdb \
|
||||||
git \
|
git \
|
||||||
gtkwave \
|
gtkwave \
|
||||||
|
help2man \
|
||||||
libfl2 \
|
libfl2 \
|
||||||
libfl-dev \
|
libfl-dev \
|
||||||
libgoogle-perftools-dev \
|
libgoogle-perftools-dev \
|
||||||
@@ -32,7 +43,6 @@ RUN apt-get update \
|
|||||||
perl \
|
perl \
|
||||||
python3 \
|
python3 \
|
||||||
wget \
|
wget \
|
||||||
zlibc \
|
|
||||||
zlib1g \
|
zlib1g \
|
||||||
zlib1g-dev \
|
zlib1g-dev \
|
||||||
&& apt-get clean \
|
&& apt-get clean \
|
||||||
@@ -51,6 +61,8 @@ COPY build.sh /tmp/build.sh
|
|||||||
|
|
||||||
ENV VERILATOR_AUTHOR_SITE=1
|
ENV VERILATOR_AUTHOR_SITE=1
|
||||||
|
|
||||||
|
USER verilator
|
||||||
|
|
||||||
WORKDIR /work
|
WORKDIR /work
|
||||||
|
|
||||||
ENTRYPOINT [ "/tmp/build.sh" ]
|
ENTRYPOINT [ "/tmp/build.sh" ]
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
Verilator Build Docker Container
|
Verilator Build Docker Container
|
||||||
================================
|
================================
|
||||||
|
|
||||||
@@ -8,7 +11,7 @@ Verilator build. It uses the following parameters:
|
|||||||
|
|
||||||
- Source revision (default: master)
|
- Source revision (default: master)
|
||||||
|
|
||||||
- Compiler (GCC 9.3.0, clang 10.0.0, default: 9.3.0)
|
- Compiler (GCC 10.3.0, clang 10.0.0, default: 10.3.0)
|
||||||
|
|
||||||
The container is published as ``verilator/verilator-buildenv`` on `docker
|
The container is published as ``verilator/verilator-buildenv`` on `docker
|
||||||
hub
|
hub
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
# Version 2.0.
|
# Version 2.0.
|
||||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
FROM ubuntu:20.04
|
FROM ubuntu:22.04
|
||||||
|
|
||||||
RUN apt-get update \
|
RUN apt-get update \
|
||||||
&& DEBIAN_FRONTEND=noninteractive \
|
&& DEBIAN_FRONTEND=noninteractive \
|
||||||
@@ -19,10 +19,16 @@ RUN apt-get update \
|
|||||||
ccache \
|
ccache \
|
||||||
flex \
|
flex \
|
||||||
git \
|
git \
|
||||||
|
help2man \
|
||||||
|
libfl2 \
|
||||||
libfl-dev \
|
libfl-dev \
|
||||||
libgoogle-perftools-dev \
|
libgoogle-perftools-dev \
|
||||||
|
numactl \
|
||||||
perl \
|
perl \
|
||||||
|
perl-doc \
|
||||||
python3 \
|
python3 \
|
||||||
|
zlib1g \
|
||||||
|
zlib1g-dev \
|
||||||
&& apt-get clean \
|
&& apt-get clean \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
@@ -39,7 +45,7 @@ RUN git clone "${REPO}" verilator && \
|
|||||||
git checkout "${SOURCE_COMMIT}" && \
|
git checkout "${SOURCE_COMMIT}" && \
|
||||||
autoconf && \
|
autoconf && \
|
||||||
./configure && \
|
./configure && \
|
||||||
make -j "$(nproc)" && \
|
make && \
|
||||||
make install && \
|
make install && \
|
||||||
cd .. && \
|
cd .. && \
|
||||||
rm -r verilator
|
rm -r verilator
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
Verilator Executable Docker Container
|
Verilator Executable Docker Container
|
||||||
=====================================
|
=====================================
|
||||||
|
|
||||||
@@ -62,12 +65,11 @@ Internals
|
|||||||
---------
|
---------
|
||||||
|
|
||||||
The Dockerfile builds Verilator and removes the tree when completed to
|
The Dockerfile builds Verilator and removes the tree when completed to
|
||||||
reduce the image size. The entrypoint is set as a wrapper script
|
reduce the image size. The entrypoint is a wrapper script
|
||||||
(``verilator-wrap.sh``). That script 1. calls Verilator, and 2. copies the
|
(``verilator-wrap.sh``). That script 1. calls Verilator, and 2. copies the
|
||||||
Verilated runtime files to the ``obj_dir`` or the ``-Mdir``
|
Verilated runtime files to the ``obj_dir`` or the ``-Mdir``
|
||||||
respectively. This allows the user to have the files to they may later
|
respectively. This allows the user to have the files to they may later
|
||||||
build the C++ output with the matching runtime files. The wrapper also
|
build the C++ output with the matching runtime files. The wrapper also
|
||||||
patches the Verilated Makefile accordingly.
|
patches the Verilated Makefile accordingly.
|
||||||
|
|
||||||
There is also a hook defined that is run by docker hub via automated
|
A hook is also defined and run by Docker Hub via automated builds.
|
||||||
builds.
|
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
# DESCRIPTION: codecov.io config
|
# DESCRIPTION: codecov.io config
|
||||||
#
|
#
|
||||||
# Copyright 2020-2021 by Wilson Snyder. This program is free software; you
|
# Copyright 2020-2024 by Wilson Snyder. This program is free software; you
|
||||||
# can redistribute it and/or modify it under the terms of either the GNU
|
# 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
|
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
# Version 2.0.
|
# Version 2.0.
|
||||||
|
|||||||
+103
-58
@@ -1,20 +1,20 @@
|
|||||||
# DESCRIPTION: Process this file with autoconf to produce a configure script.
|
# DESCRIPTION: Process this file with autoconf to produce a configure script.
|
||||||
#
|
#
|
||||||
# Copyright 2003-2021 by Wilson Snyder. Verilator is free software; you
|
# Copyright 2003-2024 by Wilson Snyder. Verilator is free software; you
|
||||||
# can redistribute it and/or modify it under the terms of either the GNU Lesser
|
# 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.
|
# General Public License Version 3 or the Perl Artistic License Version 2.0.
|
||||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
#AC_INIT([Verilator],[#.### YYYY-MM-DD])
|
# When releasing, also update header of Changes file, and CmakeLists.txt,
|
||||||
#AC_INIT([Verilator],[#.### devel])
|
|
||||||
AC_INIT([Verilator],[4.216 2021-12-05],
|
|
||||||
[https://verilator.org],
|
|
||||||
[verilator],[https://verilator.org])
|
|
||||||
# When releasing, also update header of Changes file
|
|
||||||
# and commit using "devel release" or "Version bump" message
|
# and commit using "devel release" or "Version bump" message
|
||||||
# Then 'make maintainer-dist'
|
# Then 'make maintainer-dist'
|
||||||
|
#AC_INIT([Verilator],[#.### YYYY-MM-DD])
|
||||||
|
#AC_INIT([Verilator],[#.### devel])
|
||||||
|
AC_INIT([Verilator],[5.024 2024-04-05],
|
||||||
|
[https://verilator.org],
|
||||||
|
[verilator],[https://verilator.org])
|
||||||
|
|
||||||
AC_CONFIG_HEADER(src/config_build.h)
|
AC_CONFIG_HEADERS(src/config_package.h)
|
||||||
AC_CONFIG_FILES(Makefile src/Makefile src/Makefile_obj include/verilated.mk include/verilated_config.h verilator.pc verilator-config.cmake verilator-config-version.cmake)
|
AC_CONFIG_FILES(Makefile src/Makefile src/Makefile_obj include/verilated.mk include/verilated_config.h verilator.pc verilator-config.cmake verilator-config-version.cmake)
|
||||||
|
|
||||||
# Version
|
# Version
|
||||||
@@ -22,6 +22,12 @@ AC_MSG_RESULT([configuring for $PACKAGE_STRING])
|
|||||||
PACKAGE_VERSION_NUMBER=`AS_ECHO("$PACKAGE_VERSION") | sed 's/ .*//g'`
|
PACKAGE_VERSION_NUMBER=`AS_ECHO("$PACKAGE_VERSION") | sed 's/ .*//g'`
|
||||||
AC_SUBST(PACKAGE_VERSION_NUMBER)
|
AC_SUBST(PACKAGE_VERSION_NUMBER)
|
||||||
AC_DEFINE_UNQUOTED([PACKAGE_VERSION_NUMBER_STRING],["$PACKAGE_VERSION_NUMBER"],[Package version as a number])
|
AC_DEFINE_UNQUOTED([PACKAGE_VERSION_NUMBER_STRING],["$PACKAGE_VERSION_NUMBER"],[Package version as a number])
|
||||||
|
VERILATOR_VERSION_INTEGER=`AS_ECHO("$PACKAGE_VERSION") | [sed 's/\([0-9]\)\.\([0-9][0-9][0-9]\) .*/\1\2000/g']`
|
||||||
|
AC_SUBST(VERILATOR_VERSION_INTEGER)
|
||||||
|
AC_DEFINE_UNQUOTED([PACKAGE_VERSION_STRING_CHAR],
|
||||||
|
[static const char* const PACKAGE_STRING_UNUSED = "$PACKAGE_STRING";],
|
||||||
|
[Package version as a number])
|
||||||
|
AC_SUBST(PACKAGE_VERSION_STRING_CHAR)
|
||||||
|
|
||||||
# Ignore automake flags passed by Ubuntu builds
|
# Ignore automake flags passed by Ubuntu builds
|
||||||
AC_ARG_ENABLE([dependency-tracking],
|
AC_ARG_ENABLE([dependency-tracking],
|
||||||
@@ -61,20 +67,6 @@ AC_ARG_ENABLE([tcmalloc],
|
|||||||
[CFG_WITH_TCMALLOC=check;])
|
[CFG_WITH_TCMALLOC=check;])
|
||||||
AC_MSG_RESULT($CFG_WITH_TCMALLOC)
|
AC_MSG_RESULT($CFG_WITH_TCMALLOC)
|
||||||
|
|
||||||
# Flag to enable -m32 build
|
|
||||||
AC_MSG_CHECKING(whether to use -m32)
|
|
||||||
AC_ARG_ENABLE([m32],
|
|
||||||
[AS_HELP_STRING([--enable-m32],
|
|
||||||
[Use -m32 for all compilation and link,
|
|
||||||
including Verialtor and generated models.])],
|
|
||||||
[case "${enableval}" in
|
|
||||||
yes) CFG_ENABLE_M32=yes ;;
|
|
||||||
no) CFG_ENABLE_M32=no ;;
|
|
||||||
*) AC_MSG_ERROR([bad value '${enableval}' for --enable-m32]) ;;
|
|
||||||
esac],
|
|
||||||
CFG_ENABLE_M32=no)
|
|
||||||
AC_MSG_RESULT($CFG_ENABLE_M32)
|
|
||||||
|
|
||||||
# Flag to enable coverage build
|
# Flag to enable coverage build
|
||||||
AC_MSG_CHECKING(whether to build for coverage collection)
|
AC_MSG_CHECKING(whether to build for coverage collection)
|
||||||
AC_ARG_ENABLE([coverage],
|
AC_ARG_ENABLE([coverage],
|
||||||
@@ -110,7 +102,7 @@ AC_MSG_CHECKING(whether to show and stop on compilation warnings)
|
|||||||
AC_ARG_ENABLE([ccwarn],
|
AC_ARG_ENABLE([ccwarn],
|
||||||
[AS_HELP_STRING([--enable-ccwarn],
|
[AS_HELP_STRING([--enable-ccwarn],
|
||||||
[enable showing and stopping on compilation warnings
|
[enable showing and stopping on compilation warnings
|
||||||
in Verilator binrary and Verilated makefiles])],
|
in Verilator binary and Verilated makefiles])],
|
||||||
[case "${enableval}" in
|
[case "${enableval}" in
|
||||||
yes) CFG_WITH_CCWARN=yes ;;
|
yes) CFG_WITH_CCWARN=yes ;;
|
||||||
no) CFG_WITH_CCWARN=no ;;
|
no) CFG_WITH_CCWARN=no ;;
|
||||||
@@ -143,10 +135,10 @@ AC_SUBST(CFG_WITH_LONGTESTS)
|
|||||||
AC_MSG_RESULT($CFG_WITH_LONGTESTS)
|
AC_MSG_RESULT($CFG_WITH_LONGTESTS)
|
||||||
|
|
||||||
# Compiler flags (ensure they are not empty to avoid configure defaults)
|
# Compiler flags (ensure they are not empty to avoid configure defaults)
|
||||||
CFLAGS+=" "
|
CFLAGS="$CFLAGS "
|
||||||
CPPFLAGS+=" "
|
CPPFLAGS="$CPPFLAGS "
|
||||||
CXXFLAGS+=" "
|
CXXFLAGS="$CXXFLAGS "
|
||||||
LDFLAGS+=" "
|
LDFLAGS="$LDFLAGS "
|
||||||
|
|
||||||
# Checks for programs.
|
# Checks for programs.
|
||||||
AC_PROG_CC
|
AC_PROG_CC
|
||||||
@@ -313,15 +305,7 @@ AC_DEFUN([_MY_LDLIBS_CHECK_OPT],
|
|||||||
_MY_LDLIBS_CHECK_IFELSE($2, $1="$$1 $2")
|
_MY_LDLIBS_CHECK_IFELSE($2, $1="$$1 $2")
|
||||||
])
|
])
|
||||||
|
|
||||||
# When using -m32. Check this first as later checks may fail with the -m32 flag.
|
# Add the coverage flags early as they influence later checks.
|
||||||
if test "$CFG_ENABLE_M32" = "yes"; then
|
|
||||||
_MY_CXX_CHECK_IFELSE(
|
|
||||||
-m32,
|
|
||||||
[CXX="$CXX -m32"],
|
|
||||||
[AC_MSG_ERROR([--enable-m32 was given but compiler does not support -m32])])
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Similarly, add the coverage flags early as they influence later checks.
|
|
||||||
if test "$CFG_ENABLE_COVERAGE" = "yes"; then
|
if test "$CFG_ENABLE_COVERAGE" = "yes"; then
|
||||||
_MY_CXX_CHECK_OPT(CXX,--coverage)
|
_MY_CXX_CHECK_OPT(CXX,--coverage)
|
||||||
# Otherwise inline may not show as uncovered
|
# Otherwise inline may not show as uncovered
|
||||||
@@ -346,18 +330,16 @@ AC_SUBST(CFG_CXXFLAGS_PROFILE)
|
|||||||
|
|
||||||
# Flag to select newest language standard supported
|
# Flag to select newest language standard supported
|
||||||
# Macros work such that first option that passes is the one we take
|
# Macros work such that first option that passes is the one we take
|
||||||
# Currently enabled c++14 due to packaged SystemC dependency
|
# Currently enable c++17/c++14 due to packaged SystemC dependency
|
||||||
# c++14 is the newest that Verilator is regressed to support
|
# c++17 is the newest that Verilator is regularly tested to support
|
||||||
# c++11 is the oldest that Verilator supports
|
# c++14 is the oldest that Verilator supports
|
||||||
# gnu is requried for Cygwin to compile verilated.h successfully
|
# gnu is required for Cygwin to compile verilated.h successfully
|
||||||
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++20)
|
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++20)
|
||||||
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++20)
|
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++20)
|
||||||
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++17)
|
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++17)
|
||||||
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++17)
|
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++17)
|
||||||
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++14)
|
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++14)
|
||||||
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++14)
|
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++14)
|
||||||
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++11)
|
|
||||||
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++11)
|
|
||||||
AC_SUBST(CFG_CXXFLAGS_STD_NEWEST)
|
AC_SUBST(CFG_CXXFLAGS_STD_NEWEST)
|
||||||
|
|
||||||
# Flags for compiling Verilator internals including parser, and Verilated files
|
# Flags for compiling Verilator internals including parser, and Verilated files
|
||||||
@@ -368,6 +350,35 @@ _MY_CXX_CHECK_OPT(CFG_CXXFLAGS_WEXTRA,-Wlogical-op)
|
|||||||
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_WEXTRA,-Wthread-safety)
|
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_WEXTRA,-Wthread-safety)
|
||||||
AC_SUBST(CFG_CXXFLAGS_WEXTRA)
|
AC_SUBST(CFG_CXXFLAGS_WEXTRA)
|
||||||
|
|
||||||
|
# Flags for coroutine support for dynamic scheduling
|
||||||
|
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_COROUTINES,-fcoroutines-ts)
|
||||||
|
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_COROUTINES,-fcoroutines)
|
||||||
|
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_COROUTINES,-fcoroutines-ts -Wno-deprecated-experimental-coroutine)
|
||||||
|
AC_SUBST(CFG_CXXFLAGS_COROUTINES)
|
||||||
|
|
||||||
|
# HAVE_COROUTINES
|
||||||
|
# Check if coroutines are supported at all
|
||||||
|
AC_MSG_CHECKING([whether coroutines are supported by $CXX])
|
||||||
|
ACO_SAVE_CXXFLAGS="$CXXFLAGS"
|
||||||
|
CXXFLAGS="$CXXFLAGS $CFG_CXXFLAGS_COROUTINES"
|
||||||
|
AC_LINK_IFELSE(
|
||||||
|
[AC_LANG_PROGRAM([
|
||||||
|
#ifdef __clang__
|
||||||
|
#define __cpp_impl_coroutine 1
|
||||||
|
#endif
|
||||||
|
#include <coroutine>
|
||||||
|
],[[]])],
|
||||||
|
[_my_result=yes
|
||||||
|
AC_DEFINE([HAVE_COROUTINES],[1],[Defined if coroutines are supported by $CXX])],
|
||||||
|
[AC_LINK_IFELSE(
|
||||||
|
[AC_LANG_PROGRAM([#include <experimental/coroutine>],[[]])],
|
||||||
|
[_my_result=yes
|
||||||
|
AC_DEFINE([HAVE_COROUTINES],[1],[Defined if coroutines are supported by $CXX])],
|
||||||
|
[_my_result=no])])
|
||||||
|
AC_MSG_RESULT($_my_result)
|
||||||
|
CXXFLAGS="$ACO_SAVE_CXXFLAGS"
|
||||||
|
AC_SUBST(HAVE_COROUTINES)
|
||||||
|
|
||||||
# Flags for compiling Verilator internals including parser always
|
# Flags for compiling Verilator internals including parser always
|
||||||
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-Qunused-arguments)
|
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-Qunused-arguments)
|
||||||
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-faligned-new)
|
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-faligned-new)
|
||||||
@@ -410,14 +421,19 @@ m4_foreach([cflag],[
|
|||||||
[-mno-cet],
|
[-mno-cet],
|
||||||
[-Qunused-arguments],
|
[-Qunused-arguments],
|
||||||
[-Wno-bool-operation],
|
[-Wno-bool-operation],
|
||||||
[-Wno-tautological-bitwise-compare],
|
[-Wno-c++11-narrowing],
|
||||||
|
[-Wno-constant-logical-operand],
|
||||||
|
[-Wno-non-pod-varargs],
|
||||||
[-Wno-parentheses-equality],
|
[-Wno-parentheses-equality],
|
||||||
|
[-Wno-shadow],
|
||||||
[-Wno-sign-compare],
|
[-Wno-sign-compare],
|
||||||
|
[-Wno-tautological-bitwise-compare],
|
||||||
|
[-Wno-tautological-compare],
|
||||||
[-Wno-uninitialized],
|
[-Wno-uninitialized],
|
||||||
|
[-Wno-unused-but-set-parameter],
|
||||||
[-Wno-unused-but-set-variable],
|
[-Wno-unused-but-set-variable],
|
||||||
[-Wno-unused-parameter],
|
[-Wno-unused-parameter],
|
||||||
[-Wno-unused-variable],
|
[-Wno-unused-variable]],[
|
||||||
[-Wno-shadow]],[
|
|
||||||
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_NO_UNUSED,cflag)
|
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_NO_UNUSED,cflag)
|
||||||
# CMake will test what flags work itself, so pass all flags through to it
|
# CMake will test what flags work itself, so pass all flags through to it
|
||||||
CFG_CXX_FLAGS_CMAKE="$CFG_CXX_FLAGS_CMAKE cflag"
|
CFG_CXX_FLAGS_CMAKE="$CFG_CXX_FLAGS_CMAKE cflag"
|
||||||
@@ -438,6 +454,10 @@ m4_foreach([ldflag], [
|
|||||||
AC_SUBST(CFG_LDLIBS_THREADS)
|
AC_SUBST(CFG_LDLIBS_THREADS)
|
||||||
AC_SUBST(CFG_LDFLAGS_THREADS_CMAKE)
|
AC_SUBST(CFG_LDFLAGS_THREADS_CMAKE)
|
||||||
|
|
||||||
|
# If 'mold' is installed, use it to link for faster buildtimes
|
||||||
|
_MY_LDLIBS_CHECK_OPT(CFG_LDFLAGS_SRC, -fuse-ld=mold)
|
||||||
|
_MY_LDLIBS_CHECK_OPT(CFG_LDFLAGS_VERILATED, -fuse-ld=mold)
|
||||||
|
|
||||||
# When linking partially statically
|
# When linking partially statically
|
||||||
if test "$CFG_ENABLE_PARTIAL_STATIC" = "yes"; then
|
if test "$CFG_ENABLE_PARTIAL_STATIC" = "yes"; then
|
||||||
_MY_LDLIBS_CHECK_OPT(CFG_LDFLAGS_SRC, -static-libgcc)
|
_MY_LDLIBS_CHECK_OPT(CFG_LDFLAGS_SRC, -static-libgcc)
|
||||||
@@ -448,12 +468,14 @@ else
|
|||||||
LTCMALLOC=-ltcmalloc_minimal
|
LTCMALLOC=-ltcmalloc_minimal
|
||||||
fi
|
fi
|
||||||
AC_SUBST(CFG_LDFLAGS_SRC)
|
AC_SUBST(CFG_LDFLAGS_SRC)
|
||||||
|
AC_SUBST(CFG_LDFLAGS_VERILATED)
|
||||||
|
|
||||||
# The pthread library is required by tcmalloc, so add it if it exists. If it
|
# The pthread library is required by tcmalloc, so add it if it exists. If it
|
||||||
# does not, the tcmalloc check below will fail anyway, and linking against
|
# does not, the tcmalloc check below will fail anyway, and linking against
|
||||||
# pthreads is harmless otherwise.
|
# pthreads is harmless otherwise.
|
||||||
CFG_LIBS="$LIBS $CFG_LIBS"
|
CFG_LIBS="$LIBS $CFG_LIBS"
|
||||||
_MY_LDLIBS_CHECK_OPT(CFG_LIBS, -lpthread)
|
_MY_LDLIBS_CHECK_OPT(CFG_LIBS, -lpthread)
|
||||||
|
_MY_LDLIBS_CHECK_OPT(CFG_LIBS, -latomic)
|
||||||
|
|
||||||
# Check libraries for MingW
|
# Check libraries for MingW
|
||||||
_MY_LDLIBS_CHECK_OPT(CFG_LIBS, -lbcrypt)
|
_MY_LDLIBS_CHECK_OPT(CFG_LIBS, -lbcrypt)
|
||||||
@@ -476,14 +498,14 @@ _MY_LDLIBS_CHECK_IFELSE(
|
|||||||
fi])
|
fi])
|
||||||
AC_SUBST(CFG_LIBS)
|
AC_SUBST(CFG_LIBS)
|
||||||
|
|
||||||
# Need C++11 at least
|
# Need C++14 at least
|
||||||
#Alternative: AX_CXX_COMPILE_STDCXX([11])
|
#Alternative: AX_CXX_COMPILE_STDCXX([14])
|
||||||
AC_DEFUN([_MY_CXX_CHECK_CXX_VER],
|
AC_DEFUN([_MY_CXX_CHECK_CXX_VER],
|
||||||
[# _MY_CXX_CHECK_CXX_VER(flag) -- Check if compiler runs C++11
|
[# _MY_CXX_CHECK_CXX_VER(flag) -- Check if compiler runs C++14
|
||||||
# Set $_my_result
|
# Set $_my_result
|
||||||
AC_LINK_IFELSE(
|
AC_LINK_IFELSE(
|
||||||
[AC_LANG_PROGRAM([#include <thread>
|
[AC_LANG_PROGRAM([#include <thread>
|
||||||
#if (__cplusplus < 201103L)
|
#if (__cplusplus < 201402L)
|
||||||
# error "Too old"
|
# error "Too old"
|
||||||
#endif
|
#endif
|
||||||
], [[ ]])],
|
], [[ ]])],
|
||||||
@@ -496,23 +518,46 @@ AC_DEFUN([_MY_CXX_CHECK_CXX_VER],
|
|||||||
[_my_result=no])
|
[_my_result=no])
|
||||||
])
|
])
|
||||||
|
|
||||||
AC_MSG_CHECKING(whether $CXX supports C++11)
|
# Add $CFG_CXXFLAGS_STD only if can't compile correctly otherwise,
|
||||||
|
# as adding std= when not needed can cause errors with the C++ std library.
|
||||||
|
CFG_CXXFLAGS_STD=$CFG_CXXFLAGS_STD_NEWEST
|
||||||
|
AC_MSG_CHECKING(whether $CXX supports C++14)
|
||||||
_MY_CXX_CHECK_CXX_VER()
|
_MY_CXX_CHECK_CXX_VER()
|
||||||
AC_MSG_RESULT($_my_result)
|
AC_MSG_RESULT($_my_result)
|
||||||
if test "$_my_result" = "no" ; then
|
if test "$_my_result" = "no" ; then
|
||||||
CXXFLAGS="$CXXFLAGS $CFG_CXXFLAGS_STD_NEWEST"
|
CXXFLAGS="$CXXFLAGS $CFG_CXXFLAGS_STD"
|
||||||
CFG_CXX_FLAGS_CMAKE="$CFG_CXX_FLAGS_CMAKE $CFG_CXXFLAGS_STD_NEWEST"
|
CFG_CXX_FLAGS_CMAKE="$CFG_CXX_FLAGS_CMAKE $CFG_CXXFLAGS_STD"
|
||||||
AC_MSG_CHECKING(whether $CXX supports C++11 with $CFG_CXXFLAGS_STD_NEWEST)
|
AC_MSG_CHECKING(whether $CXX supports C++14 with $CFG_CXXFLAGS_STD)
|
||||||
_MY_CXX_CHECK_CXX_VER()
|
_MY_CXX_CHECK_CXX_VER()
|
||||||
AC_MSG_RESULT($_my_result)
|
AC_MSG_RESULT($_my_result)
|
||||||
|
else
|
||||||
|
# CFG_CXXFLAGS_STD is also propagated to include/verilated.mk.in
|
||||||
|
# make sure we use the same std flag while compiling verilator and verilated design
|
||||||
|
CFG_CXXFLAGS_STD=""
|
||||||
fi
|
fi
|
||||||
if test "$_my_result" = "no" ; then
|
if test "$_my_result" = "no" ; then
|
||||||
AC_MSG_NOTICE([[]])
|
AC_MSG_NOTICE([[]])
|
||||||
AC_MSG_ERROR([[the $CXX compiler appears to not support C++11.
|
AC_MSG_ERROR([[the $CXX compiler appears to not support C++14.
|
||||||
|
|
||||||
Verilator requires a C++11 or newer compiler.]])
|
Verilator requires a C++14 or newer compiler.]])
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
AC_SUBST(CFG_CXXFLAGS_STD)
|
||||||
|
|
||||||
|
# Compiler precompiled header options (assumes either gcc or clang++)
|
||||||
|
AC_MSG_CHECKING([for $CXX precompile header include option])
|
||||||
|
if $CXX --help | grep include-pch >/dev/null 2>/dev/null ; then
|
||||||
|
# clang
|
||||||
|
CFG_CXXFLAGS_PCH_I=-include-pch
|
||||||
|
CFG_GCH_IF_CLANG=.gch
|
||||||
|
else
|
||||||
|
# GCC
|
||||||
|
CFG_CXXFLAGS_PCH_I=-include
|
||||||
|
CFG_GCH_IF_CLANG=
|
||||||
|
fi
|
||||||
|
AC_MSG_RESULT($CFG_CXXFLAGS_PCH_I)
|
||||||
|
AC_SUBST(CFG_CXXFLAGS_PCH_I)
|
||||||
|
AC_SUBST(CFG_GCH_IF_CLANG)
|
||||||
|
|
||||||
# Checks for library functions.
|
# Checks for library functions.
|
||||||
AC_CHECK_MEMBER([struct stat.st_mtim.tv_nsec],
|
AC_CHECK_MEMBER([struct stat.st_mtim.tv_nsec],
|
||||||
@@ -528,7 +573,7 @@ ACO_SAVE_LIBS="$LIBS"
|
|||||||
LIBS="$LIBS -lsystemc"
|
LIBS="$LIBS -lsystemc"
|
||||||
AC_LINK_IFELSE(
|
AC_LINK_IFELSE(
|
||||||
[AC_LANG_PROGRAM([[#include <systemc.h>
|
[AC_LANG_PROGRAM([[#include <systemc.h>
|
||||||
extern "C" int sc_main(int argc, char* argv[]) {}
|
extern "C" int sc_main(int argc, char* argv[]) { return 0; }
|
||||||
]],[[sc_version()]])],
|
]],[[sc_version()]])],
|
||||||
[_my_result=yes
|
[_my_result=yes
|
||||||
AC_DEFINE([HAVE_SYSTEMC],[1],[Defined if have SystemC library])],
|
AC_DEFINE([HAVE_SYSTEMC],[1],[Defined if have SystemC library])],
|
||||||
|
|||||||
@@ -2,3 +2,4 @@
|
|||||||
*.html
|
*.html
|
||||||
*.pdf
|
*.pdf
|
||||||
_build
|
_build
|
||||||
|
guide/spelling.txt
|
||||||
|
|||||||
+22
-20
@@ -10,9 +10,12 @@ contributions flow more efficiently.
|
|||||||
Did you find a bug?
|
Did you find a bug?
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
- Please **Ensure the bug was not already reported** by searching
|
- Please **ensure the bug was not already reported** by searching
|
||||||
`Verilator Issues <https://verilator.org/issues>`__.
|
`Verilator Issues <https://verilator.org/issues>`__.
|
||||||
|
|
||||||
|
- Please **download the latest development GitHub version**, build, and see
|
||||||
|
if the issue has been fixed.
|
||||||
|
|
||||||
- If you're unable to find an open issue addressing the problem, `open a
|
- If you're unable to find an open issue addressing the problem, `open a
|
||||||
new Verilator issue <https://verilator.org/issues/new>`__.
|
new Verilator issue <https://verilator.org/issues/new>`__.
|
||||||
|
|
||||||
@@ -20,21 +23,28 @@ Did you find a bug?
|
|||||||
demonstrating the bug and expected behavior that is not occurring.
|
demonstrating the bug and expected behavior that is not occurring.
|
||||||
|
|
||||||
- The ideal example works against other simulators, and is in the
|
- The ideal example works against other simulators, and is in the
|
||||||
test_regress/t test format, as described in `docs/internals
|
test_regress/t test format, as described in
|
||||||
<internals.rst>`__.
|
`Verilator Internals Documentation
|
||||||
|
<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 bug?
|
||||||
---------------------------------------
|
---------------------------------------
|
||||||
|
|
||||||
- Please `Open a new issue <https://verilator.org/issues/new>`__.
|
- Please `Open a new Verilator issue <https://verilator.org/issues/new>`__
|
||||||
|
if there is not one already describing the bug.
|
||||||
|
|
||||||
- You may attach a patch to the issue, or (preferred) may request a
|
- Please `Open a Verilator pull request
|
||||||
GitHub pull request.
|
<https://github.com/verilator/verilator/pulls>`__.
|
||||||
|
|
||||||
- Verilator uses GitHub Actions to provide continuous integration. You
|
- See the coding conventions, and other developer information in
|
||||||
may want to enable Actions on your GitHub branch to ensure your changes
|
``docs/internals.rst`` in the distribution, or as rendered at
|
||||||
keep the tests passing. See `docs/internals <internals.rst>`__.
|
`Verilator Internals Documentation
|
||||||
|
<https://github.com/verilator/verilator/blob/master/docs/internals.rst>`__.
|
||||||
|
|
||||||
|
- Verilator uses GitHub Actions to provide continuous integration. You
|
||||||
|
may want to enable Actions on your GitHub branch to ensure your changes
|
||||||
|
keep the tests passing.
|
||||||
|
|
||||||
- Your source-code contributions must be certified as open source,
|
- Your source-code contributions must be certified as open source,
|
||||||
under the `Developer Certificate of
|
under the `Developer Certificate of
|
||||||
@@ -44,15 +54,10 @@ Did you write a patch that fixes a bug?
|
|||||||
- Have your patch include the addition of your name to `docs/CONTRIBUTORS
|
- Have your patch include the addition of your name to `docs/CONTRIBUTORS
|
||||||
<CONTRIBUTORS>`__ (preferred).
|
<CONTRIBUTORS>`__ (preferred).
|
||||||
|
|
||||||
- Use "git -s" as part of your commit. This adds a "signed-of-by"
|
|
||||||
attribute which will certify your contribution as described in the
|
|
||||||
`Signed-of-By convention
|
|
||||||
<https://github.com/wking/signed-off-by/blob/master/Documentation/SubmittingPatches>`__.
|
|
||||||
|
|
||||||
- Email, or post in an issue a statement that you certify your
|
- Email, or post in an issue a statement that you certify your
|
||||||
contributions.
|
contributions.
|
||||||
|
|
||||||
- In any of these cases your name will be added to `docs/CONTRIBUTORS
|
- In any of these cases, your name will be added to `docs/CONTRIBUTORS
|
||||||
<CONTRIBUTORS>`__ and you are agreeing all future contributions are
|
<CONTRIBUTORS>`__ and you are agreeing all future contributions are
|
||||||
also certified.
|
also certified.
|
||||||
|
|
||||||
@@ -61,13 +66,10 @@ Did you write a patch that fixes a bug?
|
|||||||
contribution.
|
contribution.
|
||||||
|
|
||||||
- Your test contributions are generally considered released into the
|
- Your test contributions are generally considered released into the
|
||||||
Creative Commons Public Domain (CC0), unless you request otherwise or
|
Creative Commons Public Domain (CC0), unless you request otherwise, or
|
||||||
put a GNU/Artistic license on your file.
|
put a GNU/Artistic license on your file.
|
||||||
|
|
||||||
- Most important is we get your patch. If you’d like to clean up
|
- Most important is we get your patch.
|
||||||
indentation and related issues ahead of our feedback, that is
|
|
||||||
appreciated; please see the coding conventions in `docs/internals
|
|
||||||
<internals.rst>`__.
|
|
||||||
|
|
||||||
|
|
||||||
Do you have questions?
|
Do you have questions?
|
||||||
|
|||||||
@@ -3,76 +3,149 @@ under the Developer Certificate of Origin (https://developercertificate.org/).
|
|||||||
|
|
||||||
Please see the Verilator manual for 200+ additional contributors. Thanks to all.
|
Please see the Verilator manual for 200+ additional contributors. Thanks to all.
|
||||||
|
|
||||||
|
Adam Bagley
|
||||||
|
Adrian Sampson
|
||||||
|
Adrien Le Masle
|
||||||
Ahmed El-Mahmoudy
|
Ahmed El-Mahmoudy
|
||||||
|
Aleksander Kiryk
|
||||||
Alex Chadwick
|
Alex Chadwick
|
||||||
Àlex Torregrosa
|
Àlex Torregrosa
|
||||||
|
Aliaksei Chapyzhenka
|
||||||
Ameya Vikram Singh
|
Ameya Vikram Singh
|
||||||
Andreas Kuster
|
Andreas Kuster
|
||||||
|
Andrei Kostovski
|
||||||
|
Andrew Miloradovsky
|
||||||
|
Andrew Nolte
|
||||||
|
Anthony Donlon
|
||||||
|
Arkadiusz Kozdra
|
||||||
|
Aylon Chaim Porat
|
||||||
|
Bartłomiej Chmiel
|
||||||
|
Cameron Kirk
|
||||||
|
Chih-Mao Chen
|
||||||
Chris Randall
|
Chris Randall
|
||||||
|
Chuxuan Wang
|
||||||
|
Chykon
|
||||||
Conor McCullough
|
Conor McCullough
|
||||||
Dan Petrisko
|
Dan Petrisko
|
||||||
Daniel Bates
|
Daniel Bates
|
||||||
David Horton
|
David Horton
|
||||||
|
David Ledger
|
||||||
David Metz
|
David Metz
|
||||||
David Stanford
|
David Stanford
|
||||||
David Turner
|
David Turner
|
||||||
|
Don Williamson
|
||||||
|
Drew Ranck
|
||||||
Drew Taussig
|
Drew Taussig
|
||||||
Driss Hafdi
|
Driss Hafdi
|
||||||
Edgar E. Iglesias
|
Edgar E. Iglesias
|
||||||
Eric Rippey
|
Eric Rippey
|
||||||
|
Ethan Sifferman
|
||||||
|
Eyck Jentzsch
|
||||||
Fan Shupei
|
Fan Shupei
|
||||||
|
february cozzocrea
|
||||||
|
Felix Neumärker
|
||||||
Felix Yan
|
Felix Yan
|
||||||
|
Frans Skarman
|
||||||
|
Fuad Ismail
|
||||||
|
G-A. Kamendje
|
||||||
Garrett Smith
|
Garrett Smith
|
||||||
Geza Lore
|
Geza Lore
|
||||||
Gianfranco Costamagna
|
Gianfranco Costamagna
|
||||||
Glen Gibb
|
Glen Gibb
|
||||||
|
Gökçe Aydos
|
||||||
Graham Rushton
|
Graham Rushton
|
||||||
|
Guokai Chen
|
||||||
|
Gus Smith
|
||||||
|
Gustav Svensk
|
||||||
Harald Heckmann
|
Harald Heckmann
|
||||||
|
Hennadii Chernyshchyk
|
||||||
Howard Su
|
Howard Su
|
||||||
Huang Rui
|
Huang Rui
|
||||||
|
Huanghuang Zhou
|
||||||
|
HungMingWu
|
||||||
HyungKi Jeong
|
HyungKi Jeong
|
||||||
|
Ícaro Lima
|
||||||
|
Ilya Barkov
|
||||||
Iru Cai
|
Iru Cai
|
||||||
Ivan Vnučec
|
Ivan Vnučec
|
||||||
Iztok Jeras
|
Iztok Jeras
|
||||||
|
Jake Merdich
|
||||||
James Hanlon
|
James Hanlon
|
||||||
James Hutchinson
|
James Hutchinson
|
||||||
James Pallister
|
James Pallister
|
||||||
|
James Shi
|
||||||
Jamey Hicks
|
Jamey Hicks
|
||||||
|
Jamie Iles
|
||||||
Jan Van Winkel
|
Jan Van Winkel
|
||||||
|
Jiangjie Weng
|
||||||
Jean Berniolles
|
Jean Berniolles
|
||||||
Jeremy Bennett
|
Jeremy Bennett
|
||||||
|
Jesse Taube
|
||||||
|
Jevin Sweval
|
||||||
|
Jiacheng Qian
|
||||||
|
Jiamin Zhu
|
||||||
|
Jinyan Xu
|
||||||
|
Jiuyang Liu
|
||||||
|
Joey Liu
|
||||||
John Coiner
|
John Coiner
|
||||||
John Demme
|
John Demme
|
||||||
|
John Wehle
|
||||||
Jonathan Drolet
|
Jonathan Drolet
|
||||||
|
Jonathan Schröter
|
||||||
|
Jordan McConnon
|
||||||
|
Jose Loyola
|
||||||
|
Josep Sans
|
||||||
|
Joseph Nwabueze
|
||||||
Josh Redford
|
Josh Redford
|
||||||
|
Julian Daube
|
||||||
Julie Schwartz
|
Julie Schwartz
|
||||||
Julien Margetts
|
Julien Margetts
|
||||||
|
Justin Thiel
|
||||||
Kaleb Barrett
|
Kaleb Barrett
|
||||||
|
Kamil Rakoczy
|
||||||
Kanad Kanhere
|
Kanad Kanhere
|
||||||
|
Kefa Chen
|
||||||
Keith Colbert
|
Keith Colbert
|
||||||
Kevin Kiningham
|
Kevin Kiningham
|
||||||
|
Kevin Nygaard
|
||||||
|
Kritik Bhimani
|
||||||
Krzysztof Bieganski
|
Krzysztof Bieganski
|
||||||
|
Krzysztof Boronski
|
||||||
|
Krzysztof Boroński
|
||||||
Kuba Ober
|
Kuba Ober
|
||||||
|
Larry Doolittle
|
||||||
Ludwig Rogiers
|
Ludwig Rogiers
|
||||||
Lukasz Dalek
|
Lukasz Dalek
|
||||||
Maarten De Braekeleer
|
Maarten De Braekeleer
|
||||||
Maciej Sobkowski
|
Maciej Sobkowski
|
||||||
|
Marcel Chang
|
||||||
Marco Widmer
|
Marco Widmer
|
||||||
|
Mariusz Glebocki
|
||||||
Markus Krause
|
Markus Krause
|
||||||
Marlon James
|
Marlon James
|
||||||
Marshal Qiao
|
Marshal Qiao
|
||||||
Martin Schmidt
|
Martin Schmidt
|
||||||
|
Martin Stadler
|
||||||
Matthew Ballance
|
Matthew Ballance
|
||||||
Michael Killough
|
Michael Killough
|
||||||
Michaël Lefebvre
|
Michaël Lefebvre
|
||||||
|
Michal Czyz
|
||||||
Mike Popoloski
|
Mike Popoloski
|
||||||
Miodrag Milanović
|
Miodrag Milanović
|
||||||
|
Mladen Slijepcevic
|
||||||
Morten Borup Petersen
|
Morten Borup Petersen
|
||||||
|
Mostafa Gamal
|
||||||
Nandu Raj
|
Nandu Raj
|
||||||
Nathan Kohagen
|
Nathan Kohagen
|
||||||
Nathan Myers
|
Nathan Myers
|
||||||
|
Nolan Poe
|
||||||
|
Oleh Maksymenko
|
||||||
Patrick Stewart
|
Patrick Stewart
|
||||||
|
Paul Swirhun
|
||||||
Paul Wright
|
Paul Wright
|
||||||
|
Pawel Sagan
|
||||||
|
Pengcheng Xu
|
||||||
|
Peter Debacker
|
||||||
Peter Horvath
|
Peter Horvath
|
||||||
Peter Monsson
|
Peter Monsson
|
||||||
Philipp Wagner
|
Philipp Wagner
|
||||||
@@ -80,31 +153,55 @@ Pierre-Henri Horrein
|
|||||||
Pieter Kapsenberg
|
Pieter Kapsenberg
|
||||||
Piotr Binkowski
|
Piotr Binkowski
|
||||||
Qingyao Sun
|
Qingyao Sun
|
||||||
|
Quentin Corradi
|
||||||
Rafal Kapuscik
|
Rafal Kapuscik
|
||||||
|
Rasfunk
|
||||||
|
Raynard Qiao
|
||||||
Richard Myers
|
Richard Myers
|
||||||
|
Risto Pejašinović
|
||||||
|
Robert Balas
|
||||||
Rupert Swarbrick
|
Rupert Swarbrick
|
||||||
|
Ryszard Rozak
|
||||||
Samuel Riedel
|
Samuel Riedel
|
||||||
Sean Cross
|
Sean Cross
|
||||||
Sebastien Van Cauwenberghe
|
Sebastien Van Cauwenberghe
|
||||||
Sergi Granell
|
Sergi Granell
|
||||||
|
Srinivasan Venkataramanan
|
||||||
Stefan Wallentowitz
|
Stefan Wallentowitz
|
||||||
Stephen Henry
|
Stephen Henry
|
||||||
Steven Hugg
|
Steven Hugg
|
||||||
|
Szymon Gizler
|
||||||
|
Sören Tempel
|
||||||
Teng Huang
|
Teng Huang
|
||||||
|
Tim Hutt
|
||||||
Tim Snyder
|
Tim Snyder
|
||||||
Tobias Rosenkranz
|
Tobias Rosenkranz
|
||||||
Tobias Wölfel
|
Tobias Wölfel
|
||||||
Todd Strader
|
Todd Strader
|
||||||
Tomasz Gorochowik
|
Tomasz Gorochowik
|
||||||
|
Topa Topino
|
||||||
|
Toru Niina
|
||||||
|
Tudor Timi
|
||||||
Tymoteusz Blazejczyk
|
Tymoteusz Blazejczyk
|
||||||
Udi Finkelstein
|
Udi Finkelstein
|
||||||
Unai Martinez-Corral
|
Unai Martinez-Corral
|
||||||
|
Varun Koyyalagunta
|
||||||
Vassilis Papaefstathiou
|
Vassilis Papaefstathiou
|
||||||
Veripool API Bot
|
Veripool API Bot
|
||||||
Victor Besyakov
|
Victor Besyakov
|
||||||
|
Vito Gamberini
|
||||||
|
William D. Jones
|
||||||
Wilson Snyder
|
Wilson Snyder
|
||||||
|
Xi Zhang
|
||||||
|
Yan Xu
|
||||||
|
Yinan Xu
|
||||||
|
Yoda Lee
|
||||||
Yossi Nivin
|
Yossi Nivin
|
||||||
|
Yu-Sheng Lin
|
||||||
Yuri Victorovich
|
Yuri Victorovich
|
||||||
Yutetsu TAKATSUKASA
|
Yutetsu TAKATSUKASA
|
||||||
Yves Mathieu
|
Yves Mathieu
|
||||||
Zhanglei Wang
|
Zhanglei Wang
|
||||||
|
Zhou Shen
|
||||||
|
Zixi Li
|
||||||
|
أحمد المحمودي
|
||||||
|
|||||||
+8
-2
@@ -5,7 +5,7 @@
|
|||||||
#
|
#
|
||||||
# Code available from: https://verilator.org
|
# Code available from: https://verilator.org
|
||||||
#
|
#
|
||||||
# Copyright 2003-2021 by Wilson Snyder. This program is free software; you
|
# Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||||
# can redistribute it and/or modify it under the terms of either the GNU
|
# 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
|
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
# Version 2.0.
|
# Version 2.0.
|
||||||
@@ -18,12 +18,16 @@
|
|||||||
RST2HTML = rst2html
|
RST2HTML = rst2html
|
||||||
PYTHON3 = python3
|
PYTHON3 = python3
|
||||||
DOXYGEN = doxygen
|
DOXYGEN = doxygen
|
||||||
SPHINXOPTS ?= -c guide
|
|
||||||
SPHINXBUILD ?= sphinx-build
|
SPHINXBUILD ?= sphinx-build
|
||||||
|
|
||||||
SOURCEDIR = guide
|
SOURCEDIR = guide
|
||||||
BUILDDIR = _build
|
BUILDDIR = _build
|
||||||
|
|
||||||
|
SPHINXOPTS ?= -c guide
|
||||||
|
ifneq ($(VERILATOR_ANALYTICS_ID),)
|
||||||
|
SPHINXOPTS += -D html_theme_options.analytics_id=$(VERILATOR_ANALYTICS_ID)
|
||||||
|
endif
|
||||||
|
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
.SUFFIXES:
|
.SUFFIXES:
|
||||||
@@ -35,6 +39,7 @@ default:
|
|||||||
# Intermediate rules
|
# Intermediate rules
|
||||||
|
|
||||||
vl-extract: ../bin/verilator ../Changes
|
vl-extract: ../bin/verilator ../Changes
|
||||||
|
ln -sf ../spelling.txt guide/spelling.txt
|
||||||
mkdir -p _build/gen
|
mkdir -p _build/gen
|
||||||
$(PYTHON3) bin/vl_sphinx_extract ../bin/verilator
|
$(PYTHON3) bin/vl_sphinx_extract ../bin/verilator
|
||||||
sed 's/`/\&96;/g' < ../Changes > _build/gen/Changes
|
sed 's/`/\&96;/g' < ../Changes > _build/gen/Changes
|
||||||
@@ -77,6 +82,7 @@ clean mostlyclean distclean maintainer-clean::
|
|||||||
rm -f *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs *.idx
|
rm -f *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs *.idx
|
||||||
rm -f *.ev *.evs *.ov *.ovs *.cv *.cvs *.ma *.mas
|
rm -f *.ev *.evs *.ov *.ovs *.cv *.cvs *.ma *.mas
|
||||||
rm -f *.tex
|
rm -f *.tex
|
||||||
|
rm -f guide/spelling.txt
|
||||||
|
|
||||||
distclean maintainer-clean::
|
distclean maintainer-clean::
|
||||||
rm -f *.info* *.1 *.html *.pdf $(INFOS)
|
rm -f *.info* *.1 *.html *.pdf $(INFOS)
|
||||||
|
|||||||
@@ -0,0 +1,21 @@
|
|||||||
|
Verilator Documentation
|
||||||
|
=======================
|
||||||
|
|
||||||
|
This folder contains sources for Verilator documentation.
|
||||||
|
|
||||||
|
For formatted documentation see:
|
||||||
|
|
||||||
|
- `Verilator README <https://github.com/verilator/verilator>`_
|
||||||
|
|
||||||
|
- `Verilator installation and package directory structure
|
||||||
|
<https://verilator.org/install>`_
|
||||||
|
|
||||||
|
- `Verilator manual (HTML) <https://verilator.org/verilator_doc.html>`_,
|
||||||
|
or `Verilator manual (PDF) <https://verilator.org/verilator_doc.pdf>`_
|
||||||
|
|
||||||
|
- `Subscribe to Verilator announcements
|
||||||
|
<https://github.com/verilator/verilator-announce>`_
|
||||||
|
|
||||||
|
- `Verilator forum <https://verilator.org/forum>`_
|
||||||
|
|
||||||
|
- `Verilator issues <https://verilator.org/issues>`_
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# pylint: disable=C0112,C0114,C0115,C0116,C0301,R0201,R0903
|
# pylint: disable=C0112,C0114,C0115,C0116,C0209,C0301,R0903
|
||||||
# -*- Python -*- See copyright, etc below
|
# -*- Python -*- See copyright, etc below
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
@@ -14,7 +14,7 @@ class VlSphinxExtract:
|
|||||||
SkipBasenames = {}
|
SkipBasenames = {}
|
||||||
|
|
||||||
def process(self, filename):
|
def process(self, filename):
|
||||||
with open(filename) as fhr:
|
with open(filename, "r", encoding="utf8") as fhr:
|
||||||
fhw = None
|
fhw = None
|
||||||
for line in fhr:
|
for line in fhr:
|
||||||
# =for VL_SPHINX_EXTRACT "file_to_write_to"
|
# =for VL_SPHINX_EXTRACT "file_to_write_to"
|
||||||
@@ -22,7 +22,7 @@ class VlSphinxExtract:
|
|||||||
if match:
|
if match:
|
||||||
outname = match.group(1)
|
outname = match.group(1)
|
||||||
print("Writing %s" % outname)
|
print("Writing %s" % outname)
|
||||||
fhw = open(outname, "w")
|
fhw = open(outname, "w", encoding="utf8") # pylint: disable=consider-using-with
|
||||||
fhw.write(
|
fhw.write(
|
||||||
".. comment: generated by vl_sphinx_extract from " +
|
".. comment: generated by vl_sphinx_extract from " +
|
||||||
filename + "\n")
|
filename + "\n")
|
||||||
@@ -40,7 +40,7 @@ parser = argparse.ArgumentParser(
|
|||||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||||
description="""Read a file and extract documentation data.""",
|
description="""Read a file and extract documentation data.""",
|
||||||
epilog=
|
epilog=
|
||||||
""" Copyright 2021-2021 by Wilson Snyder. This package is free software;
|
""" Copyright 2021-2024 by Wilson Snyder. This package is free software;
|
||||||
you can redistribute it and/or modify it under the terms of either the GNU
|
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
|
Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
Version 2.0.
|
Version 2.0.
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# pylint: disable=C0112,C0114,C0115,C0116,C0301,R0903
|
# pylint: disable=C0112,C0114,C0115,C0116,C0209,C0301,R0903
|
||||||
# -*- Python -*- See copyright, etc below
|
# -*- Python -*- See copyright, etc below
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
@@ -27,7 +27,7 @@ class VlSphinxFix:
|
|||||||
|
|
||||||
def _edit(self, filename):
|
def _edit(self, filename):
|
||||||
is_html = re.search(r'\.(html)$', filename)
|
is_html = re.search(r'\.(html)$', filename)
|
||||||
with open(filename) as fhr:
|
with open(filename, "r", encoding="utf8") as fhr:
|
||||||
origfile = fhr.read()
|
origfile = fhr.read()
|
||||||
wholefile = origfile
|
wholefile = origfile
|
||||||
# Option doesn't like spaces, so we use
|
# Option doesn't like spaces, so we use
|
||||||
@@ -43,7 +43,7 @@ class VlSphinxFix:
|
|||||||
if self.debug:
|
if self.debug:
|
||||||
print("Edit %s" % filename)
|
print("Edit %s" % filename)
|
||||||
tempname = filename + ".tmp"
|
tempname = filename + ".tmp"
|
||||||
with open(tempname, "w") as fhw:
|
with open(tempname, "w", encoding="utf8") as fhw:
|
||||||
fhw.write(wholefile)
|
fhw.write(wholefile)
|
||||||
os.rename(tempname, filename)
|
os.rename(tempname, filename)
|
||||||
|
|
||||||
@@ -55,7 +55,7 @@ parser = argparse.ArgumentParser(
|
|||||||
formatter_class=argparse.RawDescriptionHelpFormatter,
|
formatter_class=argparse.RawDescriptionHelpFormatter,
|
||||||
description="""Post-process Sphinx HTML.""",
|
description="""Post-process Sphinx HTML.""",
|
||||||
epilog=
|
epilog=
|
||||||
""" Copyright 2021-2021 by Wilson Snyder. This package is free software;
|
""" Copyright 2021-2024 by Wilson Snyder. This package is free software;
|
||||||
you can redistribute it and/or modify it under the terms of either the GNU
|
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
|
Lesser General Public License Version 3 or the Perl Artistic License
|
||||||
Version 2.0.
|
Version 2.0.
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
.. comment: generated by t_lint_didnotconverge_bad
|
.. comment: generated by t_lint_didnotconverge_bad
|
||||||
.. code-block::
|
.. code-block::
|
||||||
|
|
||||||
-V{t#,#}+ Vt_lint_didnotconverge_bad___024root___change_request
|
-V{t#,#} 'stl' region trigger index 1 is active: @([hybrid] a)
|
||||||
-V{t#,#}+ Vt_lint_didnotconverge_bad___024root___change_request_1
|
%Error: t/t_lint_didnotconverge_bad.v:7: Settle region did not converge.
|
||||||
-V{t#,#} CHANGE: t/t_lint_didnotconverge_bad.v:14: a
|
|
||||||
%Error: t/t_lint_didnotconverge_bad.v:7: Verilated model didn't converge
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. comment: generated by t_lint_didnotconverge_nodbg_bad
|
.. comment: generated by t_lint_didnotconverge_nodbg_bad
|
||||||
.. code-block::
|
.. code-block::
|
||||||
|
|
||||||
%Error: t/t_lint_didnotconverge_bad.v:7: Verilated model didn't converge
|
%Error: t/t_lint_didnotconverge_bad.v:7: Settle region did not converge.
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. comment: generated by t_lint_stmtdly_bad
|
.. comment: generated by t_lint_stmtdly_bad
|
||||||
.. code-block::
|
.. code-block::
|
||||||
|
|
||||||
%Warning-STMTDLY: example.v:1:8 Unsupported: Ignoring delay on this delayed statement.
|
%Warning-STMTDLY: example.v:1:7 Ignoring delay on this statement due to --no-timing
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. comment: generated by t_lint_width_docs_bad
|
.. comment: generated by t_lint_widthexpand_docs_bad
|
||||||
.. code-block:: sv
|
.. code-block:: sv
|
||||||
:linenos:
|
:linenos:
|
||||||
:emphasize-lines: 3
|
:emphasize-lines: 3
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
.. comment: generated by t_lint_width_docs_bad
|
.. comment: generated by t_lint_widthexpand_docs_bad
|
||||||
.. code-block:: sv
|
.. code-block:: sv
|
||||||
:emphasize-lines: 1
|
:emphasize-lines: 1
|
||||||
|
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
.. comment: generated by t_lint_widthexpand_docs_bad
|
||||||
|
.. code-block::
|
||||||
|
|
||||||
|
%Warning-WIDTHEXPAND: example.v:3:29 Bit extraction of array[4:0] requires 3 bit index, not 2 bits.
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
.. comment: generated by t_lint_width_docs_bad
|
|
||||||
.. code-block::
|
|
||||||
|
|
||||||
%Warning-WIDTH: example.v:3:29 Bit extraction of array[4:0] requires 3 bit index, not 2 bits.
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
****************
|
****************
|
||||||
@@ -10,7 +10,7 @@ Revision History
|
|||||||
"Revision History" in the sidebar.
|
"Revision History" in the sidebar.
|
||||||
|
|
||||||
Changes are contained in the :file:`Changes` file of the distribution, and
|
Changes are contained in the :file:`Changes` file of the distribution, and
|
||||||
also summarized below. To subscribe to new versions see `Verilator
|
also summarized below. To subscribe to new versions, see `Verilator
|
||||||
Announcements <https://github.com/verilator/verilator-announce>`_.
|
Announcements <https://github.com/verilator/verilator-announce>`_.
|
||||||
|
|
||||||
.. include:: ../_build/gen/Changes
|
.. include:: ../_build/gen/Changes
|
||||||
|
|||||||
+18
-13
@@ -1,6 +1,7 @@
|
|||||||
# pylint: disable=C0103,C0114,C0116,C0301,E0402,W0622
|
# pylint: disable=C0103,C0114,C0116,C0301,E0402,W0622
|
||||||
#
|
#
|
||||||
# Configuration file for Verilator's Sphinx documentation builder.
|
# Configuration file for Verilator's Sphinx documentation builder.
|
||||||
|
# Copyright 2003-2024 by Wilson Snyder.
|
||||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
#
|
#
|
||||||
# This file only contains overridden options. For a full list:
|
# This file only contains overridden options. For a full list:
|
||||||
@@ -9,10 +10,10 @@
|
|||||||
# ----------------------------------------------------------------------
|
# ----------------------------------------------------------------------
|
||||||
# -- Path setup
|
# -- Path setup
|
||||||
|
|
||||||
from datetime import datetime
|
|
||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
sys.path.insert(0, os.path.abspath('./_ext'))
|
sys.path.insert(0, os.path.abspath('./_ext'))
|
||||||
|
|
||||||
import sphinx_rtd_theme # pylint: disable=wrong-import-position,
|
import sphinx_rtd_theme # pylint: disable=wrong-import-position,
|
||||||
@@ -20,12 +21,20 @@ import sphinx_rtd_theme # pylint: disable=wrong-import-position,
|
|||||||
|
|
||||||
def get_vlt_version():
|
def get_vlt_version():
|
||||||
filename = "../../Makefile"
|
filename = "../../Makefile"
|
||||||
with open(filename) as fh:
|
with open(filename, "r", encoding="utf8") as fh:
|
||||||
for line in fh:
|
for line in fh:
|
||||||
match = re.search(r"PACKAGE_VERSION_NUMBER *= *([a-z0-9.]+)", line)
|
match = re.search(r"PACKAGE_VERSION *= *([a-z0-9.]+) +([-0-9]+)",
|
||||||
|
line)
|
||||||
if match:
|
if match:
|
||||||
return match.group(1)
|
return match.group(1), match.group(2)
|
||||||
return "unknown"
|
match = re.search(r"PACKAGE_VERSION *= *([a-z0-9.]+) +devel", line)
|
||||||
|
if match:
|
||||||
|
try:
|
||||||
|
data = os.popen('git log -n 1 --pretty=%cs').read()
|
||||||
|
except Exception: # pylint: disable=broad-except
|
||||||
|
data = "" # fallback, and Sphinx will fill in today's date
|
||||||
|
return "Devel " + match.group(1), data
|
||||||
|
return "unknown", "unknown"
|
||||||
|
|
||||||
|
|
||||||
def setup(app):
|
def setup(app):
|
||||||
@@ -36,14 +45,14 @@ def setup(app):
|
|||||||
# -- Project information
|
# -- Project information
|
||||||
|
|
||||||
project = 'Verilator'
|
project = 'Verilator'
|
||||||
copyright = '2021 by Wilson Snyder, under LGPL-3.0 or Artistic-2.0'
|
copyright = '2024 by Wilson Snyder, under LGPL-3.0 or Artistic-2.0'
|
||||||
author = 'Wilson Snyder'
|
author = 'Wilson Snyder'
|
||||||
|
|
||||||
# The master toctree document.
|
# The master toctree document.
|
||||||
master_doc = "index"
|
master_doc = "index"
|
||||||
|
|
||||||
version = get_vlt_version()
|
version, today_fmt = get_vlt_version()
|
||||||
release = get_vlt_version()
|
release = version
|
||||||
|
|
||||||
rst_prolog = """
|
rst_prolog = """
|
||||||
.. role:: vlopt(option)
|
.. role:: vlopt(option)
|
||||||
@@ -87,9 +96,6 @@ source_suffix = [".rst"]
|
|||||||
# Add any paths that contain templates here, relative to this directory.
|
# Add any paths that contain templates here, relative to this directory.
|
||||||
templates_path = ['_templates']
|
templates_path = ['_templates']
|
||||||
|
|
||||||
# Date format to ISO
|
|
||||||
today_fmt = datetime.now().strftime("%F")
|
|
||||||
|
|
||||||
# If true, `todo` and `todoList` produce output, else they produce nothing.
|
# If true, `todo` and `todoList` produce output, else they produce nothing.
|
||||||
todo_include_todos = True
|
todo_include_todos = True
|
||||||
|
|
||||||
@@ -109,7 +115,6 @@ html_theme = 'sphinx_rtd_theme'
|
|||||||
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
|
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
|
||||||
|
|
||||||
html_theme_options = {
|
html_theme_options = {
|
||||||
'analytics_id': 'G-D27B0C9QEB',
|
|
||||||
'logo_only': True,
|
'logo_only': True,
|
||||||
'style_nav_header_background': "#45acf8", # Default is #2980B9
|
'style_nav_header_background': "#45acf8", # Default is #2980B9
|
||||||
# 'canonical_url':
|
# 'canonical_url':
|
||||||
@@ -225,4 +230,4 @@ spelling_ignore_contributor_names = True
|
|||||||
|
|
||||||
breathe_projects = {"verilated": "_build/doxygen/verilated/xml/"}
|
breathe_projects = {"verilated": "_build/doxygen/verilated/xml/"}
|
||||||
breathe_default_project = "verilated"
|
breathe_default_project = "verilated"
|
||||||
breathe_default_members = ('members')
|
breathe_default_members = 'members'
|
||||||
|
|||||||
+105
-74
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. _Connecting:
|
.. _Connecting:
|
||||||
@@ -51,8 +51,8 @@ also the instance of the top level instance in the design hierarchy (what
|
|||||||
you would refer to with :code:`$root` in SystemVerilog). This meant that
|
you would refer to with :code:`$root` in SystemVerilog). This meant that
|
||||||
all internal variables that were implemented by Verilator in the root scope
|
all internal variables that were implemented by Verilator in the root scope
|
||||||
were accessible as members of the model class itself. Note there were often
|
were accessible as members of the model class itself. Note there were often
|
||||||
many such variable due to module inlining, including :code:`/* verilator
|
many such variable due to module inlining, including
|
||||||
public_flat */` items.
|
:code:`/* verilator public_flat */` items.
|
||||||
|
|
||||||
This means that user code that accesses internal signals in the model
|
This means that user code that accesses internal signals in the model
|
||||||
(likely including :code:`/* verilator public_flat */` signals, as they are
|
(likely including :code:`/* verilator public_flat */` signals, as they are
|
||||||
@@ -86,58 +86,20 @@ Connecting to C++
|
|||||||
In C++ output mode (:vlopt:`--cc`), the Verilator generated model class is a
|
In C++ output mode (:vlopt:`--cc`), the Verilator generated model class is a
|
||||||
simple C++ class. The user must write a C++ wrapper and main loop for the
|
simple C++ class. The user must write a C++ wrapper and main loop for the
|
||||||
simulation, which instantiates the model class, and link with the Verilated
|
simulation, which instantiates the model class, and link with the Verilated
|
||||||
model. Here is a simple example:
|
model.
|
||||||
|
|
||||||
.. code-block:: C++
|
Refer to ``examples/make_tracing_c`` in the distribution for a detailed
|
||||||
|
commented example.
|
||||||
|
|
||||||
#include <verilated.h> // Defines common routines
|
Top level IO signals are read and written as members of the model. You
|
||||||
#include <iostream> // Need std::cout
|
call the model's :code:`eval()` method to evaluate the model. When the
|
||||||
#include "Vtop.h" // From Verilating "top.v"
|
simulation is complete call the model's :code:`final()` method to execute
|
||||||
|
any SystemVerilog final blocks, and complete any assertions. If using
|
||||||
|
:vlopt:`--timing`, there are two additional functions for checking if
|
||||||
|
there are any events pending in the simulation due to delays, and for
|
||||||
|
retrieving the simulation time of the next delayed event. See
|
||||||
|
:ref:`Evaluation Loop`.
|
||||||
|
|
||||||
Vtop *top; // Instantiation of model
|
|
||||||
|
|
||||||
vluint64_t main_time = 0; // Current simulation time
|
|
||||||
// This is a 64-bit integer to reduce wrap over issues and
|
|
||||||
// allow modulus. This is in units of the timeprecision
|
|
||||||
// used in Verilog (or from --timescale-override)
|
|
||||||
|
|
||||||
double sc_time_stamp() { // Called by $time in Verilog
|
|
||||||
return main_time; // converts to double, to match
|
|
||||||
// what SystemC does
|
|
||||||
}
|
|
||||||
|
|
||||||
int main(int argc, char** argv) {
|
|
||||||
Verilated::commandArgs(argc, argv); // Remember args
|
|
||||||
|
|
||||||
top = new Vtop; // Create model
|
|
||||||
|
|
||||||
top->reset_l = 0; // Set some inputs
|
|
||||||
|
|
||||||
while (!Verilated::gotFinish()) {
|
|
||||||
if (main_time > 10) {
|
|
||||||
top->reset_l = 1; // Deassert reset
|
|
||||||
}
|
|
||||||
if ((main_time % 10) == 1) {
|
|
||||||
top->clk = 1; // Toggle clock
|
|
||||||
}
|
|
||||||
if ((main_time % 10) == 6) {
|
|
||||||
top->clk = 0;
|
|
||||||
}
|
|
||||||
top->eval(); // Evaluate model
|
|
||||||
cout << top->out << endl; // Read a output
|
|
||||||
main_time++; // Time passes...
|
|
||||||
}
|
|
||||||
|
|
||||||
top->final(); // Done simulating
|
|
||||||
// // (Though this example doesn't get here)
|
|
||||||
delete top;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
Note top level IO signals are read and written as members of the model. You
|
|
||||||
call the :code:`eval()` method to evaluate the model. When the simulation is
|
|
||||||
complete call the :code:`final()` method to execute any SystemVerilog final
|
|
||||||
blocks, and complete any assertions. See :ref:`Evaluation Loop`.
|
|
||||||
|
|
||||||
|
|
||||||
Connecting to SystemC
|
Connecting to SystemC
|
||||||
@@ -150,7 +112,7 @@ netlist as an instantiation.
|
|||||||
The SC_MODULE gets the same pinout as the Verilog module, with the
|
The SC_MODULE gets the same pinout as the Verilog module, with the
|
||||||
following type conversions: Pins of a single bit become bool. Pins 2-32
|
following type conversions: Pins of a single bit become bool. Pins 2-32
|
||||||
bits wide become uint32_t's. Pins 33-64 bits wide become sc_bv's or
|
bits wide become uint32_t's. Pins 33-64 bits wide become sc_bv's or
|
||||||
vluint64_t's depending on the :vlopt:`--no-pins64` option. Wider pins
|
uint64_t's depending on the :vlopt:`--no-pins64` option. Wider pins
|
||||||
become sc_bv's. (Uints simulate the fastest so are used where possible.)
|
become sc_bv's. (Uints simulate the fastest so are used where possible.)
|
||||||
|
|
||||||
Model internals, including lower level sub-modules are not pure SystemC
|
Model internals, including lower level sub-modules are not pure SystemC
|
||||||
@@ -158,6 +120,52 @@ code. This is a feature, as using the SystemC pin interconnect scheme
|
|||||||
everywhere would reduce performance by an order of magnitude.
|
everywhere would reduce performance by an order of magnitude.
|
||||||
|
|
||||||
|
|
||||||
|
Verilated API
|
||||||
|
=============
|
||||||
|
|
||||||
|
The API to a Verilated model is the C++ headers in the include/ directory
|
||||||
|
in the distribution. These headers use Doxygen comments, `///` and `//<`,
|
||||||
|
to indicate and document those functions that are part of the Verilated
|
||||||
|
public API.
|
||||||
|
|
||||||
|
Process-Level Clone APIs
|
||||||
|
--------------------------
|
||||||
|
|
||||||
|
Modern operating systems support process-level clone (a.k.a copying, forking)
|
||||||
|
with system call interfaces in C/C++, e.g., :code:`fork()` in Linux.
|
||||||
|
|
||||||
|
However, after cloning a parent process, some resources cannot be inherited
|
||||||
|
in the child process. For example, in POSIX systems, when you fork a process,
|
||||||
|
the child process inherits all the memory of the parent process. However,
|
||||||
|
only the thread that called fork is replicated in the child process. Other
|
||||||
|
threads are not.
|
||||||
|
|
||||||
|
Therefore, to support the process-level clone mechanisms, Verilator supports
|
||||||
|
:code:`prepareClone()` and :code:`atClone()` APIs to allow the user to manually
|
||||||
|
re-construct the model in the child process. The two APIs handle all necessary
|
||||||
|
resources required for releasing and re-initializing before and after cloning.
|
||||||
|
|
||||||
|
The two APIs are supported in the verilated models. Here is an example of usage
|
||||||
|
with Linux :code:`fork()` and :code:`pthread_atfork` APIs:
|
||||||
|
|
||||||
|
.. code-block:: C++
|
||||||
|
|
||||||
|
// static function pointers to fit pthread_atfork
|
||||||
|
static auto prepareClone = [](){ topp->prepareClone(); };
|
||||||
|
static auto atClone = [](){ topp->atClone(); };
|
||||||
|
|
||||||
|
// in main function, register the handlers:
|
||||||
|
pthread_atfork(prepareClone, atClone, atClone);
|
||||||
|
|
||||||
|
For better flexibility, you can also manually call the handlers before and
|
||||||
|
after :code:`fork()`.
|
||||||
|
|
||||||
|
With the process-level clone APIs, users can create process-level snapshots
|
||||||
|
for the verilated models. While the Verilator save/restore option provides
|
||||||
|
persistent and circuit-dependent snapshots, the process-level clone APIs
|
||||||
|
enable in-memory, circuit-transparent, and highly efficient snapshots.
|
||||||
|
|
||||||
|
|
||||||
Direct Programming Interface (DPI)
|
Direct Programming Interface (DPI)
|
||||||
==================================
|
==================================
|
||||||
|
|
||||||
@@ -200,7 +208,7 @@ DPI System Task/Functions
|
|||||||
-------------------------
|
-------------------------
|
||||||
|
|
||||||
Verilator extends the DPI format to allow using the same scheme to
|
Verilator extends the DPI format to allow using the same scheme to
|
||||||
efficiently add system functions. Simply use a dollar-sign prefixed system
|
efficiently add system functions. Use a dollar-sign prefixed system
|
||||||
function name for the import, but note it must be escaped.
|
function name for the import, but note it must be escaped.
|
||||||
|
|
||||||
.. code-block:: sv
|
.. code-block:: sv
|
||||||
@@ -257,7 +265,9 @@ with respect to that top level module, then the scope could be set with
|
|||||||
|
|
||||||
#include "svdpi.h"
|
#include "svdpi.h"
|
||||||
...
|
...
|
||||||
svSetScope(svGetScopeFromName("TOP.dut"));
|
const svScope scope = svGetScopeFromName("TOP.dut");
|
||||||
|
assert(scope); // Check for nullptr if scope not found
|
||||||
|
svSetScope(scope);
|
||||||
|
|
||||||
(Remember that Verilator adds a "TOP" to the top of the module hierarchy.)
|
(Remember that Verilator adds a "TOP" to the top of the module hierarchy.)
|
||||||
|
|
||||||
@@ -410,9 +420,11 @@ changed on the specified clock edge.
|
|||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
cat >our.v <<'EOF'
|
cat >our.v <<'EOF'
|
||||||
module our (input clk);
|
module our #(
|
||||||
reg readme /*verilator public_flat_rd*/;
|
parameter WIDTH /*verilator public_flat_rd*/ = 32
|
||||||
reg writeme /*verilator public_flat_rw @(posedge clk) */;
|
) (input clk);
|
||||||
|
reg [WIDTH-1:0] readme /*verilator public_flat_rd*/;
|
||||||
|
reg [WIDTH-1:0] writeme /*verilator public_flat_rw @(posedge clk) */;
|
||||||
initial $finish;
|
initial $finish;
|
||||||
endmodule
|
endmodule
|
||||||
EOF
|
EOF
|
||||||
@@ -422,36 +434,39 @@ accesses the above signal "readme" would be:
|
|||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
cat >sim_main.cpp <<'<<EOF'
|
cat >sim_main.cpp <<'EOF'
|
||||||
#include "Vour.h"
|
#include "Vour.h"
|
||||||
#include "verilated.h"
|
#include "verilated.h"
|
||||||
#include "verilated_vpi.h" // Required to get definitions
|
#include "verilated_vpi.h" // Required to get definitions
|
||||||
|
|
||||||
vluint64_t main_time = 0; // See comments in first example
|
uint64_t main_time = 0; // See comments in first example
|
||||||
double sc_time_stamp() { return main_time; }
|
double sc_time_stamp() { return main_time; }
|
||||||
|
|
||||||
void read_and_check() {
|
void read_and_check() {
|
||||||
vpiHandle vh1 = vpi_handle_by_name((PLI_BYTE8*)"TOP.our.readme", NULL);
|
vpiHandle vh1 = vpi_handle_by_name((PLI_BYTE8*)"TOP.our.readme", NULL);
|
||||||
if (!vh1) vl_fatal(__FILE__, __LINE__, "sim_main", "No handle found");
|
if (!vh1) vl_fatal(__FILE__, __LINE__, "sim_main", "No handle found");
|
||||||
const char* name = vpi_get_str(vpiName, vh1);
|
const char* name = vpi_get_str(vpiName, vh1);
|
||||||
printf("Module name: %s\n", name); // Prints "readme"
|
const char* type = vpi_get_str(vpiType, vh1);
|
||||||
|
const int size = vpi_get(vpiSize, vh1);
|
||||||
|
printf("register name: %s, type: %s, size: %d\n", name, type, size); // Prints "register name: readme, type: vpiReg, size: 32"
|
||||||
|
|
||||||
s_vpi_value v;
|
s_vpi_value v;
|
||||||
v.format = vpiIntVal;
|
v.format = vpiIntVal;
|
||||||
vpi_get_value(vh1, &v);
|
vpi_get_value(vh1, &v);
|
||||||
printf("Value of v: %d\n", v.value.integer); // Prints "readme"
|
printf("Value of %s: %d\n", name, v.value.integer); // Prints "Value of readme: 0"
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(int argc, char** argv, char** env) {
|
int main(int argc, char** argv) {
|
||||||
Verilated::commandArgs(argc, argv);
|
Verilated::commandArgs(argc, argv);
|
||||||
Vour* top = new Vour;
|
const std::unique_ptr<VerilatedContext> contextp{new VerilatedContext};
|
||||||
Verilated::internalsDump(); // See scopes to help debug
|
const std::unique_ptr<Vour> top{new Vour{contextp.get()}};
|
||||||
while (!Verilated::gotFinish()) {
|
|
||||||
|
contextp->internalsDump(); // See scopes to help debug
|
||||||
|
while (!contextp->gotFinish()) {
|
||||||
top->eval();
|
top->eval();
|
||||||
VerilatedVpi::callValueCbs(); // For signal callbacks
|
VerilatedVpi::callValueCbs(); // For signal callbacks
|
||||||
read_and_check();
|
read_and_check();
|
||||||
}
|
}
|
||||||
delete top;
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
EOF
|
EOF
|
||||||
@@ -478,10 +493,25 @@ there is only a single design, you would call :code:`eval_step()` then
|
|||||||
:code:`eval_end_step()`; in fact :code:`eval()` described above is just a
|
:code:`eval_end_step()`; in fact :code:`eval()` described above is just a
|
||||||
wrapper which calls these two functions.
|
wrapper which calls these two functions.
|
||||||
|
|
||||||
|
3. If using delays and :vlopt:`--timing`, there are two additional methods
|
||||||
|
the user should call:
|
||||||
|
|
||||||
|
* :code:`designp->eventsPending()`, which returns :code:`true` if there are
|
||||||
|
any delayed events pending,
|
||||||
|
* :code:`designp->nextTimeSlot()`, which returns the simulation time of the
|
||||||
|
next delayed event. This method can only be called if
|
||||||
|
:code:`designp->eventsPending()` returned :code:`true`.
|
||||||
|
|
||||||
|
Call :code:`eventsPending()` to check if you should continue with the
|
||||||
|
simulation, and then :code:`nextTimeSlot()` to move simulation time forward.
|
||||||
|
:vlopt:`--main` can be used with :vlopt:`--timing` to generate a basic example
|
||||||
|
of a timing-enabled eval loop.
|
||||||
|
|
||||||
When :code:`eval()` (or :code:`eval_step()`) is called Verilator looks for
|
When :code:`eval()` (or :code:`eval_step()`) is called Verilator looks for
|
||||||
changes in clock signals and evaluates related sequential always blocks,
|
changes in clock signals and evaluates related sequential always blocks,
|
||||||
such as computing always_ff @ (posedge...) outputs. Then Verilator
|
such as computing always_ff @ (posedge...) outputs. With :vlopt:`--timing`, it
|
||||||
evaluates combinatorial logic.
|
resumes any delayed processes awaiting the current simulation time. Then
|
||||||
|
Verilator evaluates combinational logic.
|
||||||
|
|
||||||
Note combinatorial logic is not computed before sequential always blocks
|
Note combinatorial logic is not computed before sequential always blocks
|
||||||
are computed (for speed reasons). Therefore it is best to set any non-clock
|
are computed (for speed reasons). Therefore it is best to set any non-clock
|
||||||
@@ -499,14 +529,15 @@ distribution.
|
|||||||
Verilated and VerilatedContext
|
Verilated and VerilatedContext
|
||||||
==============================
|
==============================
|
||||||
|
|
||||||
Multiple Verilated models may be part of the same simulation context, that
|
Multiple C++ Verilated models may be part of the same simulation context,
|
||||||
is share a VPI interface, sense of time, and common settings. This common
|
that is share a VPI interface, sense of time, and common settings. This
|
||||||
simulation context information is stored in a ``VerilatedContext``
|
common simulation context information is stored in a ``VerilatedContext``
|
||||||
structure. If a ``VerilatedContext`` is not created prior to creating a
|
structure. If a ``VerilatedContext`` is not created prior to creating a
|
||||||
model, a default global one is created automatically.
|
model, a default global one is created automatically. SystemC requires
|
||||||
|
using only the single, default VerilatedContext.
|
||||||
|
|
||||||
The ``Verilated::`` methods, including the ``Verilated::commandArgs`` call
|
The ``Verilated::`` methods, including the ``Verilated::commandArgs`` call
|
||||||
shown above, simply call VerilatedContext methods using the default global
|
shown above, call VerilatedContext methods using the default global
|
||||||
VerilatedContext. (Technically they operate on the last one used by a
|
VerilatedContext. (Technically they operate on the last one used by a
|
||||||
given thread.) If you are using multiple simulation contexts you should
|
given thread.) If you are using multiple simulation contexts you should
|
||||||
not use the Verilated:: methods, and instead always use VerilatedContext
|
not use the Verilated:: methods, and instead always use VerilatedContext
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
*******************************
|
*******************************
|
||||||
|
|||||||
+149
-102
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
************************
|
************************
|
||||||
@@ -11,7 +11,7 @@ Authors
|
|||||||
When possible, please instead report bugs at `Verilator Issues
|
When possible, please instead report bugs at `Verilator Issues
|
||||||
<https://verilator.org/issues>`_.
|
<https://verilator.org/issues>`_.
|
||||||
|
|
||||||
Primary author is Wilson Snyder <[email protected]>.
|
The primary author is Wilson Snyder <[email protected]>.
|
||||||
|
|
||||||
Major concepts by Paul Wasson, Duane Galbi, John Coiner, Geza Lore, Yutetsu
|
Major concepts by Paul Wasson, Duane Galbi, John Coiner, Geza Lore, Yutetsu
|
||||||
Takatsukasa, and Jie Xu.
|
Takatsukasa, and Jie Xu.
|
||||||
@@ -22,122 +22,165 @@ Contributors
|
|||||||
|
|
||||||
Many people have provided ideas and other assistance with Verilator.
|
Many people have provided ideas and other assistance with Verilator.
|
||||||
|
|
||||||
Verilator is receiving major development support from the `CHIPS Alliance
|
Verilator is receiving significant development support from the `CHIPS
|
||||||
<https://chipsalliance.org>`_.
|
Alliance <https://chipsalliance.org>`_, `Antmicro Ltd
|
||||||
|
<https://antmicro.com>`_ and `Shunyao CAD <https://shunyaocad.com>`_.
|
||||||
|
|
||||||
Previous major corporate sponsors of Verilator, by providing significant
|
Previous major corporate sponsors of Verilator, by providing significant
|
||||||
contributions of time or funds included include: Atmel Corporation, Cavium
|
contributions of time or funds include: Antmicro Ltd., Atmel Corporation,
|
||||||
Inc., Compaq Corporation, Digital Equipment Corporation, Embecosm Ltd.,
|
Compaq Corporation, Digital Equipment Corporation, Embecosm Ltd., Hicamp
|
||||||
Hicamp Systems, Intel Corporation, Mindspeed Technologies Inc., MicroTune
|
Systems, Intel Corporation, Marvell Inc., Mindspeed Technologies Inc.,
|
||||||
Inc., picoChip Designs Ltd., Sun Microsystems Inc., Nauticus Networks Inc.,
|
MicroTune Inc., picoChip Designs Ltd., Sun Microsystems Inc., Nauticus
|
||||||
and SiCortex Inc.
|
Networks Inc., SiCortex Inc, Shunyao CAD, and Western Digital Inc.
|
||||||
|
|
||||||
The people who have contributed major functionality are: Byron Bradley,
|
The contributors of major functionality are: Jeremy Bennett, Krzysztof
|
||||||
Jeremy Bennett, Lane Brooks, John Coiner, Duane Galbi, Geza Lore, Todd
|
Bieganski, Byron Bradley, Lane Brooks, John Coiner, Duane Galbi, Geza Lore,
|
||||||
Strader, Stefan Wallentowitz, Paul Wasson, Jie Xu, and Wilson Snyder.
|
Todd Strader, Yutetsu Takatsukasa, Stefan Wallentowitz, Paul Wasson, Jie
|
||||||
Major testers included Jeff Dutton, Jonathon Donaldson, Ralf Karge, David
|
Xu, and Wilson Snyder.
|
||||||
Hewson, Iztok Jeras, Wim Michiels, Alex Solomatnikov, Sebastien Van
|
|
||||||
Cauwenberghe, Gene Weber, and Clifford Wolf.
|
|
||||||
|
|
||||||
Some of the people who have provided ideas, and feedback for Verilator
|
Some of the people who have provided ideas, and feedback for Verilator
|
||||||
include: David Addison, Nikana Anastasiadis, Vasu Arasanipalai, Jens Arm,
|
include:
|
||||||
Tariq B. Ahmad, Sharad Bagri, Matthew Ballance, Andrew Bardsley, Matthew
|
|
||||||
Barr, Geoff Barrett, Kaleb Barrett, Julius Baxter, Jeremy Bennett, Michael
|
David Addison, Tariq B. Ahmad, Nikana Anastasiadis, John David Anglin,
|
||||||
Berman, Jean Berniolles, Victor Besyakov, Moinak Bhattacharyya, Krzysztof
|
Frederic Antonin, Hans Van Antwerpen, Vasu Arasanipalai, Jens Arm, Rohan
|
||||||
Bieganski, David Binderman, Piotr Binkowski, Johan Bjork, David Black,
|
Arshid, Gökçe Aydos, Adam Bagley, Sharad Bagri, Robert Balas, Marco
|
||||||
Tymoteusz Blazejczyk, Daniel Bone, Morten Borup Petersen, Gregg Bouchard,
|
Balboni, Matthew Ballance, Andrew Bardsley, Ilya Barkov, Matthew Barr,
|
||||||
Christopher Boumenot, Nick Bowler, Byron Bradley, Bryan Brady, Charlie
|
Geoff Barrett, Kaleb Barrett, Daniel Bates, Julius Baxter, Michael Berman,
|
||||||
Brej, J Briquet, Lane Brooks, John Brownlee, Jeff Bush, Lawrence Butcher,
|
Jean Berniolles, Victor Besyakov, Narayan Bhagavatula, Moinak
|
||||||
Tony Bybell, Iru Cai, Ted Campbell, Chris Candler, Lauren Carlson, Donal
|
Bhattacharyya, Kritik Bhimani, David Biancolin, David Binderman, Piotr
|
||||||
Casey, Alex Chadwick, Terry Chen, Yi-Chung Chen, Enzo Chi, Robert A. Clark,
|
Binkowski, Johan Björk, David Black, Tymoteusz Blazejczyk, Scott Bleiweiss,
|
||||||
Ryan Clarke, Allan Cochrane, John Coiner, Gianfranco Costamagna, Sean
|
David van der Bokke, Daniel Bone, Guy Bonneau, Krzysztof Boroński, Gregg
|
||||||
Cross, George Cuan, Joe DErrico, Lukasz Dalek, Gunter Dannoritzer, Ashutosh
|
Bouchard, Christopher Boumenot, Nick Bowler, Bryan Brady, Maarten De
|
||||||
Das, Maarten De Braekeleer, Bernard Deadman, Alberto Del Rio, John Demme,
|
Braekeleer, Charlie Brej, J Briquet, John Brownlee, KC Buckenmaier, Jeff
|
||||||
Mike Denio, John Deroo, Philip Derrick, John Dickol, Ruben Diez, Danny
|
Bush, Lawrence Butcher, Tony Bybell, Iru Cai, Ted Campbell, Anthony Campos,
|
||||||
Ding, Jacko Dirks, Ivan Djordjevic, Jonathon Donaldson, Sebastian Dressler,
|
Chris Candler, Lauren Carlson, Gregory Carver, Donal Casey, Sebastien Van
|
||||||
Alex Duller, Jeff Dutton, Tomas Dzetkulic, Richard E George, Edgar
|
Cauwenberghe, Alex Chadwick, Greg Chadwick, Marcel Chang, Aliaksei
|
||||||
E. Iglesias, Usuario Eda, Charles Eddleston, Chandan Egbert, Jan Egil Ruud,
|
Chapyzhenka, Chih-Mao Chen, Guokai Chen, Terry Chen, Yi-Chung Chen, Yurii
|
||||||
Joe Eiler, Ahmed El-Mahmoudy, Trevor Elbourne, Mats Engstrom, Charles Eric
|
Cherkasov, Hennadii Chernyshchyk, Enzo Chi, Robert A. Clark, Ryan Clarke,
|
||||||
LaForest, Robert Farrell, Eugen Fekete, Fabrizio Ferrandi, Udi Finkelstein,
|
Allan Cochrane, Keith Colbert, Quentin Corradi, Nassim Corteggiani,
|
||||||
Brian Flachs, Andrea Foletto, Bob Fredieu, Duane Galbi, Benjamin Gartner,
|
Gianfranco Costamagna, February Cozzocrea, Sean Cross, George Cuan, Michal
|
||||||
Christian Gelinek, Peter Gerst, Glen Gibb, Michael Gielda, Barbara Gigerl,
|
Czyz, Joe DErrico, Jim Dai, Lukasz Dalek, Laurens van Dam, Gunter
|
||||||
Shankar Giri, Dan Gisselquist, Petr Gladkikh, Sam Gladstone, Andrew
|
Dannoritzer, Ashutosh Das, Julian Daube, Bernard Deadman, Peter Debacker,
|
||||||
Goessling, Amir Gonnen, Chitlesh Goorah, Tomasz Gorochowik, Kai Gossner,
|
John Demme, Mike Denio, John Deroo, Philip Derrick, Aadi Desai, John
|
||||||
Sergi Granell, Al Grant, Alexander Grobman, Xuan Guo, Driss Hafdi, Neil
|
Dickol, Ruben Diez, Danny Ding, Jacko Dirks, Ivan Djordjevic, Brad Dobbie,
|
||||||
Hamilton, James Hanlon, Oyvind Harboe, Jannis Harder, Junji Hashimoto,
|
Paul Donahue, Jonathon Donaldson, Anthony Donlon, Caleb Donovick, Larry
|
||||||
Thomas Hawkins, Mitch Hayenga, Harald Heckmann, Robert Henry, Stephen
|
Doolittle, Leendert van Doorn, Sebastian Dressler, Jonathan Drolet, Maciej
|
||||||
Henry, David Hewson, Jamey Hicks, Joel Holdsworth, Andrew Holme, Hiroki
|
Dudek, Alex Duller, Jeff Dutton, Tomas Dzetkulic, Usuario Eda, Charles
|
||||||
Honda, Alex Hornung, Pierre-Henri Horrein, David Horton, Peter Horvath, Jae
|
Eddleston, Chandan Egbert, Joe Eiler, Ahmed El-Mahmoudy, Trevor Elbourne,
|
||||||
Hossell, Kuoping Hsu, Alan Hunter, James Hutchinson, Anderson Ignacio da
|
Mats Engstrom, Robert Farrell, Julien Faucher, Olivier Faure, Eugen Fekete,
|
||||||
Silva, Jamie Iles, Thomas J Whatson, Ben Jackson, Mark Jackson Pulver,
|
Fabrizio Ferrandi, Udi Finkelstein, Brian Flachs, Bill Flynn, Andrea
|
||||||
Shareef Jalloq, Marlon James, Krzysztof Jankowski, HyungKi Jeong, Iztok
|
Foletto, Alex Forencich, Aurelien Francillon, Bob Fredieu, Manuel
|
||||||
Jeras, James Johnson, Christophe Joly, Franck Jullien, James Jung, Mike
|
Freiberger, Mostafa Gamal, Vito Gamberini, Mostafa Garnal, Benjamin
|
||||||
Kagen, Arthur Kahlich, Kaalia Kahn, Guy-Armand Kamendje, Vasu Kandadi,
|
Gartner, Christian Gelinek, Richard E George, Peter Gerst, Glen Gibb,
|
||||||
Kanad Kanhere, Patricio Kaplan, Pieter Kapsenberg, Rafal Kapuscik, Ralf
|
Michael Gielda, Barbara Gigerl, Nimrod Gileadi, Shankar Giri, Dan
|
||||||
Karge, Dan Katz, Sol Katzman, Ian Kennedy, Michael Killough, Jonathan
|
Gisselquist, Petr Gladkikh, Sam Gladstone, Mariusz Glebocki, Embedded Go,
|
||||||
Kimmitt, Olof Kindgren, Kevin Kiningham, Dan Kirkham, Sobhan Klnv, Gernot
|
Andrew Goessling, Amir Gonnen, Chitlesh Goorah, Tomasz Gorochowik, Kai
|
||||||
Koch, Jack Koenig, Soon Koh, Nathan Kohagen, Steve Kolecki, Brett Koonce,
|
Gossner, Tarik Graba, Sergi Granell, Al Grant, Nathan Graybeal, Alexander
|
||||||
Will Korteland, Wojciech Koszek, Varun Koyyalagunta, Markus Krause, David
|
Grobman, Qian Gu, Xuan Guo, Prabhat Gupta, Driss Hafdi, Neil Hamilton,
|
||||||
Kravitz, Roland Kruse, Andreas Kuster, Sergey Kvachonok, Ed Lander, Steve
|
James Hanlon, Tang Haojin, Øyvind Harboe, Jannis Harder, David Harris,
|
||||||
Lang, Stephane Laurent, Walter Lavino, Christian Leber, Larry Lee, Igor
|
Junji Hashimoto, Thomas Hawkins, Mitch Hayenga, Harald Heckmann, Robert
|
||||||
Lesik, John Li, Eivind Liland, Charlie Lind, Andrew Ling, Jiuyang Liu, Paul
|
Henry, Stephen Henry, Sebastian Hesselbarth, David Hewson, Jamey Hicks,
|
||||||
Liu, Derek Lockhart, Jake Longo, Geza Lore, Arthur Low, Stefan Ludwig, Dan
|
Joel Holdsworth, Andrew Holme, Peter Holmes, Hiroki Honda, Alex Hornung,
|
||||||
Lussier, Fred Ma, Duraid Madina, Odd Magne Reitan, Affe Mao, Julien
|
Pierre-Henri Horrein, David Horton, Peter Horvath, Jae Hossell, Kuoping
|
||||||
Margetts, Mark Marshall, Alfonso Martinez, Unai Martinez-Corral, Yves
|
Hsu, Teng Huang, Steven Hugg, Huanghuang Zhou, Alan Hunter, James
|
||||||
Mathieu, Patrick Maupin, Conor McCullough, Jason McMullan, Elliot Mednick,
|
Hutchinson, Tim Hutt, Ehab Ibrahim, Edgar E. Iglesias, Shahid Ikram, Jamie
|
||||||
Wim Michiels, Miodrag Milanovic, Peter Monsson, Sean Moore, Dennis
|
Iles, Vighnesh Iyer, Ben Jackson, Daniel Jacques, Shareef Jalloq, Marlon
|
||||||
Muhlestein, John Murphy, Matt Myers, Nathan Myers, Richard Myers, Dimitris
|
James, Krzysztof Jankowski, Eyck Jentzsch, HyungKi Jeong, Iztok Jeras,
|
||||||
Nalbantis, Peter Nelson, Bob Newgard, Paul Nitza, Yossi Nivin, Pete Nixon,
|
Alexandre Joannou, James Johnson, Christophe Joly, Justin Jones,
|
||||||
Lisa Noack, Mark Nodine, Kuba Ober, Andreas Olofsson, Baltazar Ortiz,
|
William D. Jones, Larry Darryl Lee Jr., Franck Jullien, James Jung,
|
||||||
Aleksander Osman, Don Owen, James Pallister, Vassilis Papaefstathiou, Brad
|
Yoshitomo Kaneda, Mike Kagen, Arthur Kahlich, Kaalia Kahn, Guy-Armand
|
||||||
Parker, Dan Petrisko, Maciej Piechotka, David Pierce, Cody Piersall,
|
Kamendje, Vasu Kandadi, Kanad Kanhere, Patricio Kaplan, Pieter Kapsenberg,
|
||||||
Dominic Plunkett, David Poole, Mike Popoloski, Roman Popov, Rich Porter,
|
Rafal Kapuscik, Ralf Karge, Per Karlsson, Dan Katz, Sol Katzman, Ian
|
||||||
Niranjan Prabhu, Usha Priyadharshini, Prateek Puri, Marshal Qiao, Nandu
|
Kennedy, Ami Keren, Michael Killough, Sun Kim, Jonathan Kimmitt, Olof
|
||||||
Raj, Danilo Ramos, Chris Randall, Anton Rapp, Josh Redford, Frederic
|
Kindgren, Kevin Kiningham, Cameron Kirk, Dan Kirkham, Aleksander Kiryk,
|
||||||
Requin, Dustin Richmond, Samuel Riedel, Eric Rippey, Oleg Rodionov, Ludwig
|
Sobhan Klnv, Gernot Koch, Jack Koenig, Soon Koh, Nathan Kohagen, Steve
|
||||||
Rogiers, Paul Rolfe, Arjen Roodselaar, Tobias Rosenkranz, Huang Rui, Denis
|
Kolecki, Brett Koonce, Will Korteland, Andrei Kostovski, Wojciech Koszek,
|
||||||
Rystsov, John Sanguinetti, Galen Seitz, Joseph Shaker, Salman Sheikh, Yu
|
Varun Koyyalagunta, Arkadiusz Kozdra, Markus Krause, David Kravitz, Adam
|
||||||
Sheng Lin, Hao Shi, Mike Shinkarovsky, Rafael Shirakawa, Jeffrey Short, Fan
|
Krolnik, Roland Kruse, Mahesh Kumashikar, Andreas Kuster, Sergey Kvachonok,
|
||||||
Shupei, Rodney Sinclair, Steven Slatter, Brian Small, Garrett Smith, Tim
|
Charles Eric LaForest, Kevin Laeufer, Ed Lander, Steve Lang, Pierre
|
||||||
Snyder, Wilson Snyder, Maciej Sobkowski, Stan Sokorac, Alex Solomatnikov,
|
Laroche, Stephane Laurent, Walter Lavino, Christian Leber, David Ledger,
|
||||||
Wei Song, Art Stamness, David Stanford, John Stevenson, Pete Stevenson,
|
Alex Lee, Larry Lee, Yoda Lee, Michaël Lefebvre, Dag Lem, Igor Lesik, John
|
||||||
Patrick Stewart, Rob Stoddard, Todd Strader, John Stroebel, Sven Stucki,
|
Li, Kay Li, Zixi Li, Davide Libenzi, Nandor Licker, Eivind Liland, Ícaro
|
||||||
Howard Su, Emerson Suguimoto, Gene Sullivan, Wai Sum Mong, Qingyao Sun,
|
Lima, Kevin Lin, Yu-Sheng Lin, Charlie Lind, Andrew Ling, Jiuyang Liu, Joey
|
||||||
Renga Sundararajan, Rupert Swarbrick, Yutetsu Takatsukasa, Thierry Tambe,
|
Liu, Paul Liu, Derek Lockhart, Jake Longo, Arthur Low, Jose Loyola, Stefan
|
||||||
Drew Taussig, Peter Tengstrand, Wesley Terpstra, Rui Terra, Stefan Thiede,
|
Ludwig, Dan Lussier, Konstantin Lübeck, Fred Ma, Liwei Ma, Duraid Madina,
|
||||||
Gary Thomas, Ian Thompson, Kevin Thompson, Mike Thyer, Hans Tichelaar,
|
Oleh Maksymenko, Affe Mao, Julien Margetts, Chick Markley, Alexis Marquet,
|
||||||
Viktor Tomov, Steve Tong, Alex Torregrosa, Michael Tresidder, David Turner,
|
Mark Marshall, Alfonso Martinez, Unai Martinez-Corral, Adrien Le Masle,
|
||||||
Neil Turton, Cong Van Nguyen, Hans Van Antwerpen, Jan Van Winkel, Sebastien
|
Yves Mathieu, Vladimir Matveyenko, Patrick Maupin, Stan Mayer, Conor
|
||||||
Van Cauwenberghe, Laurens van Dam, Leendert van Doorn, Srini Vemuri, Yuri
|
McCullough, Jason McMullan, Elliot Mednick, Yuan Mei, Andy Meier,
|
||||||
Victorovich, Bogdan Vukobratovic, Holger Waechtler, Philipp Wagner, Stefan
|
Rodrigo A. Melo, Benjamin Menküc, Jake Merdich, David Metz, Wim Michiels,
|
||||||
Wallentowitz, Shawn Wang, Paul Wasson, Greg Waters, Thomas Watts, Eugene
|
Miodrag Milanović, Darryl Miles, Kevin Millis, Andrew Miloradovsky, Wai Sum
|
||||||
Weber, David Welch, Martin Whitaker, Marco Widmer, Leon Wildman, Daniel
|
Mong, Peter Monsson, Sean Moore, Stuart Morris, Dennis Muhlestein, John
|
||||||
Wilkerson, Gerald Williams, Trevor Williams, Jeff Winston, Joshua Wise,
|
Murphy, Matt Myers, Nathan Myers, Richard Myers, Alex Mykyta, Dimitris
|
||||||
Clifford Wolf, Tobias Wolfel, Johan Wouters, Paul Wright, Junyi Xi, Ding
|
Nalbantis, Peter Nelson, Felix Neumärker, Bob Newgard, Cong Van Nguyen,
|
||||||
Xiaoliang, Jie Xu, Mandy Xu, Yinan Xu, Luke Yang, Amir Yazdanbakhsh, and
|
Rachit Nigam, Toru Niina, Paul Nitza, Yossi Nivin, Pete Nixon, Lisa Noack,
|
||||||
Keyi Zhang.
|
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
|
||||||
|
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.
|
||||||
|
|
||||||
|
Thanks to them, and all those we've missed mentioning above, and to those
|
||||||
|
whom have wished to remain anonymous.
|
||||||
|
|
||||||
Thanks to them, and all those we've missed including above, or wished to
|
|
||||||
remain anonymous.
|
|
||||||
|
|
||||||
Historical Origins
|
Historical Origins
|
||||||
==================
|
==================
|
||||||
|
|
||||||
Verilator was conceived in 1994 by Paul Wasson at the Core Logic Group at
|
Verilator was conceived in 1994 by Paul Wasson at the Core Logic Group at
|
||||||
Digital Equipment Corporation. The Verilog code that was converted to C
|
Digital Equipment Corporation. The Verilog code that was converted to C
|
||||||
was then merged with a C based CPU model of the Alpha processor and
|
was then merged with a C-based CPU model of the Alpha processor and
|
||||||
simulated in a C based environment called CCLI.
|
simulated in a C-based environment called CCLI.
|
||||||
|
|
||||||
In 1995 Verilator started being used also for Multimedia and Network
|
In 1995 Verilator started being used for Multimedia and Network Processor
|
||||||
Processor development inside Digital. Duane Galbi took over active
|
development inside Digital. Duane Galbi took over the active development
|
||||||
development of Verilator, and added several performance enhancements. CCLI
|
of Verilator, and added several performance enhancements, and CCLI was
|
||||||
was still being used as the shell.
|
still being used as the shell.
|
||||||
|
|
||||||
In 1998, through the efforts of existing DECies, mainly Duane Galbi,
|
In 1998, through the efforts of existing DECies, mainly Duane Galbi,
|
||||||
Digital graciously agreed to release the source code. (Subject to the code
|
Digital graciously agreed to release the source code. (Subject to the code
|
||||||
not being resold, which is compatible with the GNU Public License.)
|
not being resold, which is compatible with the GNU Public License.)
|
||||||
|
|
||||||
In 2001, Wilson Snyder took the kit, and added a SystemC mode, and called
|
In 2001, Wilson Snyder took the kit, added a SystemC mode, and called
|
||||||
it Verilator2. This was the first packaged public release.
|
it Verilator2. This was the first packaged public release.
|
||||||
|
|
||||||
In 2002, Wilson Snyder created Verilator 3.000 by rewriting Verilator from
|
In 2002, Wilson Snyder created Verilator 3.000 by rewriting Verilator from
|
||||||
@@ -151,6 +194,10 @@ In 2018, Verilator 4.000 was released with multithreaded support.
|
|||||||
In 2019, Verilator joined the `CHIPS Alliance
|
In 2019, Verilator joined the `CHIPS Alliance
|
||||||
<https://chipsalliance.org>`_.
|
<https://chipsalliance.org>`_.
|
||||||
|
|
||||||
|
In 2022, Verilator 5.000 was released with IEEE scheduling semantics,
|
||||||
|
fork/join, delay handling, DFG performance optimizations, and other
|
||||||
|
improvements.
|
||||||
|
|
||||||
Currently, various language features and performance enhancements are added
|
Currently, various language features and performance enhancements are added
|
||||||
as the need arises. Verilator is now about 3x faster than in 2002, and is
|
as the need arises, focusing on completing Universal Verification
|
||||||
faster than most (if not every) other simulator.
|
Methodology (UVM, IEEE 1800.2-2017) support.
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
*********
|
*********
|
||||||
@@ -8,12 +8,12 @@ Copyright
|
|||||||
The latest version of Verilator is available from `https://verilator.org
|
The latest version of Verilator is available from `https://verilator.org
|
||||||
<https://verilator.org>`_.
|
<https://verilator.org>`_.
|
||||||
|
|
||||||
Copyright 2003-2021 by Wilson Snyder. This program is free software; you
|
Copyright 2003-2024 by Wilson Snyder. This program is free software; you
|
||||||
can redistribute it and/or modify the Verilator internals under the terms
|
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
|
of either the GNU Lesser General Public License Version 3 or the Perl
|
||||||
Artistic License Version 2.0.
|
Artistic License Version 2.0.
|
||||||
|
|
||||||
All Verilog and C++/SystemC code quoted within this documentation file are
|
All Verilog and C++/SystemC code quoted within this documentation file is
|
||||||
released as Creative Commons Public Domain (CC0). Many example files and
|
released as Creative Commons Public Domain (CC0). Many example files and
|
||||||
test files are likewise released under CC0 into effectively the Public
|
test files are likewise released under CC0 into effectively the Public
|
||||||
Domain as described in the files themselves.
|
Domain as described in the files themselves.
|
||||||
|
|||||||
+10
-16
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
Deprecations
|
Deprecations
|
||||||
@@ -6,20 +6,14 @@ Deprecations
|
|||||||
|
|
||||||
The following deprecated items are scheduled for future removal:
|
The following deprecated items are scheduled for future removal:
|
||||||
|
|
||||||
C++11 compiler support
|
C++14 compiler support
|
||||||
Verilator currently requires C++11 or newer compilers. Verilator will
|
Verilator currently requires a C++20 or newer compiler for timing, and a
|
||||||
require C++14 or newer compilers for both compiling Verilator and
|
C++14 or newer compiler for both compiling Verilator and compiling
|
||||||
compiling Verilated models no sooner than January 2023.
|
Verilated models with --no-timing.
|
||||||
|
|
||||||
Verilated_heavy.h
|
Verilator will require C++20 or newer compilers for both compiling
|
||||||
The legacy "verilated_heavy.h" include was replaced with just including
|
Verilator and compiling all Verilated models no sooner than January 2025.
|
||||||
"verilated.h". Verilated_heavy.h is planned for removal no sooner than
|
|
||||||
July 2022.
|
|
||||||
|
|
||||||
Configuration File -msg
|
XML output
|
||||||
The :vlopt:`lint_off` "-msg" option has been replaced with the "-rule"
|
Verilator currently supports XML parser output (enabled with `--xml-only`).
|
||||||
option. "-msg" is planned for removal no sooner than January 2021.
|
Support for `--xml-*` options will be deprecated no sooner than January 2025.
|
||||||
|
|
||||||
XML locations
|
|
||||||
The XML "fl" attribute has been replaced with the "loc" attribute. "fl"
|
|
||||||
is planned for removal no sooner than January 2021.
|
|
||||||
|
|||||||
+86
-12
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
Environment
|
Environment
|
||||||
@@ -10,7 +10,7 @@ associated programs.
|
|||||||
.. option:: LD_LIBRARY_PATH
|
.. option:: LD_LIBRARY_PATH
|
||||||
|
|
||||||
A generic Linux/OS variable specifying what directories have shared
|
A generic Linux/OS variable specifying what directories have shared
|
||||||
object (.so) files. This path should include SystemC and any other
|
object (.so) files. This path should include SystemC and other
|
||||||
shared objects needed at simulation runtime.
|
shared objects needed at simulation runtime.
|
||||||
|
|
||||||
.. option:: MAKE
|
.. option:: MAKE
|
||||||
@@ -20,10 +20,16 @@ associated programs.
|
|||||||
this variable to launch GNU make. If this variable is not specified,
|
this variable to launch GNU make. If this variable is not specified,
|
||||||
"make" is used.
|
"make" is used.
|
||||||
|
|
||||||
|
.. option:: MAKEFLAGS
|
||||||
|
|
||||||
|
Flags created by :command:`make` to pass to submakes. Verilator searches
|
||||||
|
this variable to determine if a jobserver is used; see
|
||||||
|
:vlopt:`--build-jobs`.
|
||||||
|
|
||||||
.. option:: OBJCACHE
|
.. option:: OBJCACHE
|
||||||
|
|
||||||
Optionally specifies a caching or distribution program to place in front
|
Optionally specifies a caching or distribution program to place in front
|
||||||
of all runs of the C++ compiler. For example, "ccache". If using
|
of all runs of the C++ compiler. For example, "ccache" or "sccache". If using
|
||||||
:command:`distcc` or :command:`icecc`/:command:`icecream`, they would
|
:command:`distcc` or :command:`icecc`/:command:`icecream`, they would
|
||||||
generally be run under :command:`ccache`; see the documentation for
|
generally be run under :command:`ccache`; see the documentation for
|
||||||
those programs. If OBJCACHE is not set, and at configure time ccache
|
those programs. If OBJCACHE is not set, and at configure time ccache
|
||||||
@@ -54,14 +60,14 @@ associated programs.
|
|||||||
|
|
||||||
.. option:: SYSTEMC_INCLUDE
|
.. option:: SYSTEMC_INCLUDE
|
||||||
|
|
||||||
If set, specifies the directory containing the systemc.h header file. If
|
If set, specifies the directory containing the systemc.h header file.
|
||||||
not specified, it will come from a default optionally specified at
|
If not specified, it will come from a default optionally specified at
|
||||||
configure time (before Verilator was compiled), or computed from
|
configure time (before Verilator was compiled), or computed from
|
||||||
SYSTEMC/include.
|
SYSTEMC/include.
|
||||||
|
|
||||||
.. option:: SYSTEMC_LIBDIR
|
.. option:: SYSTEMC_LIBDIR
|
||||||
|
|
||||||
If set, specifies the directory containing the libsystemc.a library. If
|
If set, specifies the directory containing the libsystemc.a library. If
|
||||||
not specified, it will come from a default optionally specified at
|
not specified, it will come from a default optionally specified at
|
||||||
configure time (before Verilator was compiled), or computed from
|
configure time (before Verilator was compiled), or computed from
|
||||||
SYSTEMC/lib-SYSTEMC_ARCH.
|
SYSTEMC/lib-SYSTEMC_ARCH.
|
||||||
@@ -85,9 +91,77 @@ associated programs.
|
|||||||
|
|
||||||
.. option:: VERILATOR_ROOT
|
.. option:: VERILATOR_ROOT
|
||||||
|
|
||||||
Specifies the directory containing the distribution kit. This is used
|
The ``VERILATOR_ROOT`` environment variable is used in several places:
|
||||||
to find the executable, Perl library, and include files. If not
|
|
||||||
specified, it will come from a default optionally specified at configure
|
* At ``./configure`` time: If set, it is embedded into the binary, and
|
||||||
time (before Verilator was compiled). It should not be specified if
|
at runtime if ``VERILATOR_ROOT`` is not set, the embedded value is
|
||||||
using a pre-compiled Verilator package as the hard-coded value should be
|
used for the runtime default.
|
||||||
correct. See :ref:`Installation`.
|
|
||||||
|
* When ``verilator`` is run: If ``VERILATOR_ROOT`` is set it will be
|
||||||
|
used to find the ``verilator_bin`` executable (this is the actual
|
||||||
|
Verilator binary; ``verilator`` is a Perl wrapper). If not set, the
|
||||||
|
``verilator`` script uses other methods to find ``verilator_bin``
|
||||||
|
(looking in the same directory and falling back to ``$PATH``).
|
||||||
|
|
||||||
|
* When ``make`` is run on the Makefile generated by ``verilator``: The
|
||||||
|
value of ``VERILATOR_ROOT`` (falling back to the value embedded in the
|
||||||
|
binary if not set) is used to find the include files
|
||||||
|
(``include/verilated.mk``).
|
||||||
|
|
||||||
|
If you are using a pre-compiled Verilator package, you should not need
|
||||||
|
to set ``VERILATOR_ROOT`` - the value embedded in the binary should be
|
||||||
|
correct. In fact this option *does not work* with Verilator packages
|
||||||
|
that have been installed with ``make install``. If a Verilator package
|
||||||
|
has been installed using ``./configure --prefix=/some/path && make
|
||||||
|
install`` and then moved to another location, you cannot use
|
||||||
|
``VERILATOR_ROOT`` to point to the new version.
|
||||||
|
|
||||||
|
See :ref:`Installation` for more details.
|
||||||
|
|
||||||
|
.. option:: VERILATOR_VALGRIND
|
||||||
|
|
||||||
|
If set, the command to run when using the :vlopt:`--valgrind` option, such as
|
||||||
|
"valgrind --tool=callgrind". If not specified, it will use "valgrind".
|
||||||
|
|
||||||
|
|
||||||
|
Make Variables
|
||||||
|
==============
|
||||||
|
|
||||||
|
This section describes the make variables used by Verilator. These may be
|
||||||
|
set by passing them to make e.g. ``make CXX=my-gcc ...``.
|
||||||
|
|
||||||
|
.. option:: AR
|
||||||
|
|
||||||
|
Optionally overrides the default :command:`ar` (archive) binary used by
|
||||||
|
the Verilated makefiles. If AR is not set, the version found at
|
||||||
|
configure time is used.
|
||||||
|
|
||||||
|
.. option:: CXX
|
||||||
|
|
||||||
|
Optionally overrides the default compiler binary used by the Verilated
|
||||||
|
makefiles. If CXX is not set, the version found at configure time is
|
||||||
|
used. Note the default flags passed to the compiler are determined at
|
||||||
|
configuration time, so changing the CXX compiler version using this
|
||||||
|
variable, as opposed to passing it at configuration time, may not give
|
||||||
|
desired results.
|
||||||
|
|
||||||
|
.. option:: LINK
|
||||||
|
|
||||||
|
Optionally overrides the default linker binary used by the Verilated
|
||||||
|
makefiles. If LINK is not set, the version found at configure time is
|
||||||
|
used. Note the default flags passed to the linker are determined at
|
||||||
|
configuration time, so changing the LINK version using this variable, as
|
||||||
|
opposed to passing it at configuration time, may not give desired
|
||||||
|
results.
|
||||||
|
|
||||||
|
.. option:: PERL
|
||||||
|
|
||||||
|
Optionally overrides the default :command:`perl` binary used by the
|
||||||
|
Verilated makefiles. If PERL is not set, the version found at configure
|
||||||
|
time, and compiled into the Verilator binary, is used.
|
||||||
|
|
||||||
|
.. option:: PYTHON3
|
||||||
|
|
||||||
|
Optionally overrides the default :command:`python3` binary used by the
|
||||||
|
Verilated makefiles. If PYTHON3 is not set, the version found at
|
||||||
|
configure time is used.
|
||||||
|
|||||||
@@ -0,0 +1,63 @@
|
|||||||
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
|
.. _Example Create-Binary Execution:
|
||||||
|
|
||||||
|
Example Create-Binary Execution
|
||||||
|
===============================
|
||||||
|
|
||||||
|
We'll compile this SystemVerilog example into a Verilated simulation binary. For
|
||||||
|
an example that discusses the next level of detail see :ref:`Example C++
|
||||||
|
Execution`.
|
||||||
|
|
||||||
|
.. include:: example_common_install.rst
|
||||||
|
|
||||||
|
Now, let's create an example Verilog file:
|
||||||
|
|
||||||
|
.. code-block:: bash
|
||||||
|
|
||||||
|
mkdir test_our
|
||||||
|
cd test_our
|
||||||
|
|
||||||
|
cat >our.v <<'EOF'
|
||||||
|
module our;
|
||||||
|
initial begin $display("Hello World"); $finish; end
|
||||||
|
endmodule
|
||||||
|
EOF
|
||||||
|
|
||||||
|
Now we run Verilator on our little example.
|
||||||
|
|
||||||
|
.. code-block:: bash
|
||||||
|
|
||||||
|
verilator --binary -j 0 -Wall our.v
|
||||||
|
|
||||||
|
Breaking this command down:
|
||||||
|
|
||||||
|
#. :vlopt:`--binary` telling Verilator to do everything needed to create a
|
||||||
|
simulation executable.
|
||||||
|
|
||||||
|
#. :vlopt:`-j` `0` to Verilate using use as many CPU threads as the machine
|
||||||
|
has.
|
||||||
|
|
||||||
|
#. :vlopt:`-Wall` so Verilator has stronger lint warnings
|
||||||
|
enabled.
|
||||||
|
|
||||||
|
#. An finally, :command:`our.v`, which is our SystemVerilog design file.
|
||||||
|
|
||||||
|
And now we run it:
|
||||||
|
|
||||||
|
.. code-block:: bash
|
||||||
|
|
||||||
|
obj_dir/Vour
|
||||||
|
|
||||||
|
And we get as output:
|
||||||
|
|
||||||
|
.. code-block:: bash
|
||||||
|
|
||||||
|
Hello World
|
||||||
|
- our.v:2: Verilog $finish
|
||||||
|
|
||||||
|
You're better off using a Makefile to run the steps for you, so when your
|
||||||
|
source changes, it will automatically run all of the appropriate steps. To
|
||||||
|
aid this, Verilator can create a makefile dependency file. For examples
|
||||||
|
that do this, see the :file:`examples` directory in the distribution.
|
||||||
+17
-15
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. _Example C++ Execution:
|
.. _Example C++ Execution:
|
||||||
@@ -12,7 +12,7 @@ of what this C++ code is doing, see
|
|||||||
|
|
||||||
.. include:: example_common_install.rst
|
.. include:: example_common_install.rst
|
||||||
|
|
||||||
Now, let's create an example Verilog, and C++ wrapper file:
|
Now, let's create an example Verilog and C++ wrapper file:
|
||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
@@ -28,7 +28,7 @@ Now, let's create an example Verilog, and C++ wrapper file:
|
|||||||
cat >sim_main.cpp <<'EOF'
|
cat >sim_main.cpp <<'EOF'
|
||||||
#include "Vour.h"
|
#include "Vour.h"
|
||||||
#include "verilated.h"
|
#include "verilated.h"
|
||||||
int main(int argc, char** argv, char** env) {
|
int main(int argc, char** argv) {
|
||||||
VerilatedContext* contextp = new VerilatedContext;
|
VerilatedContext* contextp = new VerilatedContext;
|
||||||
contextp->commandArgs(argc, argv);
|
contextp->commandArgs(argc, argv);
|
||||||
Vour* top = new Vour{contextp};
|
Vour* top = new Vour{contextp};
|
||||||
@@ -39,19 +39,15 @@ Now, let's create an example Verilog, and C++ wrapper file:
|
|||||||
}
|
}
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
Now we run Verilator on our little example.
|
Now we run Verilator on our little example;
|
||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
verilator -Wall --cc --exe --build sim_main.cpp our.v
|
verilator --cc --exe --build -j 0 -Wall sim_main.cpp our.v
|
||||||
|
|
||||||
Breaking this command down:
|
Breaking this command down:
|
||||||
|
|
||||||
#. :vlopt:`-Wall` so Verilator has stronger lint warnings
|
#. :vlopt:`--cc` to get C++ output (versus e.g., SystemC, or only linting).
|
||||||
enabled.
|
|
||||||
|
|
||||||
#. :vlopt:`--cc` to get C++ output (versus e.g. SystemC
|
|
||||||
or only linting).
|
|
||||||
|
|
||||||
#. :vlopt:`--exe`, along with our :command:`sim_main.cpp` wrapper file, so
|
#. :vlopt:`--exe`, along with our :command:`sim_main.cpp` wrapper file, so
|
||||||
the build will create an executable instead of only a library.
|
the build will create an executable instead of only a library.
|
||||||
@@ -61,7 +57,13 @@ Breaking this command down:
|
|||||||
own compile rules, and run make yourself as we show in :ref:`Example
|
own compile rules, and run make yourself as we show in :ref:`Example
|
||||||
SystemC Execution`.)
|
SystemC Execution`.)
|
||||||
|
|
||||||
#. An finally, :command:`our.v` which is our SystemVerilog design file.
|
#. :vlopt:`-j 0 <-j>` to Verilate using use as many CPU threads as the
|
||||||
|
machine has.
|
||||||
|
|
||||||
|
#. :vlopt:`-Wall` so Verilator has stronger lint warnings
|
||||||
|
enabled.
|
||||||
|
|
||||||
|
#. And finally, :command:`our.v` which is our SystemVerilog design file.
|
||||||
|
|
||||||
Once Verilator completes we can see the generated C++ code under the
|
Once Verilator completes we can see the generated C++ code under the
|
||||||
:file:`obj_dir` directory.
|
:file:`obj_dir` directory.
|
||||||
@@ -86,7 +88,7 @@ And we get as output:
|
|||||||
Hello World
|
Hello World
|
||||||
- our.v:2: Verilog $finish
|
- our.v:2: Verilog $finish
|
||||||
|
|
||||||
Really, you're better off using a Makefile to run the steps for you so when
|
You're better off using a Makefile to run the steps for you, so when your
|
||||||
your source changes it will automatically run all of the appropriate steps.
|
source changes, it will automatically run all of the appropriate steps. To
|
||||||
To aid this Verilator can create a makefile dependency file. For examples
|
aid this, Verilator can create a makefile dependency file. For examples
|
||||||
that do this see the :file:`examples` directory in the distribution.
|
that do this, see the :file:`examples` directory in the distribution.
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
First you need Verilator installed, see :ref:`Installation`. In brief, if
|
First you need Verilator installed, see :ref:`Installation`. In brief, if
|
||||||
you installed Verilator using the package manager of your operating system,
|
you installed Verilator using the package manager of your operating system,
|
||||||
or did a :command:`make install` to place Verilator into your default path,
|
or did a :command:`make install` to place Verilator into your default path,
|
||||||
you do not need anything special in your environment, and should not have
|
you do not need anything special in your environment, and should not have
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. _Examples in the Distribution:
|
.. _Examples in the Distribution:
|
||||||
@@ -7,9 +7,11 @@ Examples in the Distribution
|
|||||||
============================
|
============================
|
||||||
|
|
||||||
See the ``examples/`` directory that is part of the distribution, and
|
See the ``examples/`` directory that is part of the distribution, and
|
||||||
is installed (in a OS-specific place, often in e.g.
|
is installed (in an OS-specific place, often in e.g.
|
||||||
``/usr/local/share/verilator/examples``). These examples include:
|
``/usr/local/share/verilator/examples``). These examples include:
|
||||||
|
|
||||||
|
examples/make_hello_binary
|
||||||
|
Example GNU-make simple Verilog->binary conversion
|
||||||
examples/make_hello_c
|
examples/make_hello_c
|
||||||
Example GNU-make simple Verilog->C++ conversion
|
Example GNU-make simple Verilog->C++ conversion
|
||||||
examples/make_hello_sc
|
examples/make_hello_sc
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. _Example SystemC Execution:
|
.. _Example SystemC Execution:
|
||||||
@@ -43,7 +43,7 @@ Now we run Verilator on our little example:
|
|||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
verilator -Wall --sc --exe sc_main.cpp our.v
|
verilator --sc --exe -Wall sc_main.cpp our.v
|
||||||
|
|
||||||
This example does not use --build, therefore we need to explicitly compile
|
This example does not use --build, therefore we need to explicitly compile
|
||||||
it:
|
it:
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. _Examples:
|
.. _Examples:
|
||||||
@@ -9,6 +9,7 @@ Examples
|
|||||||
|
|
||||||
This section covers the following examples:
|
This section covers the following examples:
|
||||||
|
|
||||||
|
* :ref:`Example Create-Binary Execution`
|
||||||
* :ref:`Example C++ Execution`
|
* :ref:`Example C++ Execution`
|
||||||
* :ref:`Example SystemC Execution`
|
* :ref:`Example SystemC Execution`
|
||||||
* :ref:`Examples in the Distribution`
|
* :ref:`Examples in the Distribution`
|
||||||
@@ -17,6 +18,7 @@ This section covers the following examples:
|
|||||||
:maxdepth: 1
|
:maxdepth: 1
|
||||||
:hidden:
|
:hidden:
|
||||||
|
|
||||||
|
example_binary.rst
|
||||||
example_cc.rst
|
example_cc.rst
|
||||||
example_sc.rst
|
example_sc.rst
|
||||||
example_dist.rst
|
example_dist.rst
|
||||||
|
|||||||
+45
-16
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. _Simulation Runtime Arguments:
|
.. _Simulation Runtime Arguments:
|
||||||
@@ -8,7 +8,7 @@ Simulation Runtime Arguments
|
|||||||
|
|
||||||
The following are the arguments that may be passed to a Verilated
|
The following are the arguments that may be passed to a Verilated
|
||||||
executable, provided that executable calls
|
executable, provided that executable calls
|
||||||
:code:`Verilated::commandArgs()`.
|
:code:`VerilatedContext*->commandArgs(argc, argv)`.
|
||||||
|
|
||||||
All simulation runtime arguments begin with "+verilator", so that the
|
All simulation runtime arguments begin with "+verilator", so that the
|
||||||
user's executable may skip over all "+verilator" arguments when parsing its
|
user's executable may skip over all "+verilator" arguments when parsing its
|
||||||
@@ -19,11 +19,20 @@ Summary:
|
|||||||
.. include:: ../_build/gen/args_verilated.rst
|
.. include:: ../_build/gen/args_verilated.rst
|
||||||
|
|
||||||
|
|
||||||
|
.. option:: +verilator+coverage+file+<filename>
|
||||||
|
|
||||||
|
When a model was Verilated using :vlopt:`--coverage`, sets the filename
|
||||||
|
to write coverage data into. Defaults to :file:`coverage.dat`.
|
||||||
|
|
||||||
.. option:: +verilator+debug
|
.. option:: +verilator+debug
|
||||||
|
|
||||||
Enable simulation runtime debugging. Equivalent to
|
Enable simulation runtime debugging. Equivalent to
|
||||||
:vlopt:`+verilator+debugi+4 <+verilator+debugi+\<value\>>`.
|
:vlopt:`+verilator+debugi+4 <+verilator+debugi+\<value\>>`.
|
||||||
|
|
||||||
|
To be useful, the model typically must first be compiled with debug
|
||||||
|
capabilities by Verilating with :vlopt:`--runtime-debug` or `-CFLAGS
|
||||||
|
-DVL_DEBUG=1`.
|
||||||
|
|
||||||
.. option:: +verilator+debugi+<value>
|
.. option:: +verilator+debugi+<value>
|
||||||
|
|
||||||
Enable simulation runtime debugging at the provided level.
|
Enable simulation runtime debugging at the provided level.
|
||||||
@@ -38,42 +47,62 @@ Summary:
|
|||||||
|
|
||||||
Display help and exit.
|
Display help and exit.
|
||||||
|
|
||||||
.. option:: +verilator+prof+threads+file+<filename>
|
.. option:: +verilator+prof+exec+file+<filename>
|
||||||
|
|
||||||
When a model was Verilated using :vlopt:`--prof-threads`, sets the
|
When a model was Verilated using :vlopt:`--prof-exec`, sets the
|
||||||
simulation runtime filename to dump to. Defaults to
|
simulation runtime filename to dump to. Defaults to
|
||||||
:file:`profile_threads.dat`.
|
:file:`profile_exec.dat`.
|
||||||
|
|
||||||
.. option:: +verilator+prof+threads+start+<value>
|
.. option:: +verilator+prof+exec+start+<value>
|
||||||
|
|
||||||
When a model was Verilated using :vlopt:`--prof-threads`, the simulation
|
When a model was Verilated using :vlopt:`--prof-exec`, the simulation
|
||||||
runtime will wait until $time is at this value (expressed in units of
|
runtime will wait until $time is at this value (expressed in units of
|
||||||
the time precision), then start the profiling warmup, then
|
the time precision), then start the profiling warmup, then
|
||||||
capturing. Generally this should be set to some time that is well within
|
capturing. Generally this should be set to some time that is well within
|
||||||
the normal operation of the simulation, i.e. outside of reset. If 0, the
|
the normal operation of the simulation, i.e. outside of reset. If 0, the
|
||||||
dump is disabled. Defaults to 1.
|
dump is disabled. Defaults to 1.
|
||||||
|
|
||||||
.. option:: +verilator+prof+threads+window+<value>
|
.. option:: +verilator+prof+exec+window+<value>
|
||||||
|
|
||||||
When a model was Verilated using :vlopt:`--prof-threads`, after $time
|
When a model was Verilated using :vlopt:`--prof-exec`, after $time
|
||||||
reaches :vlopt:`+verilator+prof+threads+start+\<value\>`, Verilator will
|
reaches :vlopt:`+verilator+prof+exec+start+\<value\>`, Verilator will
|
||||||
warm up the profiling for this number of eval() calls, then will capture
|
warm up the profiling for this number of eval() calls, then will capture
|
||||||
the profiling of this number of eval() calls. Defaults to 2, which
|
the profiling of this number of eval() calls. Defaults to 2, which
|
||||||
makes sense for a single-clock-domain module where it's typical to want
|
makes sense for a single-clock-domain module where it's typical to want
|
||||||
to capture one posedge eval() and one negedge eval().
|
to capture one posedge eval() and one negedge eval().
|
||||||
|
|
||||||
|
.. option:: +verilator+prof+threads+file+<filename>
|
||||||
|
|
||||||
|
Removed in 5.020. Was an alias for
|
||||||
|
:vlopt:`+verilator+prof+exec+file+\<filename\>`
|
||||||
|
|
||||||
|
.. option:: +verilator+prof+threads+start+<value>
|
||||||
|
|
||||||
|
Removed in 5.020. Was an alias for
|
||||||
|
:vlopt:`+verilator+prof+exec+start+\<value\>`
|
||||||
|
|
||||||
|
.. option:: +verilator+prof+threads+window+<value>
|
||||||
|
|
||||||
|
Removed in 5.020. Was an alias for
|
||||||
|
:vlopt:`+verilator+prof+exec+window+\<value\>`
|
||||||
|
|
||||||
.. option:: +verilator+prof+vlt+file+<filename>
|
.. option:: +verilator+prof+vlt+file+<filename>
|
||||||
|
|
||||||
When a model was Verilated using :vlopt:`--prof-threads`, sets the
|
When a model was Verilated using :vlopt:`--prof-pgo`, sets the
|
||||||
profile-guided optimization data runtime filename to dump to. Defaults
|
profile-guided optimization data runtime filename to dump to. Defaults
|
||||||
to :file:`profile.vlt`.
|
to :file:`profile.vlt`.
|
||||||
|
|
||||||
|
.. option:: +verilator+quiet
|
||||||
|
|
||||||
|
Disable printing the simulation summary report, see :ref:`Simulation
|
||||||
|
Summary Report`.
|
||||||
|
|
||||||
.. option:: +verilator+rand+reset+<value>
|
.. option:: +verilator+rand+reset+<value>
|
||||||
|
|
||||||
When a model was Verilated using :vlopt:`--x-initial unique
|
When a model was Verilated using
|
||||||
<--x-initial>`, sets the simulation runtime initialization technique. 0
|
:vlopt:`--x-initial unique <--x-initial>`, sets the simulation runtime
|
||||||
= Reset to zeros. 1 = Reset to all-ones. 2 = Randomize. See
|
initialization technique. 0 = Reset to zeros. 1 = Reset to all-ones. 2
|
||||||
:ref:`Unknown States`.
|
= Randomize. See :ref:`Unknown States`.
|
||||||
|
|
||||||
.. option:: +verilator+seed+<value>
|
.. option:: +verilator+seed+<value>
|
||||||
|
|
||||||
@@ -84,7 +113,7 @@ Summary:
|
|||||||
.. option:: +verilator+noassert
|
.. option:: +verilator+noassert
|
||||||
|
|
||||||
Disable assert checking per runtime argument. This is the same as
|
Disable assert checking per runtime argument. This is the same as
|
||||||
calling :code:`Verilated::assertOn(false)` in the model.
|
calling :code:`VerilatedContext*->assertOn(false)` in the model.
|
||||||
|
|
||||||
.. option:: +verilator+V
|
.. option:: +verilator+V
|
||||||
|
|
||||||
|
|||||||
+897
-445
File diff suppressed because it is too large
Load Diff
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
verilator_coverage
|
verilator_coverage
|
||||||
@@ -6,14 +6,14 @@ verilator_coverage
|
|||||||
|
|
||||||
Verilator_coverage processes Verilated model-generated coverage reports.
|
Verilator_coverage processes Verilated model-generated coverage reports.
|
||||||
|
|
||||||
With --annotate, it reads the specified coverage data file and generates
|
With `--annotate`, it reads the specified coverage data file and generates
|
||||||
annotated source code with coverage metrics annotated. If multiple
|
annotated source code with coverage metrics annotated. With
|
||||||
coverage points exist on the same source code line, additional lines will
|
`--annotate-points` the coverage points corresponding to each line are also
|
||||||
be inserted to report the additional points.
|
shown.
|
||||||
|
|
||||||
Additional Verilog-XL-style standard arguments specify the search paths
|
Additional Verilog-XL-style standard arguments specify the search paths
|
||||||
necessary to find the source code that the coverage analysis was performed
|
necessary to find the source code on which the coverage analysis was
|
||||||
on.
|
performed.
|
||||||
|
|
||||||
To filter those items to be included in coverage, you may read
|
To filter those items to be included in coverage, you may read
|
||||||
logs/coverage.dat into an editor and do a M-x keep-lines to include only
|
logs/coverage.dat into an editor and do a M-x keep-lines to include only
|
||||||
@@ -24,7 +24,7 @@ statement to the appropriate statement block, or see
|
|||||||
:option:`/*verilator&32;coverage_off*/`. This will remove the coverage
|
:option:`/*verilator&32;coverage_off*/`. This will remove the coverage
|
||||||
points after the model is re-Verilated.
|
points after the model is re-Verilated.
|
||||||
|
|
||||||
For an overview of use of verilator_coverage, see :ref:`Coverage Analysis`.
|
For an overview of the use of verilator_coverage, see :ref:`Coverage Analysis`.
|
||||||
|
|
||||||
|
|
||||||
verilator_coverage Example Usage
|
verilator_coverage Example Usage
|
||||||
@@ -50,25 +50,73 @@ verilator_coverage Arguments
|
|||||||
.. option:: <filename>
|
.. option:: <filename>
|
||||||
|
|
||||||
Specifies the input coverage data file. Multiple filenames may be provided
|
Specifies the input coverage data file. Multiple filenames may be provided
|
||||||
to read multiple inputs. If no data file is specified, by default
|
to read multiple inputs. If no data file is specified, by default,
|
||||||
"coverage.dat" will be read.
|
"coverage.dat" will be read.
|
||||||
|
|
||||||
.. option:: --annotate <output_directory>
|
.. option:: --annotate <output_directory>
|
||||||
|
|
||||||
Specifies the directory name that source files with annotated coverage data
|
Specifies the directory name to which source files with annotated coverage
|
||||||
should be written to.
|
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.
|
||||||
|
|
||||||
|
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
|
||||||
|
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`.
|
||||||
|
|
||||||
|
.. 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.
|
||||||
|
|
||||||
.. option:: --annotate-all
|
.. option:: --annotate-all
|
||||||
|
|
||||||
Specifies all files should be shown. By default, only those source files
|
Specifies all files should be shown. By default, only those source files
|
||||||
which have low coverage are written to the output directory.
|
with low coverage are written to the output directory.
|
||||||
|
|
||||||
|
This option should be used together with :option:`--annotate`.
|
||||||
|
|
||||||
.. option:: --annotate-min <count>
|
.. option:: --annotate-min <count>
|
||||||
|
|
||||||
Specifies if the coverage point does not include the count number of
|
Specifies the threshold (<count>) below which coverage point is considered
|
||||||
coverage hits, then the coverage point will be considered above the
|
sufficient. If the threshold is not exceeded, then the annotation will begin
|
||||||
threashold, and the coverage report will put a "%" to indicate the coverage
|
with a "%" symbol to indicate the coverage is insufficient.
|
||||||
is not sufficient. Defaults to 10.
|
|
||||||
|
The <count> threshold defaults to 10.
|
||||||
|
|
||||||
|
This option should be used together with :option:`--annotate`.
|
||||||
|
|
||||||
|
|
||||||
|
.. option:: --annotate-points
|
||||||
|
|
||||||
|
Specifies all coverage points should be shown after each line of text. By
|
||||||
|
default, only source lines are shown.
|
||||||
|
|
||||||
|
.. code-block::
|
||||||
|
|
||||||
|
100000 input logic a, b, c;
|
||||||
|
+100000 point: comment=a // These lines are only shown
|
||||||
|
+200000 point: comment=b // with option --annotate-points
|
||||||
|
+300000 point: comment=c // enabled.
|
||||||
|
|
||||||
|
|
||||||
|
This option should be used together with :option:`--annotate`.
|
||||||
|
|
||||||
.. option:: --help
|
.. option:: --help
|
||||||
|
|
||||||
@@ -78,12 +126,12 @@ Displays a help summary, the program version, and exits.
|
|||||||
|
|
||||||
Prints an experimental report listing the relative importance of each test
|
Prints an experimental report listing the relative importance of each test
|
||||||
in covering all of the coverage points. The report shows "Covered" which
|
in covering all of the coverage points. The report shows "Covered" which
|
||||||
indicates the number of points that test covers; a test is considered to
|
indicates the number of points the test covers; a test is considered to
|
||||||
cover a point if it has a bucket count of at least 1. The "rank" column has
|
cover a point if it has a bucket count of at least 1. The "rank" column has
|
||||||
a higher number t indicate the test is more important, and rank 0 means the
|
a higher number t indicate the test is more critical, and rank 0 means the
|
||||||
test does not need to be run to cover the points. "RankPts" indicates the
|
test does not need to be run to cover the points. "RankPts" indicates the
|
||||||
number of coverage points this test will contribute to overall coverage if
|
number of coverage points this test will contribute to overall coverage if
|
||||||
all tests are run in the order of highest to lowest rank.
|
all tests are run in the order of highest to the lowest rank.
|
||||||
|
|
||||||
.. option:: --unlink
|
.. option:: --unlink
|
||||||
|
|
||||||
@@ -98,8 +146,8 @@ Displays program version and exits.
|
|||||||
|
|
||||||
Specifies the aggregate coverage results, summed across all the files,
|
Specifies the aggregate coverage results, summed across all the files,
|
||||||
should be written to the given filename in verilator_coverage data format.
|
should be written to the given filename in verilator_coverage data format.
|
||||||
This is useful for use in scripts to combine many coverage data files
|
This is useful in scripts to combine many coverage data files (likely
|
||||||
(likely generated from random test runs) into one master coverage file.
|
generated from random test runs) into one master coverage file.
|
||||||
|
|
||||||
.. option:: --write-info <filename.info>
|
.. option:: --write-info <filename.info>
|
||||||
|
|
||||||
@@ -108,7 +156,8 @@ 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
|
This may be used to feed into :command:`lcov` to aggregate or generate
|
||||||
reports.
|
reports.
|
||||||
|
|
||||||
The info format loses data compared to the Verilator coverage data format;
|
Converting from the Verilator coverage data format to the info format is
|
||||||
the info will all forms of coverage converted to line style coverage, and
|
lossy; the info will have all forms of coverage merged line coverage, and
|
||||||
if there are multiple coverage points on a single line, the minimum
|
if there are multiple coverage points on a single line they will merge.
|
||||||
coverage across those points will be used to report coverage of the line.
|
The minimum coverage across all merged points will be used to report
|
||||||
|
coverage of the line.
|
||||||
|
|||||||
@@ -1,20 +1,20 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
verilator_gantt
|
verilator_gantt
|
||||||
===============
|
===============
|
||||||
|
|
||||||
Verilator_gantt creates a visual representation to help analyze Verilator
|
Verilator_gantt creates a visual representation to help analyze Verilator
|
||||||
multithreaded simulation performance, by showing when each macro-task
|
multithreaded simulation performance by showing when each macro-task
|
||||||
starts and ends, and showing when each thread is busy or idle.
|
starts, ends, and when each thread is busy or idle.
|
||||||
|
|
||||||
For an overview of use of verilator_gantt, see :ref:`Profiling`.
|
For an overview of the use of verilator_gantt, see :ref:`Profiling`.
|
||||||
|
|
||||||
Gantt Chart VCD
|
Gantt Chart VCD
|
||||||
---------------
|
---------------
|
||||||
|
|
||||||
Verilated_gnatt creates a value change dump (VCD) format dump file which
|
Verilated_gantt creates a value change dump (VCD) format dump file which
|
||||||
may be viewed in a waveform viewer (e.g. C<GTKWave>):
|
may be viewed in a waveform viewer (e.g., C<GTKWave>):
|
||||||
|
|
||||||
.. figure:: figures/fig_gantt_min.png
|
.. figure:: figures/fig_gantt_min.png
|
||||||
|
|
||||||
@@ -27,22 +27,19 @@ time tick of the system's high-performance counter.
|
|||||||
Gantt Chart VCD Signals
|
Gantt Chart VCD Signals
|
||||||
-----------------------
|
-----------------------
|
||||||
|
|
||||||
In waveforms there are the following signals. In GTKWave, using a data
|
In waveforms, there are the following signals. In GTKWave, use "decimal"
|
||||||
format of "decimal" will remove the leading zeros and make the traces
|
data format to remove the leading zeros and make the traces easier to read.
|
||||||
easier to read.
|
|
||||||
|
|
||||||
evals
|
trace/section
|
||||||
Increments each time when eval_step was measured to be active. This
|
Shows the name of the current top of the execution section stack.
|
||||||
allow visualization of how much time eval_step was active.
|
Set GTKWave data format to "ASCII".
|
||||||
|
|
||||||
eval_loop
|
trace/depth
|
||||||
Increments each time when the evaluation loop within eval_step was
|
Shows the depth of the execution section stack.
|
||||||
measured to be active. For best performance there is only a single
|
Set GTKWave data format to "Analog".
|
||||||
evaluation loop within each eval_step call, that is the eval_loop
|
|
||||||
waveform looks identical to the evals waveform.
|
|
||||||
|
|
||||||
measured_parallelism
|
measured_parallelism
|
||||||
The number of mtasks active at this time, for best performance this will
|
The number of mtasks active at this time, for best performance, this will
|
||||||
match the thread count. In GTKWave, use a data format of "analog step" to
|
match the thread count. In GTKWave, use a data format of "analog step" to
|
||||||
view this signal.
|
view this signal.
|
||||||
|
|
||||||
@@ -72,7 +69,7 @@ verilator_gantt Arguments
|
|||||||
|
|
||||||
.. option:: <filename>
|
.. option:: <filename>
|
||||||
|
|
||||||
The filename to read data from, defaults to "profile_threads.dat".
|
The filename to read data from; the default is "profile_exec.dat".
|
||||||
|
|
||||||
.. option:: --help
|
.. option:: --help
|
||||||
|
|
||||||
@@ -84,4 +81,4 @@ Disables creating a .vcd file.
|
|||||||
|
|
||||||
.. option:: --vcd <filename>
|
.. option:: --vcd <filename>
|
||||||
|
|
||||||
Sets the output filename for vcd dump. Default is "verilator_gantt.vcd".
|
Sets the output filename for vcd dump; the default is "verilator_gantt.vcd".
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
verilator_profcfunc
|
verilator_profcfunc
|
||||||
@@ -6,14 +6,14 @@ verilator_profcfunc
|
|||||||
|
|
||||||
Verilator_profcfunc reads a profile report created by gprof. The names of
|
Verilator_profcfunc reads a profile report created by gprof. The names of
|
||||||
the functions are then transformed, assuming the user used Verilator's
|
the functions are then transformed, assuming the user used Verilator's
|
||||||
--prof-cfuncs, and a report printed showing the percentage of time, etc, in
|
--prof-cfuncs, and a report printed showing the percentage of the time,
|
||||||
each Verilog block.
|
etc., in each Verilog block.
|
||||||
|
|
||||||
Due to rounding errors in gprof reports, the input report's percentages may
|
Due to rounding errors in gprof reports, the input report's percentages may
|
||||||
not total to 100%. In the verilator_profcfunc report this will get
|
not total 100%. In the verilator_profcfunc report this will get
|
||||||
reported as a rounding error.
|
reported as a rounding error.
|
||||||
|
|
||||||
For an overview of use of verilator_profcfunc, see :ref:`Profiling`.
|
For an overview of the use of verilator_profcfunc, see :ref:`Profiling`.
|
||||||
|
|
||||||
verilator_profcfunc Arguments
|
verilator_profcfunc Arguments
|
||||||
-----------------------------
|
-----------------------------
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
*********************************
|
*********************************
|
||||||
|
|||||||
+195
-79
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
*******************
|
*******************
|
||||||
@@ -12,18 +12,31 @@ or "`ifdef`"'s may break other tools.
|
|||||||
.. option:: `__FILE__
|
.. option:: `__FILE__
|
||||||
|
|
||||||
The :option:`\`__FILE__` define expands to the current filename as a
|
The :option:`\`__FILE__` define expands to the current filename as a
|
||||||
string, like C++'s __FILE__. This Verilator feature added in 2006 was
|
string, like C++'s __FILE__. This Verilator feature, added in 2006, was
|
||||||
incorporated into the IEEE 1800-2009 standard.
|
incorporated into IEEE 1800-2009.
|
||||||
|
|
||||||
.. option:: `__LINE__
|
.. option:: `__LINE__
|
||||||
|
|
||||||
The :option:`\`__LINE__` define expands to the current filename as a
|
The :option:`\`__LINE__` define expands to the current line number like
|
||||||
string, like C++'s __LINE__. This Verilator feature added in 2006 was
|
C++'s __LINE__. This Verilator feature added in 2006 was incorporated
|
||||||
incorporated into the IEEE 1800-2009 standard.
|
into IEEE 1800-2009.
|
||||||
|
|
||||||
.. option:: `error [string]
|
.. option:: `error [string]
|
||||||
|
|
||||||
This will report an error when encountered, like C++'s #error.
|
This will report an error when the preprocessor emits it, similar to
|
||||||
|
C++'s #error.
|
||||||
|
|
||||||
|
.. option:: `line
|
||||||
|
|
||||||
|
As a special case `\`line \`__LINE__ "filename"` allows setting the
|
||||||
|
filename, without changing the line number. This is used for some
|
||||||
|
internal tests, so that debugging can leave the line numbers correctly
|
||||||
|
referring to the test file's line numbers.
|
||||||
|
|
||||||
|
.. option:: """ [string] """
|
||||||
|
|
||||||
|
A triple-quoted block specifies a string that may include newlines and
|
||||||
|
single quotes. This extension was standardized in IEEE 1800-2023.
|
||||||
|
|
||||||
.. option:: $c([string], ...);
|
.. option:: $c([string], ...);
|
||||||
|
|
||||||
@@ -45,24 +58,24 @@ or "`ifdef`"'s may break other tools.
|
|||||||
rather than hard-coding variable names in the string
|
rather than hard-coding variable names in the string
|
||||||
:code:`$c("func(a)")`, instead pass the variable as an expression
|
:code:`$c("func(a)")`, instead pass the variable as an expression
|
||||||
::code:`$c("func(",a,")")`. This will allow the call to work inside
|
::code:`$c("func(",a,")")`. This will allow the call to work inside
|
||||||
Verilog functions where the variable is flattened out, and also enable
|
Verilog functions where the variable is flattened out and enable other
|
||||||
other optimizations.
|
optimizations.
|
||||||
|
|
||||||
Verilator does not use any text inside the quotes for
|
Verilator does not use any text inside the quotes for
|
||||||
ordering/scheduling. If you need the $c to be called at a specific
|
ordering/scheduling. If you need the $c to be called at a specific
|
||||||
time, e.g. when a variable changes, then the $c must be under an
|
time, e.g., when a variable changes, then the $c must be under an
|
||||||
appropriate sensitivity statement, e.g. :code:`always @(posedge clk)
|
appropriate sensitivity statement, e.g.,
|
||||||
$c("func()")` to call it on every edge, or e.g. :code:`always @*
|
:code:`always @(posedge clk) $c("func()")` to call it on every edge, or,
|
||||||
c("func(",a,")")` to call it when :code:`a` changes (the latter working
|
e.g., :code:`always @* c("func(",a,")")` to call it when :code:`a`
|
||||||
because :code:`a` is outside the quotes).
|
changes (the latter working because :code:`a` is outside the quotes).
|
||||||
|
|
||||||
If you will be reading or writing any Verilog variables inside the C++
|
If you will be reading or writing any Verilog variables inside the C++
|
||||||
functions, the Verilog signals must be declared with
|
functions, the Verilog signals must be declared with
|
||||||
:option:`/*verilator&32;public*/` metacomments.
|
:option:`/*verilator&32;public*/` metacomments.
|
||||||
|
|
||||||
You may also append an arbitrary number to $c, generally the width of
|
You may also append a number to $c, which specifies the bit width of
|
||||||
the output; :code:`signal_32_bits = $c32("...");`. This allows for
|
the output, e.g., :code:`signal_32_bits = $c32("...");`. This allows for
|
||||||
compatibility with other simulators which require a differently named
|
compatibility with other simulators, which require a differently named
|
||||||
PLI function name for each different output width.
|
PLI function name for each different output width.
|
||||||
|
|
||||||
.. option:: $display, $write, $fdisplay, $fwrite, $sformat, $swrite
|
.. option:: $display, $write, $fdisplay, $fwrite, $sformat, $swrite
|
||||||
@@ -70,61 +83,71 @@ or "`ifdef`"'s may break other tools.
|
|||||||
Format arguments may use C fprintf sizes after the % escape. Per the
|
Format arguments may use C fprintf sizes after the % escape. Per the
|
||||||
Verilog standard, %x prints a number with the natural width, and %0x
|
Verilog standard, %x prints a number with the natural width, and %0x
|
||||||
prints a number with minimum width. Verilator extends this so %5x
|
prints a number with minimum width. Verilator extends this so %5x
|
||||||
prints 5 digits per the C standard (this is unspecified in Verilog, but
|
prints 5 digits per the C standard. This extension was standardized into
|
||||||
was incorporated into the 1800-2009).
|
1800-2009.
|
||||||
|
|
||||||
|
.. option:: $timeprecision
|
||||||
|
|
||||||
|
Returns the timeprecision of the model as an integer. This extension is
|
||||||
|
experimental and may be removed without deprecation.
|
||||||
|
|
||||||
|
.. option:: $timeunit
|
||||||
|
|
||||||
|
Returns the timeunit of the current module as an integer. This
|
||||||
|
extension is experimental and may be removed without deprecation.
|
||||||
|
|
||||||
.. option:: `coverage_block_off
|
.. option:: `coverage_block_off
|
||||||
|
|
||||||
Specifies the entire begin/end block should be ignored for coverage
|
Specifies the entire begin/end block should be ignored for coverage
|
||||||
analysis. Must be inside a code block, e.g. within a begin/end pair.
|
analysis. Must be inside a code block, e.g., within a begin/end pair.
|
||||||
Same as :option:`coverage_block_off` in :ref:`Configuration Files`.
|
Same as :option:`coverage_block_off` in :ref:`Configuration Files`.
|
||||||
|
|
||||||
.. option:: `systemc_header
|
.. option:: `systemc_header
|
||||||
|
|
||||||
Take remaining text up to the next :option:`\`verilog` or
|
Take the remaining text up to the next :option:`\`verilog` or
|
||||||
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
||||||
verbatim into the output .h file's header. Must be placed as a module
|
verbatim into the output .h file's header. Must be placed as a module
|
||||||
item, e.g. directly inside a module/endmodule pair. Despite the name of
|
item, e.g., directly inside a module/endmodule pair. Despite the name of
|
||||||
this macro, this also works in pure C++ code.
|
this macro, this also works in pure C++ code.
|
||||||
|
|
||||||
.. option:: `systemc_ctor
|
.. option:: `systemc_ctor
|
||||||
|
|
||||||
Take remaining text up to the next :option:`\`verilog` or
|
Take the remaining text up to the next :option:`\`verilog` or
|
||||||
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
||||||
verbatim into the C++ class constructor. Must be placed as a module
|
verbatim into the C++ class constructor. Must be placed as a module
|
||||||
item, e.g. directly inside a module/endmodule pair. Despite the name of
|
item, e.g., directly inside a module/endmodule pair. Despite the name of
|
||||||
this macro, this also works in pure C++ code.
|
this macro, this also works in pure C++ code.
|
||||||
|
|
||||||
.. option:: `systemc_dtor
|
.. option:: `systemc_dtor
|
||||||
|
|
||||||
Take remaining text up to the next :option:`\`verilog` or
|
Take the remaining text up to the next :option:`\`verilog` or
|
||||||
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
||||||
verbatim into the C++ class destructor. Must be placed as a module
|
verbatim into the C++ class destructor. Must be placed as a module
|
||||||
item, e.g. directly inside a module/endmodule pair. Despite the name of
|
item, e.g., directly inside a module/endmodule pair. Despite the name of
|
||||||
this macro, this also works in pure C++ code.
|
this macro, this also works in pure C++ code.
|
||||||
|
|
||||||
.. option:: `systemc_interface
|
.. option:: `systemc_interface
|
||||||
|
|
||||||
Take remaining text up to the next :option:`\`verilog` or
|
Take the remaining text up to the next :option:`\`verilog` or
|
||||||
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
||||||
verbatim into the C++ class interface. Must be placed as a module item,
|
verbatim into the C++ class interface. Must be placed as a module item,
|
||||||
e.g. directly inside a module/endmodule pair. Despite the name of this
|
e.g., directly inside a module/endmodule pair. Despite the name of this
|
||||||
macro, this also works in pure C++ code.
|
macro, this also works in pure C++ code.
|
||||||
|
|
||||||
.. option:: `systemc_imp_header
|
.. option:: `systemc_imp_header
|
||||||
|
|
||||||
Take remaining text up to the next :option:`\`verilog` or
|
Take the remaining text up to the next :option:`\`verilog` or
|
||||||
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
||||||
verbatim into the header of all files for this C++ class implementation.
|
verbatim into the header of all files for this C++ class implementation.
|
||||||
Must be placed as a module item, e.g. directly inside a module/endmodule
|
Must be placed as a module item, e.g., directly inside a module/endmodule
|
||||||
pair. Despite the name of this macro, this also works in pure C++ code.
|
pair. Despite the name of this macro, this also works in pure C++ code.
|
||||||
|
|
||||||
.. option:: `systemc_implementation
|
.. option:: `systemc_implementation
|
||||||
|
|
||||||
Take remaining text up to the next :option:`\`verilog` or
|
Take the remaining text up to the next :option:`\`verilog` or
|
||||||
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
:option:`\`systemc_... <\`systemc_header>` mode switch and place it
|
||||||
verbatim into a single file of the C++ class implementation. Must be
|
verbatim into a single file of the C++ class implementation. Must be
|
||||||
placed as a module item, e.g. directly inside a module/endmodule
|
placed as a module item, e.g., directly inside a module/endmodule
|
||||||
pair. Despite the name of this macro, this also works in pure C++ code.
|
pair. Despite the name of this macro, this also works in pure C++ code.
|
||||||
|
|
||||||
If you will be reading or writing any Verilog variables in the C++
|
If you will be reading or writing any Verilog variables in the C++
|
||||||
@@ -134,7 +157,7 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
.. option:: `SYSTEMVERILOG
|
.. option:: `SYSTEMVERILOG
|
||||||
|
|
||||||
The SYSTEMVERILOG, SV_COV_START and related standard defines are set by
|
The SYSTEMVERILOG, SV_COV_START, and related standard defines are set by
|
||||||
default when :vlopt:`--language <--language>` is "1800-\*".
|
default when :vlopt:`--language <--language>` is "1800-\*".
|
||||||
|
|
||||||
.. option:: `VERILATOR
|
.. option:: `VERILATOR
|
||||||
@@ -148,9 +171,16 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
.. option:: `verilator_config
|
.. option:: `verilator_config
|
||||||
|
|
||||||
Take remaining text up to the next :option:`\`verilog` mode switch and
|
Take the remaining text up to the next :option:`\`verilog` mode switch and
|
||||||
treat it as Verilator configuration commands. See :ref:`Configuration Files`.
|
treat it as Verilator configuration commands. See :ref:`Configuration Files`.
|
||||||
|
|
||||||
|
.. option:: `VERILATOR_TIMING
|
||||||
|
|
||||||
|
The VERILATOR_TIMING define is set when :vlopt:`--timing` is used to
|
||||||
|
allow an "\`ifdef" of code dependent on this feature. Note that this define
|
||||||
|
is not affected by the :option:`timing_off` configuration file option
|
||||||
|
nor timing metacomments.
|
||||||
|
|
||||||
.. option:: `verilog
|
.. option:: `verilog
|
||||||
|
|
||||||
Switch back to processing Verilog code after a
|
Switch back to processing Verilog code after a
|
||||||
@@ -160,8 +190,12 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
.. option:: /*verilator&32;clock_enable*/
|
.. option:: /*verilator&32;clock_enable*/
|
||||||
|
|
||||||
|
Deprecated and has no effect (ignored).
|
||||||
|
|
||||||
|
In versions before 5.000:
|
||||||
|
|
||||||
Used after a signal declaration to indicate the signal is used to gate a
|
Used after a signal declaration to indicate the signal is used to gate a
|
||||||
clock, and the user takes responsibility for insuring there are no races
|
clock, and the user is responsible for ensuring there are no races
|
||||||
related to it. (Typically by adding a latch, and running static timing
|
related to it. (Typically by adding a latch, and running static timing
|
||||||
analysis.) For example:
|
analysis.) For example:
|
||||||
|
|
||||||
@@ -174,9 +208,7 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
The clock_enable attribute will cause the clock gate to be ignored in
|
The clock_enable attribute will cause the clock gate to be ignored in
|
||||||
the scheduling algorithm, sometimes required for correct clock behavior,
|
the scheduling algorithm, sometimes required for correct clock behavior,
|
||||||
and always improving performance. It's also a good idea to enable the
|
and always improving performance.
|
||||||
:option:`IMPERFECTSCH` warning, to ensure all clock enables are properly
|
|
||||||
recognized.
|
|
||||||
|
|
||||||
Same as :option:`clock_enable` configuration file option.
|
Same as :option:`clock_enable` configuration file option.
|
||||||
|
|
||||||
@@ -184,9 +216,7 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
.. option:: /*verilator&32;no_clocker*/
|
.. option:: /*verilator&32;no_clocker*/
|
||||||
|
|
||||||
Specifies that the signal is used as clock or not. This information is
|
Specifies whether the signal is used as clock or not. See :vlopt:`--clk`.
|
||||||
used by Verilator to mark the signal and any derrived signals as
|
|
||||||
clocker. See :vlopt:`--clk`.
|
|
||||||
|
|
||||||
Same as :option:`clocker` and :option:`no_clocker` in configuration
|
Same as :option:`clocker` and :option:`no_clocker` in configuration
|
||||||
files.
|
files.
|
||||||
@@ -200,15 +230,29 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
.. option:: /*verilator&32;coverage_off*/
|
.. option:: /*verilator&32;coverage_off*/
|
||||||
|
|
||||||
Specifies that following lines of code should have coverage disabled.
|
Specifies that that following lines of code should have coverage disabled.
|
||||||
Often used to ignore an entire module for coverage analysis purposes.
|
Often used to ignore an entire module for coverage analysis purposes.
|
||||||
|
|
||||||
.. option:: /*verilator&32;coverage_on*/
|
.. option:: /*verilator&32;coverage_on*/
|
||||||
|
|
||||||
Specifies that following lines of code should have coverage re-enabled
|
Specifies that that following lines of code should have coverage re-enabled
|
||||||
(if appropriate :vlopt:`--coverage` flags are passed) after being
|
(if appropriate :vlopt:`--coverage` flags are passed) after being
|
||||||
disabled earlier with :option:`/*verilator&32;coverage_off*/`.
|
disabled earlier with :option:`/*verilator&32;coverage_off*/`.
|
||||||
|
|
||||||
|
.. option:: /*verilator&32;forceable*/
|
||||||
|
|
||||||
|
Specifies that the signal (net or variable) should be made forceable from
|
||||||
|
C++ code by generating public `<signame>__VforceEn` and
|
||||||
|
`<signame>__VforceVal` signals. The force control signals are created as
|
||||||
|
:option:`public_flat` signals.
|
||||||
|
|
||||||
|
To force a marked signal from C++, set the corresponding `__VforceVal`
|
||||||
|
variable to the desired value, and the `__VforceEn` signal to the bit-mask
|
||||||
|
indicating which bits of the signal to force. To force all bits of the
|
||||||
|
target signal, set `__VforceEn` to all ones. To release the signal (or part
|
||||||
|
thereof), set appropriate bits of the `__VforceEn` signal to zero.
|
||||||
|
|
||||||
|
Same as :option:`forceable` in configuration files.
|
||||||
|
|
||||||
.. _verilator_hier_block:
|
.. _verilator_hier_block:
|
||||||
|
|
||||||
@@ -235,10 +279,10 @@ or "`ifdef`"'s may break other tools.
|
|||||||
.. option:: /*verilator&32;isolate_assignments*/
|
.. option:: /*verilator&32;isolate_assignments*/
|
||||||
|
|
||||||
Used after a signal declaration to indicate the assignments to this
|
Used after a signal declaration to indicate the assignments to this
|
||||||
signal in any blocks should be isolated into new blocks. When there is
|
signal in any blocks should be isolated into new blocks. When large
|
||||||
a large combinatorial block that is resulting in an ``UNOPTFLAT``
|
combinatorial block results in a :option:`UNOPTFLAT` warning, attaching
|
||||||
warning, attaching this to the signal causing a false loop may clear up
|
this to the signal that was causing a false loop may work around the
|
||||||
the problem.
|
warning.
|
||||||
|
|
||||||
IE, with the following:
|
IE, with the following:
|
||||||
|
|
||||||
@@ -292,7 +336,7 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
.. option:: /*verilator&32;lint_save*/
|
.. option:: /*verilator&32;lint_save*/
|
||||||
|
|
||||||
Push the current state of what lint messages are turned on or turned off
|
Push the current state of what lint messages are turned on or off
|
||||||
to a stack. Later meta-comments may then lint_on or lint_off specific
|
to a stack. Later meta-comments may then lint_on or lint_off specific
|
||||||
messages, then return to the earlier message state by using
|
messages, then return to the earlier message state by using
|
||||||
:code:`/*verilator&32;lint_restore*/`. For example:
|
:code:`/*verilator&32;lint_restore*/`. For example:
|
||||||
@@ -304,8 +348,8 @@ or "`ifdef`"'s may break other tools.
|
|||||||
... // code needing WIDTH turned off
|
... // code needing WIDTH turned off
|
||||||
// verilator lint_restore
|
// verilator lint_restore
|
||||||
|
|
||||||
If WIDTH was on before the lint_off, it will now be restored to on, and
|
If WIDTH was on before the lint_off, it would now be restored to on, and
|
||||||
if it was off before the lint_off it will remain off.
|
if it was off before the lint_off it would remain off.
|
||||||
|
|
||||||
.. option:: /*verilator&32;no_inline_module*/
|
.. option:: /*verilator&32;no_inline_module*/
|
||||||
|
|
||||||
@@ -349,13 +393,12 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
Used after an input, output, register, or wire declaration to indicate
|
Used after an input, output, register, or wire declaration to indicate
|
||||||
the signal should be declared so that C code may read or write the value
|
the signal should be declared so that C code may read or write the value
|
||||||
of the signal. This will also declare this module public, otherwise use
|
of the signal. This will also declare this module public; otherwise, use
|
||||||
:code:`/*verilator&32;public_flat*/`.
|
:code:`/*verilator&32;public_flat*/`.
|
||||||
|
|
||||||
Instead of using public variables, consider instead making a DPI or
|
Instead of using public variables, consider making a DPI or public
|
||||||
public function that accesses the variable. This is nicer as it
|
function that accesses the variable. This is nicer as it provides an
|
||||||
provides an obvious entry point that is also compatible across
|
obvious entry point compatible across simulators.
|
||||||
simulators.
|
|
||||||
|
|
||||||
Same as :option:`public` configuration file option.
|
Same as :option:`public` configuration file option.
|
||||||
|
|
||||||
@@ -365,7 +408,7 @@ or "`ifdef`"'s may break other tools.
|
|||||||
indicate the function or task should be made into a C++ function, public
|
indicate the function or task should be made into a C++ function, public
|
||||||
to outside callers. Public tasks will be declared as a void C++
|
to outside callers. Public tasks will be declared as a void C++
|
||||||
function, public functions will get the appropriate non-void (bool,
|
function, public functions will get the appropriate non-void (bool,
|
||||||
uint32_t, etc) return type. Any input arguments will become C++
|
uint32_t, etc.) return type. Any input arguments will become C++
|
||||||
arguments to the function. Any output arguments will become C++
|
arguments to the function. Any output arguments will become C++
|
||||||
reference arguments. Any local registers/integers will become function
|
reference arguments. Any local registers/integers will become function
|
||||||
automatic variables on the stack.
|
automatic variables on the stack.
|
||||||
@@ -403,20 +446,47 @@ or "`ifdef`"'s may break other tools.
|
|||||||
.. option:: /*verilator&32;public_flat_rw @(<edge_list>)*/ (on variable)
|
.. option:: /*verilator&32;public_flat_rw @(<edge_list>)*/ (on variable)
|
||||||
|
|
||||||
Used after an input, output, register, or wire declaration to indicate
|
Used after an input, output, register, or wire declaration to indicate
|
||||||
the signal should be declared public_flat_rd (see above), and also
|
the signal should be declared public_flat_rd (see above), and writable,
|
||||||
writable, where writes should be considered to have the timing specified
|
where writes should be considered to have the timing specified by the
|
||||||
by the given sensitivity edge list. Set for all variables, ports and
|
given sensitivity edge list. Use of this is implied when using the
|
||||||
wires using the :vlopt:`--public-flat-rw` option.
|
:vlopt:`--public-flat-rw` option.
|
||||||
|
|
||||||
Same as :option:`public_flat_rw` configuration file option.
|
Same as :option:`public_flat_rw` configuration file option.
|
||||||
|
|
||||||
|
.. option:: /*verilator&32;public_[|flat|flat_rd|flat_rw]_on [@(<edge_list>)]*/ (as scope)
|
||||||
|
|
||||||
|
Used to wrap multiple signals and parameters with the respective public attribute.
|
||||||
|
See attribute above for their respective behavior. Cannot be nested. e.g:
|
||||||
|
|
||||||
|
.. code-block:: sv
|
||||||
|
|
||||||
|
/*verilator public_flat_rw_on*/
|
||||||
|
logic clk;
|
||||||
|
logic rst;
|
||||||
|
parameter width = 8;
|
||||||
|
/* verilator public_off*/
|
||||||
|
logic data;
|
||||||
|
|
||||||
|
Is equivalent to:
|
||||||
|
|
||||||
|
.. code-block:: sv
|
||||||
|
|
||||||
|
logic clk /*verilator public_flat_rw*/;
|
||||||
|
logic rst /*verilator public_flat_rw*/;
|
||||||
|
parameter width /*verilator public_flat_rw*/ = 8;
|
||||||
|
logic data;
|
||||||
|
|
||||||
|
.. option:: /*verilator&32;public_off*/
|
||||||
|
|
||||||
|
Terminates the previous `/*verilator public*_on*/` directive; see above.
|
||||||
|
|
||||||
.. option:: /*verilator&32;public_module*/
|
.. option:: /*verilator&32;public_module*/
|
||||||
|
|
||||||
Used after a module statement to indicate the module should not be
|
Used after a module statement to indicate the module should not be
|
||||||
inlined (unless specifically requested) so that C code may access the
|
inlined (unless specifically requested) so that C code may access the
|
||||||
module. Verilator automatically sets this attribute when the module
|
module. Verilator automatically sets this attribute when the module
|
||||||
contains any public signals or \`systemc_ directives. Also set for all
|
contains public signals or \`systemc_ directives. Use of this is
|
||||||
modules when using the :vlopt:`--public` option.
|
implied when using the :vlopt:`--public` option.
|
||||||
|
|
||||||
Same as :option:`public` configuration file option.
|
Same as :option:`public` configuration file option.
|
||||||
|
|
||||||
@@ -425,27 +495,26 @@ or "`ifdef`"'s may break other tools.
|
|||||||
Deprecated and ignored. Previously used after an input declaration to
|
Deprecated and ignored. Previously used after an input declaration to
|
||||||
indicate the signal should be declared in SystemC as a sc_clock instead
|
indicate the signal should be declared in SystemC as a sc_clock instead
|
||||||
of a bool. This was needed in SystemC 1.1 and 1.2 only; versions 2.0
|
of a bool. This was needed in SystemC 1.1 and 1.2 only; versions 2.0
|
||||||
and later do not require clock pins to be sc_clocks and this is no
|
and later do not require clock pins to be sc_clocks, and this is no
|
||||||
longer needed and is ignored.
|
longer needed and is ignored.
|
||||||
|
|
||||||
.. option:: /*verilator&32;sc_bv*/
|
.. option:: /*verilator&32;sc_bv*/
|
||||||
|
|
||||||
Used after a port declaration. It sets the port to be of
|
Used after a port declaration. It sets the port to be of
|
||||||
:code:`sc_bv<{width}>` type, instead of bool, vluint32_t or vluint64_t.
|
:code:`sc_bv<{width}>` type, instead of bool, uint32_t, or uint64_t.
|
||||||
This may be useful if the port width is parameterized and the
|
This may be useful if the port width is parameterized and the
|
||||||
instantiating C++ code wants to always have a sc_bv so it can accept any
|
instantiating C++ code always wants to have a sc_bv accept any width.
|
||||||
width. In general you should avoid using this attribute when not
|
In general, you should avoid using this attribute when unnecessary, as
|
||||||
necessary as with increasing usage of sc_bv the performance decreases
|
the performance decreases significantly with increasing usage of sc_bv.
|
||||||
significantly.
|
|
||||||
|
|
||||||
Same as :option:`sc_bv` configuration file option.
|
Same as :option:`sc_bv` configuration file option.
|
||||||
|
|
||||||
.. option:: /*verilator&32;sformat*/
|
.. option:: /*verilator&32;sformat*/
|
||||||
|
|
||||||
Attached to the final argument of type "input string" of a function or
|
Attached to the final argument of type "input string" of a function or
|
||||||
task to indicate the function or task should pass all remaining
|
task to indicate that the function or task should pass all remaining
|
||||||
arguments through $sformatf. This allows creation of DPI functions with
|
arguments through $sformatf. This allows creation of DPI functions with
|
||||||
$display like behavior. See the :file:`test_regress/t/t_dpi_display.v`
|
$display-like behavior. See the :file:`test_regress/t/t_dpi_display.v`
|
||||||
file for an example.
|
file for an example.
|
||||||
|
|
||||||
Same as :option:`sformat` configuration file option.
|
Same as :option:`sformat` configuration file option.
|
||||||
@@ -455,7 +524,7 @@ or "`ifdef`"'s may break other tools.
|
|||||||
Attached to a variable or a net declaration to break the variable into
|
Attached to a variable or a net declaration to break the variable into
|
||||||
multiple pieces typically to resolve ``UNOPTFLAT`` performance issues.
|
multiple pieces typically to resolve ``UNOPTFLAT`` performance issues.
|
||||||
Typically the variables to attach this to are recommended by Verilator
|
Typically the variables to attach this to are recommended by Verilator
|
||||||
itself, see :option:`UNOPTFLAT`.
|
itself; see :option:`UNOPTFLAT`.
|
||||||
|
|
||||||
For example, Verilator will internally convert a variable with the
|
For example, Verilator will internally convert a variable with the
|
||||||
metacomment such as:
|
metacomment such as:
|
||||||
@@ -472,12 +541,12 @@ or "`ifdef`"'s may break other tools.
|
|||||||
logic [7:0] x__BRA__1__KET__ /*verilator split_var*/;
|
logic [7:0] x__BRA__1__KET__ /*verilator split_var*/;
|
||||||
|
|
||||||
Note that the generated packed variables retain the split_var
|
Note that the generated packed variables retain the split_var
|
||||||
metacomment because they may be split into further smaller pieces
|
metacomment because they may be split into smaller pieces according to
|
||||||
according to the access patterns.
|
the access patterns.
|
||||||
|
|
||||||
This only supports unpacked arrays, packed arrays, and packed structs of
|
This only supports unpacked arrays, packed arrays, and packed structs of
|
||||||
integer types (reg, logic, bit, byte, int...); otherwise if a split was
|
integer types (reg, logic, bit, byte, int...); otherwise, if a split was
|
||||||
requested but cannot occur a SPLITVAR warning is issued. Splitting
|
requested but cannot occur, a SPLITVAR warning is issued. Splitting
|
||||||
large arrays may slow down the Verilation speed, so use this only on
|
large arrays may slow down the Verilation speed, so use this only on
|
||||||
variables that require it.
|
variables that require it.
|
||||||
|
|
||||||
@@ -489,8 +558,28 @@ or "`ifdef`"'s may break other tools.
|
|||||||
Verilator) text that should be passed through to the XML output as a tag,
|
Verilator) text that should be passed through to the XML output as a tag,
|
||||||
for use by downstream applications.
|
for use by downstream applications.
|
||||||
|
|
||||||
|
.. option:: /*verilator&32;timing_off*/
|
||||||
|
|
||||||
|
Ignore all timing constructs after this metacomment. All timing controls
|
||||||
|
behave as if they were not there (the same way as with
|
||||||
|
:option:`--no-timing`), and :code:`fork`/:code:`join*` blocks are
|
||||||
|
converted into :code:`begin`/:code:`end` blocks.
|
||||||
|
|
||||||
|
Same as :option:`timing_off` configuration file option.
|
||||||
|
|
||||||
|
.. option:: /*verilator&32;timing_on*/
|
||||||
|
|
||||||
|
Re-enable all timing constructs after this metacomment (only applicable
|
||||||
|
after :option:`timing_off`).
|
||||||
|
|
||||||
|
Same as :option:`timing_on` configuration file option.
|
||||||
|
|
||||||
.. option:: /*verilator&32;trace_init_task*/
|
.. option:: /*verilator&32;trace_init_task*/
|
||||||
|
|
||||||
|
Removed.
|
||||||
|
|
||||||
|
In versions before 5.024:
|
||||||
|
|
||||||
Attached to a DPI import to indicate that function should be called when
|
Attached to a DPI import to indicate that function should be called when
|
||||||
initializing tracing. This attribute is indented only to be used
|
initializing tracing. This attribute is indented only to be used
|
||||||
internally in code that Verilator generates when :vlopt:`--lib-create`
|
internally in code that Verilator generates when :vlopt:`--lib-create`
|
||||||
@@ -498,12 +587,39 @@ or "`ifdef`"'s may break other tools.
|
|||||||
|
|
||||||
.. option:: /*verilator&32;tracing_off*/
|
.. option:: /*verilator&32;tracing_off*/
|
||||||
|
|
||||||
Disable waveform tracing for all future signals that are declared in
|
Disable waveform tracing for all future signals declared in this module,
|
||||||
this module, or instances below this module. Often this is placed just
|
or instances below this module. Often this is placed just after a
|
||||||
after a primitive's module statement, so that the entire module and
|
primitive's module statement, so that the entire module and instances
|
||||||
instances below it are not traced.
|
below it are not traced.
|
||||||
|
|
||||||
.. option:: /*verilator&32;tracing_on*/
|
.. option:: /*verilator&32;tracing_on*/
|
||||||
|
|
||||||
Re-enable waveform tracing for all future signals or instances that are
|
Re-enable waveform tracing for all future signals or instances that are
|
||||||
declared.
|
declared.
|
||||||
|
|
||||||
|
.. option:: /*verilator&32;unroll_disable*/
|
||||||
|
|
||||||
|
Used in a statement position to indicate the immediately following loop
|
||||||
|
at the same statement level should not be unrolled by Verilator,
|
||||||
|
ignoring :vlopt:`--unroll-count`. This is similar to clang's ``#pragma
|
||||||
|
clang loop unroll(disable)``.
|
||||||
|
|
||||||
|
This option does not currently disable the C++ compiler's unrolling (or
|
||||||
|
not) of any loops that make it through to the Verilated C++ code.
|
||||||
|
|
||||||
|
.. option:: /*verilator&32;unroll_full*/
|
||||||
|
|
||||||
|
Rarely needed. Used in a statement position to indicate the immediately
|
||||||
|
following loop at the same statement level should always be fully
|
||||||
|
unrolled by Verilator, ignoring :vlopt:`--unroll-count`. This is
|
||||||
|
similar to clang's ``#pragma clang loop unroll(full)``.
|
||||||
|
|
||||||
|
.. option:: $stacktrace
|
||||||
|
|
||||||
|
Called as a task, print a stack trace. Called as a function, return a
|
||||||
|
string with a stack trace. This relies on the C++ system trace, which
|
||||||
|
may give less meaningful results if the model is not compiled with debug
|
||||||
|
symbols. Also, the data represents the C++ stack; the SystemVerilog
|
||||||
|
functions/tasks involved may be renamed and/or inlined before becoming
|
||||||
|
the C++ functions that may be visible in the stack trace. This
|
||||||
|
extension was standardized in IEEE 1800-2023.
|
||||||
|
|||||||
+123
-108
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
******************************
|
******************************
|
||||||
@@ -14,8 +14,8 @@ Can I contribute?
|
|||||||
"""""""""""""""""
|
"""""""""""""""""
|
||||||
|
|
||||||
Please contribute! Just submit a pull request, or raise an issue to
|
Please contribute! Just submit a pull request, or raise an issue to
|
||||||
discuss if looking for something to help on. For more information see our
|
discuss if you are looking for something to help on. For more information
|
||||||
contributor agreement.
|
see our contributor agreement.
|
||||||
|
|
||||||
|
|
||||||
How widely is Verilator used?
|
How widely is Verilator used?
|
||||||
@@ -24,7 +24,7 @@ How widely is Verilator used?
|
|||||||
Verilator is used by many of the largest silicon design companies, large
|
Verilator is used by many of the largest silicon design companies, large
|
||||||
organizations such as CERN, and even by college student projects.
|
organizations such as CERN, and even by college student projects.
|
||||||
|
|
||||||
Verilator is one of the "big 4" simulators, meaning one of the 4 main
|
Verilator is one of the "big 4" simulators, meaning one of the four leading
|
||||||
SystemVerilog simulators available, namely the closed-source products Synopsys
|
SystemVerilog simulators available, namely the closed-source products Synopsys
|
||||||
VCS (tm), Mentor Questa/ModelSim (tm), Cadence
|
VCS (tm), Mentor Questa/ModelSim (tm), Cadence
|
||||||
Xcelium/Incisive/NC-Verilog/NC-Sim (tm), and the open-source Verilator.
|
Xcelium/Incisive/NC-Verilog/NC-Sim (tm), and the open-source Verilator.
|
||||||
@@ -35,17 +35,17 @@ simulators.
|
|||||||
Does Verilator run under Windows?
|
Does Verilator run under Windows?
|
||||||
"""""""""""""""""""""""""""""""""
|
"""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
Yes, ideally run Ubuntu under Windows Subsystem for Linux (WSL2).
|
Yes, ideally, run Ubuntu under Windows Subsystem for Linux (WSL2).
|
||||||
Alternatively use Cygwin, though this tends to be slower and is not
|
Alternatively, use Cygwin, though this tends to be slower and is not
|
||||||
regurally tested. Verilated output also compiles under Microsoft Visual
|
regularly tested. Verilated output also compiles under Microsoft Visual
|
||||||
C++, but this is also not regurally tested.
|
C++, but this is also not regularly tested.
|
||||||
|
|
||||||
|
|
||||||
Can you provide binaries?
|
Can you provide binaries?
|
||||||
"""""""""""""""""""""""""
|
"""""""""""""""""""""""""
|
||||||
|
|
||||||
You can install Verilator via the system package manager (apt, yum, etc.)
|
You can install Verilator via the system package manager (apt, yum, etc.)
|
||||||
on many Linux distributions, including Debian, Ubuntu, SuSE, RedHat, and
|
on many Linux distributions, including Debian, Ubuntu, SuSE, Red Hat, and
|
||||||
others. These packages are provided by the Linux distributions and
|
others. These packages are provided by the Linux distributions and
|
||||||
generally will lag the version of the mainline Verilator repository. If no
|
generally will lag the version of the mainline Verilator repository. If no
|
||||||
binary package is available for your distribution, how about you set one
|
binary package is available for your distribution, how about you set one
|
||||||
@@ -58,37 +58,52 @@ How can it be faster than (name-a-big-3-closed-source-simulator)?
|
|||||||
Generally, the implied part of the question is "... with all of the
|
Generally, the implied part of the question is "... with all of the
|
||||||
manpower they can put into developing it."
|
manpower they can put into developing it."
|
||||||
|
|
||||||
Most simulators have to be compliant with the complete IEEE 1364 (Verilog)
|
Most simulators must comply with the complete IEEE 1364 (Verilog) and IEEE
|
||||||
and IEEE 1800 (SystemVerilog) standards, meaning they have to be event
|
1800 (SystemVerilog) standards, meaning they have to be event-driven. This
|
||||||
driven. This prevents them from being able to reorder blocks and make
|
prevents them from being able to reorder blocks and make netlist-style
|
||||||
netlist-style optimizations, which are where most of the gains come from.
|
optimizations, which are where most of the gains come from.
|
||||||
|
|
||||||
You should not be scared by non-compliance. Your synthesis tool isn't
|
You should not be scared by non-compliance. Your synthesis tool isn't
|
||||||
compliant with the whole standard to start with, so your simulator need not
|
compliant with the whole standard to start with, so your simulator need not
|
||||||
be either. Verilator is closer to the synthesis interpretation, so this is
|
be either. Verilator is closer to the synthesis interpretation, which is
|
||||||
a good thing for getting working silicon.
|
a good thing for getting working silicon.
|
||||||
|
|
||||||
|
|
||||||
Will Verilator output remain under my own license/copyright?
|
Will Verilator output remain under my own license/copyright?
|
||||||
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
Yes, it's just like using GCC on your programs; this is why Verilator uses
|
Your SystemVerilog, VPI/DPI, or main() C++ code remains under your own license.
|
||||||
the "GNU **Lesser** Public License Version 3" instead of the more typical
|
|
||||||
"GNU Public License". See the licenses for details, but in brief, if you
|
It's just like how using GCC on your programs does not change the copyright
|
||||||
change Verilator itself or the header files Verilator includes, you must
|
of your program; this is why Verilator uses the "GNU **Lesser** Public
|
||||||
make the source code available under the GNU Lesser Public License.
|
License Version 3" instead of the more typical "GNU Public License". See
|
||||||
However, Verilator output (the Verilated code) only "include"s the licensed
|
the licenses for details.
|
||||||
files, and so you are **not** required to open-source release any output
|
|
||||||
from Verilator.
|
Some examples:
|
||||||
|
|
||||||
|
* Any SystemVerilog or other input fed into Verilator remains your own.
|
||||||
|
|
||||||
|
* Any of your VPI/DPI C++ routines that Verilator calls remain your own.
|
||||||
|
|
||||||
|
* Any of your main() C++ code that calls into Verilator remains your own.
|
||||||
|
|
||||||
|
* If you change Verilator itself, for example, changing or adding a file
|
||||||
|
under the src/ directory in the repository, you must make the source code
|
||||||
|
available under the GNU Lesser Public License.
|
||||||
|
|
||||||
|
* If you change a header Verilator provides, for example, under include/ in
|
||||||
|
the repository, you must make the source code available under the GNU
|
||||||
|
Lesser Public License.
|
||||||
|
|
||||||
You also have the option of using the Perl Artistic License, which again
|
You also have the option of using the Perl Artistic License, which again
|
||||||
does not require you to release your Verilog or generated code, and also
|
does not require you to release your Verilog, C++, or generated code. This
|
||||||
allows you to modify Verilator for internal use without distributing the
|
license also allows you to modify Verilator for internal use without
|
||||||
modified version. But please contribute back to the community!
|
distributing the modified version. But please contribute back to the
|
||||||
|
community!
|
||||||
|
|
||||||
One limit is that you cannot under either license release a closed-source
|
Under both licenses, you can offer a commercial product based on
|
||||||
Verilog simulation product incorporating Verilator. That is you can have a
|
Verilator directly or embedded within. However, under both licenses,
|
||||||
commercial product, but must make the source code available.
|
any changes you make to Verilator for such a product must be open-sourced.
|
||||||
|
|
||||||
As is standard with Open Source, contributions back to Verilator will be
|
As is standard with Open Source, contributions back to Verilator will be
|
||||||
placed under the Verilator copyright and LGPL/Artistic license. Small test
|
placed under the Verilator copyright and LGPL/Artistic license. Small test
|
||||||
@@ -99,11 +114,11 @@ and large tests under the LGPL/Artistic, unless requested otherwise.
|
|||||||
Why is running Verilator (to create a model) so slow?
|
Why is running Verilator (to create a model) so slow?
|
||||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""
|
"""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
Verilator may require more memory than the resulting simulator will
|
Verilator may require more memory than the resulting simulation,
|
||||||
require, as Verilator internally creates all of the state of the resulting
|
as Verilator internally creates all of the state of the resulting
|
||||||
generated simulator in order to optimize it. If it takes more than a few
|
generated simulator to optimize it. If it takes more than a few
|
||||||
minutes or so (and you're not using :vlopt:`--debug` since debug mode is
|
minutes or so (and you're not using :vlopt:`--debug` since debug mode is
|
||||||
disk bound), see if your machine is paging; most likely you need to run it
|
disk bound), see if your machine is paging; most likely, you need to run it
|
||||||
on a machine with more memory. Very large designs are known to have topped
|
on a machine with more memory. Very large designs are known to have topped
|
||||||
64 GB resident set size. Alternatively, see :ref:`Hierarchical Verilation`.
|
64 GB resident set size. Alternatively, see :ref:`Hierarchical Verilation`.
|
||||||
|
|
||||||
@@ -113,14 +128,17 @@ How do I generate waveforms (traces) in C++?
|
|||||||
|
|
||||||
See also the next question for tracing in SystemC mode.
|
See also the next question for tracing in SystemC mode.
|
||||||
|
|
||||||
A. Pass the :vlopt:`--trace` option to Verilator, and in your top level C
|
A. Pass the :vlopt:`--trace` option to Verilator. Then you may use ``$dumpfile`` and
|
||||||
code, call ``Verilated::traceEverOn(true)``. Then you may use
|
``$dumpvars`` to enable traces, the same as with any Verilog simulator,
|
||||||
``$dumpfile`` and ``$dumpvars`` to enable traces, same as with any
|
although Verilator ignores the arguments to ``$dumpvars``. See
|
||||||
Verilog simulator. See ``examples/make_tracing_c`` in the distribution.
|
``examples/make_tracing_c`` in the distribution.
|
||||||
|
|
||||||
|
If writing the top-level C code, call ``Verilated::traceEverOn(true)``;
|
||||||
|
this is done for you if using :vlopt:`--binary`.
|
||||||
|
|
||||||
B. Or, for finer-grained control, or C++ files with multiple Verilated
|
B. Or, for finer-grained control, or C++ files with multiple Verilated
|
||||||
modules you may also create the trace purely from C++. Create a
|
modules, you may also create the trace purely from C++. Create a
|
||||||
VerilatedVcdC object, and in your main loop right after ``eval()`` call
|
VerilatedVcdC object, and in your main loop, right after ``eval()`` call
|
||||||
``trace_object->dump(contextp->time())`` every time step, and finally
|
``trace_object->dump(contextp->time())`` every time step, and finally
|
||||||
call ``trace_object->close()``.
|
call ``trace_object->close()``.
|
||||||
|
|
||||||
@@ -129,12 +147,13 @@ B. Or, for finer-grained control, or C++ files with multiple Verilated
|
|||||||
|
|
||||||
#include "verilated_vcd_c.h"
|
#include "verilated_vcd_c.h"
|
||||||
...
|
...
|
||||||
int main(int argc, char** argv, char** env) {
|
int main(int argc, char** argv) {
|
||||||
const std::unique_ptr<VerilatedContext> contextp{new VerilatedContext};
|
const std::unique_ptr<VerilatedContext> contextp{new VerilatedContext};
|
||||||
...
|
...
|
||||||
Verilated::traceEverOn(true);
|
Verilated::traceEverOn(true);
|
||||||
VerilatedVcdC* tfp = new VerilatedVcdC;
|
VerilatedVcdC* tfp = new VerilatedVcdC;
|
||||||
topp->trace(tfp, 99); // Trace 99 levels of hierarchy
|
topp->trace(tfp, 99); // Trace 99 levels of hierarchy (or see below)
|
||||||
|
// tfp->dumpvars(1, "t"); // trace 1 level under "t"
|
||||||
tfp->open("obj_dir/t_trace_ena_cc/simx.vcd");
|
tfp->open("obj_dir/t_trace_ena_cc/simx.vcd");
|
||||||
...
|
...
|
||||||
while (contextp->time() < sim_time && !contextp->gotFinish()) {
|
while (contextp->time() < sim_time && !contextp->gotFinish()) {
|
||||||
@@ -147,8 +166,8 @@ B. Or, for finer-grained control, or C++ files with multiple Verilated
|
|||||||
|
|
||||||
You also need to compile :file:`verilated_vcd_c.cpp` and add it to your
|
You also need to compile :file:`verilated_vcd_c.cpp` and add it to your
|
||||||
link, preferably by adding the dependencies in your Makefile's
|
link, preferably by adding the dependencies in your Makefile's
|
||||||
:code:`$(VK_GLOBAL_OBJS)` link rule. This is done for you if using the
|
:code:`$(VK_GLOBAL_OBJS)` link rule. This is done for you if you are using
|
||||||
Verilator :vlopt:`--exe` option.
|
the Verilator :vlopt:`--binary` or :vlopt:`--exe` option.
|
||||||
|
|
||||||
you can call :code:`trace_object->trace()` on multiple Verilated objects
|
you can call :code:`trace_object->trace()` on multiple Verilated objects
|
||||||
with the same trace file if you want all data to land in the same output
|
with the same trace file if you want all data to land in the same output
|
||||||
@@ -158,22 +177,22 @@ file.
|
|||||||
How do I generate waveforms (traces) in SystemC?
|
How do I generate waveforms (traces) in SystemC?
|
||||||
""""""""""""""""""""""""""""""""""""""""""""""""
|
""""""""""""""""""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
A. Pass the :vlopt:`--trace` option to Verilator, and in your top level
|
A. Pass the :vlopt:`--trace` option to Verilator, and in your top-level
|
||||||
:code:`sc_main()`, call :code:`Verilated::traceEverOn(true)`. Then you
|
:code:`sc_main()`, call :code:`Verilated::traceEverOn(true)`. Then you
|
||||||
may use :code:`$dumpfile` and code:`$dumpvars` to enable traces, same as
|
may use :code:`$dumpfile` and code:`$dumpvars` to enable traces, as
|
||||||
with any Verilog simulator, see the non-SystemC example in
|
with any Verilog simulator; see the non-SystemC example in
|
||||||
:file:`examples/make_tracing_c`. This will trace only the module
|
:file:`examples/make_tracing_c`. This will trace only the module
|
||||||
containing the :code:`$dumpvar`.
|
containing the :code:`$dumpvar`.
|
||||||
|
|
||||||
B. Or, you may create a trace purely from SystemC, which may trace all
|
B. Or, you may create a trace purely from SystemC, which may trace all
|
||||||
Verilated designs in the SystemC model. Create a VerilatedVcdSc object
|
Verilated designs in the SystemC model. Create a VerilatedVcdSc object
|
||||||
as you would create a normal SystemC trace file. For an example, see
|
as you would create a standard SystemC trace file. For an example, see
|
||||||
the call to ``VerilatedVcdSc`` in the
|
the call to ``VerilatedVcdSc`` in the
|
||||||
:file:`examples/make_tracing_sc/sc_main.cpp` file of the distribution,
|
:file:`examples/make_tracing_sc/sc_main.cpp` file of the distribution,
|
||||||
and below.
|
and below.
|
||||||
|
|
||||||
C. Alternatively you may use the C++ trace mechanism described in the
|
C. Alternatively, you may use the C++ trace mechanism described in the
|
||||||
previous question, note the timescale and timeprecision will be
|
previous question; note that the timescale and timeprecision will be
|
||||||
inherited from your SystemC settings.
|
inherited from your SystemC settings.
|
||||||
|
|
||||||
.. code-block:: C++
|
.. code-block:: C++
|
||||||
@@ -181,7 +200,7 @@ C. Alternatively you may use the C++ trace mechanism described in the
|
|||||||
|
|
||||||
#include "verilated_vcd_sc.h"
|
#include "verilated_vcd_sc.h"
|
||||||
...
|
...
|
||||||
int main(int argc, char** argv, char** env) {
|
int main(int argc, char** argv) {
|
||||||
...
|
...
|
||||||
Verilated::traceEverOn(true);
|
Verilated::traceEverOn(true);
|
||||||
VerilatedVcdSc* tfp = new VerilatedVcdSc;
|
VerilatedVcdSc* tfp = new VerilatedVcdSc;
|
||||||
@@ -198,53 +217,49 @@ C. Alternatively you may use the C++ trace mechanism described in the
|
|||||||
You also need to compile :file:`verilated_vcd_sc.cpp` and
|
You also need to compile :file:`verilated_vcd_sc.cpp` and
|
||||||
:file:`verilated_vcd_c.cpp` and add them to your link, preferably by adding
|
:file:`verilated_vcd_c.cpp` and add them to your link, preferably by adding
|
||||||
the dependencies in your Makefile's :code:`$(VK_GLOBAL_OBJS)` link rule.
|
the dependencies in your Makefile's :code:`$(VK_GLOBAL_OBJS)` link rule.
|
||||||
This is done for you if using the Verilator :vlopt:`--exe` option.
|
This is done for you if you are using the Verilator :vlopt:`--binary` or
|
||||||
|
:vlopt:`--exe` option.
|
||||||
|
|
||||||
You can call :code:`->trace()` on multiple Verilated objects with the same
|
You can call :code:`->trace()` on multiple Verilated objects with the same
|
||||||
trace file if you want all data to land in the same output file.
|
trace file if you want all data to land in the same output file.
|
||||||
|
|
||||||
When using SystemC 2.3, the SystemC library must have been built with the
|
|
||||||
experimental simulation phase callback based tracing disabled. This is
|
|
||||||
disabled by default when building SystemC with its configure based build
|
|
||||||
system, but when building SystemC with CMake, you must pass
|
|
||||||
``-DENABLE_PHASE_CALLBACKS_TRACING=OFF`` to disable this feature.
|
|
||||||
|
|
||||||
|
|
||||||
How do I generate FST waveforms (traces) in C++ or SystemC?
|
How do I generate FST waveforms (traces) in C++ or SystemC?
|
||||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
FST is a trace file format developed by GTKWave. Verilator provides basic
|
FST is a trace file format developed by GTKWave. Verilator provides basic
|
||||||
FST support. To dump traces in FST format, add the :vlopt:`--trace-fst`
|
FST support. To dump traces in FST format, add the :vlopt:`--trace-fst`
|
||||||
option to Verilator and either A. use :code:`$dumpfile & $dumpvars` in
|
option to Verilator and either:
|
||||||
Verilog as described in the VCD example above,
|
|
||||||
|
Use :code:`$dumpfile & $dumpvars` in Verilog as described in the VCD
|
||||||
|
example above,
|
||||||
|
|
||||||
Or, in C++ change the include described in the VCD example above:
|
Or, in C++ change the include described in the VCD example above:
|
||||||
|
|
||||||
.. code-block:: C++
|
.. code-block:: C++
|
||||||
|
|
||||||
#include "verilated_fst_c.h"
|
#include "verilated_fst_c.h"
|
||||||
VerilatedFstC* tfp = new VerilatedFstC;
|
VerilatedFstC* tfp = new VerilatedFstC;
|
||||||
|
|
||||||
|
|
||||||
Or, in SystemC change the include described in the VCD example above:
|
Or, in SystemC, change the include described in the VCD example above:
|
||||||
|
|
||||||
.. code-block:: C++
|
.. code-block:: C++
|
||||||
|
|
||||||
#include "verilated_fst_sc.h"
|
#include "verilated_fst_sc.h"
|
||||||
VerilatedFstC* tfp = new VerilatedFstSc;
|
VerilatedFstC* tfp = new VerilatedFstSc;
|
||||||
|
|
||||||
|
|
||||||
Note that currently supporting both FST and VCD in a single simulation is
|
Currently, supporting FST and VCD in a single simulation is not supported,
|
||||||
impossible, but such requirement should be rare. You can however ifdef
|
but such usage should be unlikely. You can however ifdef around the trace
|
||||||
around the trace format in your C++ main loop, and select VCD or FST at
|
format in your C++ main loop, and select VCD or FST at compile time.
|
||||||
build time, should you require.
|
|
||||||
|
|
||||||
|
|
||||||
How do I view waveforms (aka dumps or traces)?
|
How do I view waveforms (aka dumps or traces)?
|
||||||
""""""""""""""""""""""""""""""""""""""""""""""
|
""""""""""""""""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
Verilator creates standard VCD (Value Change Dump) and FST files. VCD
|
Verilator creates standard VCD (Value Change Dump) and FST files. VCD
|
||||||
files are viewable with the open source GTKWave (recommended) or Dinotrace
|
files are viewable with the open-source GTKWave (recommended), or Dinotrace
|
||||||
(legacy) programs, or any of the many closed-source offerings; FST is
|
(legacy) programs, or any of the many closed-source offerings; FST is
|
||||||
supported only by GTKWave.
|
supported only by GTKWave.
|
||||||
|
|
||||||
@@ -257,20 +272,20 @@ A. Instead of calling ``VerilatedVcdC->open`` or ``$dumpvars`` at the
|
|||||||
tracing to begin.
|
tracing to begin.
|
||||||
|
|
||||||
B. Add the :option:`/*verilator&32;tracing_off*/` metacomment to any very
|
B. Add the :option:`/*verilator&32;tracing_off*/` metacomment to any very
|
||||||
low level modules you never want to trace (such as perhaps library
|
low-level modules you never want to trace (such as perhaps library
|
||||||
cells).
|
cells).
|
||||||
|
|
||||||
C. Use the :vlopt:`--trace-depth` option to limit the depth of tracing, for
|
C. Use the :vlopt:`--trace-depth` option to limit the tracing depth, for
|
||||||
example :vlopt:`--trace-depth 1 <--trace-depth>` to see only the top
|
example :vlopt:`--trace-depth 1 <--trace-depth>` to see only the
|
||||||
level signals.
|
top-level signals.
|
||||||
|
|
||||||
D. You can also consider using FST tracing instead of VCD. FST dumps are a
|
D. You can also consider using FST tracing instead of VCD. FST dumps are a
|
||||||
fraction of the size of the equivalent VCD. FST tracing can be slower
|
fraction of the size of the equivalent VCD. FST tracing can be slower
|
||||||
than VCD tracing, but it might be the only option if the VCD file size
|
than VCD tracing, but it might be the only option if the VCD file size
|
||||||
is prohibitively large.
|
is prohibitively large.
|
||||||
|
|
||||||
E. Be sure you write your trace files to a local solid-state drive, instead
|
E. Write your trace files to a machine-local solid-state drive instead of a
|
||||||
of to a network drive. Network drives are generally far slower.
|
network drive. Network drives are generally far slower.
|
||||||
|
|
||||||
|
|
||||||
Where is the translate_off command? (How do I ignore a construct?)
|
Where is the translate_off command? (How do I ignore a construct?)
|
||||||
@@ -297,7 +312,7 @@ Why do I get "unexpected 'do'" or "unexpected 'bit'" errors?
|
|||||||
|
|
||||||
The words \ ``do``\ , \ ``bit``\ , \ ``ref``\ , \ ``return``\ , and others
|
The words \ ``do``\ , \ ``bit``\ , \ ``ref``\ , \ ``return``\ , and others
|
||||||
are reserved keywords in SystemVerilog. Older Verilog code might use these
|
are reserved keywords in SystemVerilog. Older Verilog code might use these
|
||||||
as identifiers. You should change your code to not use them to ensure it
|
as identifiers, and you should change your code to not use them to ensure it
|
||||||
works with newer tools. Alternatively, surround them by the Verilog
|
works with newer tools. Alternatively, surround them by the Verilog
|
||||||
2005/SystemVerilog begin_keywords pragma to indicate Verilog 2001 code.
|
2005/SystemVerilog begin_keywords pragma to indicate Verilog 2001 code.
|
||||||
|
|
||||||
@@ -309,7 +324,7 @@ works with newer tools. Alternatively, surround them by the Verilog
|
|||||||
`end_keywords
|
`end_keywords
|
||||||
|
|
||||||
|
|
||||||
If you want the whole design to be parsed as Verilog 2001, see the
|
If you want the whole design parsed as Verilog 2001, see the
|
||||||
:vlopt:`--default-language` option.
|
:vlopt:`--default-language` option.
|
||||||
|
|
||||||
|
|
||||||
@@ -326,11 +341,11 @@ Why do I get "undefined reference to sc_time_stamp()?
|
|||||||
|
|
||||||
In Verilator 4.200 and later, using the timeInc function is recommended
|
In Verilator 4.200 and later, using the timeInc function is recommended
|
||||||
instead. See the :ref:`Connecting to C++` examples. Some linkers (MSVC++)
|
instead. See the :ref:`Connecting to C++` examples. Some linkers (MSVC++)
|
||||||
still require :code:`sc_time_stamp()` to be defined, either define this
|
still require :code:`sc_time_stamp()` to be defined; either define this
|
||||||
with :code:`double sc_time_stamp() { return 0; }` or compile the Verilated
|
with :code:`double sc_time_stamp() { return 0; }` or compile the Verilated
|
||||||
code with :code:`-CFLAGS -DVL_TIME_CONTEXT`.
|
code with :code:`-CFLAGS -DVL_TIME_CONTEXT`.
|
||||||
|
|
||||||
Prior to Verilator 4.200, the :code:`sc_time_stamp()` function needs to be
|
Before Verilator 4.200, the :code:`sc_time_stamp()` function needs to be
|
||||||
defined in C++ (non SystemC) to return the current simulation time.
|
defined in C++ (non SystemC) to return the current simulation time.
|
||||||
|
|
||||||
|
|
||||||
@@ -340,8 +355,8 @@ Why do I get "undefined reference to \`VL_RAND_RESET_I' or \`Verilated::...'"?
|
|||||||
You need to link your compiled Verilated code against the
|
You need to link your compiled Verilated code against the
|
||||||
:code:`verilated.cpp` file found in the include directory of the Verilator
|
:code:`verilated.cpp` file found in the include directory of the Verilator
|
||||||
kit. This is one target in the ``$(VK_GLOBAL_OBJS)`` make variable, which
|
kit. This is one target in the ``$(VK_GLOBAL_OBJS)`` make variable, which
|
||||||
should be part of your Makefile's link rule. If you use :vlopt:`--exe`,
|
should be part of your Makefile's link rule. If you use :vlopt:`--exe` or
|
||||||
this is done for you.
|
:vlopt:`--binary`, this is done for you.
|
||||||
|
|
||||||
|
|
||||||
Is the PLI supported?
|
Is the PLI supported?
|
||||||
@@ -353,17 +368,17 @@ also use the "import DPI" SystemVerilog feature to call C code (see the
|
|||||||
chapter above). There is also limited VPI access to public signals.
|
chapter above). There is also limited VPI access to public signals.
|
||||||
|
|
||||||
If you want something more complex, since Verilator emits standard C++
|
If you want something more complex, since Verilator emits standard C++
|
||||||
code, you can simply write your own C++ routines that can access and modify
|
code, you can write C++ routines that can access and modify signal
|
||||||
signal values without needing any PLI interface code, and call it with
|
values without needing any PLI interface code, and call it with
|
||||||
$c("{any_c++_statement}").
|
$c("{any_c++_statement}").
|
||||||
|
|
||||||
See the :ref:`Connecting` section.
|
See the :ref:`Connecting` section.
|
||||||
|
|
||||||
|
|
||||||
How do I make a Verilog module that contain a C++ object?
|
How do I make a Verilog module that contains a C++ object?
|
||||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
You need to add the object to the structure that Verilator creates, then
|
You need to add the object to the structure Verilator creates, then
|
||||||
use $c to call a method inside your object. The
|
use $c to call a method inside your object. The
|
||||||
:file:`test_regress/t/t_extend_class` files in the distribution show an
|
:file:`test_regress/t/t_extend_class` files in the distribution show an
|
||||||
example of how to do this.
|
example of how to do this.
|
||||||
@@ -372,9 +387,9 @@ example of how to do this.
|
|||||||
How do I get faster build times?
|
How do I get faster build times?
|
||||||
""""""""""""""""""""""""""""""""
|
""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
* When running make, pass the make variable VM_PARALLEL_BUILDS=1 so that
|
* When running make, pass the make variable VM_PARALLEL_BUILDS=1, so that
|
||||||
builds occur in parallel. Note this is now set by default if an output
|
builds occur in parallel. Note this is now set by default if an output
|
||||||
file was large enough to be split due to the :vlopt:`--output-split`
|
file is large enough to be split due to the :vlopt:`--output-split`
|
||||||
option.
|
option.
|
||||||
|
|
||||||
* Verilator emits any infrequently executed "cold" routines into separate
|
* Verilator emits any infrequently executed "cold" routines into separate
|
||||||
@@ -385,17 +400,17 @@ How do I get faster build times?
|
|||||||
* Use a recent compiler. Newer compilers tend to be faster.
|
* Use a recent compiler. Newer compilers tend to be faster.
|
||||||
|
|
||||||
* Compile in parallel on many machines and use caching; see the web for the
|
* Compile in parallel on many machines and use caching; see the web for the
|
||||||
ccache, distcc and icecream packages. ccache will skip GCC runs between
|
ccache, sccache, distcc, or icecream packages. ccache will skip GCC runs between
|
||||||
identical source builds, even across different users. If ccache was
|
identical source builds, even across different users. If ccache was
|
||||||
installed when Verilator was built it is used, or see OBJCACHE
|
installed when Verilator was built, it is used, or see OBJCACHE
|
||||||
environment variable to override this. Also see the
|
environment variable to override this. Also see the
|
||||||
:vlopt:`--output-split` option and :ref: `Profiling ccache efficiency`
|
:vlopt:`--output-split` option and :ref: `Profiling ccache efficiency`.
|
||||||
|
|
||||||
* To reduce the compile time of classes that use a Verilated module (e.g. a
|
* To reduce the compile time of classes that use a Verilated module (e.g., a
|
||||||
top CPP file) you may wish to add a
|
top CPP file) you may wish to add a
|
||||||
:option:`/*verilator&32;no_inline_module*/` metacomment to your top level
|
:option:`/*verilator&32;no_inline_module*/` metacomment to your top-level
|
||||||
module. This will decrease the amount of code in the model's Verilated
|
module. This will decrease the amount of code in the model's Verilated
|
||||||
class, improving compile times of any instantiating top level C++ code,
|
class, improving compile times of any instantiating top-level C++ code,
|
||||||
at a relatively small cost of execution performance.
|
at a relatively small cost of execution performance.
|
||||||
|
|
||||||
* Use :ref:`hierarchical verilation`.
|
* Use :ref:`hierarchical verilation`.
|
||||||
@@ -405,7 +420,7 @@ Why do so many files need to recompile when I add a signal?
|
|||||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
Adding a new signal requires the symbol table to be recompiled. Verilator
|
Adding a new signal requires the symbol table to be recompiled. Verilator
|
||||||
uses one large symbol table, as that results in 2-3 less assembly
|
uses one large symbol table, resulting in 2-3 fewer assembly
|
||||||
instructions for each signal access. This makes the execution time 10-15%
|
instructions for each signal access. This makes the execution time 10-15%
|
||||||
faster, but can result in more compilations when something changes.
|
faster, but can result in more compilations when something changes.
|
||||||
|
|
||||||
@@ -433,8 +448,8 @@ How do I access signals in C?
|
|||||||
|
|
||||||
The best thing to do is to make a SystemVerilog "export DPI" task or
|
The best thing to do is to make a SystemVerilog "export DPI" task or
|
||||||
function that accesses that signal, as described in the DPI chapter in the
|
function that accesses that signal, as described in the DPI chapter in the
|
||||||
manual and DPI tutorials on the web. This will allow Verilator to better
|
manual and DPI tutorials on the web. This will allow Verilator to
|
||||||
optimize the model and should be portable across simulators.
|
optimize the model better and should be portable across simulators.
|
||||||
|
|
||||||
If you really want raw access to the signals, declare the signals you will
|
If you really want raw access to the signals, declare the signals you will
|
||||||
be accessing with a :option:`/*verilator&32;public*/` metacomment before
|
be accessing with a :option:`/*verilator&32;public*/` metacomment before
|
||||||
@@ -443,17 +458,17 @@ the signal, as you would any other member variable.
|
|||||||
|
|
||||||
Signals are the smallest of 8-bit unsigned chars (equivalent to uint8_t),
|
Signals are the smallest of 8-bit unsigned chars (equivalent to uint8_t),
|
||||||
16-bit unsigned shorts (uint16_t), 32-bit unsigned longs (uint32_t), or
|
16-bit unsigned shorts (uint16_t), 32-bit unsigned longs (uint32_t), or
|
||||||
64-bit unsigned long longs (uint64_t) that fits the width of the signal.
|
64-bit unsigned long longs (uint64_t) that fit the width of the signal.
|
||||||
Generally, you can use just uint32_t's for 1 to 32 bits, or vluint64_t for
|
Generally, you can use just uint32_t's for 1 to 32 bits, or uint64_t for
|
||||||
1 to 64 bits, and the compiler will properly up-convert smaller entities.
|
1 to 64 bits, and the compiler will properly up-convert smaller entities.
|
||||||
Note even signed ports are declared as unsigned; you must sign extend
|
Note that even signed ports are declared as unsigned; you must sign extend
|
||||||
yourself to the appropriate signal width.
|
yourself to the appropriate signal width.
|
||||||
|
|
||||||
Signals wider than 64 bits are stored as an array of 32-bit uint32_t's.
|
Signals wider than 64 bits are stored as an array of 32-bit uint32_t's.
|
||||||
Thus to read bits 31:0, access signal[0], and for bits 63:32, access
|
Thus, to read bits 31:0, access signal[0], and for bits 63:32, access
|
||||||
signal[1]. Unused bits (for example bit numbers 65-96 of a 65-bit vector)
|
signal[1]. Unused bits (for example, bit numbers 65-96 of a 65-bit vector)
|
||||||
will always be zero. If you change the value you must make sure to pack
|
will always be zero. If you change the value, you must pack
|
||||||
zeros in the unused bits or core-dumps may result, because Verilator strips
|
zeros in the unused bits, or core-dumps may result because Verilator strips
|
||||||
array bound checks where it believes them to be unnecessary to improve
|
array bound checks where it believes them to be unnecessary to improve
|
||||||
performance.
|
performance.
|
||||||
|
|
||||||
@@ -470,20 +485,20 @@ From the sc_main.cpp file, you'd then:
|
|||||||
|
|
||||||
#include "Vour.h"
|
#include "Vour.h"
|
||||||
#include "Vour_our.h"
|
#include "Vour_our.h"
|
||||||
cout << "clock is " << top->our->clk << endl;
|
std::cout << "clock is " << top->our->clk << std::endl;
|
||||||
|
|
||||||
|
|
||||||
In this example, clk is a bool you can read or set as any other variable.
|
In this example, clk is a bool you can read or set as any other variable.
|
||||||
The value of normal signals may be set, though clocks shouldn't be changed
|
The value of normal signals may be set, though your code shouldn't change
|
||||||
by your code or you'll get strange results.
|
clocks, or you'll get strange results.
|
||||||
|
|
||||||
|
|
||||||
Should a module be in Verilog or SystemC?
|
Should a module be in Verilog or SystemC?
|
||||||
"""""""""""""""""""""""""""""""""""""""""
|
"""""""""""""""""""""""""""""""""""""""""
|
||||||
|
|
||||||
Sometimes there is a block that just interconnects instances, and have a
|
Sometimes there is a block that only interconnects instances, and you have a
|
||||||
choice as to if you write it in Verilog or SystemC. Everything else being
|
choice if you write it in Verilog or SystemC. Everything else being
|
||||||
equal, best performance is when Verilator sees all of the design. So, look
|
equal, the best performance is when Verilator sees all of the design. So, look
|
||||||
at the hierarchy of your design, labeling instances as to if they are
|
at the hierarchy of your design, labeling instances as to if they are
|
||||||
SystemC or Verilog. Then:
|
SystemC or Verilog. Then:
|
||||||
|
|
||||||
@@ -494,6 +509,6 @@ SystemC or Verilog. Then:
|
|||||||
|
|
||||||
* A module with only Verilog instances below can be either, but for best
|
* A module with only Verilog instances below can be either, but for best
|
||||||
performance should be Verilog. (The exception is if you have a design
|
performance should be Verilog. (The exception is if you have a design
|
||||||
that is instantiated many times; in this case Verilating one of the lower
|
that is instantiated many times; in this case, Verilating one of the lower
|
||||||
modules and instantiating that Verilated instances multiple times into a
|
modules and instantiating that Verilated instances multiple times into a
|
||||||
SystemC module *may* be faster.)
|
SystemC module *may* be faster.)
|
||||||
|
|||||||
+33
-17
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
*****
|
*****
|
||||||
@@ -50,25 +50,29 @@ For --cc/--sc, it creates:
|
|||||||
- Make include file with class names (from --make gmake)
|
- Make include file with class names (from --make gmake)
|
||||||
* - *{prefix}*\ _hier.mk
|
* - *{prefix}*\ _hier.mk
|
||||||
- Make file for hierarchy blocks (from --make gmake)
|
- Make file for hierarchy blocks (from --make gmake)
|
||||||
* - *{prefix|*\ _hierMkArgs.f
|
* - *{prefix}*\ __hierMkArgs.f
|
||||||
- Arguments for hierarchical Verilation (from --make gmake)
|
- Arguments for hierarchical Verilation (from --make gmake)
|
||||||
* - *{prefix}*\ _hierCMakeArgs.f
|
* - *{prefix}*\ __hierCMakeArgs.f
|
||||||
- Arguments for hierarchical Verilation (from --make cmake)
|
- Arguments for hierarchical Verilation (from --make cmake)
|
||||||
* - *{prefix}*\ .h
|
* - *{prefix}*\ .h
|
||||||
- Model header
|
- Model header
|
||||||
* - *{prefix}*\ .cpp
|
* - *{prefix}*\ .cpp
|
||||||
- Model C++ file
|
- Model C++ file
|
||||||
* - *{prefix}*\ ___024root.h
|
* - *{prefix}*\ ___024root.h
|
||||||
- Top level (SystemVerilog $root) internal header file
|
- Top-level internal header file (from SystemVerilog $root)
|
||||||
* - *{prefix}*\ ___024root.cpp
|
* - *{prefix}*\ ___024root.cpp
|
||||||
- Top level (SystemVerilog $root) internal C++ file
|
- Top-level internal C++ file (from SystemVerilog $root)
|
||||||
* - *{prefix}*___024root*{__n}*\ .cpp
|
* - *{prefix}*\ ___024root\ *{__n}*\ .cpp
|
||||||
- Additional top level internal C++ files (from --output-split)
|
- Additional top-level internal C++ files
|
||||||
|
* - *{prefix}*\ ___024root\ *{__DepSet_hash__n}*\ .cpp
|
||||||
|
- Additional top-level internal C++ files (hashed to reduce build times)
|
||||||
* - *{prefix}*\ ___024root__Slow\ *{__n}*\ .cpp
|
* - *{prefix}*\ ___024root__Slow\ *{__n}*\ .cpp
|
||||||
- Infrequent cold routines
|
- Infrequent cold routines
|
||||||
* - *{prefix}*\ ___024root__Trace{__n}*\ .cpp
|
* - *{prefix}*\ ___024root\ *{__DepSet_hash__n}*\ .cpp
|
||||||
|
- Infrequent cold routines (hashed to reduce build times)
|
||||||
|
* - *{prefix}*\ ___024root__Trace\ *{__n}*\ .cpp
|
||||||
- Wave file generation code (from --trace)
|
- Wave file generation code (from --trace)
|
||||||
* - *{prefix}*\ ___024root__Trace__Slow{__n}*\ .cpp
|
* - *{prefix}*\ ___024root__Trace__Slow\ *{__n}*\ .cpp
|
||||||
- Wave file generation code (from --trace)
|
- Wave file generation code (from --trace)
|
||||||
* - *{prefix}*\ __Dpi.h
|
* - *{prefix}*\ __Dpi.h
|
||||||
- DPI import and export declarations (from --dpi)
|
- DPI import and export declarations (from --dpi)
|
||||||
@@ -87,7 +91,9 @@ For --cc/--sc, it creates:
|
|||||||
* - *{prefix}{each_verilog_module}*\ .cpp
|
* - *{prefix}{each_verilog_module}*\ .cpp
|
||||||
- Lower level internal C++ files
|
- Lower level internal C++ files
|
||||||
* - *{prefix}{each_verilog_module}{__n}*\ .cpp
|
* - *{prefix}{each_verilog_module}{__n}*\ .cpp
|
||||||
- Additional lower C++ files (from --output-split)
|
- Additional lower C++ files
|
||||||
|
* - *{prefix}{each_verilog_module}{__DepSet_hash__n}*\ .cpp
|
||||||
|
- Additional lower C++ files (hashed to reduce build times)
|
||||||
|
|
||||||
For --hierarchy mode, it creates:
|
For --hierarchy mode, it creates:
|
||||||
|
|
||||||
@@ -100,12 +106,16 @@ For --hierarchy mode, it creates:
|
|||||||
* - *{prefix}*\ __hier.dir
|
* - *{prefix}*\ __hier.dir
|
||||||
- Directory to store .dot, .vpp, .tree of top module (from --hierarchy)
|
- Directory to store .dot, .vpp, .tree of top module (from --hierarchy)
|
||||||
|
|
||||||
In certain debug and other modes, it also creates:
|
In specific debug and other modes, it also creates:
|
||||||
|
|
||||||
.. list-table::
|
.. list-table::
|
||||||
|
|
||||||
* - *{prefix}*\ .xml
|
* - *{prefix}*\ .xml
|
||||||
- XML tree information (from --xml)
|
- XML tree information (from --xml)
|
||||||
|
* - *{prefix}*\ .tree.json
|
||||||
|
- JSON tree information (from --json-only)
|
||||||
|
* - *{prefix}*\ .tree.meta.json
|
||||||
|
- JSON tree metadata (from --json-only)
|
||||||
* - *{prefix}*\ __cdc.txt
|
* - *{prefix}*\ __cdc.txt
|
||||||
- Clock Domain Crossing checks (from --cdc)
|
- Clock Domain Crossing checks (from --cdc)
|
||||||
* - *{prefix}*\ __stats.txt
|
* - *{prefix}*\ __stats.txt
|
||||||
@@ -120,8 +130,10 @@ In certain debug and other modes, it also creates:
|
|||||||
- Debugging graph files (from --debug)
|
- Debugging graph files (from --debug)
|
||||||
* - *{prefix}{misc}*\ .tree
|
* - *{prefix}{misc}*\ .tree
|
||||||
- Debugging files (from --debug)
|
- Debugging files (from --debug)
|
||||||
* - {mod_prefix}_{each_verilog_module}*{__n}*\ .vpp
|
* - *{prefix}*\ __inputs\ .vpp
|
||||||
- Pre-processed verilog (from --debug)
|
- Pre-processed verilog for all files (from --debug)
|
||||||
|
* - *{prefix}*\ _ *{each_verilog_base_filename}*\ .vpp
|
||||||
|
- Pre-processed verilog for each file (from --debug)
|
||||||
|
|
||||||
After running Make, the C++ compiler may produce the following:
|
After running Make, the C++ compiler may produce the following:
|
||||||
|
|
||||||
@@ -137,6 +149,10 @@ After running Make, the C++ compiler may produce the following:
|
|||||||
- Intermediate objects
|
- Intermediate objects
|
||||||
* - *{prefix}*\
|
* - *{prefix}*\
|
||||||
- Final executable (from --exe)
|
- Final executable (from --exe)
|
||||||
|
* - lib\ *{prefix}*\ .a
|
||||||
|
- Final archive (default lib mode)
|
||||||
|
* - libverilated.a
|
||||||
|
- Runtime for verilated model (default lib mode)
|
||||||
* - *{prefix}*\ __ALL.a
|
* - *{prefix}*\ __ALL.a
|
||||||
- Library of all Verilated objects
|
- Library of all Verilated objects
|
||||||
* - *{prefix}*\ __ALL.cpp
|
* - *{prefix}*\ __ALL.cpp
|
||||||
@@ -155,13 +171,13 @@ The Verilated executable may produce the following:
|
|||||||
* - gmon.out
|
* - gmon.out
|
||||||
- GCC/clang code profiler output, often fed into :command:`verilator_profcfunc`
|
- GCC/clang code profiler output, often fed into :command:`verilator_profcfunc`
|
||||||
* - profile.vlt
|
* - profile.vlt
|
||||||
- -profile data file for :ref:`Thread PGO`
|
- --prof-pgo data file for :ref:`Thread PGO`
|
||||||
* - profile_threads.dat
|
* - profile_exec.dat
|
||||||
- -profile-threads data file for :command:`verilator_gnatt`
|
- --prof-exec data file for :command:`verilator_gantt`
|
||||||
|
|
||||||
Verilator_gantt may produce the following:
|
Verilator_gantt may produce the following:
|
||||||
|
|
||||||
.. list-table::
|
.. list-table::
|
||||||
|
|
||||||
* - profile_threads.vcd
|
* - profile_exec.vcd
|
||||||
- Gantt report waveform output
|
- Gantt report waveform output
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
######################
|
######################
|
||||||
@@ -12,6 +12,7 @@ Verilator User's Guide
|
|||||||
overview.rst
|
overview.rst
|
||||||
examples.rst
|
examples.rst
|
||||||
install.rst
|
install.rst
|
||||||
|
install-cmake.rst
|
||||||
|
|
||||||
|
|
||||||
.. toctree::
|
.. toctree::
|
||||||
|
|||||||
@@ -0,0 +1,72 @@
|
|||||||
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
|
.. _CMakeInstallation:
|
||||||
|
|
||||||
|
******************
|
||||||
|
CMake Installation
|
||||||
|
******************
|
||||||
|
|
||||||
|
This section discusses how to build and install Verilator using cmake.
|
||||||
|
Currently cmake is only officially supported for Windows builds (not Linux).
|
||||||
|
|
||||||
|
.. _Tools Install:
|
||||||
|
|
||||||
|
Quick Install
|
||||||
|
=============
|
||||||
|
|
||||||
|
1. Install Python for your platform from https://www.python.org/downloads/.
|
||||||
|
2. Install CMake for your platform from https://cmake.org/download/ or build it from source.
|
||||||
|
3. If the compiler of your choice is MSVC, then install https://visualstudio.microsoft.com/downloads/.
|
||||||
|
If the compiler of your choice is Clang, then install https://releases.llvm.org/download.html or build it from source.
|
||||||
|
4. For flex and bison use https://github.com/lexxmark/winflexbison to build and install.
|
||||||
|
5. For build on Windows using MSVC set environment variable WIN_FLEX_BISON to install directory.
|
||||||
|
For build on Windows/Linux/OS-X using ninja set the environment variable
|
||||||
|
FLEX_INCLUDE to the directory containing FlexLexer.h and ensure that flex/bison
|
||||||
|
is available within the PATH.
|
||||||
|
|
||||||
|
To obtain verilator sources download https://github.com/verilator/verilator/archive/refs/heads/master.zip
|
||||||
|
or clone https://github.com/verilator/verilator using git :ref:`Obtain Sources`.
|
||||||
|
|
||||||
|
To build using MSVC:
|
||||||
|
|
||||||
|
::
|
||||||
|
|
||||||
|
cd verilator # directory containing source files of verilator
|
||||||
|
mkdir build
|
||||||
|
cmake .. -DCMAKE_BUILD_TYPE=Release --install-prefix $PWD/../install
|
||||||
|
cmake --build . --config Release
|
||||||
|
cmake --install . --prefix $PWD/../install
|
||||||
|
|
||||||
|
|
||||||
|
To build using ninja:
|
||||||
|
|
||||||
|
::
|
||||||
|
|
||||||
|
cd verilator
|
||||||
|
mkdir build
|
||||||
|
cmake -G Ninja .. -DCMAKE_BUILD_TYPE=Release --install-prefix $PWD/../install -DCMAKE_MAKE_PROGRAM=<path to ninja binary> -DBISON_EXECUTABLE=<path to bison> -DFLEX_EXECUTABLE=<path to flex>
|
||||||
|
<path to ninja binary> #execute ninja
|
||||||
|
cmake --install . --prefix $PWD/../install
|
||||||
|
|
||||||
|
|
||||||
|
.. _CMake Usage:
|
||||||
|
|
||||||
|
Usage
|
||||||
|
=====
|
||||||
|
|
||||||
|
To use Verilator set the environment variable ``VERILATOR_ROOT`` to the
|
||||||
|
install directory specified in the above build.
|
||||||
|
|
||||||
|
Example
|
||||||
|
=======
|
||||||
|
|
||||||
|
::
|
||||||
|
|
||||||
|
cd verilator/examples
|
||||||
|
cd cmake_hello_c
|
||||||
|
mkdir build
|
||||||
|
cd build
|
||||||
|
cmake .. # cmake -G Ninja ..
|
||||||
|
cmake --build . --config Release # ninja
|
||||||
|
# execute the generated binary
|
||||||
+53
-54
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. _Installation:
|
.. _Installation:
|
||||||
@@ -16,14 +16,14 @@ Package Manager Quick Install
|
|||||||
|
|
||||||
Using a distribution's package manager is the easiest way to get
|
Using a distribution's package manager is the easiest way to get
|
||||||
started. (Note packages are unlikely to have the most recent version, so
|
started. (Note packages are unlikely to have the most recent version, so
|
||||||
:ref:`Git Install`, might be a better alternative.) To install as a
|
:ref:`Git Install` might be a better alternative.) To install as a
|
||||||
package:
|
package:
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
apt-get install verilator # On Ubuntu
|
apt-get install verilator # On Ubuntu
|
||||||
|
|
||||||
For other distributions refer to `Repology Verilator Distro Packages
|
For other distributions, refer to `Repology Verilator Distro Packages
|
||||||
<https://repology.org/project/verilator>`__.
|
<https://repology.org/project/verilator>`__.
|
||||||
|
|
||||||
.. _Git Install:
|
.. _Git Install:
|
||||||
@@ -31,15 +31,15 @@ For other distributions refer to `Repology Verilator Distro Packages
|
|||||||
Git Quick Install
|
Git Quick Install
|
||||||
=================
|
=================
|
||||||
|
|
||||||
Installing Verilator from Git provides the most flexibility. For additional
|
Installing Verilator from Git provides the most flexibility; for additional
|
||||||
options and details see :ref:`Detailed Build Instructions` below.
|
options and details, see :ref:`Detailed Build Instructions` below.
|
||||||
|
|
||||||
In brief, to install from git:
|
In brief, to install from git:
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
# Prerequisites:
|
# Prerequisites:
|
||||||
#sudo apt-get install git perl python3 make autoconf g++ flex bison ccache
|
#sudo apt-get install git help2man perl python3 make autoconf g++ flex bison ccache
|
||||||
#sudo apt-get install libgoogle-perftools-dev numactl perl-doc
|
#sudo apt-get install libgoogle-perftools-dev numactl perl-doc
|
||||||
#sudo apt-get install libfl2 # Ubuntu only (ignore if gives error)
|
#sudo apt-get install libfl2 # Ubuntu only (ignore if gives error)
|
||||||
#sudo apt-get install libfl-dev # Ubuntu only (ignore if gives error)
|
#sudo apt-get install libfl-dev # Ubuntu only (ignore if gives error)
|
||||||
@@ -68,7 +68,7 @@ In brief, to install from git:
|
|||||||
Detailed Build Instructions
|
Detailed Build Instructions
|
||||||
===========================
|
===========================
|
||||||
|
|
||||||
This section describes details of the build process, and assumes you are
|
This section describes details of the build process and assumes you are
|
||||||
building from Git. For using a pre-built binary for your Linux
|
building from Git. For using a pre-built binary for your Linux
|
||||||
distribution, see instead :ref:`Package Manager Quick Install`.
|
distribution, see instead :ref:`Package Manager Quick Install`.
|
||||||
|
|
||||||
@@ -77,34 +77,42 @@ OS Requirements
|
|||||||
---------------
|
---------------
|
||||||
|
|
||||||
Verilator is developed and has primary testing on Ubuntu, with additional
|
Verilator is developed and has primary testing on Ubuntu, with additional
|
||||||
testing on FreeBSD and Apple OS-X. Versions have also built on Redhat
|
testing on FreeBSD and Apple OS-X. Versions have also been built on Red Hat
|
||||||
Linux, and other flavors of GNU/Linux-ish platforms. Verilator also works
|
Linux, other flavors of GNU/Linux-ish platforms, Windows Subsystem for
|
||||||
on Windows Subsystem for Linux (WSL2), Windows under Cygwin, and Windows
|
Linux (WSL2), Windows under Cygwin, and Windows under MinGW (gcc
|
||||||
under MinGW (gcc -mno-cygwin). Verilated output (not Verilator itself)
|
-mno-cygwin). Verilated output (not Verilator itself) compiles under all
|
||||||
compiles under all the options above, plus using MSVC++.
|
the options above, plus using MSVC++.
|
||||||
|
|
||||||
|
|
||||||
Install Prerequisites
|
Install Prerequisites
|
||||||
---------------------
|
---------------------
|
||||||
|
|
||||||
To build or run Verilator you need these standard packages:
|
To build or run Verilator, you need these standard packages:
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
sudo apt-get install git perl python3 make
|
sudo apt-get install git help2man perl python3 make
|
||||||
sudo apt-get install g++ # Alternatively, clang
|
sudo apt-get install g++ # Alternatively, clang
|
||||||
sudo apt-get install libgz # Non-Ubuntu (ignore if gives error)
|
sudo apt-get install libgz # Non-Ubuntu (ignore if gives error)
|
||||||
sudo apt-get install libfl2 # Ubuntu only (ignore if gives error)
|
sudo apt-get install libfl2 # Ubuntu only (ignore if gives error)
|
||||||
sudo apt-get install libfl-dev # Ubuntu only (ignore if gives error)
|
sudo apt-get install libfl-dev # Ubuntu only (ignore if gives error)
|
||||||
sudo apt-get install zlibc zlib1g zlib1g-dev # Ubuntu only (ignore if gives error)
|
sudo apt-get install zlibc zlib1g zlib1g-dev # Ubuntu only (ignore if gives error)
|
||||||
|
|
||||||
To build or run the following are optional but should be installed for good
|
To build or run Verilator, the following are optional but should be installed
|
||||||
performance:
|
for good performance:
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
sudo apt-get install ccache # If present at build, needed for run
|
sudo apt-get install ccache # If present at build, needed for run
|
||||||
sudo apt-get install libgoogle-perftools-dev numactl perl-doc
|
sudo apt-get install mold # If present at build, needed for run
|
||||||
|
sudo apt-get install libgoogle-perftools-dev numactl
|
||||||
|
|
||||||
|
The following is optional but is recommended for nicely rendered command line
|
||||||
|
help when running Verilator:
|
||||||
|
|
||||||
|
::
|
||||||
|
|
||||||
|
sudo apt-get install perl-doc
|
||||||
|
|
||||||
To build Verilator you will need to install these packages; these do not
|
To build Verilator you will need to install these packages; these do not
|
||||||
need to be present to run Verilator:
|
need to be present to run Verilator:
|
||||||
@@ -117,8 +125,10 @@ Those developing Verilator itself may also want these (see internals.rst):
|
|||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
sudo apt-get install gdb graphviz cmake clang clang-format-11 gprof lcov
|
sudo apt-get install clang clang-format-14 cmake gdb gprof graphviz lcov
|
||||||
sudo pip3 install sphinx sphinx_rtd_theme breathe
|
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 Pod::Perldoc
|
||||||
cpan install Parallel::Forker
|
cpan install Parallel::Forker
|
||||||
|
|
||||||
@@ -142,16 +152,18 @@ To make use of Verilator FST tracing you will want `GTKwave
|
|||||||
required at Verilator build time.
|
required at Verilator build time.
|
||||||
|
|
||||||
|
|
||||||
|
.. _Obtain Sources:
|
||||||
|
|
||||||
Obtain Sources
|
Obtain Sources
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
Get the sources from the git repository: (You need do this only once,
|
Get the sources from the git repository: (You need to do this only once,
|
||||||
ever.)
|
ever.)
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
git clone https://github.com/verilator/verilator # Only first time
|
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
|
## 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:
|
Enter the checkout and determine what version/branch to use:
|
||||||
|
|
||||||
@@ -178,7 +190,7 @@ Create the configuration script:
|
|||||||
Eventual Installation Options
|
Eventual Installation Options
|
||||||
-----------------------------
|
-----------------------------
|
||||||
|
|
||||||
Before configuring the build, you have to decide how you're going to
|
Before configuring the build, you must decide how you're going to
|
||||||
eventually install Verilator onto your system. Verilator will be compiling
|
eventually install Verilator onto your system. Verilator will be compiling
|
||||||
the current value of the environment variables :option:`VERILATOR_ROOT`,
|
the current value of the environment variables :option:`VERILATOR_ROOT`,
|
||||||
:option:`SYSTEMC_INCLUDE`, and :option:`SYSTEMC_LIBDIR` as defaults into
|
:option:`SYSTEMC_INCLUDE`, and :option:`SYSTEMC_LIBDIR` as defaults into
|
||||||
@@ -191,8 +203,9 @@ These are the installation options:
|
|||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
Our personal favorite is to always run Verilator in-place from its Git
|
Our personal favorite is to always run Verilator in-place from its Git
|
||||||
directory. This allows the easiest experimentation and upgrading, and
|
directory (don't run ``make install``). This allows the easiest
|
||||||
allows many versions of Verilator to co-exist on a system.
|
experimentation and upgrading, and allows many versions of Verilator to
|
||||||
|
co-exist on a system.
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
@@ -201,19 +214,20 @@ allows many versions of Verilator to co-exist on a system.
|
|||||||
./configure
|
./configure
|
||||||
# Running will use files from $VERILATOR_ROOT, so no install needed
|
# Running will use files from $VERILATOR_ROOT, so no install needed
|
||||||
|
|
||||||
Note after installing (below steps), a calling program or shell must set
|
Note after installing (see `Installation`_), a calling program or shell
|
||||||
the environment variable :option:`VERILATOR_ROOT` to point to this Git
|
must set the environment variable :option:`VERILATOR_ROOT` to point to this
|
||||||
directory, then execute ``$VERILATOR_ROOT/bin/verilator``, which will find
|
Git directory, then execute ``$VERILATOR_ROOT/bin/verilator``, which will
|
||||||
the path to all needed files.
|
find the path to all needed files.
|
||||||
|
|
||||||
|
|
||||||
2. Install into a specific location
|
2. Install into a Specific Prefix
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
You may eventually be installing onto a project/company-wide "CAD" tools
|
You may be an OS package maintainer building a Verilator package, or you
|
||||||
disk that may support multiple versions of every tool. Tell configure the
|
may eventually be installing onto a project/company-wide "CAD" tools disk
|
||||||
eventual destination directory name. We recommend the destination location
|
that may support multiple versions of every tool. Tell configure the
|
||||||
include the Verilator version name:
|
eventual destination directory name. We recommend that the destination
|
||||||
|
location include the Verilator version name:
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
@@ -222,7 +236,8 @@ include the Verilator version name:
|
|||||||
# For the tarball, use the version number instead of git describe
|
# For the tarball, use the version number instead of git describe
|
||||||
./configure --prefix /CAD_DISK/verilator/`git describe | sed "s/verilator_//"`
|
./configure --prefix /CAD_DISK/verilator/`git describe | sed "s/verilator_//"`
|
||||||
|
|
||||||
Note after installing (below steps), if you use `modulecmd
|
Note after installing (see `Installation`_), you need to add the path to
|
||||||
|
the ``bin`` directory to your ``PATH``. Or, if you use `modulecmd
|
||||||
<http://modules.sourceforge.net/>`__, you'll want a module file like the
|
<http://modules.sourceforge.net/>`__, you'll want a module file like the
|
||||||
following:
|
following:
|
||||||
|
|
||||||
@@ -235,23 +250,7 @@ following:
|
|||||||
prepend-path PKG_CONFIG_PATH $install_root/share/pkgconfig
|
prepend-path PKG_CONFIG_PATH $install_root/share/pkgconfig
|
||||||
|
|
||||||
|
|
||||||
3. Install into a Specific Path
|
3. Install System Globally
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
You may eventually install Verilator into a specific installation prefix,
|
|
||||||
as most GNU tools support:
|
|
||||||
|
|
||||||
::
|
|
||||||
|
|
||||||
unset VERILATOR_ROOT # if your shell is bash
|
|
||||||
unsetenv VERILATOR_ROOT # if your shell is csh
|
|
||||||
./configure --prefix /opt/verilator-VERSION
|
|
||||||
|
|
||||||
Then after installing (below steps) you will need to add
|
|
||||||
``/opt/verilator-VERSION/bin`` to your ``$PATH`` environment variable.
|
|
||||||
|
|
||||||
|
|
||||||
4. Install System Globally
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
The final option is to eventually install Verilator globally, using
|
The final option is to eventually install Verilator globally, using
|
||||||
@@ -263,8 +262,8 @@ configure's default system paths:
|
|||||||
unsetenv VERILATOR_ROOT # if your shell is csh
|
unsetenv VERILATOR_ROOT # if your shell is csh
|
||||||
./configure
|
./configure
|
||||||
|
|
||||||
Then after installing (below) the binaries should be in a location that is
|
Then after installing (see `Installation`_), the binaries should be in a
|
||||||
already in your ``$PATH`` environment variable.
|
location already in your ``$PATH`` environment variable.
|
||||||
|
|
||||||
|
|
||||||
Configure
|
Configure
|
||||||
|
|||||||
+168
-107
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
***************
|
***************
|
||||||
@@ -41,7 +41,7 @@ union, var, void, priority case/if, and unique case/if.
|
|||||||
It also supports .name and .\* interconnection.
|
It also supports .name and .\* interconnection.
|
||||||
|
|
||||||
Verilator partially supports concurrent assert and cover statements; see
|
Verilator partially supports concurrent assert and cover statements; see
|
||||||
the enclosed coverage tests for the syntax which is allowed.
|
the enclosed coverage tests for the allowed syntax.
|
||||||
|
|
||||||
Verilator has limited support for class and related object-oriented
|
Verilator has limited support for class and related object-oriented
|
||||||
constructs.
|
constructs.
|
||||||
@@ -58,8 +58,18 @@ function call-like preprocessor defines, default define arguments,
|
|||||||
SystemVerilog 2017 (IEEE 1800-2017) Support
|
SystemVerilog 2017 (IEEE 1800-2017) Support
|
||||||
-------------------------------------------
|
-------------------------------------------
|
||||||
|
|
||||||
Verilator supports the 2017 "for" loop constructs, and several minor
|
Verilator supports the 2017 "for" loop constructs and several cleanups IEEE
|
||||||
cleanups IEEE made in 1800-2017.
|
made in 1800-2017.
|
||||||
|
|
||||||
|
|
||||||
|
SystemVerilog 2023 (IEEE 1800-2023) Support
|
||||||
|
-------------------------------------------
|
||||||
|
|
||||||
|
Verilator supports some of the 2023 improvements, including triple-quoted
|
||||||
|
string blocks that may include newlines and single quotes.
|
||||||
|
|
||||||
|
Verilator implements a full IEEE 1800-2023 compliant preprocessor,
|
||||||
|
including triple-quoted strings, and \`ifdef expressions.
|
||||||
|
|
||||||
|
|
||||||
Verilog AMS Support
|
Verilog AMS Support
|
||||||
@@ -67,32 +77,98 @@ Verilog AMS Support
|
|||||||
|
|
||||||
Verilator implements a very small subset of Verilog AMS (Verilog Analog and
|
Verilator implements a very small subset of Verilog AMS (Verilog Analog and
|
||||||
Mixed-Signal Extensions) with the subset corresponding to those VMS
|
Mixed-Signal Extensions) with the subset corresponding to those VMS
|
||||||
keywords with near equivalents in the Verilog 2005 or SystemVerilog 2009
|
keywords with near-equivalents in Verilog IEEE 1364 or SystemVerilog
|
||||||
languages.
|
IEEE 1800.
|
||||||
|
|
||||||
AMS parsing is enabled with :vlopt:`--language VAMS <--language>` or
|
AMS parsing is enabled with :vlopt:`--language VAMS <--language>` or
|
||||||
:vlopt:`--language 1800+VAMS <--language>`.
|
:vlopt:`--language 1800+VAMS <--language>`.
|
||||||
|
|
||||||
At present Verilator implements ceil, exp, floor, ln, log, pow, sqrt,
|
Verilator implements ceil, exp, floor, ln, log, pow, sqrt, string, and
|
||||||
string, and wreal.
|
wreal.
|
||||||
|
|
||||||
|
|
||||||
Synthesis Directive Assertion Support
|
Synthesis Directive Assertion Support
|
||||||
-------------------------------------
|
-------------------------------------
|
||||||
|
|
||||||
With the :vlopt:`--assert` option, Verilator reads any :code:`//synopsys
|
With the :vlopt:`--assert` option, Verilator reads any
|
||||||
full_case` or :code:`//synopsys parallel_case` directives. The same
|
|
||||||
applies to any :code:`//ambit synthesis`, :code:`//cadence` or
|
:code:`//synopsys full_case` or :code:`//synopsys parallel_case`
|
||||||
:code:`//pragma` directives of the same form.
|
directives. The same applies to any :code:`//ambit synthesis`,
|
||||||
|
:code:`//cadence` or :code:`//pragma` directives of the same form.
|
||||||
|
|
||||||
When these synthesis directives are discovered, Verilator will either
|
When these synthesis directives are discovered, Verilator will either
|
||||||
formally prove the directive to be true, or failing that, will insert the
|
formally prove the directive to be true, or, failing that, will insert the
|
||||||
appropriate code to detect failing cases at simulation runtime and print an
|
appropriate code to detect failing cases at simulation runtime and print an
|
||||||
"Assertion failed" error message.
|
"Assertion failed" error message.
|
||||||
|
|
||||||
Verilator likewise also asserts any "unique" or "priority" SystemVerilog
|
Verilator likewise also asserts any "unique" or "priority" SystemVerilog
|
||||||
keywords on case statement, as well as "unique" on if statements. However,
|
keywords on case statements, as well as "unique" on if statements. However,
|
||||||
"priority if" is currently simply ignored.
|
"priority if" is currently ignored.
|
||||||
|
|
||||||
|
|
||||||
|
Time
|
||||||
|
====
|
||||||
|
|
||||||
|
With :vlopt:`--timing`, all timing controls are supported:
|
||||||
|
|
||||||
|
* delay statements,
|
||||||
|
* event control statements not only at the top of a process,
|
||||||
|
* intra-assignment timing controls,
|
||||||
|
* net delays,
|
||||||
|
* :code:`wait` statements,
|
||||||
|
|
||||||
|
as well as all flavors of :code:`fork`.
|
||||||
|
|
||||||
|
Compiling a Verilated design that uses these features requires a
|
||||||
|
compiler with C++20 coroutine support, e.g. Clang 5, GCC 10, or newer.
|
||||||
|
|
||||||
|
:code:`#0` delays cause Verilator to issue the :option:`ZERODLY` warning, as
|
||||||
|
they work differently than described in the LRM. They do not schedule process
|
||||||
|
resumption in the Inactive region, though the process will get resumed in the
|
||||||
|
same time slot.
|
||||||
|
|
||||||
|
Rising/falling/turn-off delays are currently unsupported and cause the
|
||||||
|
:option:`RISEFALLDLY` warning.
|
||||||
|
|
||||||
|
Minimum/typical/maximum delays are currently unsupported. The typical delay is
|
||||||
|
always the one chosen. Such expressions cause the :option:`MINTYPMAX` warning.
|
||||||
|
|
||||||
|
Another consequence of using :vlopt:`--timing` is that the :vlopt:`--main`
|
||||||
|
option generates a main file with a proper timing eval loop, eliminating the
|
||||||
|
need for writing any driving C++ code. You can simply compile the
|
||||||
|
simulation (perhaps using :vlopt:`--build`) and run it.
|
||||||
|
|
||||||
|
With :vlopt:`--no-timing`, all timing controls cause the :option:`NOTIMING`
|
||||||
|
error, except:
|
||||||
|
|
||||||
|
* delay statements - they are ignored (as they are in synthesis), though they
|
||||||
|
do issue a :option:`STMTDLY` warning,
|
||||||
|
* intra-assignment timing controls - they are ignored, though they do issue an
|
||||||
|
:option:`ASSIGNDLY` warning,
|
||||||
|
* net delays - they are ignored,
|
||||||
|
* event controls at the top of the procedure,
|
||||||
|
|
||||||
|
Forks cause this error as well, except:
|
||||||
|
|
||||||
|
* forks with no statements,
|
||||||
|
* :code:`fork..join` or :code:`fork..join_any` with one statement,
|
||||||
|
* forks with :vlopt:`--bbox-unsup`.
|
||||||
|
|
||||||
|
If neither :vlopt:`--timing` nor :vlopt:`--no-timing` is specified, all
|
||||||
|
timing controls cause the :option:`NEEDTIMINGOPT` error, except event
|
||||||
|
controls at the top of the process. Forks cause this error as well, except:
|
||||||
|
|
||||||
|
* forks with no statements,
|
||||||
|
* :code:`fork..join` or :code:`fork..join_any` with one statement,
|
||||||
|
* forks with :vlopt:`--bbox-unsup`.
|
||||||
|
|
||||||
|
Timing controls and forks can also be ignored in specific files or parts of
|
||||||
|
files. The :option:`/*verilator&32;timing_off*/` and
|
||||||
|
:option:`/*verilator&32;timing_off*/` metacomments will make Verilator ignore
|
||||||
|
the encompassed timing controls and forks, regardless of the chosen
|
||||||
|
:vlopt:`--timing` or :vlopt:`--no-timing` option. This can also be achieved
|
||||||
|
using the :option:`timing_off` and :option:`timing_off` options in Verilator
|
||||||
|
configuration files.
|
||||||
|
|
||||||
|
|
||||||
.. _Language Limitations:
|
.. _Language Limitations:
|
||||||
@@ -108,15 +184,15 @@ Synthesis Subset
|
|||||||
|
|
||||||
Verilator supports the Synthesis subset with other verification constructs
|
Verilator supports the Synthesis subset with other verification constructs
|
||||||
being added over time. Verilator also simulates events as Synopsys's Design
|
being added over time. Verilator also simulates events as Synopsys's Design
|
||||||
Compiler would; namely given a block of the form:
|
Compiler would, namely given a block of the form:
|
||||||
|
|
||||||
.. code-block:: sv
|
.. code-block:: sv
|
||||||
|
|
||||||
always @(x) y = x & z;
|
always @(x) y = x & z;
|
||||||
|
|
||||||
This will recompute y when there is even a potential for change in x or a
|
This will recompute y when there is a potential for change in x or a change
|
||||||
change in z, that is when the flops computing x or z evaluate (which is
|
in z; that is when the flops computing x or z evaluate (which is what
|
||||||
what Design Compiler will synthesize.) A compliant simulator would only
|
Design Compiler will synthesize.) A compliant simulator will only
|
||||||
calculate y if x changes. We recommend using always_comb to make the code
|
calculate y if x changes. We recommend using always_comb to make the code
|
||||||
run the same everywhere. Also avoid putting $displays in combo blocks, as
|
run the same everywhere. Also avoid putting $displays in combo blocks, as
|
||||||
they may print multiple times when not desired, even on compliant
|
they may print multiple times when not desired, even on compliant
|
||||||
@@ -129,14 +205,14 @@ Signal Naming
|
|||||||
To avoid conflicts with C symbol naming, any character in a signal name
|
To avoid conflicts with C symbol naming, any character in a signal name
|
||||||
that is not alphanumeric nor a single underscore will be replaced by __0hh
|
that is not alphanumeric nor a single underscore will be replaced by __0hh
|
||||||
where hh is the hex code of the character. To avoid conflicts with
|
where hh is the hex code of the character. To avoid conflicts with
|
||||||
Verilator's internal symbols, any double underscore are replaced with
|
Verilator's internal symbols, any double underscore is replaced with
|
||||||
___05F (5F is the hex code of an underscore.)
|
___05F (5F is the hex code of an underscore.)
|
||||||
|
|
||||||
|
|
||||||
Bind
|
Bind
|
||||||
----
|
----
|
||||||
|
|
||||||
sVerilator only supports bind to a target module name, not to an
|
Verilator only supports bind to a target module name, not to an
|
||||||
instance path.
|
instance path.
|
||||||
|
|
||||||
|
|
||||||
@@ -144,14 +220,13 @@ Class
|
|||||||
-----
|
-----
|
||||||
|
|
||||||
Verilator class support is limited but in active development. Verilator
|
Verilator class support is limited but in active development. Verilator
|
||||||
supports members, and methods. Verilator does not support class static
|
supports members, methods, class extend, and class parameters.
|
||||||
members, class extend, or class parameters.
|
|
||||||
|
|
||||||
|
|
||||||
Dotted cross-hierarchy references
|
Dotted cross-hierarchy references
|
||||||
---------------------------------
|
---------------------------------
|
||||||
|
|
||||||
Verilator supports dotted references to variables, functions and tasks in
|
Verilator supports dotted references to variables, functions, and tasks in
|
||||||
different modules. The portion before the dot must have a constant value;
|
different modules. The portion before the dot must have a constant value;
|
||||||
for example a[2].b is acceptable, while a[x].b is generally not.
|
for example a[2].b is acceptable, while a[x].b is generally not.
|
||||||
|
|
||||||
@@ -165,7 +240,7 @@ code.
|
|||||||
Latches
|
Latches
|
||||||
-------
|
-------
|
||||||
|
|
||||||
Verilator is optimized for edge sensitive (flop based) designs. It will
|
Verilator is optimized for edge-sensitive (flop-based) designs. It will
|
||||||
attempt to do the correct thing for latches, but most performance
|
attempt to do the correct thing for latches, but most performance
|
||||||
optimizations will be disabled around the latch.
|
optimizations will be disabled around the latch.
|
||||||
|
|
||||||
@@ -173,17 +248,9 @@ optimizations will be disabled around the latch.
|
|||||||
Structures and Unions
|
Structures and Unions
|
||||||
---------------------
|
---------------------
|
||||||
|
|
||||||
Presently Verilator only supports packed structs and packed unions. Rand
|
All structures and unions are scheduled together, which means that
|
||||||
and randc tags on members are simply ignored. All structures and unions
|
generating one member of a structure from blocking, and another from
|
||||||
are represented as a single vector, which means that generating one member
|
non-blocking assignments is unsupported.
|
||||||
of a structure from blocking, and another from non-blocking assignments is
|
|
||||||
unsupported.
|
|
||||||
|
|
||||||
|
|
||||||
Time
|
|
||||||
----
|
|
||||||
|
|
||||||
All delays (#) are ignored, as they are in synthesis.
|
|
||||||
|
|
||||||
|
|
||||||
.. _Unknown States:
|
.. _Unknown States:
|
||||||
@@ -191,38 +258,38 @@ All delays (#) are ignored, as they are in synthesis.
|
|||||||
Unknown States
|
Unknown States
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
Verilator is mostly a two state simulator, not a four state simulator.
|
Verilator is mostly a two-state simulator, not a four-state simulator.
|
||||||
However, it has two features which uncover most initialization bugs
|
However, it has two features that uncover most initialization bugs
|
||||||
(including many that a four state simulator will miss.)
|
(including many that a four-state simulator will miss.)
|
||||||
|
|
||||||
Identity comparisons (=== or !==) are converted to standard ==/!= when
|
Identity comparisons (=== or !==) are converted to standard ==/!= when
|
||||||
neither side is a constant. This may make the expression yield a different
|
neither side is a constant. This may make the expression yield a different
|
||||||
result compared to a four state simulator. An === comparison to X will
|
result than a four-state simulator. An === comparison to X will
|
||||||
always be false, so that Verilog code which checks for uninitialized logic
|
always be false, so that Verilog code which checks for uninitialized logic
|
||||||
will not fire.
|
will not fire.
|
||||||
|
|
||||||
Assigning X to a variable will actually assign a constant value as
|
Assigning X to a variable will assign a constant value as determined by the
|
||||||
determined by the :vlopt:`--x-assign` option. This allows runtime
|
:vlopt:`--x-assign` option. This allows runtime randomization; thus, if
|
||||||
randomization, thus if the value is actually used, the random value should
|
the value is used, the random value should cause downstream errors.
|
||||||
cause downstream errors. Integers also get randomized, even though the
|
Integers also get randomized, even though the Verilog 2001 specification
|
||||||
Verilog 2001 specification says they initialize to zero. Note however that
|
says they initialize to zero. However, randomization happens at
|
||||||
randomization happens at initialization time and hence during a single
|
initialization time; hence, during a single simulation run, the same
|
||||||
simulation run, the same constant (but random) value will be used every
|
constant (but random) value will be used every time the assignment is
|
||||||
time the assignment is executed.
|
executed.
|
||||||
|
|
||||||
All variables, depending on :vlopt:`--x-initial` setting, are typically
|
All variables, depending on :vlopt:`--x-initial` setting, are typically
|
||||||
randomly initialized using a function. By running several random
|
randomly initialized using a function. You can determine that reset is
|
||||||
simulation runs you can determine that reset is working correctly. On the
|
working correctly by running several random simulation runs. On the first
|
||||||
first run, have the function initialize variables to zero. On the second,
|
run, have the function initialize variables to zero. On the second, have
|
||||||
have it initialize variables to one. On the third and following runs have
|
it initialize variables to one. On the third and following runs, have it
|
||||||
it initialize them randomly. If the results match, reset works. (Note
|
initialize them randomly. If the results match, reset works. (Note that
|
||||||
this is what the hardware will really do.) In practice, just setting all
|
this is what the hardware will do.) In practice, setting all variables to
|
||||||
variables to one at startup finds most problems (since typically control
|
one at startup finds the most problems (since control signals are typically
|
||||||
signals are active-high).
|
active-high).
|
||||||
|
|
||||||
:vlopt:`--x-assign` applies to variables explicitly initialized or assigned
|
:vlopt:`--x-assign` applies to variables explicitly initialized or assigned
|
||||||
an X. Uninitialized clocks are initialized to zero, while all other state
|
an X. Uninitialized clocks are initialized to zero, while all other state
|
||||||
holding variables are initialized to a random value. Event driven
|
holding variables are initialized to a random value. Event-driven
|
||||||
simulators will generally trigger an edge on a transition from X to 1
|
simulators will generally trigger an edge on a transition from X to 1
|
||||||
(posedge) or X to 0 (negedge). However, by default, since clocks are
|
(posedge) or X to 0 (negedge). However, by default, since clocks are
|
||||||
initialized to zero, Verilator will not trigger an initial negedge. Some
|
initialized to zero, Verilator will not trigger an initial negedge. Some
|
||||||
@@ -258,33 +325,8 @@ External logic will be needed to combine these signals with any external
|
|||||||
drivers.
|
drivers.
|
||||||
|
|
||||||
Tristate drivers are not supported inside functions and tasks; an inout
|
Tristate drivers are not supported inside functions and tasks; an inout
|
||||||
there will be considered a two state variable that is read and written
|
there will be considered a two-state variable that is read and written
|
||||||
instead of a four state variable.
|
instead of a four-state variable.
|
||||||
|
|
||||||
|
|
||||||
Functions & Tasks
|
|
||||||
-----------------
|
|
||||||
|
|
||||||
All functions and tasks will be inlined (will not become functions in C.)
|
|
||||||
The only support provided is for simple statements in tasks (which may
|
|
||||||
affect global variables).
|
|
||||||
|
|
||||||
Recursive functions and tasks are not supported. All inputs and outputs
|
|
||||||
are automatic, as if they had the Verilog 2001 "automatic" keyword
|
|
||||||
prepended. (If you don't know what this means, Verilator will do what you
|
|
||||||
probably expect, what C does. The default behavior of Verilog is
|
|
||||||
different.)
|
|
||||||
|
|
||||||
|
|
||||||
Generated Clocks
|
|
||||||
----------------
|
|
||||||
|
|
||||||
Verilator attempts to deal with generated and gated clocks correctly,
|
|
||||||
however some cases cause problems in the scheduling algorithm which is
|
|
||||||
optimized for performance. The safest option is to have all clocks as
|
|
||||||
primary inputs to the model, or wires directly attached to primary inputs.
|
|
||||||
For proper behavior clock enables may also need the
|
|
||||||
:option:`/*verilator&32;clock_enable*/` metacomment.
|
|
||||||
|
|
||||||
|
|
||||||
Gate Primitives
|
Gate Primitives
|
||||||
@@ -313,14 +355,14 @@ error for more information.
|
|||||||
Array Out of Bounds
|
Array Out of Bounds
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
Writing a memory element that is outside the bounds specified for the array
|
Writing a memory element outside the bounds specified for the array may
|
||||||
may cause a different memory element inside the array to be written
|
cause a different memory element inside the array to be written instead.
|
||||||
instead. For power-of-2 sized arrays, Verilator will give a width warning
|
For power-of-2 sized arrays, Verilator will give a width warning and the
|
||||||
and the address. For non-power-of-2-sizes arrays, index 0 will be written.
|
address. For non-power-of-2-sizes arrays, index 0 will be written.
|
||||||
|
|
||||||
Reading a memory element that is outside the bounds specified for the array
|
Reading a memory element outside the bounds specified for the array will
|
||||||
will give a width warning and wrap around the power-of-2 size. For
|
give a width warning and wrap around the power-of-2 size. For
|
||||||
non-power-of-2 sizes, it will return a unspecified constant of the
|
non-power-of-2 sizes, it will return an unspecified constant of the
|
||||||
appropriate width.
|
appropriate width.
|
||||||
|
|
||||||
|
|
||||||
@@ -339,7 +381,7 @@ statements must be simple expressions that complete in one cycle.
|
|||||||
Encrypted Verilog
|
Encrypted Verilog
|
||||||
-----------------
|
-----------------
|
||||||
|
|
||||||
Open source simulators like Verilator are unable to use encrypted RTL
|
Open-source simulators like Verilator cannot use encrypted RTL
|
||||||
(i.e. IEEE P1735). Talk to your IP vendor about delivering IP blocks via
|
(i.e. IEEE P1735). Talk to your IP vendor about delivering IP blocks via
|
||||||
Verilator's :vlopt:`--protect-lib` feature.
|
Verilator's :vlopt:`--protect-lib` feature.
|
||||||
|
|
||||||
@@ -380,12 +422,12 @@ This section describes specific limitations for each language keyword.
|
|||||||
certain limited cases.
|
certain limited cases.
|
||||||
|
|
||||||
'{} operator
|
'{} operator
|
||||||
Assignment patterns with order based, default, constant integer (array)
|
Assignment patterns with an order based, default, constant integer (array)
|
||||||
or member identifier (struct/union) keys are supported. Data type keys
|
or member identifier (struct/union) keys are supported. Data type keys
|
||||||
and keys which are computed from a constant expression are not supported.
|
and keys computed from a constant expression are not supported.
|
||||||
|
|
||||||
\`uselib
|
\`uselib
|
||||||
Uselib, a vendor specific library specification method, is ignored along
|
Uselib, a vendor-specific library specification method, is ignored along
|
||||||
with anything following it until the end of that line.
|
with anything following it until the end of that line.
|
||||||
|
|
||||||
cast operator
|
cast operator
|
||||||
@@ -393,8 +435,12 @@ cast operator
|
|||||||
unsigned, not arrays nor structs.
|
unsigned, not arrays nor structs.
|
||||||
|
|
||||||
chandle
|
chandle
|
||||||
Treated as a "longint"; does not yet warn about operations that are
|
Treated as a "longint"; does not yet warn about operations specified as
|
||||||
specified as illegal on chandles.
|
illegal on chandles.
|
||||||
|
|
||||||
|
checker
|
||||||
|
Treated as a "module"; does not yet warn about many constructs illegal
|
||||||
|
inside a checker.
|
||||||
|
|
||||||
disable
|
disable
|
||||||
Disable statements may be used only if the block being disabled is a
|
Disable statements may be used only if the block being disabled is a
|
||||||
@@ -402,12 +448,27 @@ disable
|
|||||||
provide loop break and continue functionality before SystemVerilog added
|
provide loop break and continue functionality before SystemVerilog added
|
||||||
the break and continue keywords.
|
the break and continue keywords.
|
||||||
|
|
||||||
|
force, release
|
||||||
|
Verilator supports the procedural `force` (and corresponding `release`)
|
||||||
|
statement. However, the behavior of the `force` statement does not
|
||||||
|
entirely comply with IEEE 1800. According to the standard, when a
|
||||||
|
procedural statement of the form `force a = b;` is executed, the
|
||||||
|
simulation should behave as if, from that point forwards, a continuous
|
||||||
|
assignment `assign a = b;` has been added to override the drivers of `a`.
|
||||||
|
More specifically: the value of `a` should be updated whenever the value
|
||||||
|
of `b` changes, until a `release a;` statement is executed. Verilator
|
||||||
|
instead evaluates the current value of `b` when the `force` statement is
|
||||||
|
executed, and forces `a` to that value, without updating it until a new
|
||||||
|
`force` or `release` statement is encountered that applies to `a`. This
|
||||||
|
non-standard behavior is nevertheless consistent with some other
|
||||||
|
simulators.
|
||||||
|
|
||||||
inside
|
inside
|
||||||
Inside expressions may not include unpacked array traversal or $ as an
|
Inside expressions may not include unpacked array traversal or $ as an
|
||||||
upper bound. Case inside and case matches are also unsupported.
|
upper bound. Case inside and case matches are also unsupported.
|
||||||
|
|
||||||
interface
|
interface
|
||||||
Interfaces and modports, including with generated data types are
|
Interfaces and modports, including generated data types are
|
||||||
supported. Generate blocks around modports are not supported, nor are
|
supported. Generate blocks around modports are not supported, nor are
|
||||||
virtual interfaces nor unnamed interfaces.
|
virtual interfaces nor unnamed interfaces.
|
||||||
|
|
||||||
@@ -419,25 +480,25 @@ specify specparam
|
|||||||
All specify blocks and timing checks are ignored.
|
All specify blocks and timing checks are ignored.
|
||||||
|
|
||||||
uwire
|
uwire
|
||||||
Verilator does not perform warning checking on uwires, it treats the
|
Verilator does not perform warning checking on uwires; it treats the
|
||||||
uwire keyword as if it were the normal wire keyword.
|
uwire keyword as if it were the normal wire keyword.
|
||||||
|
|
||||||
$bits, $countbits, $countones, $finish, $isunknown, $onehot, $onehot0, $signed, $stime, $stop, $time, $unsigned,
|
$bits, $countbits, $countones, $finish, $isunknown, $onehot, $onehot0, $signed, $stime, $stop, $time, $unsigned,
|
||||||
Generally supported.
|
Generally supported.
|
||||||
|
|
||||||
$dump/$dumpports and related
|
$dump/$dumpports and related
|
||||||
$dumpfile or $dumpports will create a VCD or FST file (which is based on
|
$dumpfile or $dumpports will create a VCD or FST file (based on
|
||||||
the :vlopt:`--trace` option given when the model was Verilated). This
|
the :vlopt:`--trace` option given when the model was Verilated). This
|
||||||
will take effect starting at the next eval() call. If you have multiple
|
will take effect starting at the next eval() call. If you have multiple
|
||||||
Verilated designs under the same C model, then this will dump signals
|
Verilated designs under the same C model, this will dump signals
|
||||||
only from the design containing the $dumpvars.
|
only from the design containing the $dumpvars.
|
||||||
|
|
||||||
$dumpvars and $dumpports module identifier is ignored; the traced
|
$dumpvars and $dumpports module identifier is ignored; the traced
|
||||||
instances will always start at the top of the design. The levels argument
|
instances will always start at the top of the design. The levels argument
|
||||||
is also ignored, use tracing_on/tracing_off pragmas instead.
|
is also ignored; use tracing_on/tracing_off pragmas instead.
|
||||||
|
|
||||||
$dumpportson/$dumpportsoff/$dumpportsall/$dumpportslimit filename
|
$dumpportson/$dumpportsoff/$dumpportsall/$dumpportslimit filename
|
||||||
argument is ignored, only a single trace file may be active at once.
|
argument is ignored; only a single trace file may be active at once.
|
||||||
|
|
||||||
$dumpall/$dumpportsall, $dumpon/$dumpportson, $dumpoff/$dumpportsoff, and
|
$dumpall/$dumpportsall, $dumpon/$dumpportson, $dumpoff/$dumpportsoff, and
|
||||||
$dumplimit/$dumpportlimit are currently ignored.
|
$dumplimit/$dumpportlimit are currently ignored.
|
||||||
@@ -446,7 +507,7 @@ $error, $fatal, $info, $warning.
|
|||||||
Generally supported.
|
Generally supported.
|
||||||
|
|
||||||
$exit, $finish, $stop
|
$exit, $finish, $stop
|
||||||
The rarely used optional parameter to $finish and $stop is ignored. $exit
|
The rarely used optional parameter to $finish and $stop is ignored; $exit
|
||||||
is aliased to $finish.
|
is aliased to $finish.
|
||||||
|
|
||||||
$fopen, $fclose, $fdisplay, $ferror, $feof, $fflush, $fgetc, $fgets, $fscanf, $fwrite, $fscanf, $sscanf
|
$fopen, $fclose, $fdisplay, $ferror, $feof, $fflush, $fgetc, $fgets, $fscanf, $fwrite, $fscanf, $sscanf
|
||||||
@@ -462,8 +523,8 @@ $random, $urandom, $urandom_range
|
|||||||
per object for random stability of $urandom/$urandom_range.
|
per object for random stability of $urandom/$urandom_range.
|
||||||
|
|
||||||
$readmemb, $readmemh
|
$readmemb, $readmemh
|
||||||
Read memory commands are supported. Note Verilator and the Verilog
|
Read memory commands are supported. Verilator and the Verilog
|
||||||
specification does not include support for readmem to multi-dimensional
|
specification do not include support for readmem to multi-dimensional
|
||||||
arrays.
|
arrays.
|
||||||
|
|
||||||
$test$plusargs, $value$plusargs
|
$test$plusargs, $value$plusargs
|
||||||
@@ -471,7 +532,7 @@ $test$plusargs, $value$plusargs
|
|||||||
|
|
||||||
.. code-block:: C++
|
.. code-block:: C++
|
||||||
|
|
||||||
Verilated::commandArgs(argc, argv);
|
{VerilatedContext*} ->commandArgs(argc, argv);
|
||||||
|
|
||||||
to register the command line before calling $test$plusargs or
|
to register the command line before calling $test$plusargs or
|
||||||
$value$plusargs.
|
$value$plusargs.
|
||||||
|
|||||||
+16
-16
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
********
|
********
|
||||||
@@ -8,30 +8,30 @@ Overview
|
|||||||
Welcome to Verilator!
|
Welcome to Verilator!
|
||||||
|
|
||||||
The Verilator package converts Verilog [#]_ and SystemVerilog [#]_ hardware
|
The Verilator package converts Verilog [#]_ and SystemVerilog [#]_ hardware
|
||||||
description language (HDL) designs into a C++ or SystemC model that after
|
description language (HDL) designs into a C++ or SystemC model that, after
|
||||||
compiling can be executed. Verilator is not a traditional simulator, but a
|
compiling, can be executed. Verilator is not a traditional simulator but a
|
||||||
compiler.
|
compiler.
|
||||||
|
|
||||||
Verilator is typically used as follows:
|
Verilator is typically used as follows:
|
||||||
|
|
||||||
1. The :command:`verilator` executable is invoked with parameters similar
|
1. The :command:`verilator` executable is invoked with parameters similar
|
||||||
to GCC, or other simulators such as Cadence Verilog-XL/NC-Verilog, or
|
to GCC or other simulators such as Cadence Verilog-XL/NC-Verilog, or
|
||||||
Synopsys VCS. Verilator reads the specified SystemVerilog code, lints it,
|
Synopsys VCS. Verilator reads the specified SystemVerilog code, lints it,
|
||||||
optionally adds coverage and waveform tracing support, and compiles the
|
optionally adds coverage and waveform tracing support, and compiles the
|
||||||
design into a source level multithreaded C++ or SystemC "model". The
|
design into a source-level multithreaded C++ or SystemC "model". The
|
||||||
resulting model's C++ or SystemC code is output as .cpp and .h files. This
|
resulting model's C++ or SystemC code is output as .cpp and .h files. This
|
||||||
is referred to as "Verilating" and the process is "to Verilate"; the output
|
is referred to as "Verilating", and the process is "to Verilate"; the
|
||||||
is a "Verilated" model.
|
output is a "Verilated" model.
|
||||||
|
|
||||||
2. For simulation, a small user written C++ wrapper file is required, the
|
2. For simulation, a small user-written C++ wrapper file is required, the
|
||||||
"wrapper". This wrapper defines the C++ standard function "main()" which
|
"wrapper". This wrapper defines the C++ standard function "main()", which
|
||||||
instantiates the Verilated model as a C++/SystemC object.
|
instantiates the Verilated model as a C++/SystemC object.
|
||||||
|
|
||||||
3. The user C++ wrapper, the files created by Verilator, a "runtime
|
3. The user C++ wrapper, the files created by Verilator, a "runtime
|
||||||
library" provided by Verilator, and if applicable SystemC libraries are
|
library" provided by Verilator, and, if applicable, SystemC libraries are
|
||||||
then compiled using a C++ compiler to create a simulation executable.
|
then compiled using a C++ compiler to create a simulation executable.
|
||||||
|
|
||||||
4. The resulting executable will perform the actual simulation, during
|
4. The resulting executable will perform the actual simulation during
|
||||||
"simulation runtime".
|
"simulation runtime".
|
||||||
|
|
||||||
5. If appropriately enabled, the executable may also generate waveform
|
5. If appropriately enabled, the executable may also generate waveform
|
||||||
@@ -44,12 +44,12 @@ The best place to get started is to try the :ref:`Examples`.
|
|||||||
.. [#] Verilog is defined by the `Institute of Electrical and Electronics
|
.. [#] Verilog is defined by the `Institute of Electrical and Electronics
|
||||||
Engineers (IEEE) Standard for Verilog Hardware Description
|
Engineers (IEEE) Standard for Verilog Hardware Description
|
||||||
Language`, Std. 1364, released in 1995, 2001, and 2005. The
|
Language`, Std. 1364, released in 1995, 2001, and 2005. The
|
||||||
Verilator documentation uses the shorthand e.g. "IEEE 1394-2005" to
|
Verilator documentation uses the shorthand, e.g., "IEEE 1364-2005",
|
||||||
refer to the e.g. 2005 version of this standard.
|
to refer to the, e.g., 2005 version of this standard.
|
||||||
|
|
||||||
.. [#] SystemVerilog is defined by the `Institute of Electrical and
|
.. [#] SystemVerilog is defined by the `Institute of Electrical and
|
||||||
Electronics Engineers (IEEE) Standard for SystemVerilog - Unified
|
Electronics Engineers (IEEE) Standard for SystemVerilog - Unified
|
||||||
Hardware Design, Specification, and Verification Language`, Standard
|
Hardware Design, Specification, and Verification Language`, Standard
|
||||||
1800, released in 2005, 2009, 2012, and 2017. The Verilator
|
1800, released in 2005, 2009, 2012, 2017, and 2023. The Verilator
|
||||||
documentation uses the shorthand e.g. "IEEE 1800-2017" to refer to
|
documentation uses the shorthand e.g., "IEEE 1800-2023", to refer to
|
||||||
the e.g. 2017 version of this standard.
|
the, e.g., 2023 version of this standard.
|
||||||
|
|||||||
+247
-148
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. _Simulating:
|
.. _Simulating:
|
||||||
@@ -7,9 +7,63 @@
|
|||||||
Simulating (Verilated-Model Runtime)
|
Simulating (Verilated-Model Runtime)
|
||||||
************************************
|
************************************
|
||||||
|
|
||||||
This section describes items related to simulating, that using a Verilated
|
This section describes items related to simulating, that is, using a
|
||||||
model's executable. For the runtime arguments to a simulated model, see
|
Verilated model's executable. For the runtime arguments to a simulated
|
||||||
:ref:`Simulation Runtime Arguments`.
|
model, see :ref:`Simulation Runtime Arguments`.
|
||||||
|
|
||||||
|
|
||||||
|
.. _Simulation Summary Report:
|
||||||
|
|
||||||
|
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`.
|
||||||
|
The report may be disabled with :vlopt:`+verilator+quiet`.
|
||||||
|
|
||||||
|
For example:
|
||||||
|
|
||||||
|
.. code-block::
|
||||||
|
|
||||||
|
- S i m u l a t i o n R e p o r t: Verilator ...
|
||||||
|
- Verilator: End at simtime 123 ns; walltime 1234.001 s; speed 123 ns/s
|
||||||
|
- Verilator: cpu 22.001 s on 4 threads; alloced 123 MB
|
||||||
|
|
||||||
|
The information in this report is:
|
||||||
|
|
||||||
|
.. describe:: "Verilator ..."
|
||||||
|
|
||||||
|
Program version.
|
||||||
|
|
||||||
|
.. describe:: "End at simtime 123 ns"
|
||||||
|
|
||||||
|
Verilog $time at which the model finished or stopped.
|
||||||
|
|
||||||
|
.. describe:: "walltime 1234.001 s"
|
||||||
|
|
||||||
|
Real elapsed wall time in seconds.
|
||||||
|
|
||||||
|
.. describe:: "speed 123.1 ns/s"
|
||||||
|
|
||||||
|
Simulated time (if non-zero) divided by wall time. e.g. `123 ns/s` means
|
||||||
|
123 simulated nanoseconds took 1 second of wall time; for a model with
|
||||||
|
only a 1 GHz clock that would be equivalent to 123.1 cycles per
|
||||||
|
second. The units are automatically selected to give a number between 1
|
||||||
|
and 1000. The wall time includes initialization, initial and final
|
||||||
|
process blocks, so indicates a slower speed than if the model had a
|
||||||
|
longer runtime.
|
||||||
|
|
||||||
|
.. describe:: "cpu 22 s"
|
||||||
|
|
||||||
|
CPU time used total across all CPU threads in seconds.
|
||||||
|
|
||||||
|
.. describe:: "4 threads"
|
||||||
|
|
||||||
|
Number of simultaneous threads used.
|
||||||
|
|
||||||
|
.. describe:: "alloced 123 MB"
|
||||||
|
|
||||||
|
Total memory used during simulation in megabytes.
|
||||||
|
|
||||||
|
|
||||||
.. _Benchmarking & Optimization:
|
.. _Benchmarking & Optimization:
|
||||||
@@ -18,30 +72,32 @@ Benchmarking & Optimization
|
|||||||
===========================
|
===========================
|
||||||
|
|
||||||
For best performance, run Verilator with the :vlopt:`-O3`
|
For best performance, run Verilator with the :vlopt:`-O3`
|
||||||
:vlopt:`--x-assign fast <--x-assign>` :vlopt:`--x-initial fast
|
:vlopt:`--x-assign fast <--x-assign>`
|
||||||
<--x-initial>` :vlopt:`--noassert <--assert>` options. The :vlopt:`-O3`
|
:vlopt:`--x-initial fast <--x-initial>`
|
||||||
option will require longer time to run Verilator, and :vlopt:`--x-assign
|
:vlopt:`--noassert <--assert>` options. The :vlopt:`-O3`
|
||||||
fast <--x-assign>` :vlopt:`--x-initial fast <--x-assign>` may increase the
|
option will require a longer time to run Verilator, and
|
||||||
risk of reset bugs in trade for performance; see the above documentation
|
:vlopt:`--x-assign fast <--x-assign>`
|
||||||
for these options.
|
:vlopt:`--x-initial fast <--x-assign>`
|
||||||
|
may increase the risk of reset bugs in trade for performance; see the above
|
||||||
|
documentation for these options.
|
||||||
|
|
||||||
If using Verilated multithreaded, use ``numactl`` to ensure you are using
|
If using Verilated multithreaded, use ``numactl`` to ensure you use
|
||||||
non-conflicting hardware resources. See :ref:`Multithreading`. Also
|
non-conflicting hardware resources. See :ref:`Multithreading`. Also,
|
||||||
consider using profile-guided optimization, see :ref:`Thread PGO`.
|
consider using profile-guided optimization; see :ref:`Thread PGO`.
|
||||||
|
|
||||||
Minor Verilog code changes can also give big wins. You should not have any
|
Minor Verilog code changes can also give big wins. You should not have any
|
||||||
UNOPTFLAT warnings from Verilator. Fixing these warnings can result in
|
:option:`UNOPTFLAT` warnings from Verilator. Fixing these warnings can
|
||||||
huge improvements; one user fixed their one UNOPTFLAT warning by making a
|
result in huge improvements; one user fixed their one UNOPTFLAT warning by
|
||||||
simple change to a clock latch used to gate clocks and gained a 60%
|
making a simple change to a clocked latch used to gate clocks and gained a
|
||||||
performance improvement.
|
60% performance improvement.
|
||||||
|
|
||||||
Beyond that, the performance of a Verilated model depends mostly on your
|
Beyond that, the performance of a Verilated model depends primarily on your
|
||||||
C++ compiler and size of your CPU's caches. Experience shows that large
|
C++ compiler and the size of your CPU's caches. Experience shows that the
|
||||||
models are often limited by the size of the instruction cache, and as such
|
instruction cache size often limits large models, and reducing code size,
|
||||||
reducing code size if possible can be beneficial.
|
if possible, can be beneficial.
|
||||||
|
|
||||||
The supplied $VERILATOR_ROOT/include/verilated.mk file uses the OPT,
|
The supplied $VERILATOR_ROOT/include/verilated.mk file uses the OPT,
|
||||||
OPT_FAST, OPT_SLOW and OPT_GLOBAL variables to control optimization. You
|
OPT_FAST, OPT_SLOW, and OPT_GLOBAL variables to control optimization. You
|
||||||
can set these when compiling the output of Verilator with Make, for
|
can set these when compiling the output of Verilator with Make, for
|
||||||
example:
|
example:
|
||||||
|
|
||||||
@@ -49,17 +105,17 @@ example:
|
|||||||
|
|
||||||
make OPT_FAST="-Os -march=native" -f Vour.mk Vour__ALL.a
|
make OPT_FAST="-Os -march=native" -f Vour.mk Vour__ALL.a
|
||||||
|
|
||||||
OPT_FAST specifies optimization options for those parts of the model that
|
OPT_FAST specifies optimization options for those parts of the model
|
||||||
are on the fast path. This is mostly code that is executed every
|
on the fast path. This is mostly code that is executed every
|
||||||
cycle. OPT_SLOW applies to slow-path code, which executes rarely, often
|
cycle. OPT_SLOW applies to slow-path code, which rarely executes, often
|
||||||
only once at the beginning or end of simulation. Note that OPT_SLOW is
|
only once at the beginning or end of the simulation. OPT_SLOW is
|
||||||
ignored if VM_PARALLEL_BUILDS is not 1, in which case all generated code
|
ignored if VM_PARALLEL_BUILDS is not 1, in which case all generated code
|
||||||
will be compiled in a single compilation unit using OPT_FAST. See also the
|
will be compiled in a single compilation unit using OPT_FAST. See also the
|
||||||
Verilator :vlopt:`--output-split` option. The OPT_GLOBAL variable applies
|
Verilator :vlopt:`--output-split` option. The OPT_GLOBAL variable applies
|
||||||
to common code in the runtime library used by Verilated models (shipped in
|
to common code in the runtime library used by Verilated models (shipped in
|
||||||
$VERILATOR_ROOT/include). Additional C++ files passed on the verilator
|
$VERILATOR_ROOT/include). Additional C++ files passed on the verilator
|
||||||
command line use OPT_FAST. The OPT variable applies to all compilation
|
command line use OPT_FAST. The OPT variable applies to all compilation
|
||||||
units in addition to the specific "OPT" variables described above.
|
units and the specific "OPT" variables described above.
|
||||||
|
|
||||||
You can also use the :vlopt:`-CFLAGS` and/or :vlopt:`-LDFLAGS` options on
|
You can also use the :vlopt:`-CFLAGS` and/or :vlopt:`-LDFLAGS` options on
|
||||||
the verilator command line to pass arguments directly to the compiler or
|
the verilator command line to pass arguments directly to the compiler or
|
||||||
@@ -68,53 +124,53 @@ linker.
|
|||||||
The default values of the "OPT" variables are chosen to yield good
|
The default values of the "OPT" variables are chosen to yield good
|
||||||
simulation speed with reasonable C++ compilation times. To this end,
|
simulation speed with reasonable C++ compilation times. To this end,
|
||||||
OPT_FAST is set to "-Os" by default. Higher optimization such as "-O2" or
|
OPT_FAST is set to "-Os" by default. Higher optimization such as "-O2" or
|
||||||
"-O3" may help (though often they provide only a very small performance
|
"-O3" may help (though often they provide only a minimal performance
|
||||||
benefit), but compile times may be excessively large even with medium sized
|
benefit), but compile times may be excessively large even with medium-sized
|
||||||
designs. Compilation times can be improved at the expense of simulation
|
designs. Compilation times can be improved at the expense of simulation
|
||||||
speed by reducing optimization, for example with OPT_FAST="-O0". Often good
|
speed by reducing optimization, for example, with OPT_FAST="-O0". Often
|
||||||
simulation speed can be achieved with OPT_FAST="-O1 -fstrict-aliasing" but
|
good simulation speed can be achieved with OPT_FAST="-O1 -fstrict-aliasing"
|
||||||
with improved compilation times. Files controlled by OPT_SLOW have little
|
but with improved compilation times. Files controlled by OPT_SLOW have
|
||||||
effect on performance and therefore OPT_SLOW is empty by default
|
little effect on performance, and therefore OPT_SLOW is empty by default
|
||||||
(equivalent to "-O0") for improved compilation speed. In common use-cases
|
(equivalent to "-O0") for improved compilation speed. In common use cases,
|
||||||
there should be little benefit in changing OPT_SLOW. OPT_GLOBAL is set to
|
there should be little benefit in changing OPT_SLOW. OPT_GLOBAL is set to
|
||||||
"-Os" by default and there should rarely be a need to change it. As the
|
"-Os" by default, and there should rarely be a need to change it. As the
|
||||||
runtime library is small in comparison to a lot of Verilated models,
|
runtime library is small compared to many Verilated models, disabling
|
||||||
disabling optimization on the runtime library should not have a serious
|
optimization on the runtime library should not seriously affect overall
|
||||||
effect on overall compilation time, but may have detrimental effect on
|
compilation time but may have a detrimental effect on simulation speed,
|
||||||
simulation speed, especially with tracing. In addition to the above, for
|
especially with tracing. In addition to the above, for best results, use
|
||||||
best results use OPT="-march=native", the latest Clang compiler (about 10%
|
OPT="-march=native", the latest Clang compiler (about 10% faster than GCC),
|
||||||
faster than GCC), and link statically.
|
and link statically.
|
||||||
|
|
||||||
Generally the answer to which optimization level gives the best user
|
Generally, the answer to which optimization level gives the best user
|
||||||
experience depends on the use case and some experimentation can pay
|
experience depends on the use case, and some experimentation can pay
|
||||||
dividends. For a speedy debug cycle during development, especially on large
|
dividends. For a speedy debug cycle during development, especially on large
|
||||||
designs where C++ compilation speed can dominate, consider using lower
|
designs where C++ compilation speed can dominate, consider using lower
|
||||||
optimization to get to an executable faster. For throughput oriented use
|
optimization to get to an executable faster. For throughput-oriented use
|
||||||
cases, for example regressions, it is usually worth spending extra
|
cases, for example, regressions, it is usually worth spending extra
|
||||||
compilation time to reduce total CPU time.
|
compilation time to reduce total CPU time.
|
||||||
|
|
||||||
If you will be running many simulations on a single model, you can
|
If you will be running many simulations on a single model, you can
|
||||||
investigate profile guided optimization. See :ref:`Compiler PGO`.
|
investigate profile-guided optimization. See :ref:`Compiler PGO`.
|
||||||
|
|
||||||
Modern compilers also support link-time optimization (LTO), which can help
|
Modern compilers also support link-time optimization (LTO), which can help,
|
||||||
especially if you link in DPI code. To enable LTO on GCC, pass "-flto" in
|
especially if you link in DPI code. To enable LTO on GCC, pass "-flto" in
|
||||||
both compilation and link. Note LTO may cause excessive compile times on
|
both compilation and link. Note that LTO may cause excessive compile times
|
||||||
large designs.
|
on large designs.
|
||||||
|
|
||||||
Unfortunately, using the optimizer with SystemC files can result in
|
Unfortunately, using the optimizer with SystemC files can result in
|
||||||
compilation taking several minutes. (The SystemC libraries have many little
|
compilation taking several minutes. (The SystemC libraries have many little
|
||||||
inlined functions that drive the compiler nuts.)
|
inlined functions that drive the compiler nuts.)
|
||||||
|
|
||||||
If you are using your own makefiles, you may want to compile the Verilated
|
If using your own makefiles, you may want to compile the Verilated
|
||||||
code with ``--MAKEFLAGS -DVL_INLINE_OPT=inline``. This will inline
|
code with ``--MAKEFLAGS -DVL_INLINE_OPT=inline``. This will inline
|
||||||
functions, however this requires that all cpp files be compiled in a single
|
functions; however, this requires that all cpp files be compiled in a single
|
||||||
compiler run.
|
compiler run.
|
||||||
|
|
||||||
You may uncover further tuning possibilities by profiling the Verilog code.
|
You may uncover further tuning possibilities by profiling the Verilog code.
|
||||||
See :ref:`profiling`.
|
See :ref:`profiling`.
|
||||||
|
|
||||||
When done optimizing, please let the author know the results. We like to
|
When done optimizing, please let the author know the results. We like to
|
||||||
keep tabs on how Verilator compares, and may be able to suggest additional
|
keep tabs on how Verilator compares and may be able to suggest additional
|
||||||
improvements.
|
improvements.
|
||||||
|
|
||||||
|
|
||||||
@@ -141,14 +197,14 @@ Functional Coverage
|
|||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
With :vlopt:`--coverage` or :vlopt:`--coverage-user`, Verilator will
|
With :vlopt:`--coverage` or :vlopt:`--coverage-user`, Verilator will
|
||||||
translate functional coverage points which the user has inserted manually
|
translate functional coverage points the user has inserted manually in
|
||||||
into the SystemVerilog design, into the Verilated model.
|
SystemVerilog code through into the Verilated model.
|
||||||
|
|
||||||
Currently, all functional coverage points are specified using SystemVerilog
|
Currently, all functional coverage points are specified using SystemVerilog
|
||||||
assertion syntax which must be separately enabled with :vlopt:`--assert`.
|
assertion syntax, which must be separately enabled with :vlopt:`--assert`.
|
||||||
|
|
||||||
For example, the following SystemVerilog statement will add a coverage
|
For example, the following SystemVerilog statement will add a coverage
|
||||||
point, under the coverage name "DefaultClock":
|
point under the coverage name "DefaultClock":
|
||||||
|
|
||||||
.. code-block:: sv
|
.. code-block:: sv
|
||||||
|
|
||||||
@@ -161,13 +217,13 @@ Line Coverage
|
|||||||
-------------
|
-------------
|
||||||
|
|
||||||
With :vlopt:`--coverage` or :vlopt:`--coverage-line`, Verilator will
|
With :vlopt:`--coverage` or :vlopt:`--coverage-line`, Verilator will
|
||||||
automatically add coverage analysis at each code flow change point (e.g. at
|
automatically add coverage analysis at each code flow change point (e.g.,
|
||||||
branches). At each such branch a unique counter is incremented. At the
|
at branches). At each such branch, a counter is incremented. At the end
|
||||||
end of a test, the counters along with the filename and line number
|
of a test, the counters, filename, and line number corresponding to each
|
||||||
corresponding to each counter are written into the coverage file.
|
counter are written into the coverage file.
|
||||||
|
|
||||||
Verilator automatically disables coverage of branches that have a $stop in
|
Verilator automatically disables coverage of branches with a $stop in
|
||||||
them, as it is assumed $stop branches contain an error check that should
|
them, as it is assumed that $stop branches contain an error check that should
|
||||||
not occur. A :option:`/*verilator&32;coverage_block_off*/` metacomment
|
not occur. A :option:`/*verilator&32;coverage_block_off*/` metacomment
|
||||||
will perform a similar function on any code in that block or below, or
|
will perform a similar function on any code in that block or below, or
|
||||||
:option:`/*verilator&32;coverage_off*/` and
|
:option:`/*verilator&32;coverage_off*/` and
|
||||||
@@ -175,8 +231,9 @@ will perform a similar function on any code in that block or below, or
|
|||||||
respectively around a block of code.
|
respectively around a block of code.
|
||||||
|
|
||||||
Verilator may over-count combinatorial (non-clocked) blocks when those
|
Verilator may over-count combinatorial (non-clocked) blocks when those
|
||||||
blocks receive signals which have had the UNOPTFLAT warning disabled; for
|
blocks receive signals which have had the :option:`UNOPTFLAT` warning
|
||||||
most accurate results do not disable this warning when using coverage.
|
disabled; for the most accurate results, do not disable this warning when
|
||||||
|
using coverage.
|
||||||
|
|
||||||
|
|
||||||
.. _Toggle Coverage:
|
.. _Toggle Coverage:
|
||||||
@@ -187,8 +244,8 @@ Toggle Coverage
|
|||||||
With :vlopt:`--coverage` or :vlopt:`--coverage-toggle`, Verilator will
|
With :vlopt:`--coverage` or :vlopt:`--coverage-toggle`, Verilator will
|
||||||
automatically add toggle coverage analysis into the Verilated model.
|
automatically add toggle coverage analysis into the Verilated model.
|
||||||
|
|
||||||
Every bit of every signal in a module has a counter inserted. The counter
|
Every bit of every signal in a module has a counter inserted, and the
|
||||||
will increment on every edge change of the corresponding bit.
|
counter will increment on every edge change of the corresponding bit.
|
||||||
|
|
||||||
Signals that are part of tasks or begin/end blocks are considered local
|
Signals that are part of tasks or begin/end blocks are considered local
|
||||||
variables and are not covered. Signals that begin with underscores (see
|
variables and are not covered. Signals that begin with underscores (see
|
||||||
@@ -196,17 +253,17 @@ variables and are not covered. Signals that begin with underscores (see
|
|||||||
total storage across all dimensions, see :vlopt:`--coverage-max-width`) are
|
total storage across all dimensions, see :vlopt:`--coverage-max-width`) are
|
||||||
also not covered.
|
also not covered.
|
||||||
|
|
||||||
Hierarchy is compressed, such that if a module is instantiated multiple
|
Hierarchy is compressed, so if a module is instantiated multiple times,
|
||||||
times, coverage will be summed for that bit across **all** instantiations
|
coverage will be summed for that bit across **all** instantiations of that
|
||||||
of that module with the same parameter set. A module instantiated with
|
module with the same parameter set. A module instantiated with different
|
||||||
different parameter values is considered a different module, and will get
|
parameter values is considered a different module and will get counted
|
||||||
counted separately.
|
separately.
|
||||||
|
|
||||||
Verilator makes a minimally-intelligent decision about what clock domain
|
Verilator makes a minimally-intelligent decision about what clock domain
|
||||||
the signal goes to, and only looks for edges in that clock domain. This
|
the signal goes to, and only looks for edges in that clock domain. This
|
||||||
means that edges may be ignored if it is known that the edge could never be
|
means that edges may be ignored if it is known that the receiving logic
|
||||||
seen by the receiving logic. This algorithm may improve in the future.
|
could never see the edge. This algorithm may improve in the future. The
|
||||||
The net result is coverage may be lower than what would be seen by looking
|
net result is that coverage may be lower than what would be seen by looking
|
||||||
at traces, but the coverage is a more accurate representation of the
|
at traces, but the coverage is a more accurate representation of the
|
||||||
quality of stimulus into the design.
|
quality of stimulus into the design.
|
||||||
|
|
||||||
@@ -224,36 +281,42 @@ signals that do not need toggle analysis, such as RAMs and register files.
|
|||||||
Coverage Collection
|
Coverage Collection
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
When any coverage flag was used to Verilate, Verilator will add appropriate
|
When any coverage flag is used to Verilate, Verilator will add appropriate
|
||||||
coverage point insertions into the model and collect the coverage data.
|
coverage point insertions into the model and collect the coverage data.
|
||||||
|
|
||||||
To get the coverage data from the model, in the user wrapper code,
|
To get the coverage data from the model, write the coverage with either:
|
||||||
typically at the end once a test passes, call
|
|
||||||
:code:`Verilated::threadContextp()->coveragep()->write` with an argument of the filename for
|
1. Using :vlopt:`--binary` or :vlopt:`--main`, and Verilator will dump
|
||||||
the coverage data file to write coverage data to (typically
|
coverage when the test completes to the filename specified with
|
||||||
"logs/coverage.dat").
|
:vlopt:`+verilator+coverage+file+\<filename\>`.
|
||||||
|
|
||||||
|
2. In the user wrapper code, typically at the end once a test passes, call
|
||||||
|
:code:`Verilated::threadContextp()->coveragep()->write` with an argument
|
||||||
|
of the filename for the coverage data file to write coverage data to
|
||||||
|
(typically "logs/coverage.dat").
|
||||||
|
|
||||||
Run each of your tests in different directories, potentially in parallel.
|
Run each of your tests in different directories, potentially in parallel.
|
||||||
Each test will create a :file:`logs/coverage.dat` file.
|
Each test will create the file specified above,
|
||||||
|
e.g. :file:`logs/coverage.dat`.
|
||||||
|
|
||||||
After running all of the tests, execute the :command:`verilator_coverage`
|
After running all of the tests, execute the :command:`verilator_coverage`
|
||||||
command, passing arguments pointing to the filenames of all of the
|
command, passing arguments pointing to the filenames of all the
|
||||||
individual coverage files. :command:`verilator_coverage` will reads the
|
individual coverage files. :command:`verilator_coverage` will read the
|
||||||
:file:`logs/coverage.dat` file(s), and create an annotated source code
|
:file:`logs/coverage.dat` file(s), and create an annotated source code
|
||||||
listing showing code coverage details.
|
listing showing code coverage details.
|
||||||
|
|
||||||
:command:`verilator_coverage` may also be used for test grading, that is
|
:command:`verilator_coverage` may also be used for test grading, computing
|
||||||
computing which tests are important to fully cover the design.
|
which tests are important to give full verification coverage on the design.
|
||||||
|
|
||||||
For an example, see the :file:`examples/make_tracing_c/logs` directory.
|
For an example, see the :file:`examples/make_tracing_c/logs` directory.
|
||||||
Grep for lines starting with '%' to see what lines Verilator believes need
|
Grep for lines starting with '%' to see what lines Verilator believes need
|
||||||
more coverage.
|
more coverage.
|
||||||
|
|
||||||
Additional options of :command:`verilator_coverage` allow for merging of
|
Additional options of :command:`verilator_coverage` allow for the merging
|
||||||
coverage data files or other transformations.
|
of coverage data files or other transformations.
|
||||||
|
|
||||||
Info files can be written by verilator_coverage for import to
|
Info files can be written by verilator_coverage for import to
|
||||||
:command:`lcov`. This enables use of :command:`genhtml` for HTML reports
|
:command:`lcov`. This enables using :command:`genhtml` for HTML reports
|
||||||
and importing reports to sites such as `https://codecov.io
|
and importing reports to sites such as `https://codecov.io
|
||||||
<https://codecov.io>`_.
|
<https://codecov.io>`_.
|
||||||
|
|
||||||
@@ -270,39 +333,41 @@ profiled C++ code functions.
|
|||||||
|
|
||||||
To use profiling:
|
To use profiling:
|
||||||
|
|
||||||
#. Use Verilator's :vlopt:`--prof-cfuncs`.
|
#. Make sure the Verilog code will call `$finish` at the end of simulation
|
||||||
|
(otherwise the C library may not correctly create the `gmon.out` file in
|
||||||
|
the later steps below).
|
||||||
|
#. Run Verilator, adding the :vlopt:`--prof-cfuncs` option.
|
||||||
#. Build and run the simulation model.
|
#. Build and run the simulation model.
|
||||||
#. The model will create gmon.out.
|
#. The model will create `gmon.out`.
|
||||||
#. Run :command:`gprof` to see where in the C++ code the time is spent.
|
#. Run :command:`gprof gmon.out > gprof.log` to see where in the C++ code
|
||||||
#. Run the gprof output through the :command:`verilator_profcfunc` program
|
the time is spent.
|
||||||
and it will tell you what Verilog line numbers on which most of the time
|
#. Run :command:`verilator_profcfunc gprof.log > profcfunc.log` to take the
|
||||||
is being spent.
|
gprof output and translate into output showing the Verilog line numbers
|
||||||
|
on which most of the time is being spent.
|
||||||
|
|
||||||
|
|
||||||
.. _Thread Profiling:
|
.. _Execution Profiling:
|
||||||
|
|
||||||
Thread Profiling
|
Execution Profiling
|
||||||
================
|
===================
|
||||||
|
|
||||||
When using multithreaded mode (:vlopt:`--threads`), it is useful to see
|
For performance optimization, it is helpful to see statistics and visualize how
|
||||||
statistics and visualize how well the multiple CPUs are being utilized.
|
execution time is distributed in a verilated model.
|
||||||
|
|
||||||
With the :vlopt:`--prof-threads` option, Verilator will:
|
With the :vlopt:`--prof-exec` option, Verilator will:
|
||||||
|
|
||||||
* Add code to the Verilated model to record the start and end time of each
|
* Add code to the Verilated model to record execution flow.
|
||||||
macro-task across a number of calls to eval. (What is a macro-task? See
|
|
||||||
the Verilator internals document (:file:`docs/internals.rst` in the
|
|
||||||
distribution.)
|
|
||||||
|
|
||||||
* Add code to save profiling data in non-human-friendly form to the file
|
* Add code to save profiling data in non-human-friendly form to the file
|
||||||
specified with :vlopt:`+verilator+prof+threads+file+\<filename\>`.
|
specified with :vlopt:`+verilator+prof+exec+file+\<filename\>`.
|
||||||
|
|
||||||
* Add code to save profiling data for thread profile-guided
|
* In multithreaded models, add code to record each macro-task's start and
|
||||||
optimization. See :ref:`Thread PGO`.
|
end time across several calls to eval. (What is a macro-task? See the
|
||||||
|
Verilator internals document (:file:`docs/internals.rst` in the
|
||||||
|
distribution.)
|
||||||
|
|
||||||
The :command:`verilator_gantt` program may then be run to transform the
|
The :command:`verilator_gantt` program may then be run to transform the
|
||||||
saved profiling file into a nicer visual format and produce some related
|
saved profiling file into a visual format and produce related statistics.
|
||||||
statistics.
|
|
||||||
|
|
||||||
.. figure:: figures/fig_gantt_min.png
|
.. figure:: figures/fig_gantt_min.png
|
||||||
|
|
||||||
@@ -310,11 +375,11 @@ statistics.
|
|||||||
|
|
||||||
The measured_parallelism shows the number of CPUs being used at a given moment.
|
The measured_parallelism shows the number of CPUs being used at a given moment.
|
||||||
|
|
||||||
The cpu_thread section shows which thread is executing on each of the physical CPUs.
|
The cpu_thread section shows which thread is executing on each physical CPU.
|
||||||
|
|
||||||
The thread_mtask section shows which macro-task is running on a given thread.
|
The thread_mtask section shows which macro-task is running on a given thread.
|
||||||
|
|
||||||
For more information see :command:`verilator_gantt`.
|
For more information, see :command:`verilator_gantt`.
|
||||||
|
|
||||||
|
|
||||||
.. _Profiling ccache efficiency:
|
.. _Profiling ccache efficiency:
|
||||||
@@ -322,12 +387,11 @@ For more information see :command:`verilator_gantt`.
|
|||||||
Profiling ccache efficiency
|
Profiling ccache efficiency
|
||||||
===========================
|
===========================
|
||||||
|
|
||||||
The Verilator generated Makefile provides support for basic profiling of
|
The Verilator-generated Makefile supports basic profiling of ccache
|
||||||
ccache behavior during the build. This can be used to track down files that
|
behavior during the build. This can be used to track down files that might
|
||||||
might be unnecessarily rebuilt, though as of today even small code changes
|
be unnecessarily rebuilt, though as of today, even minor code changes will
|
||||||
will usually require rebuilding a large number of files. Improving ccache
|
usually require rebuilding a large number of files. Improving ccache
|
||||||
efficiency during the edit/compile/test loop is an active area of
|
efficiency during the edit/compile/test loop is an active development area.
|
||||||
development.
|
|
||||||
|
|
||||||
To get a basic report of how well ccache is doing, add the `ccache-report`
|
To get a basic report of how well ccache is doing, add the `ccache-report`
|
||||||
target when invoking the generated Makefile:
|
target when invoking the generated Makefile:
|
||||||
@@ -351,17 +415,17 @@ releases.
|
|||||||
Save/Restore
|
Save/Restore
|
||||||
============
|
============
|
||||||
|
|
||||||
The intermediate state of a Verilated model may be saved, so that it may
|
The intermediate state of a Verilated model may be saved so that it may
|
||||||
later be restored.
|
later be restored.
|
||||||
|
|
||||||
To enable this feature, use :vlopt:`--savable`. There are limitations in
|
To enable this feature, use :vlopt:`--savable`. There are limitations in
|
||||||
what language features are supported along with :vlopt:`--savable`; if you
|
what language features are supported along with :vlopt:`--savable`; if you
|
||||||
attempt to use an unsupported feature Verilator will throw an error.
|
attempt to use an unsupported feature, Verilator will throw an error.
|
||||||
|
|
||||||
To use save/restore, the user wrapper code must create a VerilatedSerialize
|
To use save/restore, the user wrapper code must create a VerilatedSerialize
|
||||||
or VerilatedDeserialze object then calling the :code:`<<` or :code:`>>`
|
or VerilatedDeserialze object and then call the :code:`<<` or :code:`>>`
|
||||||
operators on the generated model and any other data the process needs
|
operators on the generated model and any other data the process needs to be
|
||||||
saved/restored. These functions are not thread safe, and are typically
|
saved/restored. These functions are not thread-safe and are typically
|
||||||
called only by a main thread.
|
called only by a main thread.
|
||||||
|
|
||||||
For example:
|
For example:
|
||||||
@@ -371,7 +435,7 @@ For example:
|
|||||||
void save_model(const char* filenamep) {
|
void save_model(const char* filenamep) {
|
||||||
VerilatedSave os;
|
VerilatedSave os;
|
||||||
os.open(filenamep);
|
os.open(filenamep);
|
||||||
os << main_time; // user code must save the timestamp, etc
|
os << main_time; // user code must save the timestamp
|
||||||
os << *topp;
|
os << *topp;
|
||||||
}
|
}
|
||||||
void restore_model(const char* filenamep) {
|
void restore_model(const char* filenamep) {
|
||||||
@@ -386,11 +450,11 @@ Profile-Guided Optimization
|
|||||||
===========================
|
===========================
|
||||||
|
|
||||||
Profile-guided optimization is the technique where profiling data is
|
Profile-guided optimization is the technique where profiling data is
|
||||||
collected by running your simulation executable, then this information is
|
collected by running your simulation executable; then this information is
|
||||||
used to guide the next Verilation or compilation.
|
used to guide the next Verilation or compilation.
|
||||||
|
|
||||||
There are two forms of profile-guided optimizations. Unfortunately for
|
There are two forms of profile-guided optimizations. Unfortunately, for
|
||||||
best results they must each be performed from the highest level code to the
|
best results, they must each be performed from the highest level code to the
|
||||||
lowest, which means performing them separately and in this order:
|
lowest, which means performing them separately and in this order:
|
||||||
|
|
||||||
* :ref:`Thread PGO`
|
* :ref:`Thread PGO`
|
||||||
@@ -398,7 +462,7 @@ lowest, which means performing them separately and in this order:
|
|||||||
|
|
||||||
Other forms of PGO may be supported in the future, such as clock and reset
|
Other forms of PGO may be supported in the future, such as clock and reset
|
||||||
toggle rate PGO, branch prediction PGO, statement execution time PGO, or
|
toggle rate PGO, branch prediction PGO, statement execution time PGO, or
|
||||||
others as they prove beneficial.
|
others, as they prove beneficial.
|
||||||
|
|
||||||
|
|
||||||
.. _Thread PGO:
|
.. _Thread PGO:
|
||||||
@@ -406,8 +470,8 @@ others as they prove beneficial.
|
|||||||
Thread Profile-Guided Optimization
|
Thread Profile-Guided Optimization
|
||||||
----------------------------------
|
----------------------------------
|
||||||
|
|
||||||
Verilator supports thread profile-guided optimization (Thread PGO) to
|
Verilator supports profile-guided optimization (Verilation) of multithreaded
|
||||||
improve multithreaded performance.
|
models (Thread PGO) to improve performance.
|
||||||
|
|
||||||
When using multithreading, Verilator computes how long macro tasks take and
|
When using multithreading, Verilator computes how long macro tasks take and
|
||||||
tries to balance those across threads. (What is a macro-task? See the
|
tries to balance those across threads. (What is a macro-task? See the
|
||||||
@@ -417,30 +481,31 @@ balanced, leading to decreased performance. Thread PGO allows collecting
|
|||||||
profiling data to replace the estimates and better optimize these
|
profiling data to replace the estimates and better optimize these
|
||||||
decisions.
|
decisions.
|
||||||
|
|
||||||
To use Thread PGO, Verilate the model with the :vlopt:`--prof-threads`
|
To use Thread PGO, Verilate the model with the :vlopt:`--prof-pgo` option. This
|
||||||
option.
|
will code to the verilated model to save profiling data for profile-guided
|
||||||
|
optimization.
|
||||||
|
|
||||||
Run the model executable. When the executable exits, it will create a
|
Run the model executable. When the executable exits, it will create a
|
||||||
profile.vlt file.
|
profile.vlt file.
|
||||||
|
|
||||||
Rerun Verilator, optionally omitting the :vlopt:`--prof-threads` option,
|
Rerun Verilator, optionally omitting the :vlopt:`--prof-pgo` option and
|
||||||
and adding the profile.vlt generated earlier to the command line.
|
adding the :file:`profile.vlt` generated earlier to the command line.
|
||||||
|
|
||||||
Note there is no Verilator equivalent to GCC's --fprofile-use. Verilator's
|
Note there is no Verilator equivalent to GCC's --fprofile-use. Verilator's
|
||||||
profile data file (profile.vlt) can be placed on the verilator command line
|
profile data file (:file:`profile.vlt`) can be placed directly on the
|
||||||
directly without any prefix.
|
verilator command line without any option prefix.
|
||||||
|
|
||||||
If results from multiple simulations are to be used in generating the
|
If results from multiple simulations are to be used in generating the
|
||||||
optimization, multiple simulation's profile.vlt may be concatenated
|
optimization, multiple simulation's profile.vlt may be concatenated
|
||||||
externally, or each of the files may be fed as separate command line
|
externally, or each file may be fed as separate command line options into
|
||||||
options into Verilator. Verilator will simply sum the profile results, so
|
Verilator. Verilator will sum the profile results, so a long-running test
|
||||||
a longer running test will have proportionally more weight for optimization
|
will have more weight for optimization proportionally than a
|
||||||
than a shorter running test.
|
shorter-running test.
|
||||||
|
|
||||||
If you provide any profile feedback data to Verilator, and it cannot use
|
If you provide any profile feedback data to Verilator and it cannot use
|
||||||
it, it will issue the :option:`PROFOUTOFDATE` warning that threads were
|
it, it will issue the :option:`PROFOUTOFDATE` warning that threads were
|
||||||
scheduled using estimated costs. This usually indicates that the profile
|
scheduled using estimated costs. This usually indicates that the profile
|
||||||
data was generated from different Verilog source code than Verilator is
|
data was generated from a different Verilog source code than Verilator is
|
||||||
currently running against. Therefore, repeat the data collection phase to
|
currently running against. Therefore, repeat the data collection phase to
|
||||||
create new profiling data, then rerun Verilator with the same input source
|
create new profiling data, then rerun Verilator with the same input source
|
||||||
files and that new profiling data.
|
files and that new profiling data.
|
||||||
@@ -452,12 +517,12 @@ Compiler Profile-Guided Optimization
|
|||||||
------------------------------------
|
------------------------------------
|
||||||
|
|
||||||
GCC and Clang support compiler profile-guided optimization (PGO). This
|
GCC and Clang support compiler profile-guided optimization (PGO). This
|
||||||
optimizes any C/C++ program including Verilated code. Using compiler PGO
|
optimizes any C/C++ program, including Verilated code. Using compiler PGO
|
||||||
typically yields improvements of 5-15% on both single-threaded and
|
typically yields improvements of 5-15% on both single-threaded and
|
||||||
multi-threaded models.
|
multithreaded models.
|
||||||
|
|
||||||
To use compiler PGO with GCC or Clang, please see the appropriate compiler
|
Please see the appropriate compiler documentation to use PGO with GCC or
|
||||||
documentation. The process in GCC 10 was as follows:
|
Clang. The process in GCC 10 was as follows:
|
||||||
|
|
||||||
1. Compile the Verilated model with the compiler's "-fprofile-generate"
|
1. Compile the Verilated model with the compiler's "-fprofile-generate"
|
||||||
flag:
|
flag:
|
||||||
@@ -467,7 +532,7 @@ documentation. The process in GCC 10 was as follows:
|
|||||||
verilator [whatever_flags] --make \
|
verilator [whatever_flags] --make \
|
||||||
-CFLAGS -fprofile-generate -LDFLAGS -fprofile-generate
|
-CFLAGS -fprofile-generate -LDFLAGS -fprofile-generate
|
||||||
|
|
||||||
or, if calling make yourself, add -fprofile-generate appropriately to your
|
Or, if calling make yourself, add -fprofile-generate appropriately to your
|
||||||
Makefile.
|
Makefile.
|
||||||
|
|
||||||
2. Run your simulation. This will create \*.gcda file(s) in the same
|
2. Run your simulation. This will create \*.gcda file(s) in the same
|
||||||
@@ -494,6 +559,40 @@ documentation. The process in GCC 10 was as follows:
|
|||||||
or, if calling make yourself, add these CFLAGS switches appropriately to
|
or, if calling make yourself, add these CFLAGS switches appropriately to
|
||||||
your Makefile.
|
your Makefile.
|
||||||
|
|
||||||
Clang and GCC also support -fauto-profile which uses sample-based
|
Clang and GCC also support -fauto-profile, which uses sample-based
|
||||||
feedback-directed optimization. See the appropriate compiler
|
feedback-directed optimization. See the appropriate compiler
|
||||||
documentation.
|
documentation.
|
||||||
|
|
||||||
|
|
||||||
|
.. _Runtime Debugging:
|
||||||
|
|
||||||
|
Runtime Debugging
|
||||||
|
=================
|
||||||
|
|
||||||
|
To debug a Verilated executable, Verilate with :vlopt:`--runtime-debug`.
|
||||||
|
This will instruct the compiler to insert debugger, and enable various
|
||||||
|
library assertions. These options slow down the executable, so do this
|
||||||
|
only when debugging.
|
||||||
|
|
||||||
|
If you are using your own Makefiles, adapt appropriately to pass the
|
||||||
|
options documented under :vlopt:`--runtime-debug` to the compiler and
|
||||||
|
linker.
|
||||||
|
|
||||||
|
Once you have a debugging-enabled executable, run it using the the standard
|
||||||
|
GNU debugger ``gdb`` or a similar tool, and create a backtrace; e.g.:
|
||||||
|
|
||||||
|
.. code-block:: bash
|
||||||
|
|
||||||
|
gdb obj_dir/Vtop
|
||||||
|
run {Vtop_command_arguments}
|
||||||
|
{Vtop prints output, perhaps a segmentation faults}
|
||||||
|
bt
|
||||||
|
|
||||||
|
Rarely the bug may disappear with :vlopt:`--runtime-debug`; if so, try
|
||||||
|
instead using the sub-options that :vlopt:`--runtime-debug` documents, to
|
||||||
|
find the maximum subset that still shows the issue. E.g. it is likely that
|
||||||
|
using `-CFLAGS -D_GLIBCXX_DEBUG` will not hide any bug, so may be used.
|
||||||
|
|
||||||
|
Using :vlopt:`--runtime-debug` or `-CFLAGS -DVL_DEBUG=1` will only print a
|
||||||
|
message if something goes wrong. To enable debug print messages at
|
||||||
|
runtime, additionally use the :vlopt:`+verilator+debug` runtime option.
|
||||||
|
|||||||
+196
-118
@@ -1,4 +1,4 @@
|
|||||||
.. Copyright 2003-2021 by Wilson Snyder.
|
.. Copyright 2003-2024 by Wilson Snyder.
|
||||||
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
**********
|
**********
|
||||||
@@ -7,9 +7,13 @@ Verilating
|
|||||||
|
|
||||||
Verilator may be used in five major ways:
|
Verilator may be used in five major ways:
|
||||||
|
|
||||||
|
* With the :vlopt:`--binary` option, Verilator will translate the design
|
||||||
|
into an executable, via generating C++ and compiling it. See
|
||||||
|
:ref:`Binary, C++ and SystemC Generation`.
|
||||||
|
|
||||||
* With the :vlopt:`--cc` or :vlopt:`--sc` options, Verilator will translate
|
* With the :vlopt:`--cc` or :vlopt:`--sc` options, Verilator will translate
|
||||||
the design into C++ or SystemC code respectively. See :ref:`C++ and
|
the design into C++ or SystemC code, respectively. See :ref:`Binary, C++
|
||||||
SystemC Generation`.
|
and SystemC Generation`.
|
||||||
|
|
||||||
* With the :vlopt:`--lint-only` option, Verilator will lint the design to
|
* With the :vlopt:`--lint-only` option, Verilator will lint the design to
|
||||||
check for warnings but will not typically create any output files.
|
check for warnings but will not typically create any output files.
|
||||||
@@ -19,25 +23,27 @@ Verilator may be used in five major ways:
|
|||||||
:file:`docs/xml.rst` in the distribution.
|
:file:`docs/xml.rst` in the distribution.
|
||||||
|
|
||||||
* With the :vlopt:`-E` option, Verilator will preprocess the code according
|
* With the :vlopt:`-E` option, Verilator will preprocess the code according
|
||||||
to IEEE preprocessing rules, and write the output to standard out. This
|
to IEEE preprocessing rules and write the output to standard out. This
|
||||||
is useful to feed other tools, and to debug how "\`define" statements are
|
is useful to feed other tools and to debug how "\`define" statements are
|
||||||
expanded.
|
expanded.
|
||||||
|
|
||||||
|
|
||||||
.. _C++ and SystemC Generation:
|
.. _Binary, C++ and SystemC Generation:
|
||||||
|
|
||||||
C++ and SystemC Generation
|
Binary, C++ and SystemC Generation
|
||||||
==========================
|
==================================
|
||||||
|
|
||||||
Verilator will translate a SystemVerilog design into C++ with the
|
Verilator will translate a SystemVerilog design into C++ with the
|
||||||
:vlopt:`--cc` option, or into SystemC with the :vlopt:`--sc` option.
|
:vlopt:`--cc` option, or into SystemC with the :vlopt:`--sc` option. It
|
||||||
|
will translate into C++ and compile it into an executable binary with the
|
||||||
|
:vlopt:`--binary` option.
|
||||||
|
|
||||||
When using these options:
|
When using these options:
|
||||||
|
|
||||||
#. Verilator reads the input Verilog code, determines all "top modules" that
|
#. Verilator reads the input Verilog code and determines all "top modules", that
|
||||||
is modules or programs that are not used as instances under other cells.
|
is, modules or programs that are not used as instances under other cells.
|
||||||
If :vlopt:`--top-module` is used, then that determines the top module and
|
If :vlopt:`--top-module` is used, then that determines the top module, and
|
||||||
all other top modules are removed, otherwise a :vlopt:`MULTITOP` warning
|
all other top modules are removed; otherwise a :vlopt:`MULTITOP` warning
|
||||||
is given.
|
is given.
|
||||||
|
|
||||||
#. Verilator writes the C++/SystemC code to output files into the
|
#. Verilator writes the C++/SystemC code to output files into the
|
||||||
@@ -45,14 +51,19 @@ When using these options:
|
|||||||
The prefix is set with :vlopt:`--prefix`, or defaults to the name of the
|
The prefix is set with :vlopt:`--prefix`, or defaults to the name of the
|
||||||
top module.
|
top module.
|
||||||
|
|
||||||
#. If :vlopt:`--exe` is used, Verilator creates makefiles to generate a
|
#. If :vlopt:`--binary` or :vlopt:`--main` is used, Verilator creates a C++
|
||||||
simulation executable, otherwise it creates makefiles to generate an
|
top wrapper to read command line arguments, create the model, and
|
||||||
archive (.a) containing the objects.
|
execute the model.
|
||||||
|
|
||||||
#. If :vlopt:`--build` option was used, it calls :ref:`GNU Make` or
|
#. If :vlopt:`--binary` or :vlopt:`--exe` is used, Verilator creates
|
||||||
:ref:`CMake` to build the model.
|
makefiles to generate a simulation executable, otherwise, it creates
|
||||||
|
makefiles to generate an archive (.a) containing the objects.
|
||||||
|
|
||||||
Once a model is built it is then typically run, see :ref:`Simulating`.
|
#. If :vlopt:`--binary` or :vlopt:`--build` is used, it calls :ref:`GNU
|
||||||
|
Make` or :ref:`CMake` to build the model.
|
||||||
|
|
||||||
|
Once a model is built, the next step is typically for the user to run it,
|
||||||
|
see :ref:`Simulating`.
|
||||||
|
|
||||||
|
|
||||||
.. _Hierarchical Verilation:
|
.. _Hierarchical Verilation:
|
||||||
@@ -60,15 +71,15 @@ Once a model is built it is then typically run, see :ref:`Simulating`.
|
|||||||
Hierarchical Verilation
|
Hierarchical Verilation
|
||||||
=======================
|
=======================
|
||||||
|
|
||||||
Large designs may take long (e.g. 10+ minutes) and huge memory (e.g. 100+
|
Large designs may take long (e.g., 10+ minutes) and huge memory (e.g., 100+
|
||||||
GB) to Verilate. In hierarchical mode, the user manually selects some
|
GB) to Verilate. In hierarchical mode, the user manually selects some
|
||||||
large lower-level hierarchy blocks to separate from the larger design. For
|
large lower-level hierarchy blocks to separate from the larger design. For
|
||||||
example a core may be the hierarchy block, and separated out of a
|
example, a core may be the hierarchy block separated out of a multi-core
|
||||||
multi-core SoC.
|
SoC design.
|
||||||
|
|
||||||
Verilator is run in hierarchical mode on the whole SoC. Verilator will
|
Verilator is run in hierarchical mode on the whole SoC. Verilator will
|
||||||
make two models, one for the CPU hierarchy block, and one for the SoC. The
|
make two models, one for the CPU hierarchy block and one for the SoC. The
|
||||||
Verialted code for the SoC will automatically call the CPU Verilated model.
|
Verilated code for the SoC will automatically call the CPU Verilated model.
|
||||||
|
|
||||||
The current hierarchical Verilation is based on :vlopt:`--lib-create`. Each
|
The current hierarchical Verilation is based on :vlopt:`--lib-create`. Each
|
||||||
hierarchy block is Verilated into a library. User modules of the hierarchy
|
hierarchy block is Verilated into a library. User modules of the hierarchy
|
||||||
@@ -78,16 +89,16 @@ blocks will see a tiny wrapper generated by :vlopt:`--lib-create`.
|
|||||||
Usage
|
Usage
|
||||||
-----
|
-----
|
||||||
|
|
||||||
Users need to mark one or more moderate size module as hierarchy block(s).
|
Users need to mark one or more moderate-size modules as hierarchy block(s).
|
||||||
There are two ways to mark a module:
|
There are two ways to mark a module:
|
||||||
|
|
||||||
* Write :option:`/*verilator&32;hier_block*/` metacomment in HDL code.
|
* Write :option:`/*verilator&32;hier_block*/` metacomment in HDL code.
|
||||||
|
|
||||||
* Add a :option:`hier_block` line in a the :ref:`Configuration Files`.
|
* Add a :option:`hier_block` line in the :ref:`Configuration Files`.
|
||||||
|
|
||||||
Then pass the :vlopt:`--hierarchical` option to Verilator
|
Then pass the :vlopt:`--hierarchical` option to Verilator.
|
||||||
|
|
||||||
Compilation is the same as when not using hierarchical mode.
|
The compilation is the same as when not using hierarchical mode.
|
||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
@@ -97,21 +108,22 @@ Compilation is the same as when not using hierarchical mode.
|
|||||||
Limitations
|
Limitations
|
||||||
-----------
|
-----------
|
||||||
|
|
||||||
Hierarchy blocks have some limitations including:
|
Hierarchy blocks have some limitations, including:
|
||||||
|
|
||||||
* The hierarchy block cannot be accessed using dot (.) from upper module(s)
|
* The hierarchy block cannot be accessed using dot (.) from the upper
|
||||||
or other hierarchy blocks.
|
module(s) or other hierarchy blocks.
|
||||||
|
|
||||||
* Signals in the block cannot be traced.
|
* Signals in the block cannot be traced.
|
||||||
|
|
||||||
* Modport cannot be used at the hierarchical block boundary.
|
* Modport cannot be used at the hierarchical block boundary.
|
||||||
|
|
||||||
* The simulation speed is likely to not be as fast as flat Verilation, in
|
* The simulation speed is likely not as fast as flat Verilation, in which
|
||||||
which all modules are globally scheduled.
|
all modules are globally scheduled.
|
||||||
|
|
||||||
* Generated clocks may not work correctly if they are generated in the
|
* Generated clocks may not work correctly if generated in the hierarchical
|
||||||
hierarchical model and pass up into another hierarchical model or the top
|
model and passed into another hierarchical model or the top module.
|
||||||
module.
|
|
||||||
|
* Delays are not allowed in hierarchy blocks.
|
||||||
|
|
||||||
But, the following usage is supported:
|
But, the following usage is supported:
|
||||||
|
|
||||||
@@ -128,8 +140,8 @@ Overlapping Verilation and Compilation
|
|||||||
--------------------------------------
|
--------------------------------------
|
||||||
|
|
||||||
Verilator needs to run 2 + *N* times in hierarchical Verilation, where *N*
|
Verilator needs to run 2 + *N* times in hierarchical Verilation, where *N*
|
||||||
is the number of hierarchy blocks. One of the two is for the top module
|
is the number of hierarchy blocks. One of the two is for the top module,
|
||||||
which refers wrappers of all other hierarchy blocks. The second one of the
|
which refers to the wrappers of all other hierarchy blocks. The second of the
|
||||||
two is the initial run that searches modules marked with
|
two is the initial run that searches modules marked with
|
||||||
:option:`/*verilator&32;hier_block*/` metacomment and creates a plan and
|
:option:`/*verilator&32;hier_block*/` metacomment and creates a plan and
|
||||||
write in :file:`{prefix}_hier.mk`. This initial run internally invokes
|
write in :file:`{prefix}_hier.mk`. This initial run internally invokes
|
||||||
@@ -151,20 +163,20 @@ Verilator supports cross-compiling Verilated code. This is generally used
|
|||||||
to run Verilator on a Linux system and produce C++ code that is then compiled
|
to run Verilator on a Linux system and produce C++ code that is then compiled
|
||||||
on Windows.
|
on Windows.
|
||||||
|
|
||||||
Cross compilation involves up to three different OSes. The build system is
|
Cross-compilation involves up to three different OSes. The build system is
|
||||||
where you configured and compiled Verilator, the host system where you run
|
where you configure and compile Verilator, the host system is where you run
|
||||||
Verilator, and the target system where you compile the Verilated code and
|
Verilator, and the target system is where you compile the Verilated code
|
||||||
run the simulation.
|
and run the simulation.
|
||||||
|
|
||||||
Currently, Verilator requires the build and host system type to be the
|
Verilator requires the build and host system types to be the
|
||||||
same, though the target system type may be different. To support this,
|
same, though the target system type may be different. To support this,
|
||||||
:command:`./configure` and make Verilator on the build system. Then, run
|
:command:`./configure` and make Verilator on the build system. Then, run
|
||||||
Verilator on the host system. Finally, the output of Verilator may be
|
Verilator on the host system. Finally, the output of Verilator may be
|
||||||
compiled on the different target system.
|
compiled on the different target system.
|
||||||
|
|
||||||
To support this, none of the files that Verilator produces will reference
|
To support this, none of the files that Verilator produces will reference
|
||||||
any configure generated build-system specific files, such as
|
any configure-generated build-system-specific files, such as
|
||||||
:file:`config.h` (which is renamed in Verilator to :file:`config_build.h`
|
:file:`config.h` (which is renamed in Verilator to :file:`config_package.h`
|
||||||
to reduce confusion.) The disadvantage of this approach is that
|
to reduce confusion.) The disadvantage of this approach is that
|
||||||
:file:`include/verilatedos.h` must self-detect the requirements of the
|
:file:`include/verilatedos.h` must self-detect the requirements of the
|
||||||
target system, rather than using configure.
|
target system, rather than using configure.
|
||||||
@@ -181,109 +193,101 @@ Multithreading
|
|||||||
|
|
||||||
Verilator supports multithreaded simulation models.
|
Verilator supports multithreaded simulation models.
|
||||||
|
|
||||||
With :vlopt:`--no-threads`, the default, the model is not thread safe, and
|
With :vlopt:`--threads 1 <--threads>`, the generated model is
|
||||||
any use of more than one thread calling into one or even different
|
single-threaded; however, the support libraries are multithread safe. This
|
||||||
Verilated models may result in unpredictable behavior. This gives the
|
allows different instantiations of the model(s) to potentially each be run
|
||||||
highest single thread performance.
|
under a different thread. All threading is the responsibility of the user's
|
||||||
|
C++ testbench.
|
||||||
With :vlopt:`--threads 1 <--threads>`, the generated model is single
|
|
||||||
threaded, however the support libraries are multithread safe. This allows
|
|
||||||
different instantiations of model(s) to potentially each be run under a
|
|
||||||
different thread. All threading is the responsibility of the user's C++
|
|
||||||
testbench.
|
|
||||||
|
|
||||||
With :vlopt:`--threads {N} <--threads>`, where N is at least 2, the
|
With :vlopt:`--threads {N} <--threads>`, where N is at least 2, the
|
||||||
generated model will be designed to run in parallel on N threads. The
|
generated model will be designed to run in parallel on N threads. The
|
||||||
thread calling eval() provides one of those threads, and the generated
|
thread calling eval() provides one of those threads, and the generated
|
||||||
model will create and manage the other N-1 threads. It's the client's
|
model will create and manage the other N-1 threads. It's the client's
|
||||||
responsibility not to oversubscribe the available CPU cores. Under CPU
|
responsibility not to oversubscribe the available CPU cores. Under CPU
|
||||||
oversubscription, the Verilated model should not livelock nor deadlock,
|
oversubscription, the Verilated model should not livelock nor deadlock;
|
||||||
however, you can expect performance to be far worse than it would be with
|
however, you can expect performance to be far worse than it would be with
|
||||||
proper ratio of threads and CPU cores.
|
the proper ratio of threads and CPU cores.
|
||||||
|
|
||||||
The remainder of this section describe behavior with :vlopt:`--threads 1
|
|
||||||
<--threads>` or :vlopt:`--threads {N} <--threads>` (not
|
|
||||||
:vlopt:`--no-threads`).
|
|
||||||
|
|
||||||
:code:`VL_THREADED` is defined in the C++ code when compiling a threaded
|
|
||||||
Verilated module, causing the Verilated support classes become threadsafe.
|
|
||||||
|
|
||||||
The thread used for constructing a model must be the same thread that calls
|
The thread used for constructing a model must be the same thread that calls
|
||||||
:code:`eval()` into the model, this is called the "eval thread". The thread
|
:code:`eval()` into the model; this is called the "eval thread". The thread
|
||||||
used to perform certain global operations such as saving and tracing must
|
used to perform certain global operations, such as saving and tracing, must
|
||||||
be done by a "main thread". In most cases the eval thread and main thread
|
be done by a "main thread". In most cases, the eval thread and main thread
|
||||||
are the same thread (i.e. the user's top C++ testbench runs on a single
|
are the same thread (i.e. the user's top C++ testbench runs on a single
|
||||||
thread), but this is not required.
|
thread), but this is not required.
|
||||||
|
|
||||||
When making frequent use of DPI imported functions in a multi-threaded
|
When making frequent use of DPI imported functions in a multithreaded
|
||||||
model, it may be beneficial to performance to adjust the
|
model, it may be beneficial to performance to adjust the
|
||||||
:vlopt:`--instr-count-dpi` option based on some experimentation. This
|
:vlopt:`--instr-count-dpi` option based on some experimentation. This
|
||||||
influences the partitioning of the model by adjusting the assumed execution
|
influences the partitioning of the model by adjusting the assumed execution
|
||||||
time of DPI imports.
|
time of DPI imports.
|
||||||
|
|
||||||
The :vlopt:`--trace-threads` options can be used to produce trace dumps
|
When using :vlopt:`--trace` to perform VCD tracing, the VCD trace
|
||||||
using multiple threads. If :vlopt:`--trace-threads` is set without
|
construction is parallelized using the same number of threads as specified
|
||||||
:vlopt:`--threads`, then :vlopt:`--trace-threads` will imply
|
with :vlopt:`--threads`, and is executed on the same thread pool as the model.
|
||||||
:vlopt:`--threads 1 <--threads>`, i.e.: the support libraries will be
|
|
||||||
|
The :vlopt:`--trace-threads` options can be used with :vlopt:`--trace-fst`
|
||||||
|
to offload FST tracing using multiple threads. If :vlopt:`--trace-threads` is
|
||||||
|
given without :vlopt:`--threads`, then :vlopt:`--trace-threads` will imply
|
||||||
|
:vlopt:`--threads 1 <--threads>`, i.e., the support libraries will be
|
||||||
thread safe.
|
thread safe.
|
||||||
|
|
||||||
With :vlopt:`--trace-threads 0 <--trace-threads>`, trace dumps are produced
|
With :vlopt:`--trace-threads 0 <--trace-threads>`, trace dumps are produced
|
||||||
on the main thread. This again gives the highest single thread performance.
|
on the main thread. This again gives the highest single-thread performance.
|
||||||
|
|
||||||
With :vlopt:`--trace-threads {N} <--trace-threads>`, where N is at least 1,
|
With :vlopt:`--trace-threads {N} <--trace-threads>`, where N is at least 1,
|
||||||
N additional threads will be created and managed by the trace files (e.g.:
|
up to N additional threads will be created and managed by the trace files
|
||||||
VerilatedVcdC or VerilatedFstC), to generate the trace dump. The main
|
(e.g., VerilatedFstC), to offload construction of the trace dump. The main
|
||||||
thread will be released to proceed with execution as soon as possible,
|
thread will be released to proceed with execution as soon as possible, though
|
||||||
though some blocking of the main thread is still necessary while capturing
|
some main thread blocking is still necessary while capturing the
|
||||||
the trace. Different trace formats can utilize a various number of
|
trace. FST tracing can utilize up to 2 offload threads, so there is no use
|
||||||
threads. See the :vlopt:`--trace-threads` option.
|
of setting :vlopt:`--trace-threads` higher than 2 at the moment.
|
||||||
|
|
||||||
When running a multithreaded model, the default Linux task scheduler often
|
When running a multithreaded model, the default Linux task scheduler often
|
||||||
works against the model, by assuming threads are short lived, and thus
|
works against the model by assuming short-lived threads and thus
|
||||||
often schedules threads using multiple hyperthreads within the same
|
it often schedules threads using multiple hyperthreads within the same
|
||||||
physical core. For best performance use the :command:`numactl` program to
|
physical core. For best performance, use the :command:`numactl` program to
|
||||||
(when the threading count fits) select unique physical cores on the same
|
(when the threading count fits) select unique physical cores on the same
|
||||||
socket. The same applies for :vlopt:`--trace-threads` as well.
|
socket. The same applies for :vlopt:`--trace-threads` as well.
|
||||||
|
|
||||||
As an example, if a model was Verilated with :vlopt:`--threads 4
|
As an example, if a model was Verilated with
|
||||||
<--threads>`, we consult:
|
:vlopt:`--threads 4 <--threads>`, we consult:
|
||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
egrep 'processor|physical id|core id' /proc/cpuinfo
|
egrep 'processor|physical id|core id' /proc/cpuinfo
|
||||||
|
|
||||||
To select cores 0, 1, 2, and 3 that are all located on the same socket (0)
|
To select cores 0, 1, 2, and 3 that are all located on the same socket (0)
|
||||||
but different physical cores. (Also useful is :command:`numactl
|
but have different physical cores. (Also useful is
|
||||||
--hardware`, or :command:`lscpu` but those doesn't show Hyperthreading
|
:command:`numactl --hardware`, or :command:`lscpu`, but those don't show
|
||||||
cores.) Then we execute:
|
hyperthreading cores.) Then we execute:
|
||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
numactl -m 0 -C 0,1,2,3 -- verilated_executable_name
|
numactl -m 0 -C 0,1,2,3 -- verilated_executable_name
|
||||||
|
|
||||||
This will limit memory to socket 0, and threads to cores 0, 1, 2, 3,
|
This will limit memory to socket 0, and threads to cores 0, 1, 2, 3,
|
||||||
(presumably on socket 0) optimizing performance. Of course this must be
|
(presumably on socket 0), optimizing performance. Of course, this must be
|
||||||
adjusted if you want another simulator using e.g. socket 1, or if you
|
adjusted if you want another simulator to use, e.g., socket 1, or if you
|
||||||
Verilated with a different number of threads. To see what CPUs are
|
Verilated with a different number of threads. To see what CPUs are
|
||||||
actually used, use :vlopt:`--prof-threads`.
|
actually used, use :vlopt:`--prof-exec`.
|
||||||
|
|
||||||
|
|
||||||
Multithreaded Verilog and Library Support
|
Multithreaded Verilog and Library Support
|
||||||
-----------------------------------------
|
-----------------------------------------
|
||||||
|
|
||||||
$display/$stop/$finish are delayed until the end of an eval() call in order
|
$display/$stop/$finish are delayed until the end of an eval() call
|
||||||
to maintain ordering between threads. This may result in additional tasks
|
to maintain ordering between threads. This may result in additional tasks
|
||||||
completing after the $stop or $finish.
|
completing after the $stop or $finish.
|
||||||
|
|
||||||
If using :vlopt:`--coverage`, the coverage routines are fully thread safe.
|
If using :vlopt:`--coverage`, the coverage routines are fully thread-safe.
|
||||||
|
|
||||||
If using the DPI, Verilator assumes pure DPI imports are thread safe,
|
If using the DPI, Verilator assumes pure DPI imports are thread-safe,
|
||||||
balancing performance versus safety. See :vlopt:`--threads-dpi`.
|
balancing performance versus safety. See :vlopt:`--threads-dpi`.
|
||||||
|
|
||||||
If using :vlopt:`--savable`, the save/restore classes are not multithreaded
|
If using :vlopt:`--savable`, the save/restore classes are not multithreaded
|
||||||
and must be called only by the eval thread.
|
and must be called only by the eval thread.
|
||||||
|
|
||||||
If using :vlopt:`--sc`, the SystemC kernel is not thread safe, therefore
|
If using :vlopt:`--sc`, the SystemC kernel is not thread-safe; therefore,
|
||||||
the eval thread and main thread must be the same.
|
the eval thread and main thread must be the same.
|
||||||
|
|
||||||
If using :vlopt:`--trace`, the tracing classes must be constructed and
|
If using :vlopt:`--trace`, the tracing classes must be constructed and
|
||||||
@@ -303,8 +307,8 @@ Verilator defaults to creating GNU Make makefiles for the model. Verilator
|
|||||||
will call make automatically when the :vlopt:'--build' option is used.
|
will call make automatically when the :vlopt:'--build' option is used.
|
||||||
|
|
||||||
If calling Verilator from a makefile, the :vlopt:'-MMD' option will create
|
If calling Verilator from a makefile, the :vlopt:'-MMD' option will create
|
||||||
a dependency file which will allow Make to only run Verilator if input
|
a dependency file, allowing Make to only run Verilator if input Verilog
|
||||||
Verilog files change.
|
files change.
|
||||||
|
|
||||||
.. _CMake:
|
.. _CMake:
|
||||||
|
|
||||||
@@ -313,8 +317,8 @@ CMake
|
|||||||
|
|
||||||
Verilator can be run using CMake, which takes care of both running
|
Verilator can be run using CMake, which takes care of both running
|
||||||
Verilator and compiling the output. There is a CMake example in the
|
Verilator and compiling the output. There is a CMake example in the
|
||||||
examples/ directory. The following is a minimal CMakeLists.txt that would
|
:file:`examples/` directory. The following is a minimal CMakeLists.txt that
|
||||||
build the code listed in :ref:`Example C++ Execution`
|
would build the code listed in :ref:`Example C++ Execution`
|
||||||
|
|
||||||
.. code-block:: CMake
|
.. code-block:: CMake
|
||||||
|
|
||||||
@@ -326,8 +330,8 @@ build the code listed in :ref:`Example C++ Execution`
|
|||||||
:code:`find_package` will automatically find an installed copy of
|
:code:`find_package` will automatically find an installed copy of
|
||||||
Verilator, or use a local build if VERILATOR_ROOT is set.
|
Verilator, or use a local build if VERILATOR_ROOT is set.
|
||||||
|
|
||||||
It is recommended to use CMake >= 3.12 and the Ninja generator, though
|
Using CMake >= 3.12 and the Ninja generator is recommended, though other
|
||||||
other combinations should work. To build with CMake, change to the folder
|
combinations should work. To build with CMake, change to the folder
|
||||||
containing CMakeLists.txt and run:
|
containing CMakeLists.txt and run:
|
||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
@@ -346,14 +350,14 @@ Or to build with your system default generator:
|
|||||||
cmake ..
|
cmake ..
|
||||||
cmake --build .
|
cmake --build .
|
||||||
|
|
||||||
If you're building the example you should have an executable to run:
|
If you're building the example, you should have an executable to run:
|
||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
./Vour
|
./Vour
|
||||||
|
|
||||||
The package sets the CMake variables verilator_FOUND, VERILATOR_ROOT and
|
The package sets the CMake variables verilator_FOUND, VERILATOR_ROOT,
|
||||||
VERILATOR_BIN to the appropriate values, and also creates a verilate()
|
and VERILATOR_BIN to the appropriate values and creates a verilate()
|
||||||
function. verilate() will automatically create custom commands to run
|
function. verilate() will automatically create custom commands to run
|
||||||
Verilator and add the generated C++ sources to the target specified.
|
Verilator and add the generated C++ sources to the target specified.
|
||||||
|
|
||||||
@@ -368,14 +372,14 @@ Verilate in CMake
|
|||||||
[OPT_GLOBAL ..] [DIRECTORY dir] [THREADS num]
|
[OPT_GLOBAL ..] [DIRECTORY dir] [THREADS num]
|
||||||
[TRACE_THREADS num] [VERILATOR_ARGS ...])
|
[TRACE_THREADS num] [VERILATOR_ARGS ...])
|
||||||
|
|
||||||
Lowercase and ... should be replaced with arguments, the uppercase parts
|
Lowercase and ... should be replaced with arguments; the uppercase parts
|
||||||
delimit the arguments and can be passed in any order, or left out entirely
|
delimit the arguments and can be passed in any order or left out entirely
|
||||||
if optional.
|
if optional.
|
||||||
|
|
||||||
verilate(target ...) can be called multiple times to add other Verilog
|
verilate(target ...) can be called multiple times to add other Verilog
|
||||||
modules to an executable or library target.
|
modules to an executable or library target.
|
||||||
|
|
||||||
When generating Verilated SystemC sources, you should also include the
|
When generating Verilated SystemC sources, you should list the
|
||||||
SystemC include directories and link to the SystemC libraries.
|
SystemC include directories and link to the SystemC libraries.
|
||||||
|
|
||||||
.. describe:: target
|
.. describe:: target
|
||||||
@@ -385,7 +389,7 @@ SystemC include directories and link to the SystemC libraries.
|
|||||||
.. describe:: COVERAGE
|
.. describe:: COVERAGE
|
||||||
|
|
||||||
Optional. Enables coverage if present, equivalent to "VERILATOR_ARGS
|
Optional. Enables coverage if present, equivalent to "VERILATOR_ARGS
|
||||||
--coverage"
|
--coverage".
|
||||||
|
|
||||||
.. describe:: DIRECTORY
|
.. describe:: DIRECTORY
|
||||||
|
|
||||||
@@ -413,22 +417,22 @@ SystemC include directories and link to the SystemC libraries.
|
|||||||
.. describe:: PREFIX
|
.. describe:: PREFIX
|
||||||
|
|
||||||
Optional. Sets the Verilator output prefix. Defaults to the name of the
|
Optional. Sets the Verilator output prefix. Defaults to the name of the
|
||||||
first source file with a "V" prepended. Must be unique in each call to
|
first source file with a "V" prepended. It must be unique in each call
|
||||||
verilate(), so this is necessary if you build a module multiple times
|
to verilate(), so this is necessary if you build a module multiple times
|
||||||
with different parameters. Must be a valid C++ identifier, i.e. contains
|
with different parameters. It must be a valid C++ identifier, i.e., it
|
||||||
no white space and only characters A-Z, a-z, 0-9 or _.
|
contains no white space and only characters A-Z, a-z, 0-9 or _.
|
||||||
|
|
||||||
.. describe:: SOURCES
|
.. describe:: SOURCES
|
||||||
|
|
||||||
List of Verilog files to Verilate. Must have at least one file.
|
List of Verilog files to Verilate. You must provide at least one file.
|
||||||
|
|
||||||
.. describe:: SYSTEMC
|
.. describe:: SYSTEMC
|
||||||
|
|
||||||
Optional. Enables SystemC mode, defaults to C++ if not specified.
|
Optional. Enables SystemC mode, defaults to C++ if not specified.
|
||||||
|
|
||||||
When using Accellera's SystemC with CMake support, a CMake target is
|
When using Accellera's SystemC with CMake support, a CMake target is
|
||||||
available that simplifies the SystemC steps. This will only work if the
|
available that simplifies the SystemC steps. This will only work if
|
||||||
SystemC installation can be found by CMake. This can be configured by
|
CMake can find the SystemC installation, and this can be configured by
|
||||||
setting the CMAKE_PREFIX_PATH variable during CMake configuration.
|
setting the CMAKE_PREFIX_PATH variable during CMake configuration.
|
||||||
|
|
||||||
Don't forget to set the same C++ standard for the Verilated sources as
|
Don't forget to set the same C++ standard for the Verilated sources as
|
||||||
@@ -437,12 +441,11 @@ SystemC include directories and link to the SystemC libraries.
|
|||||||
|
|
||||||
.. describe:: THREADS
|
.. describe:: THREADS
|
||||||
|
|
||||||
Optional. Generated a multi-threaded model, same as "--threads".
|
Optional. Enable a multithreaded model; see :vlopt:`--threads`.
|
||||||
|
|
||||||
.. describe:: TRACE_THREADS
|
.. describe:: TRACE_THREADS
|
||||||
|
|
||||||
Optional. Generated multi-threaded trace dumping, same as
|
Optional. Enable multithreaded FST trace; see :vlopt:`--trace-threads`.
|
||||||
"--trace-threads".
|
|
||||||
|
|
||||||
.. describe:: TOP_MODULE
|
.. describe:: TOP_MODULE
|
||||||
|
|
||||||
@@ -462,7 +465,7 @@ SystemC include directories and link to the SystemC libraries.
|
|||||||
.. describe:: VERILATOR_ARGS
|
.. describe:: VERILATOR_ARGS
|
||||||
|
|
||||||
Optional. Extra arguments to Verilator. Do not specify :vlopt:`--Mdir`
|
Optional. Extra arguments to Verilator. Do not specify :vlopt:`--Mdir`
|
||||||
or :vlopt:`--prefix` here, use DIRECTORY or PREFIX.
|
or :vlopt:`--prefix` here; use DIRECTORY or PREFIX.
|
||||||
|
|
||||||
|
|
||||||
SystemC Link in CMake
|
SystemC Link in CMake
|
||||||
@@ -495,3 +498,78 @@ The search paths can be configured by setting some variables:
|
|||||||
|
|
||||||
Sets the installation prefix of an installed SystemC library. (Same as
|
Sets the installation prefix of an installed SystemC library. (Same as
|
||||||
SYSTEMC_ROOT).
|
SYSTEMC_ROOT).
|
||||||
|
|
||||||
|
|
||||||
|
.. _Verilation Summary Report:
|
||||||
|
|
||||||
|
Verilation Summary Report
|
||||||
|
=========================
|
||||||
|
|
||||||
|
When Verilator generates code, unless :vlopt:`--quiet-stats` is used, it
|
||||||
|
will print a report to stdout summarizing the build. For example:
|
||||||
|
|
||||||
|
.. code-block::
|
||||||
|
|
||||||
|
- V e r i l a t i o n R e p o r t: Verilator ....
|
||||||
|
- Verilator: Built from 354 MB sources in 247 modules,
|
||||||
|
into 74 MB in 89 C++ files needing 0.192 MB
|
||||||
|
- Verilator: Walltime 26.580 s (elab=2.096, cvt=18.268,
|
||||||
|
bld=2.100); cpu 26.548 s on 1 threads; alloced 2894.672 MB
|
||||||
|
|
||||||
|
The information in this report is:
|
||||||
|
|
||||||
|
.. describe:: "Verilator ..."
|
||||||
|
|
||||||
|
Program version.
|
||||||
|
|
||||||
|
.. describe:: "234 MB sources"
|
||||||
|
|
||||||
|
Characters of post-preprocessed text in all input
|
||||||
|
Verilog and Verilator Control files in megabytes.
|
||||||
|
|
||||||
|
.. describe:: "247 modules"
|
||||||
|
|
||||||
|
Number of interfaces/modules/classes/packages in design before
|
||||||
|
elaboration.
|
||||||
|
|
||||||
|
.. describe:: "into 74 MB"
|
||||||
|
|
||||||
|
Characters of output C++ code, including comments in megabytes.
|
||||||
|
|
||||||
|
.. describe:: "89 C++ files"
|
||||||
|
|
||||||
|
Number of .cpp files created.
|
||||||
|
|
||||||
|
.. describe:: "needing 192MB"
|
||||||
|
|
||||||
|
Verilation-time minimum-bound estimate of memory needed to run model in
|
||||||
|
megabytes. (Expect to need significantly more.)
|
||||||
|
|
||||||
|
.. describe:: "Walltime 26.580 s"
|
||||||
|
|
||||||
|
Real elapsed wall time for Verilation and build.
|
||||||
|
|
||||||
|
.. describe:: "elab=2.096"
|
||||||
|
|
||||||
|
Wall time to read in files and complete elaboration.
|
||||||
|
|
||||||
|
.. describe:: "cvt=18.268"
|
||||||
|
|
||||||
|
Wall time for Verilator to process and write output.
|
||||||
|
|
||||||
|
.. describe:: "bld=2.1"
|
||||||
|
|
||||||
|
Wall time to compile gcc/clang (if using :vlopt:`--build`).
|
||||||
|
|
||||||
|
.. describe:: "cpu 22.548 s"
|
||||||
|
|
||||||
|
CPU time used, total across all CPU threads.
|
||||||
|
|
||||||
|
.. describe:: "4 threads"
|
||||||
|
|
||||||
|
Number of simultaneous threads used.
|
||||||
|
|
||||||
|
.. describe:: "alloced 123 MB"
|
||||||
|
|
||||||
|
Total memory used during build by Verilator executable (excludes
|
||||||
|
:vlopt:`--build` compiler's usage) in megabytes.
|
||||||
|
|||||||
+854
-357
File diff suppressed because it is too large
Load Diff
+1380
-247
File diff suppressed because it is too large
Load Diff
@@ -1,28 +1,39 @@
|
|||||||
ABCp
|
ABCp
|
||||||
|
Aadi
|
||||||
Accellera
|
Accellera
|
||||||
Affe
|
Affe
|
||||||
Aleksander
|
Aleksander
|
||||||
|
Alexandre
|
||||||
Ami
|
Ami
|
||||||
Amir
|
Amir
|
||||||
Anastasiadis
|
Anastasiadis
|
||||||
|
Anglin
|
||||||
|
Anikin
|
||||||
|
Antmicro
|
||||||
Antonin
|
Antonin
|
||||||
Antwerpen
|
Antwerpen
|
||||||
Arasanipalai
|
Arasanipalai
|
||||||
Arjen
|
Arjen
|
||||||
|
Arshid
|
||||||
Asciidoc
|
Asciidoc
|
||||||
Ashutosh
|
Ashutosh
|
||||||
|
Ast
|
||||||
Atmel
|
Atmel
|
||||||
Aurelien
|
Aurelien
|
||||||
Bagri
|
Bagri
|
||||||
|
Balboni
|
||||||
Baltazar
|
Baltazar
|
||||||
Bardsley
|
Bardsley
|
||||||
Benchmarking
|
Benchmarking
|
||||||
Berman
|
Berman
|
||||||
Bhagavatula
|
Bhagavatula
|
||||||
Bhattacharyya
|
Bhattacharyya
|
||||||
|
Biancolin
|
||||||
Binderman
|
Binderman
|
||||||
|
Björk
|
||||||
Bleiweiss
|
Bleiweiss
|
||||||
Bogdan
|
Bogdan
|
||||||
|
Bonneau
|
||||||
Bouchard
|
Bouchard
|
||||||
Boumenot
|
Boumenot
|
||||||
Brej
|
Brej
|
||||||
@@ -30,28 +41,41 @@ Briquet
|
|||||||
Brownlee
|
Brownlee
|
||||||
Buckenmaier
|
Buckenmaier
|
||||||
Bybell
|
Bybell
|
||||||
|
CLang
|
||||||
CMake
|
CMake
|
||||||
Cai
|
Cai
|
||||||
Cavium
|
Cavium
|
||||||
Cfuncs
|
Cfuncs
|
||||||
Chandan
|
Chandan
|
||||||
|
Chentai
|
||||||
|
Cherkasov
|
||||||
|
Chih
|
||||||
Chitlesh
|
Chitlesh
|
||||||
Christophe
|
Christophe
|
||||||
Cochrane
|
Cochrane
|
||||||
|
Conda
|
||||||
|
Corteggiani
|
||||||
|
Cozzocrea
|
||||||
Cuan
|
Cuan
|
||||||
Cygwin
|
Cygwin
|
||||||
DErrico
|
DErrico
|
||||||
|
DFG
|
||||||
Da
|
Da
|
||||||
|
Dai
|
||||||
Danilo
|
Danilo
|
||||||
Dannoritzer
|
Dannoritzer
|
||||||
Das
|
Das
|
||||||
|
Davide
|
||||||
Dcache
|
Dcache
|
||||||
Deadman
|
Deadman
|
||||||
Debacker
|
Debacker
|
||||||
|
Deepa
|
||||||
Defparams
|
Defparams
|
||||||
|
Delm
|
||||||
Denio
|
Denio
|
||||||
Deprecations
|
Deprecations
|
||||||
Deroo
|
Deroo
|
||||||
|
Desai
|
||||||
Dickol
|
Dickol
|
||||||
Diez
|
Diez
|
||||||
Dimitris
|
Dimitris
|
||||||
@@ -60,9 +84,11 @@ Djordjevic
|
|||||||
Dobbie
|
Dobbie
|
||||||
Dockerfile
|
Dockerfile
|
||||||
Donal
|
Donal
|
||||||
|
Donovick
|
||||||
Doorn
|
Doorn
|
||||||
Doxygen
|
Doxygen
|
||||||
Dressler
|
Dressler
|
||||||
|
Dudek
|
||||||
Duraid
|
Duraid
|
||||||
Dutton
|
Dutton
|
||||||
Dzetkulic
|
Dzetkulic
|
||||||
@@ -70,6 +96,7 @@ Eda
|
|||||||
Eddleston
|
Eddleston
|
||||||
Egbert
|
Egbert
|
||||||
Egil
|
Egil
|
||||||
|
Ehab
|
||||||
Eiler
|
Eiler
|
||||||
Eivind
|
Eivind
|
||||||
El
|
El
|
||||||
@@ -79,16 +106,24 @@ Engstrom
|
|||||||
Enzo
|
Enzo
|
||||||
Eugen
|
Eugen
|
||||||
Fabrizio
|
Fabrizio
|
||||||
|
Faucher
|
||||||
|
Faure
|
||||||
Fekete
|
Fekete
|
||||||
Ferrandi
|
Ferrandi
|
||||||
Flachs
|
Flachs
|
||||||
|
Flavien
|
||||||
|
Florian
|
||||||
Foletto
|
Foletto
|
||||||
|
Forencich
|
||||||
Forker
|
Forker
|
||||||
Francillon
|
Francillon
|
||||||
Fredieu
|
Fredieu
|
||||||
|
Freiberger
|
||||||
|
Frédéric
|
||||||
GTKWave
|
GTKWave
|
||||||
Galbi
|
Galbi
|
||||||
Gantt
|
Gantt
|
||||||
|
Garnal
|
||||||
Gartner
|
Gartner
|
||||||
Gelinek
|
Gelinek
|
||||||
Geoff
|
Geoff
|
||||||
@@ -104,15 +139,24 @@ Goessling
|
|||||||
Gonnen
|
Gonnen
|
||||||
Goorah
|
Goorah
|
||||||
Gossner
|
Gossner
|
||||||
|
Graba
|
||||||
|
Graphviz
|
||||||
|
Graybeal
|
||||||
Grobman
|
Grobman
|
||||||
|
Grulfen
|
||||||
|
Gu
|
||||||
Gunter
|
Gunter
|
||||||
Guo
|
Guo
|
||||||
|
Hameed
|
||||||
Hao
|
Hao
|
||||||
|
Haojin
|
||||||
Harboe
|
Harboe
|
||||||
Hashimoto
|
Hashimoto
|
||||||
Hayenga
|
Hayenga
|
||||||
|
Hesselbarth
|
||||||
Hewson
|
Hewson
|
||||||
Hicamp
|
Hicamp
|
||||||
|
Hideto
|
||||||
Hiroki
|
Hiroki
|
||||||
Holdsworth
|
Holdsworth
|
||||||
Holme
|
Holme
|
||||||
@@ -120,21 +164,29 @@ Homebrew
|
|||||||
Hornung
|
Hornung
|
||||||
Hossell
|
Hossell
|
||||||
Hsu
|
Hsu
|
||||||
|
Hutt
|
||||||
Hyperthreading
|
Hyperthreading
|
||||||
|
Ibrahim
|
||||||
|
Ikram
|
||||||
Iles
|
Iles
|
||||||
Inlines
|
Inlines
|
||||||
Inout
|
Inout
|
||||||
Iru
|
Iru
|
||||||
|
Iyer
|
||||||
Iztok
|
Iztok
|
||||||
Jacko
|
Jacko
|
||||||
Jae
|
Jae
|
||||||
Jalloq
|
Jalloq
|
||||||
Jankowski
|
Jankowski
|
||||||
Jannis
|
Jannis
|
||||||
|
Jasen
|
||||||
Jens
|
Jens
|
||||||
Jeras
|
Jeras
|
||||||
|
Jiaxun
|
||||||
Jiuyang
|
Jiuyang
|
||||||
|
Joannou
|
||||||
Joly
|
Joly
|
||||||
|
Josse
|
||||||
Jullien
|
Jullien
|
||||||
Junji
|
Junji
|
||||||
Junyi
|
Junyi
|
||||||
@@ -145,10 +197,13 @@ Kahn
|
|||||||
Kai
|
Kai
|
||||||
Kamendje
|
Kamendje
|
||||||
Kandadi
|
Kandadi
|
||||||
|
Kaneda
|
||||||
Kaplan
|
Kaplan
|
||||||
Karge
|
Karge
|
||||||
|
Karlsson
|
||||||
Katz
|
Katz
|
||||||
Katzman
|
Katzman
|
||||||
|
Kelin
|
||||||
Keren
|
Keren
|
||||||
Keyi
|
Keyi
|
||||||
Kimmitt
|
Kimmitt
|
||||||
@@ -158,9 +213,11 @@ Klnv
|
|||||||
Koenig
|
Koenig
|
||||||
Koh
|
Koh
|
||||||
Kolecki
|
Kolecki
|
||||||
|
Konstantin
|
||||||
Koonce
|
Koonce
|
||||||
Korteland
|
Korteland
|
||||||
Koszek
|
Koszek
|
||||||
|
Kouping
|
||||||
Kravitz
|
Kravitz
|
||||||
Krolnik
|
Krolnik
|
||||||
Kruse
|
Kruse
|
||||||
@@ -168,16 +225,23 @@ Kumashikar
|
|||||||
Kuoping
|
Kuoping
|
||||||
Kurachi
|
Kurachi
|
||||||
Laeufer
|
Laeufer
|
||||||
|
Laroche
|
||||||
Laurens
|
Laurens
|
||||||
Lavino
|
Lavino
|
||||||
Leber
|
Leber
|
||||||
Leendert
|
Leendert
|
||||||
|
Lem
|
||||||
Lesik
|
Lesik
|
||||||
|
Libenzi
|
||||||
|
Licker
|
||||||
Liland
|
Liland
|
||||||
Liu
|
Liu
|
||||||
|
Liwei
|
||||||
Lockhart
|
Lockhart
|
||||||
Longo
|
Longo
|
||||||
|
Luca
|
||||||
Lussier
|
Lussier
|
||||||
|
Lübeck
|
||||||
MMD
|
MMD
|
||||||
MODDUP
|
MODDUP
|
||||||
MTasks
|
MTasks
|
||||||
@@ -187,15 +251,24 @@ Mahesh
|
|||||||
Mahmoudy
|
Mahmoudy
|
||||||
Makefile
|
Makefile
|
||||||
Makefiles
|
Makefiles
|
||||||
|
Maksymenko
|
||||||
|
Markley
|
||||||
|
Marquet
|
||||||
Matveyenko
|
Matveyenko
|
||||||
Maupin
|
Maupin
|
||||||
Mdir
|
Mdir
|
||||||
Mednick
|
Mednick
|
||||||
|
Mei
|
||||||
|
Melo
|
||||||
|
Menküc
|
||||||
|
Michail
|
||||||
Michiels
|
Michiels
|
||||||
Microsystems
|
Microsystems
|
||||||
Milanovic
|
Milanovic
|
||||||
|
Millis
|
||||||
MinW
|
MinW
|
||||||
Mindspeed
|
Mindspeed
|
||||||
|
MingW
|
||||||
Miodrag
|
Miodrag
|
||||||
ModelSim
|
ModelSim
|
||||||
Modport
|
Modport
|
||||||
@@ -204,37 +277,55 @@ Mong
|
|||||||
Muhlestein
|
Muhlestein
|
||||||
Multithreaded
|
Multithreaded
|
||||||
Multithreading
|
Multithreading
|
||||||
|
Mykyta
|
||||||
NOUNOPTFLAT
|
NOUNOPTFLAT
|
||||||
|
NaN
|
||||||
Nalbantis
|
Nalbantis
|
||||||
|
Nandor
|
||||||
Narayan
|
Narayan
|
||||||
|
Nassim
|
||||||
Nauticus
|
Nauticus
|
||||||
Newgard
|
Newgard
|
||||||
|
Nigam
|
||||||
Nikana
|
Nikana
|
||||||
Niranjan
|
Niranjan
|
||||||
Nitza
|
Nitza
|
||||||
Noack
|
Noack
|
||||||
Nodine
|
Nodine
|
||||||
|
Ober
|
||||||
Oleg
|
Oleg
|
||||||
Olof
|
Olof
|
||||||
Olofsson
|
Olofsson
|
||||||
|
Oron
|
||||||
Oyvind
|
Oyvind
|
||||||
PLI
|
PLI
|
||||||
|
Palaniappan
|
||||||
Patricio
|
Patricio
|
||||||
Petr
|
Petr
|
||||||
|
Piard
|
||||||
Piechotka
|
Piechotka
|
||||||
Piersall
|
Piersall
|
||||||
|
Platz
|
||||||
|
Platzer
|
||||||
Plunkett
|
Plunkett
|
||||||
|
Popolon
|
||||||
Popov
|
Popov
|
||||||
Prabhat
|
Prabhat
|
||||||
Prabhu
|
Prabhu
|
||||||
Prateek
|
Prateek
|
||||||
Pre
|
Pre
|
||||||
Preprocess
|
Preprocess
|
||||||
|
Pretet
|
||||||
|
Pretl
|
||||||
|
Pringlemeir
|
||||||
Priyadharshini
|
Priyadharshini
|
||||||
Pullup
|
Pullup
|
||||||
Pulver
|
Pulver
|
||||||
Puri
|
Puri
|
||||||
|
Qin
|
||||||
|
Qiu
|
||||||
Questa
|
Questa
|
||||||
|
Rachit
|
||||||
Ralf
|
Ralf
|
||||||
Rapp
|
Rapp
|
||||||
Redhat
|
Redhat
|
||||||
@@ -242,33 +333,47 @@ Reitan
|
|||||||
Renga
|
Renga
|
||||||
Requin
|
Requin
|
||||||
Rodionov
|
Rodionov
|
||||||
|
Rohan
|
||||||
Rolfe
|
Rolfe
|
||||||
|
Rontionov
|
||||||
Roodselaar
|
Roodselaar
|
||||||
|
Roshit
|
||||||
Runtime
|
Runtime
|
||||||
Ruud
|
Ruud
|
||||||
Rystsov
|
Rystsov
|
||||||
STandarD
|
STandarD
|
||||||
Salman
|
Salman
|
||||||
|
Sammelson
|
||||||
|
Sanggyu
|
||||||
Sanguinetti
|
Sanguinetti
|
||||||
Sanjay
|
Sanjay
|
||||||
|
Sasselli
|
||||||
Scharrer
|
Scharrer
|
||||||
Seitz
|
Seitz
|
||||||
|
Shahid
|
||||||
Shankar
|
Shankar
|
||||||
Shanshan
|
Shanshan
|
||||||
Sharad
|
Sharad
|
||||||
Shareef
|
Shareef
|
||||||
|
Shen
|
||||||
Sheng
|
Sheng
|
||||||
Shi
|
Shi
|
||||||
Shinkarovsky
|
Shinkarovsky
|
||||||
|
Shinya
|
||||||
Shirakawa
|
Shirakawa
|
||||||
Shuba
|
Shuba
|
||||||
|
Shunyao
|
||||||
|
Slager
|
||||||
Slatter
|
Slatter
|
||||||
SoC
|
SoC
|
||||||
Sobhan
|
Sobhan
|
||||||
Sokorac
|
Sokorac
|
||||||
Solaris
|
Solaris
|
||||||
Solomatnikov
|
Solomatnikov
|
||||||
|
Solt
|
||||||
|
Southwell
|
||||||
Srini
|
Srini
|
||||||
|
Srinivasan
|
||||||
Stamness
|
Stamness
|
||||||
Stephane
|
Stephane
|
||||||
Stoddard
|
Stoddard
|
||||||
@@ -278,6 +383,7 @@ Stucki
|
|||||||
Su
|
Su
|
||||||
Suguimoto
|
Suguimoto
|
||||||
Sundararajan
|
Sundararajan
|
||||||
|
Sunderland
|
||||||
Suse
|
Suse
|
||||||
Syms
|
Syms
|
||||||
Synopsys
|
Synopsys
|
||||||
@@ -285,33 +391,45 @@ SystemC
|
|||||||
SystemVerilog
|
SystemVerilog
|
||||||
Takatsukasa
|
Takatsukasa
|
||||||
Tambe
|
Tambe
|
||||||
|
Tarik
|
||||||
Tariq
|
Tariq
|
||||||
|
Tejada
|
||||||
Tengstrand
|
Tengstrand
|
||||||
Terpstra
|
Terpstra
|
||||||
Thiede
|
Thiede
|
||||||
Thierry
|
Thierry
|
||||||
Thyer
|
Thyer
|
||||||
|
Tianrui
|
||||||
Tichelaar
|
Tichelaar
|
||||||
|
Timi
|
||||||
Tomov
|
Tomov
|
||||||
|
Tood
|
||||||
Topa
|
Topa
|
||||||
Tota
|
Tota
|
||||||
|
Trefor
|
||||||
Tresidder
|
Tresidder
|
||||||
Tri
|
Tri
|
||||||
Tristate
|
Tristate
|
||||||
|
Truong
|
||||||
Turton
|
Turton
|
||||||
UNOPTFLAT
|
UNOPTFLAT
|
||||||
Ubixum
|
Ubixum
|
||||||
|
Ueno
|
||||||
Uints
|
Uints
|
||||||
Undefines
|
Undefines
|
||||||
Unsized
|
Unsized
|
||||||
|
Urbach
|
||||||
Uselib
|
Uselib
|
||||||
Usha
|
Usha
|
||||||
Usuario
|
Usuario
|
||||||
VERILATOR
|
VERILATOR
|
||||||
|
Vandergriendt
|
||||||
Vasu
|
Vasu
|
||||||
|
Vdeeptemp
|
||||||
Vdly
|
Vdly
|
||||||
Vemumtab
|
Vemumtab
|
||||||
Vemuri
|
Vemuri
|
||||||
|
Venkataramanan
|
||||||
Veriable
|
Veriable
|
||||||
Verialted
|
Verialted
|
||||||
Verilate
|
Verilate
|
||||||
@@ -320,7 +438,10 @@ Verilating
|
|||||||
Verilation
|
Verilation
|
||||||
Verilator
|
Verilator
|
||||||
Verilog
|
Verilog
|
||||||
|
Vighnesh
|
||||||
Viktor
|
Viktor
|
||||||
|
Vilp
|
||||||
|
Vlip
|
||||||
Vm
|
Vm
|
||||||
Vukobratovic
|
Vukobratovic
|
||||||
Wai
|
Wai
|
||||||
@@ -331,6 +452,7 @@ Wfuture
|
|||||||
Whatson
|
Whatson
|
||||||
Wildman
|
Wildman
|
||||||
Wim
|
Wim
|
||||||
|
Wmisleading
|
||||||
Wno
|
Wno
|
||||||
Wojciech
|
Wojciech
|
||||||
Wolfel
|
Wolfel
|
||||||
@@ -340,27 +462,41 @@ Wwarn
|
|||||||
XSim
|
XSim
|
||||||
Xcelium
|
Xcelium
|
||||||
Xiaoliang
|
Xiaoliang
|
||||||
|
Xiaoyi
|
||||||
Xuan
|
Xuan
|
||||||
Xuanqi
|
Xuanqi
|
||||||
|
Yao
|
||||||
Yazdanbakhsh
|
Yazdanbakhsh
|
||||||
|
Yernagula
|
||||||
Yi
|
Yi
|
||||||
|
Yike
|
||||||
Yinan
|
Yinan
|
||||||
|
Yoshitomo
|
||||||
Yosys
|
Yosys
|
||||||
Yu
|
Yu
|
||||||
|
Yujia
|
||||||
|
Yurii
|
||||||
|
Zaruba
|
||||||
Zhang
|
Zhang
|
||||||
abirkmanis
|
abirkmanis
|
||||||
accessor
|
accessor
|
||||||
accessors
|
accessors
|
||||||
|
adrienlemasle
|
||||||
agrobman
|
agrobman
|
||||||
|
ahouska
|
||||||
al
|
al
|
||||||
ala
|
ala
|
||||||
|
alejandro
|
||||||
|
algrobman
|
||||||
andit
|
andit
|
||||||
ar
|
ar
|
||||||
architected
|
architected
|
||||||
args
|
args
|
||||||
arrarys
|
arrarys
|
||||||
assertOn
|
assertOn
|
||||||
|
astgen
|
||||||
async
|
async
|
||||||
|
atClone
|
||||||
ato
|
ato
|
||||||
atoi
|
atoi
|
||||||
autoconf
|
autoconf
|
||||||
@@ -372,11 +508,16 @@ backtrace
|
|||||||
backtraces
|
backtraces
|
||||||
basename
|
basename
|
||||||
bbox
|
bbox
|
||||||
|
benchmarking
|
||||||
biguint
|
biguint
|
||||||
biops
|
biops
|
||||||
|
bisonpre
|
||||||
|
bitOpTree
|
||||||
|
bitop
|
||||||
bitstoreal
|
bitstoreal
|
||||||
blackbox
|
blackbox
|
||||||
bokke
|
bokke
|
||||||
|
bool
|
||||||
brancoliticus
|
brancoliticus
|
||||||
buf
|
buf
|
||||||
bufif
|
bufif
|
||||||
@@ -384,11 +525,14 @@ buildenv
|
|||||||
bv
|
bv
|
||||||
bvs
|
bvs
|
||||||
callValueCbs
|
callValueCbs
|
||||||
|
callgrind
|
||||||
casex
|
casex
|
||||||
casez
|
casez
|
||||||
casted
|
casted
|
||||||
|
castro
|
||||||
cb
|
cb
|
||||||
ccache
|
ccache
|
||||||
|
ccall
|
||||||
cdc
|
cdc
|
||||||
ceil
|
ceil
|
||||||
celldefine
|
celldefine
|
||||||
@@ -409,13 +553,19 @@ commandArgsPlusMatch
|
|||||||
compilable
|
compilable
|
||||||
concat
|
concat
|
||||||
concats
|
concats
|
||||||
|
conf
|
||||||
config
|
config
|
||||||
const
|
const
|
||||||
|
constexpr
|
||||||
|
constpool
|
||||||
coredump
|
coredump
|
||||||
|
coroutine
|
||||||
|
coroutines
|
||||||
countbits
|
countbits
|
||||||
countones
|
countones
|
||||||
cout
|
cout
|
||||||
cpp
|
cpp
|
||||||
|
cppstyle
|
||||||
cpu
|
cpu
|
||||||
ctor
|
ctor
|
||||||
ctrace
|
ctrace
|
||||||
@@ -423,9 +573,11 @@ cutable
|
|||||||
cygwin
|
cygwin
|
||||||
dM
|
dM
|
||||||
da
|
da
|
||||||
|
danbone
|
||||||
dat
|
dat
|
||||||
datadir
|
datadir
|
||||||
datafiles
|
datafiles
|
||||||
|
david
|
||||||
ddd
|
ddd
|
||||||
deassign
|
deassign
|
||||||
debugi
|
debugi
|
||||||
@@ -433,11 +585,15 @@ defenv
|
|||||||
defname
|
defname
|
||||||
defparam
|
defparam
|
||||||
demangling
|
demangling
|
||||||
|
dep
|
||||||
der
|
der
|
||||||
|
dereference
|
||||||
desassign
|
desassign
|
||||||
destructor
|
destructor
|
||||||
|
desynchronization
|
||||||
detections
|
detections
|
||||||
dev
|
dev
|
||||||
|
devcontainer
|
||||||
devel
|
devel
|
||||||
dir
|
dir
|
||||||
displayb
|
displayb
|
||||||
@@ -446,9 +602,11 @@ doxygen
|
|||||||
dpiGetContext
|
dpiGetContext
|
||||||
dpic
|
dpic
|
||||||
dsvf
|
dsvf
|
||||||
|
dt
|
||||||
dtor
|
dtor
|
||||||
dumpall
|
dumpall
|
||||||
dumpfile
|
dumpfile
|
||||||
|
dumpi
|
||||||
dumplimit
|
dumplimit
|
||||||
dumpoff
|
dumpoff
|
||||||
dumpon
|
dumpon
|
||||||
@@ -461,13 +619,17 @@ dumpportson
|
|||||||
dumpvars
|
dumpvars
|
||||||
dut
|
dut
|
||||||
dx
|
dx
|
||||||
|
dynarray
|
||||||
elab
|
elab
|
||||||
|
eliasphanna
|
||||||
|
elike
|
||||||
elsif
|
elsif
|
||||||
endcase
|
endcase
|
||||||
endcelldefine
|
endcelldefine
|
||||||
endfunction
|
endfunction
|
||||||
endgenerate
|
endgenerate
|
||||||
endian
|
endian
|
||||||
|
endianness
|
||||||
endif
|
endif
|
||||||
endmodule
|
endmodule
|
||||||
endprotect
|
endprotect
|
||||||
@@ -480,15 +642,20 @@ enums
|
|||||||
env
|
env
|
||||||
envvar
|
envvar
|
||||||
eof
|
eof
|
||||||
|
errae
|
||||||
erroring
|
erroring
|
||||||
|
esynr
|
||||||
et
|
et
|
||||||
eval
|
eval
|
||||||
|
evals
|
||||||
exe
|
exe
|
||||||
executables
|
executables
|
||||||
expr
|
expr
|
||||||
extern
|
extern
|
||||||
|
ezchi
|
||||||
fanin
|
fanin
|
||||||
fasttrace
|
fasttrace
|
||||||
|
fauto
|
||||||
fbranch
|
fbranch
|
||||||
fclose
|
fclose
|
||||||
fdisplay
|
fdisplay
|
||||||
@@ -502,11 +669,14 @@ filesystem
|
|||||||
filt
|
filt
|
||||||
flto
|
flto
|
||||||
flushCall
|
flushCall
|
||||||
|
fno
|
||||||
fopen
|
fopen
|
||||||
|
forceable
|
||||||
foreach
|
foreach
|
||||||
fprintf
|
fprintf
|
||||||
fprofile
|
fprofile
|
||||||
fread
|
fread
|
||||||
|
freloop
|
||||||
frewind
|
frewind
|
||||||
fs
|
fs
|
||||||
fscanf
|
fscanf
|
||||||
@@ -521,12 +691,15 @@ funcs
|
|||||||
fwrite
|
fwrite
|
||||||
gantt
|
gantt
|
||||||
gcc
|
gcc
|
||||||
|
gcda
|
||||||
gdb
|
gdb
|
||||||
genblk
|
genblk
|
||||||
genvar
|
genvar
|
||||||
genvars
|
genvars
|
||||||
getenv
|
getenv
|
||||||
getline
|
getline
|
||||||
|
ggdb
|
||||||
|
glibc
|
||||||
gmake
|
gmake
|
||||||
gmon
|
gmon
|
||||||
gotFinish
|
gotFinish
|
||||||
@@ -540,6 +713,7 @@ hierCMakeArgs
|
|||||||
hierMkArgs
|
hierMkArgs
|
||||||
hierVer
|
hierVer
|
||||||
hx
|
hx
|
||||||
|
hyperthreading
|
||||||
hyperthreads
|
hyperthreads
|
||||||
icecream
|
icecream
|
||||||
idmap
|
idmap
|
||||||
@@ -550,8 +724,10 @@ ifndef
|
|||||||
impot
|
impot
|
||||||
incdir
|
incdir
|
||||||
includer
|
includer
|
||||||
|
incrementing
|
||||||
inferfaces
|
inferfaces
|
||||||
inhibitSim
|
inhibitSim
|
||||||
|
initarray
|
||||||
initializer
|
initializer
|
||||||
initializers
|
initializers
|
||||||
inits
|
inits
|
||||||
@@ -562,19 +738,26 @@ inouts
|
|||||||
inserted
|
inserted
|
||||||
instantiation
|
instantiation
|
||||||
instantiations
|
instantiations
|
||||||
|
intra
|
||||||
iostream
|
iostream
|
||||||
ish
|
ish
|
||||||
isunbounded
|
isunbounded
|
||||||
isunknown
|
isunknown
|
||||||
|
jobserver
|
||||||
|
json
|
||||||
|
jwoutersymatra
|
||||||
killua
|
killua
|
||||||
lang
|
lang
|
||||||
lcov
|
lcov
|
||||||
ld
|
ld
|
||||||
|
leavinel
|
||||||
len
|
len
|
||||||
|
libc
|
||||||
libext
|
libext
|
||||||
libgoogle
|
libgoogle
|
||||||
libsystemc
|
libsystemc
|
||||||
libtcmalloc
|
libtcmalloc
|
||||||
|
libverilated
|
||||||
linkers
|
linkers
|
||||||
linter
|
linter
|
||||||
linux
|
linux
|
||||||
@@ -584,10 +767,14 @@ ln
|
|||||||
loc
|
loc
|
||||||
localparam
|
localparam
|
||||||
localparams
|
localparams
|
||||||
|
localtime
|
||||||
logicals
|
logicals
|
||||||
longint
|
longint
|
||||||
|
lossy
|
||||||
lsb
|
lsb
|
||||||
|
lubc
|
||||||
lvalue
|
lvalue
|
||||||
|
lvalues
|
||||||
lxt
|
lxt
|
||||||
macromodule
|
macromodule
|
||||||
makefile
|
makefile
|
||||||
@@ -595,14 +782,17 @@ makefiles
|
|||||||
manpages
|
manpages
|
||||||
metacomment
|
metacomment
|
||||||
metacomments
|
metacomments
|
||||||
|
miree
|
||||||
mis
|
mis
|
||||||
misconnected
|
misconnected
|
||||||
misconversion
|
misconversion
|
||||||
|
misoptimized
|
||||||
missized
|
missized
|
||||||
mk
|
mk
|
||||||
mno
|
mno
|
||||||
modport
|
modport
|
||||||
modports
|
modports
|
||||||
|
mpb
|
||||||
msg
|
msg
|
||||||
msvc
|
msvc
|
||||||
mtask
|
mtask
|
||||||
@@ -610,14 +800,19 @@ mtasks
|
|||||||
mulithreaded
|
mulithreaded
|
||||||
mult
|
mult
|
||||||
multidim
|
multidim
|
||||||
|
multidriven
|
||||||
multiinterfaces
|
multiinterfaces
|
||||||
multiline
|
multiline
|
||||||
multipling
|
multipling
|
||||||
|
multipoint
|
||||||
multithread
|
multithread
|
||||||
multithreaded
|
multithreaded
|
||||||
multithreading
|
multithreading
|
||||||
|
musl
|
||||||
mutexes
|
mutexes
|
||||||
mux
|
mux
|
||||||
|
muzafferkal
|
||||||
|
myftptoyman
|
||||||
mysignal
|
mysignal
|
||||||
namespace
|
namespace
|
||||||
nand
|
nand
|
||||||
@@ -641,16 +836,23 @@ nullptr
|
|||||||
onehot
|
onehot
|
||||||
ooo
|
ooo
|
||||||
oprofile
|
oprofile
|
||||||
|
ortegon
|
||||||
oversubscription
|
oversubscription
|
||||||
|
parallelized
|
||||||
param
|
param
|
||||||
|
parameterization
|
||||||
parameterized
|
parameterized
|
||||||
params
|
params
|
||||||
parens
|
parens
|
||||||
|
pawel
|
||||||
pc
|
pc
|
||||||
pdf
|
pdf
|
||||||
perf
|
perf
|
||||||
perftools
|
perftools
|
||||||
|
pgo
|
||||||
|
phelter
|
||||||
picoChip
|
picoChip
|
||||||
|
pinIndex
|
||||||
pinout
|
pinout
|
||||||
plusargs
|
plusargs
|
||||||
pmos
|
pmos
|
||||||
@@ -660,11 +862,15 @@ portlists
|
|||||||
posedge
|
posedge
|
||||||
posix
|
posix
|
||||||
postfix
|
postfix
|
||||||
|
postincreemnt
|
||||||
|
postincrement
|
||||||
pragma
|
pragma
|
||||||
pragmas
|
pragmas
|
||||||
pre
|
pre
|
||||||
precisions
|
precisions
|
||||||
|
precompiled
|
||||||
predefines
|
predefines
|
||||||
|
prepareClone
|
||||||
prepend
|
prepend
|
||||||
prepended
|
prepended
|
||||||
preprocess
|
preprocess
|
||||||
@@ -676,17 +882,24 @@ prev
|
|||||||
printf
|
printf
|
||||||
printtimescale
|
printtimescale
|
||||||
profcfunc
|
profcfunc
|
||||||
|
profiler
|
||||||
prototyptes
|
prototyptes
|
||||||
ps
|
ps
|
||||||
pthread
|
pthread
|
||||||
|
ptr
|
||||||
pulldown
|
pulldown
|
||||||
pulldowns
|
pulldowns
|
||||||
pullup
|
pullup
|
||||||
pvalue
|
pvalue
|
||||||
pwd
|
pwd
|
||||||
|
py
|
||||||
qrq
|
qrq
|
||||||
|
qrqiuren
|
||||||
radix
|
radix
|
||||||
randc
|
randc
|
||||||
|
randcase
|
||||||
|
randstate
|
||||||
|
raphmaster
|
||||||
rarr
|
rarr
|
||||||
rdtsc
|
rdtsc
|
||||||
reStructuredText
|
reStructuredText
|
||||||
@@ -696,26 +909,33 @@ readmemb
|
|||||||
readmemh
|
readmemh
|
||||||
realpath
|
realpath
|
||||||
realtime
|
realtime
|
||||||
|
realtobits
|
||||||
recoding
|
recoding
|
||||||
recrem
|
recrem
|
||||||
redeclaring
|
redeclaring
|
||||||
regs
|
regs
|
||||||
reloop
|
reloop
|
||||||
|
replaceShiftOp
|
||||||
resetall
|
resetall
|
||||||
respecified
|
respecified
|
||||||
|
rodata
|
||||||
|
rolloverSize
|
||||||
rr
|
rr
|
||||||
rst
|
rst
|
||||||
runtime
|
runtime
|
||||||
runtimes
|
runtimes
|
||||||
rw
|
rw
|
||||||
sVerilator
|
sVerilator
|
||||||
|
sawatzke
|
||||||
sc
|
sc
|
||||||
scalared
|
scalared
|
||||||
|
sccache
|
||||||
sccanf
|
sccanf
|
||||||
seg
|
seg
|
||||||
setuphold
|
setuphold
|
||||||
sformat
|
sformat
|
||||||
sformatf
|
sformatf
|
||||||
|
shareefj
|
||||||
shortint
|
shortint
|
||||||
shortreal
|
shortreal
|
||||||
signame
|
signame
|
||||||
@@ -724,6 +944,8 @@ specparam
|
|||||||
splitme
|
splitme
|
||||||
spp
|
spp
|
||||||
sqrt
|
sqrt
|
||||||
|
srandom
|
||||||
|
src
|
||||||
srcdir
|
srcdir
|
||||||
srcfile
|
srcfile
|
||||||
sscanf
|
sscanf
|
||||||
@@ -732,6 +954,7 @@ stdin
|
|||||||
stdout
|
stdout
|
||||||
stime
|
stime
|
||||||
stmts
|
stmts
|
||||||
|
str
|
||||||
strcasecmp
|
strcasecmp
|
||||||
stringification
|
stringification
|
||||||
stringified
|
stringified
|
||||||
@@ -741,17 +964,23 @@ structs
|
|||||||
subcell
|
subcell
|
||||||
subcells
|
subcells
|
||||||
subexpressions
|
subexpressions
|
||||||
|
submakes
|
||||||
submodule
|
submodule
|
||||||
submodules
|
submodules
|
||||||
|
substring
|
||||||
sv
|
sv
|
||||||
svBitVal
|
svBitVal
|
||||||
svBitVecVal
|
svBitVecVal
|
||||||
svGet
|
svGet
|
||||||
|
svGetTime
|
||||||
|
svGetTimePrecision
|
||||||
svLogicVal
|
svLogicVal
|
||||||
svdpi
|
svdpi
|
||||||
|
svgGetTimeUnit
|
||||||
swrite
|
swrite
|
||||||
sys
|
sys
|
||||||
systemc
|
systemc
|
||||||
|
tenghtt
|
||||||
testbench
|
testbench
|
||||||
threadsafe
|
threadsafe
|
||||||
threashold
|
threashold
|
||||||
@@ -777,19 +1006,23 @@ trunc
|
|||||||
txt
|
txt
|
||||||
typ
|
typ
|
||||||
typedef
|
typedef
|
||||||
|
typedef'ed
|
||||||
typedefed
|
typedefed
|
||||||
typedefs
|
typedefs
|
||||||
typename
|
typename
|
||||||
uint
|
uint
|
||||||
un
|
un
|
||||||
|
unbased
|
||||||
undef
|
undef
|
||||||
undefineall
|
undefineall
|
||||||
undriven
|
undriven
|
||||||
ungetc
|
ungetc
|
||||||
|
unhandled
|
||||||
uniquified
|
uniquified
|
||||||
unistd
|
unistd
|
||||||
unlink
|
unlink
|
||||||
unlinked
|
unlinked
|
||||||
|
unnamedblk
|
||||||
unopt
|
unopt
|
||||||
unoptflat
|
unoptflat
|
||||||
unoptimizable
|
unoptimizable
|
||||||
@@ -799,13 +1032,17 @@ unsup
|
|||||||
untyped
|
untyped
|
||||||
urandom
|
urandom
|
||||||
uselib
|
uselib
|
||||||
|
utimes
|
||||||
uwire
|
uwire
|
||||||
uwires
|
uwires
|
||||||
|
valgrind
|
||||||
vc
|
vc
|
||||||
vcd
|
vcd
|
||||||
vcddiff
|
vcddiff
|
||||||
vcoverage
|
vcoverage
|
||||||
|
vdhotre
|
||||||
vec
|
vec
|
||||||
|
ventana
|
||||||
ver
|
ver
|
||||||
verFiles
|
verFiles
|
||||||
verible
|
verible
|
||||||
@@ -821,12 +1058,16 @@ vlt
|
|||||||
vltstd
|
vltstd
|
||||||
vluint
|
vluint
|
||||||
vpi
|
vpi
|
||||||
|
vpiConstType
|
||||||
|
vpiDefName
|
||||||
|
vpiInstance
|
||||||
vpiLeftRange
|
vpiLeftRange
|
||||||
vpiModule
|
vpiModule
|
||||||
vpiSize
|
vpiSize
|
||||||
vpiSuppressVal
|
vpiSuppressVal
|
||||||
vpiTimeUnit
|
vpiTimeUnit
|
||||||
vpiType
|
vpiType
|
||||||
|
vpiUndefined
|
||||||
vpm
|
vpm
|
||||||
vpp
|
vpp
|
||||||
warmup
|
warmup
|
||||||
@@ -839,11 +1080,16 @@ writeme
|
|||||||
writemem
|
writemem
|
||||||
writememb
|
writememb
|
||||||
writememh
|
writememh
|
||||||
|
xiak
|
||||||
xin
|
xin
|
||||||
xml
|
xml
|
||||||
xnor
|
xnor
|
||||||
xout
|
xout
|
||||||
xuejiazidi
|
xuejiazidi
|
||||||
yanx
|
yanx
|
||||||
|
ypq
|
||||||
yurivict
|
yurivict
|
||||||
zdave
|
zdave
|
||||||
|
Øyvind
|
||||||
|
Алексеевич
|
||||||
|
Исаак
|
||||||
|
|||||||
+1
-2
@@ -1,4 +1,4 @@
|
|||||||
PROJECT_NAME = "Verilog to Routing - ABC"
|
PROJECT_NAME = "Verilator"
|
||||||
INPUT = ../../include
|
INPUT = ../../include
|
||||||
OUTPUT_DIRECTORY = _build/doxygen/verilated
|
OUTPUT_DIRECTORY = _build/doxygen/verilated
|
||||||
|
|
||||||
@@ -37,5 +37,4 @@ PREDEFINED = \
|
|||||||
"VL_NOT_FINAL=" \
|
"VL_NOT_FINAL=" \
|
||||||
"VL_PURE=" \
|
"VL_PURE=" \
|
||||||
"VL_REQUIRES()=" \
|
"VL_REQUIRES()=" \
|
||||||
"VL_THREAD_LOCAL=" \
|
|
||||||
"__restrict=" \
|
"__restrict=" \
|
||||||
|
|||||||
+3
-4
@@ -46,9 +46,6 @@ The XML document consists of 4 sections within the top level
|
|||||||
hierarchy. Each instance is represented with the ``<cell>`` element
|
hierarchy. Each instance is represented with the ``<cell>`` element
|
||||||
with the following attributes:
|
with the following attributes:
|
||||||
|
|
||||||
- ``fl`` (deprecated): The file id and line number where the module
|
|
||||||
was instanced. Use ``loc`` instead.
|
|
||||||
|
|
||||||
- ``loc``: The file id, first line number, last line number, first
|
- ``loc``: The file id, first line number, last line number, first
|
||||||
column number and last column number of the identifier where the
|
column number and last column number of the identifier where the
|
||||||
module was instanced, separated by commas.
|
module was instanced, separated by commas.
|
||||||
@@ -73,8 +70,10 @@ The XML document consists of 4 sections within the top level
|
|||||||
Distribution
|
Distribution
|
||||||
============
|
============
|
||||||
|
|
||||||
Copyright 2020-2021 by Wilson Snyder. Verilator is free software; you can
|
Copyright 2020-2024 by Wilson Snyder. Verilator is free software; you can
|
||||||
redistribute it and/or modify it under the terms of either the GNU Lesser
|
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.
|
General Public License Version 3 or the Perl Artistic License Version 2.0.
|
||||||
|
|
||||||
|
SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||||
|
|
||||||
.. |Logo| image:: https://www.veripool.org/img/verilator_256_200_min.png
|
.. |Logo| image:: https://www.veripool.org/img/verilator_256_200_min.png
|
||||||
|
|||||||
@@ -19,7 +19,8 @@
|
|||||||
# cmake ..
|
# cmake ..
|
||||||
# cmake --build .
|
# cmake --build .
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.8)
|
cmake_minimum_required(VERSION 3.12)
|
||||||
|
cmake_policy(SET CMP0074 NEW)
|
||||||
project(cmake_hello_c)
|
project(cmake_hello_c)
|
||||||
|
|
||||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||||
@@ -29,6 +30,7 @@ endif()
|
|||||||
|
|
||||||
# Create a new executable target that will contain all your sources
|
# Create a new executable target that will contain all your sources
|
||||||
add_executable(example ../make_hello_c/sim_main.cpp)
|
add_executable(example ../make_hello_c/sim_main.cpp)
|
||||||
|
target_compile_features(example PUBLIC cxx_std_14)
|
||||||
|
|
||||||
# Add the Verilated circuit to the target
|
# Add the Verilated circuit to the target
|
||||||
verilate(example
|
verilate(example
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ endif
|
|||||||
ifeq ($(shell which cmake),)
|
ifeq ($(shell which cmake),)
|
||||||
TARGET := nocmake
|
TARGET := nocmake
|
||||||
else
|
else
|
||||||
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
|
CMAKE_VERSION := $(shell cmake --version | grep -o '[0-9][.0-9]\+')
|
||||||
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
||||||
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
||||||
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
||||||
|
|||||||
@@ -19,7 +19,8 @@
|
|||||||
# cmake ..
|
# cmake ..
|
||||||
# cmake --build .
|
# cmake --build .
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.8)
|
cmake_minimum_required(VERSION 3.12)
|
||||||
|
cmake_policy(SET CMP0074 NEW)
|
||||||
project(cmake_hello_sc CXX)
|
project(cmake_hello_sc CXX)
|
||||||
|
|
||||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||||
@@ -36,6 +37,7 @@ find_package(SystemCLanguage QUIET)
|
|||||||
|
|
||||||
# Create a new executable target that will contain all your sources
|
# Create a new executable target that will contain all your sources
|
||||||
add_executable(example ../make_hello_sc/sc_main.cpp)
|
add_executable(example ../make_hello_sc/sc_main.cpp)
|
||||||
|
target_compile_features(example PUBLIC cxx_std_14)
|
||||||
|
|
||||||
set_property(
|
set_property(
|
||||||
TARGET example
|
TARGET example
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ endif
|
|||||||
ifeq ($(shell which cmake),)
|
ifeq ($(shell which cmake),)
|
||||||
TARGET := nocmake
|
TARGET := nocmake
|
||||||
else
|
else
|
||||||
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
|
CMAKE_VERSION := $(shell cmake --version | grep -o '[0-9][.0-9]\+')
|
||||||
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
||||||
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
||||||
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
||||||
@@ -39,30 +39,12 @@ ifneq ($(CMAKE_GT_3_8),true)
|
|||||||
TARGET := oldcmake
|
TARGET := oldcmake
|
||||||
else
|
else
|
||||||
|
|
||||||
# Test existence of SYSTEMC_INCLUDE and SYSTEMC_LIBDIR environment variabless
|
# Check if SC exists via a verilator call (empty if not)
|
||||||
ifneq (,$(SYSTEMC_INCLUDE))
|
SYSTEMC_EXISTS := $(shell $(VERILATOR) --get-supported SYSTEMC)
|
||||||
ifneq (,${SYSTEMC_LIBDIR})
|
|
||||||
SYSTEMC_SET := true
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Test existence of SYSTEMC_ROOT environment variable
|
|
||||||
ifneq (SYSTEMC_SET, true)
|
|
||||||
ifneq (,${SYSTEMC_ROOT})
|
|
||||||
SYSTEMC_SET := true
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Test existence of SYSTEMC environment variable
|
|
||||||
ifneq (SYSTEMC_SET, true)
|
|
||||||
ifneq (,${SYSTEMC})
|
|
||||||
SYSTEMC_SET := true
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Test whether SystemC is installed with CMake support
|
# Test whether SystemC is installed with CMake support
|
||||||
# This will print a CMake error about processing arguments that can (currently) be ignored.
|
# This will print a CMake error about processing arguments that can (currently) be ignored.
|
||||||
ifneq (SYSTEMC_SET, true)
|
ifneq (,$(SYSTEMC_EXISTS))
|
||||||
FINDSC := $(shell mkdir -p build && cd build && cmake --find-package -DNAME=SystemCLanguage -DCMAKE_USE_PTHREADS_INIT=ON -DCOMPILER_ID=GNU -DLANGUAGE=CXX -DMODE=EXIST -DThreads_FOUND=ON)
|
FINDSC := $(shell mkdir -p build && cd build && cmake --find-package -DNAME=SystemCLanguage -DCMAKE_USE_PTHREADS_INIT=ON -DCOMPILER_ID=GNU -DLANGUAGE=CXX -DMODE=EXIST -DThreads_FOUND=ON)
|
||||||
ifneq (,$(findstring SystemCLanguage found,$(FINDSC)))
|
ifneq (,$(findstring SystemCLanguage found,$(FINDSC)))
|
||||||
SYSTEMC_SET := true
|
SYSTEMC_SET := true
|
||||||
|
|||||||
@@ -19,7 +19,8 @@
|
|||||||
# cmake ..
|
# cmake ..
|
||||||
# cmake --build .
|
# cmake --build .
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.8)
|
cmake_minimum_required(VERSION 3.12)
|
||||||
|
cmake_policy(SET CMP0074 NEW)
|
||||||
project(cmake_protect_lib)
|
project(cmake_protect_lib)
|
||||||
|
|
||||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||||
@@ -29,9 +30,12 @@ endif()
|
|||||||
|
|
||||||
# Create the main executable target
|
# Create the main executable target
|
||||||
add_executable(example ../make_protect_lib/sim_main.cpp)
|
add_executable(example ../make_protect_lib/sim_main.cpp)
|
||||||
|
target_compile_features(example PUBLIC cxx_std_14)
|
||||||
|
|
||||||
# Create a secret library
|
# Create a secret library
|
||||||
add_library(verilated_secret STATIC) # or SHARED for a shared library
|
add_library(verilated_secret STATIC) # or SHARED for a shared library
|
||||||
|
target_compile_features(verilated_secret PUBLIC cxx_std_14)
|
||||||
|
|
||||||
target_link_libraries(example PRIVATE verilated_secret)
|
target_link_libraries(example PRIVATE verilated_secret)
|
||||||
# To create both libraries on CMake >= 3.12 replace the above 2 lines with the following:
|
# To create both libraries on CMake >= 3.12 replace the above 2 lines with the following:
|
||||||
# add_library(verilated_secret OBJECT)
|
# add_library(verilated_secret OBJECT)
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ endif
|
|||||||
ifeq ($(shell which cmake),)
|
ifeq ($(shell which cmake),)
|
||||||
TARGET := nocmake
|
TARGET := nocmake
|
||||||
else
|
else
|
||||||
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
|
CMAKE_VERSION := $(shell cmake --version | grep -o '[0-9][.0-9]\+')
|
||||||
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
||||||
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
||||||
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
||||||
|
|||||||
@@ -19,7 +19,8 @@
|
|||||||
# cmake ..
|
# cmake ..
|
||||||
# cmake --build .
|
# cmake --build .
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.8)
|
cmake_minimum_required(VERSION 3.12)
|
||||||
|
cmake_policy(SET CMP0074 NEW)
|
||||||
project(cmake_tracing_c)
|
project(cmake_tracing_c)
|
||||||
|
|
||||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||||
@@ -29,9 +30,10 @@ endif()
|
|||||||
|
|
||||||
# Create a new executable target that will contain all your sources
|
# Create a new executable target that will contain all your sources
|
||||||
add_executable(example ../make_tracing_c/sim_main.cpp)
|
add_executable(example ../make_tracing_c/sim_main.cpp)
|
||||||
|
target_compile_features(example PUBLIC cxx_std_14)
|
||||||
|
|
||||||
# Add the Verilated circuit to the target
|
# Add the Verilated circuit to the target
|
||||||
verilate(example COVERAGE TRACE
|
verilate(example COVERAGE TRACE
|
||||||
INCLUDE_DIRS "../make_tracing_c"
|
INCLUDE_DIRS "../make_tracing_c"
|
||||||
VERILATOR_ARGS -f ../make_tracing_c/input.vc -Os -x-assign 0
|
VERILATOR_ARGS -f ../make_tracing_c/input.vc -x-assign fast
|
||||||
SOURCES ../make_tracing_c/top.v)
|
SOURCES ../make_tracing_c/top.v)
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ endif
|
|||||||
ifeq ($(shell which cmake),)
|
ifeq ($(shell which cmake),)
|
||||||
TARGET := nocmake
|
TARGET := nocmake
|
||||||
else
|
else
|
||||||
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
|
CMAKE_VERSION := $(shell cmake --version | grep -o '[0-9][.0-9]\+')
|
||||||
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
||||||
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
||||||
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
||||||
|
|||||||
@@ -19,7 +19,9 @@
|
|||||||
# cmake ..
|
# cmake ..
|
||||||
# cmake --build .
|
# cmake --build .
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.8)
|
cmake_minimum_required(VERSION 3.12)
|
||||||
|
cmake_policy(SET CMP0074 NEW)
|
||||||
|
|
||||||
project(cmake_tracing_sc_example CXX)
|
project(cmake_tracing_sc_example CXX)
|
||||||
|
|
||||||
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
|
||||||
@@ -36,6 +38,7 @@ find_package(SystemCLanguage QUIET)
|
|||||||
|
|
||||||
# Create a new executable target that will contain all your sources
|
# Create a new executable target that will contain all your sources
|
||||||
add_executable(example ../make_tracing_sc/sc_main.cpp)
|
add_executable(example ../make_tracing_sc/sc_main.cpp)
|
||||||
|
target_compile_features(example PUBLIC cxx_std_14)
|
||||||
|
|
||||||
set_property(
|
set_property(
|
||||||
TARGET example
|
TARGET example
|
||||||
@@ -45,7 +48,7 @@ set_property(
|
|||||||
# Add the Verilated circuit to the target
|
# Add the Verilated circuit to the target
|
||||||
verilate(example SYSTEMC COVERAGE TRACE
|
verilate(example SYSTEMC COVERAGE TRACE
|
||||||
INCLUDE_DIRS "../make_tracing_sc"
|
INCLUDE_DIRS "../make_tracing_sc"
|
||||||
VERILATOR_ARGS -f ../make_tracing_sc/input.vc -Os -x-assign 0
|
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)
|
verilator_link_systemc(example)
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ endif
|
|||||||
ifeq ($(shell which cmake),)
|
ifeq ($(shell which cmake),)
|
||||||
TARGET := nocmake
|
TARGET := nocmake
|
||||||
else
|
else
|
||||||
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
|
CMAKE_VERSION := $(shell cmake --version | grep -o '[0-9][.0-9]\+')
|
||||||
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -d.)
|
||||||
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
CMAKE_MINOR := $(shell echo $(CMAKE_VERSION) | cut -f2 -d.)
|
||||||
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
CMAKE_GT_3_8 := $(shell [ $(CMAKE_MAJOR) -gt 3 -o \( $(CMAKE_MAJOR) -eq 3 -a $(CMAKE_MINOR) -ge 8 \) ] && echo true)
|
||||||
@@ -39,30 +39,12 @@ ifneq ($(CMAKE_GT_3_8),true)
|
|||||||
TARGET := oldcmake
|
TARGET := oldcmake
|
||||||
else
|
else
|
||||||
|
|
||||||
# Test existence of SYSTEMC_INCLUDE and SYSTEMC_LIBDIR environment variabless
|
# Check if SC exists via a verilator call (empty if not)
|
||||||
ifneq (,$(SYSTEMC_INCLUDE))
|
SYSTEMC_EXISTS := $(shell $(VERILATOR) --get-supported SYSTEMC)
|
||||||
ifneq (,${SYSTEMC_LIBDIR})
|
|
||||||
SYSTEMC_SET := true
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Test existence of SYSTEMC_ROOT environment variable
|
|
||||||
ifneq (SYSTEMC_SET, true)
|
|
||||||
ifneq (,${SYSTEMC_ROOT})
|
|
||||||
SYSTEMC_SET := true
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Test existence of SYSTEMC environment variable
|
|
||||||
ifneq (SYSTEMC_SET, true)
|
|
||||||
ifneq (,${SYSTEMC})
|
|
||||||
SYSTEMC_SET := true
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Test whether SystemC is installed with CMake support
|
# Test whether SystemC is installed with CMake support
|
||||||
# This will print a CMake error about processing arguments that can (currently) be ignored.
|
# This will print a CMake error about processing arguments that can (currently) be ignored.
|
||||||
ifneq (SYSTEMC_SET, true)
|
ifneq (,$(SYSTEMC_EXISTS))
|
||||||
FINDSC := $(shell mkdir -p build && cd build && cmake --find-package -DNAME=SystemCLanguage -DCMAKE_USE_PTHREADS_INIT=ON -DCOMPILER_ID=GNU -DLANGUAGE=CXX -DMODE=EXIST -DThreads_FOUND=ON)
|
FINDSC := $(shell mkdir -p build && cd build && cmake --find-package -DNAME=SystemCLanguage -DCMAKE_USE_PTHREADS_INIT=ON -DCOMPILER_ID=GNU -DLANGUAGE=CXX -DMODE=EXIST -DThreads_FOUND=ON)
|
||||||
ifneq (,$(findstring SystemCLanguage found,$(FINDSC)))
|
ifneq (,$(findstring SystemCLanguage found,$(FINDSC)))
|
||||||
SYSTEMC_SET := true
|
SYSTEMC_SET := true
|
||||||
|
|||||||
@@ -1,54 +1,54 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# -*- Python -*- See copyright, etc below
|
# -*- Python -*- See copyright, etc below
|
||||||
# pylint: disable=C0114,C0115,R0903
|
# pylint: disable=C0103,C0114,C0115,C0209,R0903
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
|
import json
|
||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
import subprocess
|
import subprocess
|
||||||
import tempfile
|
|
||||||
import xml.etree.ElementTree as ET
|
|
||||||
from shutil import copy2
|
from shutil import copy2
|
||||||
|
from tempfile import NamedTemporaryFile
|
||||||
# from pprint import pprint, pformat
|
# from pprint import pprint, pformat
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
|
|
||||||
|
|
||||||
class VlFileCopy:
|
class VlFileCopy:
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
self,
|
self,
|
||||||
verilator_args, # presently all verilator options are passed-thru
|
verilator_args, # presently all verilator options are passed-thru
|
||||||
# ideally this script would check against options mentioned in help
|
debug=0,
|
||||||
debug=0,
|
output_dir='copied'): # directory name we output file uses
|
||||||
output_dir='copied'): # directory name we output file uses
|
|
||||||
|
|
||||||
self.debug = debug
|
self.debug = debug
|
||||||
|
|
||||||
xml_temp = tempfile.NamedTemporaryFile()
|
with NamedTemporaryFile() as tree_temp, NamedTemporaryFile(
|
||||||
|
) as meta_temp:
|
||||||
vargs = [
|
vargs = [
|
||||||
'--xml-output',
|
'--json-only-output',
|
||||||
xml_temp.name,
|
tree_temp.name,
|
||||||
'--bbox-sys', # Parse some stuff can't translate
|
'--json-only-meta-output',
|
||||||
'--bbox-unsup',
|
meta_temp.name,
|
||||||
'--prefix vlxml'
|
'--bbox-sys', # Parse some stuff can't translate
|
||||||
] # So we know name of .xml output
|
'--bbox-unsup',
|
||||||
vargs += verilator_args
|
'--prefix vljson'
|
||||||
self.run_verilator(vargs)
|
]
|
||||||
self.tree = ET.parse(xml_temp.name)
|
vargs += verilator_args
|
||||||
|
self.run_verilator(vargs)
|
||||||
|
self.tree = json.load(tree_temp)
|
||||||
|
self.meta = json.load(meta_temp)
|
||||||
|
|
||||||
os.makedirs(output_dir, 0o777, True)
|
os.makedirs(output_dir, 0o777, True)
|
||||||
|
|
||||||
# Find and copy the files
|
for file_id in self.meta['files']:
|
||||||
root = self.tree.getroot()
|
path = self.meta['files'][file_id]['realpath']
|
||||||
xfiles = root.find('files')
|
if not re.match('^<', path): # e.g. <built-in>
|
||||||
for xfile in xfiles.findall('file'):
|
|
||||||
filename = xfile.get('filename')
|
|
||||||
if not re.match('^<', filename): # e.g. <built-in>
|
|
||||||
if self.debug:
|
if self.debug:
|
||||||
print("\tcp %s %s" % (filename, output_dir))
|
print("\tcp %s %s" % (path, output_dir))
|
||||||
copy2(filename, output_dir)
|
copy2(path, output_dir)
|
||||||
|
|
||||||
def run_verilator(self, vargs):
|
def run_verilator(self, vargs):
|
||||||
"""Run Verilator command, check errors"""
|
"""Run Verilator command, check errors"""
|
||||||
@@ -61,8 +61,8 @@ class VlFileCopy:
|
|||||||
print("\t%s " % command)
|
print("\t%s " % command)
|
||||||
status = subprocess.call(command, shell=True)
|
status = subprocess.call(command, shell=True)
|
||||||
if status != 0:
|
if status != 0:
|
||||||
raise Exception("Command failed running Verilator with '" +
|
raise RuntimeError("Command failed running Verilator with '" +
|
||||||
command + "', stopped")
|
command + "', stopped")
|
||||||
|
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
@@ -72,7 +72,7 @@ if __name__ == '__main__':
|
|||||||
allow_abbrev=False,
|
allow_abbrev=False,
|
||||||
formatter_class=argparse.RawTextHelpFormatter,
|
formatter_class=argparse.RawTextHelpFormatter,
|
||||||
description=
|
description=
|
||||||
"""Example of using Verilator XML output to copy a list of files to an
|
"""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
|
output directory (-odir, defaults to 'copied'), e.g. to easily create a
|
||||||
tarball of the design to pass to others.
|
tarball of the design to pass to others.
|
||||||
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user