Compare commits

...
3256 Commits
Author SHA1 Message Date
Wilson Snyder 04c0fc8aa7 Version bump 2020-06-06 07:48:47 -04:00
Wilson Snyder 1d8955fea5 Internal: Update fastcov.py from upstream. 2020-06-06 05:48:36 -04:00
Wilson Snyder 48740a0dba Tests: Add t_param_type 2020-06-05 22:22:44 -04:00
Geza Lore 4a404bd92e Always mask LSB in V3Merge Cond when mergin AstAnd 2020-06-06 00:17:59 +01:00
Wilson Snyder ff41701ddc Fix crash on undeclared packages. 2020-06-05 18:50:06 -04:00
Wilson Snyder 2590c9c4a6 Internal: Update fastcov.py from upstream. 2020-06-05 18:05:49 -04:00
Wilson Snyder c5d61da5d2 Internal coverage: Fix coverage of tests that abort. No functional change intended. 2020-06-05 08:00:22 -04:00
Wilson Snyder 5a622fd9db Tests: Temporary fix for (#2407) 2020-06-05 07:28:51 -04:00
Wilson Snyder c83b1478e1 Internals: Ifdef out V3Combine incomplete dead code. 2020-06-04 21:55:00 -04:00
Wilson Snyder 3243651c63 Internals: Fix misc internal coverage holes. No functional change intended. 2020-06-04 21:40:40 -04:00
Wilson Snyder 8d61cd9029 New fastcov internal coverage scheme 2020-06-04 20:59:52 -04:00
Wilson Snyder 7fe49de420 Tests: Tests to fix misc internal coverage holes. 2020-06-04 20:23:55 -04:00
Wilson Snyder a433096d5a Internals: Fix misc internal coverage holes. No functional change intended. 2020-06-04 19:49:39 -04:00
Geza Lore b88e1e6970 Travis: Fix cron (always build focal) 2020-06-04 17:36:53 +01:00
Wilson Snyder 79f228b04f Remove dead code (bisonreader) 2020-06-03 20:11:09 -04:00
Wilson Snyder d7cc1e6844 Tests: Use lint in many negative tests to avoid running under both vlt and vltmt 2020-06-03 20:05:13 -04:00
Wilson Snyder 42312101b5 Tests: Add array OOB tests as unsupported (#792) 2020-06-03 19:36:50 -04:00
Wilson Snyder 329f5b712a Tests: Add alias tests as unsupported (#697) 2020-06-03 19:27:22 -04:00
Geza Lore 6ddd92c0a1 Travis: Use workspaces and per job persistent ccache (#2399)
Change the Travis builds to use workspaces and persistent ccache

We proceed in 2 stages (as before, but using workspaces for
persistence):
1. In the 'build' stage, we clone the repo, build it and
   save the whole checkout ($TRAVIS_BUILD_DIR) as a workspace
2. In the 'test' stage, rather than cloning the repo, multiple jobs
   pull down the same workspace we built to run the tests from

This enables:
- Reuse of the build in multiple test jobs (this is what we used the Travis
  cache for before)
- Each job having a separate persistent Travis cache, which now only
  contains the ccache. This means all jobs, including 'build' and 'test'
  jobs can make maximum use of ccache across runs. This drastically cuts
  down build times when the ccache hits, which is very often the case for
  'test' jobs. Also, the separate caches only store the objects build by
  the particular job that owns the cache, so we can keep the per job
  ccache small.

If the commit message contains '[travis ccache clear]', the ccache will
be cleared at the beginning of the build. This can be used to test build
complete within the 50 minute timeout imposed by Travis, even without a
persistent ccache.
2020-06-03 21:10:13 +01:00
Tomasz Gorochowik 277dee109c Fix Ariane issues with PostAdd nodes (#2400) 2020-06-03 12:50:24 -04:00
Wilson Snyder ef71576825 Fix coredump from increment patch (#2391) 2020-06-03 08:30:49 -04:00
Wilson Snyder c3271aa891 Fix duplicate VLCOVGEN short code 2020-06-02 21:42:24 -04:00
Geza Lore 1cf17b5e78 Fix unused variable. 2020-06-02 22:45:55 +01:00
Ludwig Rogiers 2b6353b36e Support vpi_handle type vpiLeftRange and vpiRightRange for vpiRange objects (#2395)
* Implement vpi_handle type vpiLeftRange and vpiRightRange for vpiRange objects

* Change VerilatedVpioConst type to vpiConstant
2020-06-02 08:04:22 -04:00
Wilson Snyder 8b647f0977 Fix error on UNPACKED in parser. (#1541) 2020-06-02 08:00:37 -04:00
Wilson Snyder 4c31c5fab5 Fix unused variable. 2020-06-02 07:52:27 -04:00
Wilson Snyder 6ce878cb0d Fix some clang-tidy warnings 2020-06-01 23:16:17 -04:00
Geza Lore a67ba04c37 Remove dead code and some unused parameters
Found with CLion inspections
2020-06-01 17:49:42 +01:00
Wilson Snyder ae448e5ef9 Fix older GCC compiler error. 2020-06-01 09:08:50 -04:00
Wilson Snyder a57826b125 Line Coverage now tracks all statement lines, not just branch lines. 2020-05-31 15:52:17 -04:00
Geza Lore 656c460605 Add --dump-tree-addrids developer option 2020-05-31 20:21:55 +01:00
Geza Lore 95534fa5c5 Remove unused headers (#2389) 2020-05-31 20:21:07 +01:00
Wilson Snyder 611e8b10c6 Fix Verilog coverage to pass real column information 2020-05-31 09:05:10 -04:00
Michael Killough 047852eb08 Fix OpenBSD make in tests. (#2388) 2020-05-31 09:03:51 -04:00
Geza Lore 6318a08056 Fix --dump-tree with sparse dumps.
"No changes since last dump!" is now only printed if the "last" dump was
actually performed and not skipped due to V3Option::dumpTreeLevel
settings.
2020-05-31 13:48:30 +01:00
Wilson Snyder b60a92eed3 Fix pre-C11 compiler warning. 2020-05-30 21:11:37 -04:00
Geza Lore fe306a36b8 Add MergeCond pass to combine assignments with ?: on rhs (#2376)
This provides minor simulation performance benefit, but can provide
large C++ compilation time improvement, notably with Clang (4x).

This patch implements #2366 .
2020-05-30 21:09:05 +01:00
Geza Lore 18870f8b62 Remove remnants of long removed --trace-dups option
See #2385
2020-05-30 20:16:40 +01:00
Geza Lore 9712ceedd7 Internals: Remove empty statements. No functional change intended.
Remove stray semicolons, mostly by capturing them in macros accurately.
This removes a ton on lint warnings from CLion.
2020-05-30 19:13:18 +01:00
Wilson Snyder 2e32387e5c Fix GCC false warning on array bounds. (#2386) 2020-05-30 13:47:53 -04:00
Wilson Snyder b66877c9df Internals: Refactor V3Expand newWordSel. No functional change intended. 2020-05-30 13:47:53 -04:00
Geza Lore 74a6f94e2b Internals: Remove dead code 2020-05-30 17:20:23 +01:00
Wilson Snyder 35fc8b7259 Debug: Show column numbers in .tree files 2020-05-30 10:08:30 -04:00
Wilson Snyder e591afd101 Disable over-sensitive debug dump. 2020-05-30 09:35:48 -04:00
Wilson Snyder a41cdf4cfb Tests: Add driver_verilator_flags (for verilator_ext_tests) 2020-05-30 08:19:44 -04:00
Wilson Snyder ef72c42aa7 Commentary 2020-05-29 19:58:59 -04:00
Wilson Snyder fbc814b54a Internal code coverage fixes 2020-05-29 19:35:54 -04:00
Wilson Snyder 4cfa3f879a Internals: Allow VL_DANGLING on pointer const. 2020-05-29 18:31:53 -04:00
Wilson Snyder 4a8c7e869f Fix coverage issue 2020-05-29 17:59:35 -04:00
Tomasz Gorochowik a4a1c7a384 Fix swerv issues with Increment nodes (#2380) 2020-05-29 13:03:04 -04:00
Ludwig Rogiers 460315128b Fix vpi_get_value() error message when passing unsupported vpiHandle. (#2378) 2020-05-29 08:10:22 -04:00
Wilson Snyder 8ddafb4d9f Update contributors (from email) 2020-05-28 21:35:38 -04:00
Wilson Snyder ebda8f866c Cleanup codacity and missing consts. 2020-05-28 21:04:36 -04:00
Wilson Snyder 5ee4595aa8 Remove dead code (git_untabify), instead use make clang-format 2020-05-28 21:04:17 -04:00
Wilson Snyder 5089ac6119 Remove VL_ULL as ULL now in MSVC & C++11 2020-05-28 20:32:07 -04:00
Wilson Snyder 3f66f846cd Travis enable SystemC test (#1601) 2020-05-28 18:52:03 -04:00
Wilson Snyder 279f21bb5b Configure now enables SystemC if it is installed as a system headers. 2020-05-28 18:51:46 -04:00
Wilson Snyder 773ed97504 Internals Most VerilatedLockGuard can be const. No functional change intended. 2020-05-28 18:23:46 -04:00
Wilson Snyder b6d4899d3f Commentary 2020-05-28 18:09:31 -04:00
Maciej Sobkowski 9d48ff7745 Support pre/postifx incrementation/decrementation in array index (#2223) 2020-05-28 18:08:15 -04:00
Stephen Henry c4aab57c62 Internals: Refactor to introduce VerilatedFdList. (#2363) 2020-05-28 17:59:18 -04:00
Maarten De Braekeleer e8f27be200 Fix Visual Studio compiler issues (#2375)
* Make sure compiler creates same object file as target of rule
* MSVC requires a string return
* Case ranges are a gnu extension which MSVC does not understand
* _dupenv_s also returns 0 if the var could not be found
See https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/dupenv-s-wdupenv-s?view=vs-2019
2020-05-28 17:39:20 -04:00
Wilson Snyder 15f0f967b3 Fix uninit variable warning 2020-05-28 17:33:44 -04:00
Wilson Snyder cbafff8a71 Commentary 2020-05-27 21:52:55 -04:00
Wilson Snyder 41e362b580 Tests: Remove some old conditional-fail checks. 2020-05-27 21:44:28 -04:00
Geza Lore 622f59ad65 Set OPT_FAST=-Os as default (#2374) 2020-05-28 00:57:49 +01:00
Wilson Snyder c5da38206e Fix configure over-disabling warnings. 2020-05-27 08:45:11 -04:00
Geza Lore d737266f64 Add OPT_GLOBAL to use for run-time library (#2373)
This allows compiling the run-time library with optimization even when OPT_FAST is not used in order to imporove model build speed, possibly during debug cycles.
2020-05-27 01:52:08 +01:00
Wilson Snyder 978c35995a Support const cast (ignored since not linting const yet) 2020-05-26 20:44:20 -04:00
Wilson Snyder 2af7f2fa18 Internals: Parser cleanup of cast. 2020-05-26 20:29:54 -04:00
Wilson Snyder 373c9090d3 Update contributors (from email) 2020-05-26 19:12:19 -04:00
Stefan Wallentowitz 723d407a87 [docker] Unify docker files (#2371)
Unify the actions in the Dockerfiles between the runtime environment
and the run containers.

Fixes #2345

Signed-off-by: Stefan Wallentowitz <[email protected]>
2020-05-26 20:38:43 +02:00
Stefan Wallentowitz dc90e6c3c3 Generate file with waivers (#2354)
This adds the flag --generate-waivefile <filename>. This will generate
a verilator config file with the proper lint_off statemens to turn off
warnings emitted during this particular run.

This feature can be used to start with using Verilator as linter and
systematically capture all known lint warning for further
elimination. It hopefully helps people turning of -Wno-fatal or
-Wno-lint and gradually improve their code base.

Signed-off-by: Stefan Wallentowitz <[email protected]>
2020-05-26 20:38:14 +02:00
Stefan Wallentowitz 68a2ed6776 Fix output of loops on waiving (#2355)
When an unopt loop is waived, we also don't want the loop's example
path being plot.

Signed-off-by: Stefan Wallentowitz <[email protected]>
2020-05-26 08:45:57 +02:00
Wilson Snyder 7f32d4dc45 Internals: Parser cleanup of expressions. 2020-05-25 21:51:05 -04:00
Geza Lore 7b683fe258 Use sane --output-split values by default to help large builds
--output-split is now on by default with value 20000.
--output-split-cfuncs and --output-split-ctrace now defaults to the
value of --output-split unless explicitly specified.
2020-05-26 01:22:10 +01:00
Geza Lore 72858175a2 Only emit VM_PARALLEL_BUILDS=1 iff --output-split caused a split.
Previously we set VM_PARALLEL_BUILDS=1 if the --output-split option was
provided. Now we only do it iff it actually causes a split.
2020-05-26 01:22:10 +01:00
Geza Lore 9d7086067c Rework serial/parallel build mode
Instead of __ALLfast.cpp and __ALLslow.cpp, we now create only a single
__ALL.cpp and compile it with OPT_FAST, this speeds up small builds
where the C compiler does not dominate. A separate patch will follow
turning VM_PARALLEL_BUILDS on by default at a certain size.

Given this change to the build there is now no point in emitting both
fast and slow routines into the same .cpp file when --output-split is
not set as they will be just included in the same __ALL.cpp file. To
keep things simpler and the output easier to comprehend, V3EmitC has
also been changed to always emit the fast and slow files separately.

Also change verilated.mk to apply OPT_SLOW to all slow files, not just
ones called *__Slow.cpp. This change in particular ensures __Syms.cpp
is build as slow.

Part of #2360.
2020-05-26 01:22:10 +01:00
Wilson Snyder 5bb1da88ed Internals: Comment grammar continuations. No functional change. 2020-05-25 19:40:20 -04:00
Wilson Snyder 9969a60b34 Commentary 2020-05-25 18:51:12 -04:00
Wilson Snyder 72402fa91e Internals: Parser cleanup of parameters, second part. 2020-05-25 18:49:29 -04:00
Wilson Snyder 8255f3f9fe Internals: Parser cleanup of parameters, first part. 2020-05-25 18:41:47 -04:00
Wilson Snyder 8957f77793 Internals: Refector needHeavy into methods. No functional change intended. 2020-05-25 15:34:24 -04:00
Wilson Snyder 7187b82d1d Update contributors (from email). 2020-05-25 13:36:24 -04:00
Ahmed El-Mahmoudy 1a92a58720 Fix spelling mistakes (#2364) 2020-05-25 12:43:32 -04:00
Wilson Snyder 2351f9b9ad Update contributors (from email). 2020-05-25 10:54:22 -04:00
Wilson Snyder abc3c216f8 Internal code coverage: Better support fastcov [still not default]. 2020-05-25 10:50:46 -04:00
Wilson Snyder f1afa667d7 Update contributors. 2020-05-25 09:16:40 -04:00
Wilson Snyder 76d0671952 Travis: Fix cron. 2020-05-25 08:46:46 -04:00
Jan Van Winkel 424769c32b Fix warning for unused param in VL_RTOIROUND_Q_D (#2356) 2020-05-25 08:13:12 -04:00
Wilson Snyder f7249ad23a Internals: AstRefDType points to AstTypedef instead of sub-dtype, in prep for future commits. 2020-05-24 14:22:06 -04:00
Wilson Snyder 613d76c578 Travis: Fix cron. 2020-05-24 08:30:59 -04:00
Wilson Snyder 50662751fe Fix compiler unsigned warnings 2020-05-23 22:38:17 -04:00
Wilson Snyder c9e59e767a Tests: Add setenv method. 2020-05-23 22:24:26 -04:00
Vassilis Papaefstathiou a7432bdea7 Support wide operands in queues and dynamic arrays (#2352) 2020-05-23 21:59:56 -04:00
Wilson Snyder 9ffad7f0db Internal cleanups. No functional change intended 2020-05-23 21:57:08 -04:00
Wilson Snyder 3097d5e093 Commentary 2020-05-23 21:56:56 -04:00
Yuri Victorovich cff4b5a5ee Fix WIFEXITED error on FreeBSD. (#2351) (#2353) 2020-05-23 16:30:36 -04:00
Wilson Snyder eda46e3949 Internals: Favor exprOrDataType where possible. No functional change intended. 2020-05-23 13:08:56 -04:00
Wilson Snyder 71651718d4 Internals: Track :: in AstDot parsing. No parsing change intended. 2020-05-23 12:44:15 -04:00
Wilson Snyder da0cb44954 Internals: Refactor parsing id's up to parent rules. No functional change intended. 2020-05-23 12:19:43 -04:00
Wilson Snyder 57621a93ad Internals: Move PLI errors into linker, and better test. 2020-05-23 11:55:34 -04:00
Wilson Snyder 6a882f9dc6 Internal code coverage improvements. No functional change intended. 2020-05-23 10:34:58 -04:00
Wilson Snyder c18b0eb122 Internal coverage: Limit parallelism to core count. 2020-05-23 09:50:04 -04:00
Wilson Snyder 3c28a66acf Internal coverage: Fix --hashset option. --stop now default. 2020-05-23 09:17:16 -04:00
Wilson Snyder 5c11de1663 Tests: Check queue typedef. 2020-05-22 22:14:26 -04:00
Wilson Snyder 72ea6bf414 Travis: Fix cron. 2020-05-22 08:39:56 -04:00
Ludwig Rogiers 101314a572 Add VPI error reset to vpi_get_time() (#2347) 2020-05-22 07:09:47 -04:00
Wilson Snyder 01f3e81a36 Internals: Parse extend/implements/etc using generic identifiers. 2020-05-21 21:31:15 -04:00
Wilson Snyder 3cb3b6c400 clang-format verilog.l. No functional change. 2020-05-21 19:46:21 -04:00
Wilson Snyder 8f58b58853 Internals: Parse using idAny where can to better detect id errors. 2020-05-20 23:29:37 -04:00
Wilson Snyder b66826169d Internals: Refactor inherits/extends parse so don't need type vs nontype IDs. 2020-05-20 23:10:45 -04:00
Wilson Snyder d2a7376f14 Fix spacing. No functional change 2020-05-20 22:33:32 -04:00
Wilson Snyder c9e8a1cb4d Commentary 2020-05-20 20:31:57 -04:00
Wilson Snyder 8170f6f03f Travis: Fix cron. 2020-05-20 17:39:32 -04:00
Stefan Wallentowitz 0abf88823f Docker upgrade to Ubuntu 20.04 (#2318)
* [docker] Remove versions from Docker files

There is no dependency on an actual version, it was only there to
silence the linter. Instead the linter is now set to not warn about
it.

Signed-off-by: Stefan Wallentowitz <[email protected]>

* [docker] Update to Ubuntu 20.04

Update to new Ubuntu release:

 - Only GCC 9.3 available. Also add clang (10.0) now.
 - SystemC is now a package 🎉

Signed-off-by: Stefan Wallentowitz <[email protected]>
2020-05-20 06:58:43 -04:00
Todd Strader accf5a9a17 Check if Parallel::Forker is new enough (#2343) 2020-05-19 14:31:13 -04:00
Wilson Snyder c64c81b7a3 Workaround missing guard (partial #2333). 2020-05-19 08:31:52 -04:00
Wilson Snyder 7834028842 Tests: Skip genhtml if too old 2020-05-19 08:24:21 -04:00
Wilson Snyder 1e0d5eb238 Release examples/Makefiles under CC0. 2020-05-18 22:23:19 -04:00
Wilson Snyder b5460bd867 Travis-CI fixes 2020-05-18 18:34:26 -04:00
Geza Lore 53cde90c8f De-constify fields to appease old GCC with broken STL
No functional change intended, fixes #2342
2020-05-18 19:01:08 +01:00
Geza Lore d20a4db773 Fix regression due to early constant folding in +: and -: (#2338) 2020-05-18 18:46:00 +01:00
Wilson Snyder 0f7677480f Commentary 2020-05-18 08:11:56 -04:00
Stephen Henry ba3930777a Support display/scan %u/%z (#2324) (#2332) 2020-05-18 08:10:32 -04:00
Geza Lore 9c054a5774 Optimize trace activity flags a bit more
- Improve flag pruning heuristic
- Set all trace activity flags in slow code. This in turns enables us
to remove checking the slow flag on the fast path.
2020-05-17 19:41:24 +01:00
Stephen Henry cef0105dfc Fix requiring C++11 algorithms. (#2339) (#2340) 2020-05-17 11:44:42 -04:00
Wilson Snyder 4773a1e77c Misc internal coverage improvements. 2020-05-17 11:06:14 -04:00
Wilson Snyder ed4c7038b4 Tracing: Remove dead code. No functional change intended. 2020-05-17 09:53:58 -04:00
Wilson Snyder c4f31d3bb6 Tracing: Remove dead code. No functional change intended. 2020-05-17 09:52:03 -04:00
Geza Lore dc25e9b949 Optimize fine grained trace activity flags (#2336)
Firstly, we always use a byte array for fine grained activity flags
instead of a bit vector (we used to use a byte array only if we had
parallel mtasks). The byte vector can be set more cheaply in eval,
closing about 1/3 of the gap in performance between compiling with
or without --trace on SweRV EH1. The speed of tracing itself is not
measurably different.

Secondly, we prune the activity tracking such that if a set of activity
flag combinations only guard a small number of signals, we will turn
those signals into awayls traced signals. This avoids code which
sometimes tests dozens of activity flags just to subsequently check one
signal and dump it if it's value changed. We can just check the signal
state straight instead, and not bother with the flags. This removes
about 30% of activity flags in SweRV EH1, and makes both single threaded
VCD and FST tracing 8-9% faster.
2020-05-17 13:53:02 +01:00
Wilson Snyder 1f52b01b2c Travis: Fix cron. 2020-05-17 08:48:31 -04:00
Wilson Snyder d5fc0fca41 Travis: Fix cron. 2020-05-17 08:19:42 -04:00
Wilson Snyder 212aa332dd Commentary 2020-05-16 18:53:18 -04:00
Wilson Snyder 17e7da77f0 Misc internal coverage improvements. 2020-05-16 18:02:54 -04:00
Wilson Snyder 201f0d3f5f Codecov badge 2020-05-16 15:02:22 -04:00
Wilson Snyder 7d0b3b300a Travis: Setup cron coverage 2020-05-16 14:59:30 -04:00
Wilson Snyder 0b55e205f7 Internal code_coverage: speedup aggregation. 2020-05-16 14:53:22 -04:00
Wilson Snyder 9c0c6439cc Clean additional objects. 2020-05-16 13:28:03 -04:00
Wilson Snyder d33d0301f8 Support verilator_coverage --write-info for lcov HTML reports. 2020-05-16 09:18:35 -04:00
Wilson Snyder 6fd7f45cef Internals: Remove dead needHInlines code 2020-05-16 07:53:27 -04:00
Wilson Snyder 57a937df03 Misc internal coverage cleanups 2020-05-16 07:43:22 -04:00
Wilson Snyder ffd461dcf8 Tests: Check need -cc message 2020-05-16 07:10:44 -04:00
Wilson Snyder f77058774e Add codecov.yml 2020-05-16 06:15:45 -04:00
Wilson Snyder 1d0a726437 Update internal code coverage framework. 2020-05-16 06:15:25 -04:00
Wilson Snyder 29bcbb0417 Suppress impossible code coverage issues 2020-05-15 22:34:29 -04:00
Wilson Snyder 2d11c2cbb3 Tests: Fix driver called with no tests 2020-05-15 22:33:35 -04:00
Wilson Snyder 2edbcce032 Tests: Need only one run of t_trace_c_api.pl 2020-05-15 22:33:20 -04:00
Wilson Snyder 35a53d9adb Add t_trace_c_api test. 2020-05-15 20:38:08 -04:00
Wilson Snyder 2885c2ce97 Fix coredump on countbits. 2020-05-15 19:29:17 -04:00
Geza Lore 900c023bb5 Refactor trace implementation to allow experimentation
The main goal of this patch is to enable splitting the full and
incremental tracing functions into multiple functions, which can then be
run in parallel at a later stage. It also simplifies further
experimentation as all of the interesting trace code construction now
happens in V3Trace. No functional change is intended by this patch, but
there are some implementation changes in the generated code.

Highlights:
- Pass symbol table directly to trace callbacks for simplicity.
- A new traceRegister function is generated which adds each trace
function as an individual callback, which means we can have multiple
callbacks for each trace function type.
- A new traceCleanup function is generated which clears the activity
flags, as the trace callbacks might be implemented as multiple functions.
- Re-worked sub-function handling so there is no separate sub-function
for each trace activity class. Sub-functions are generate when required
by splitting.
- traceFull/traceChg are now created in V3Trace rather than V3TraceDecl,
this requires carrying the trace value tree in TraceDecl until it
reaches V3Trace where the TraceInc nodes are created (previously a
TraceInc was also created in V3TraceDecl which carries the value).
2020-05-15 18:34:29 +01:00
Geza Lore 12b95f6b93 Clean up V3TraceDecl & V3Trace. No functional change intended.
- Constify variables
- Remove redundancies
- [Hopefully] make some code a bit more readable
2020-05-15 18:34:29 +01:00
Wilson Snyder 85de3048a5 Tests: Avoid poluting non-obj_ files. 2020-05-14 18:50:49 -04:00
Wilson Snyder c1a9fe07e9 Support multi channel descriptor I/O (#2190)
clang-format and Changes update. No functional change.
2020-05-14 18:14:50 -04:00
Stephen Henry 1a0da2e4ec Support multi-channel descriptor (MCD) I/O (#2197) 2020-05-14 18:03:00 -04:00
Wilson Snyder 38d11ecabe Commentary 2020-05-13 21:06:00 -04:00
Wilson Snyder 148762364b Tests: Complicated for loops long ago supported. 2020-05-13 20:53:55 -04:00
Huang Rui 68d7596adf Fix compile error when using bison 3.6.1 (#2320)
Workaround issue: bison 3.6.1 generated unexpected nested-comment
Closes: https://github.com/verilator/verilator/issues/2320
Signed-off-by: Huang Rui <[email protected]>
2020-05-13 19:18:56 -04:00
Wilson Snyder f005b7fd87 Support scan %* format 2020-05-11 22:13:59 -04:00
Wilson Snyder 68ed683681 Travis: Run 20.04 for non-cron, more others for cron. 2020-05-11 20:31:37 -04:00
Wilson Snyder 61e41595a2 Fix clang warning 2020-05-11 20:31:37 -04:00
Stephen Henry 484b574cef Fix crash on self-referential enum type. (#2319) 2020-05-11 18:44:28 -04:00
Wilson Snyder 29695adf70 Fix 10s/100s timeunits. 2020-05-11 08:15:52 -04:00
Wilson Snyder fac43811fd Commentary 2020-05-10 21:26:09 -04:00
Wilson Snyder 15f63d12d5 Fix message for seeded random. 2020-05-10 21:15:48 -04:00
Wilson Snyder ba7b3fd60f Support $display(,,). 2020-05-10 20:48:18 -04:00
Wilson Snyder 897b9ccfe2 Fix display of huge double. 2020-05-10 16:03:46 -04:00
Wilson Snyder b97e1aa9fe Support cast to string 2020-05-10 15:42:16 -04:00
Wilson Snyder d4a631446b Fix crash in unroller on increment-only while loops. 2020-05-10 15:26:41 -04:00
Wilson Snyder a2cc053c6f Tests: Fix t_math_svl.pl 2020-05-10 15:19:38 -04:00
Wilson Snyder 8998ffc4e5 Support reporting some fork syntax errors. 2020-05-10 15:01:43 -04:00
Wilson Snyder ca162716c6 Internals: clang-format 2020-05-10 14:29:15 -04:00
Wilson Snyder 629dd16714 Tests: Rename t_delay_func_bad 2020-05-10 14:28:42 -04:00
Wilson Snyder 12b903caf4 Improve error on using array.unique method. 2020-05-10 14:28:42 -04:00
Yossi Nivin f9a0cf0cff Support $countbits (#2287) 2020-05-10 14:27:22 -04:00
Wilson Snyder 070bcddf5a Support unpacked array .sum and .product. 2020-05-10 12:48:33 -04:00
Wilson Snyder feb1e2bd48 Commentary 2020-05-10 11:01:57 -04:00
Wilson Snyder 6e7ee23644 Internals: Code cleanups. 2020-05-09 15:00:46 -04:00
Wilson Snyder c00cc18d37 Optimize dead code after gotos 2020-05-09 15:00:36 -04:00
Wilson Snyder a7e17a8855 Fix double conversion on half of conditional. 2020-05-08 21:35:45 -04:00
Wilson Snyder 60fa1db731 Tests: Trivial cleanup 2020-05-08 21:35:45 -04:00
Geza Lore ac09ad3ffd Minor improvements to DPI open array handling (#2316)
- Allow arbitrary number of open array dimensions, not just 3. Note
right now this only works with the array querying functions specified
in IEEE 1800-2017 H.12.2
- Issue error when passing dynamic array or queue as DPI open array
(currently unsupported)
- Also tweaked AstVar::vlArgTypeRecurse, which should now error or fail
for unsupported types.
2020-05-08 18:22:44 +01:00
Wilson Snyder 27953e26b6 Backout example change. 2020-05-08 07:35:54 -04:00
Wilson Snyder 9375d9f603 Fix $isunknown with constant Zs. 2020-05-07 21:40:08 -04:00
Wilson Snyder 72bd91c7f1 Support $isunbounded and parameter $. (#2104) 2020-05-07 21:12:58 -04:00
Wilson Snyder 8850ca962e Fix newish error to use standard parens to ref IEEE. 2020-05-07 21:12:58 -04:00
Wilson Snyder 7fd590f855 Commentary 2020-05-07 21:12:58 -04:00
Wilson Snyder 5f7ae1fbce wip 2020-05-07 21:04:26 -04:00
Wilson Snyder b56a25e89c Fix newish error to use standard parens to ref IEEE. 2020-05-07 18:21:11 -04:00
Wilson Snyder 4f32b093e6 Commentary 2020-05-07 18:11:06 -04:00
Geza Lore 6a54fb6f96 Modify std::multimap in V3Combine safely.
We used to iterate the m_callMmap std::multimap by getting limit
iterators from equal_range, but we also modify the same map in the loop
which invalidates those limit iterators. Note this only caused actual
problems if the new AstCCall inserted via 'addCall' in the loop had a
memory address (which is used as the key) which fell into the range
returned by equal_range, so was pretty hard to trigger.
2020-05-07 14:31:43 +01:00
Wilson Snyder 546ccd56c4 Internals: Enable future JumpGo to non-end. No functional change intended. 2020-05-06 21:33:05 -04:00
Wilson Snyder ca77a93214 Add lint check for bad delay locations. 2020-05-06 19:25:13 -04:00
Dan Petrisko ee1b20e1cd Adding missing sstream include (#2312) 2020-05-06 19:16:41 -04:00
Yutetsu TAKATSUKASA aa86e0bbc0 Support 'E', 'p', and 'P' when overriding floating point parameter. (#2310) 2020-05-06 07:45:07 -04:00
Wilson Snyder b6b3482010 Internals: Use typ delay by default 2020-05-05 20:42:19 -04:00
Wilson Snyder 05aecd2c0b Internals: Fix tabs in astgen. No effective functional change. 2020-05-05 20:33:35 -04:00
Wilson Snyder 6ab3d8f3ed Internals: Refactor to add AstNodeProcedure. No functional change intended. 2020-05-05 19:12:36 -04:00
Wilson Snyder 0fcc7f2987 Fix default pkgconfig version to have no spaces (#2308) 2020-05-05 08:46:24 -04:00
Wilson Snyder 7d7e67b49b Show Verilog reference on V3Number asserts. 2020-05-04 19:57:21 -04:00
Wilson Snyder a41ea180fa Fix +: and -: on unpacked arrays. (#2304) 2020-05-04 19:40:50 -04:00
Wilson Snyder 98889b3f4e Tests: Fix permission 2020-05-04 19:35:48 -04:00
Tim Snyder 83fbfa8c71 Fix /usr/bin/env perl in lieu of /usr/bin/perl (#2307)
Enables scripts to work where perl is not installed at /usr/bin/perl
2020-05-04 19:27:30 -04:00
Tim Snyder a57262d6e7 Fix use /usr/bin/env perl in lieu of /usr/bin/perl (#2306)
Enables scripts to work where perl is not installed at /usr/bin/perl
2020-05-04 18:42:15 -04:00
Geza Lore fe708f045a Fix Travis oddity 2020-05-04 00:21:07 +01:00
Geza Lore 8afcd67a1f Fix FST tracing of little endian vectors 2020-05-03 22:39:45 +01:00
Wilson Snyder 16e258eb4c Commentary: reformat changes, relocate announcements 2020-05-03 16:10:02 -04:00
Wilson Snyder d6fbbddac9 devel release 2020-05-03 11:18:53 -04:00
Wilson Snyder 9dc65df982 Version bump 2020-05-03 11:14:37 -04:00
Wilson Snyder 8f64e4a76f Support $root, #2150. 2020-05-02 08:29:20 -04:00
John Demme 6e9008fb5a Fix VerilatedVarProps::totalSize missing the first unpacked dim (#2296) 2020-05-01 07:42:29 -04:00
Wilson Snyder 5ded80cf79 Fix MacOs Homebrew by removing default LIBS, #2298. 2020-04-30 19:53:21 -04:00
Wilson Snyder a6deee2083 Fix clock enables with bit-extends, #2299. 2020-04-30 19:22:58 -04:00
Wilson Snyder e1f45dd84a Commentary 2020-04-30 18:52:32 -04:00
Wilson Snyder 9fd4541069 Fix reduction OR on wide data, broke in v4.026, #2300. 2020-04-30 17:53:54 -04:00
Geza Lore 849487da23 Modify --build to be a standalone option (#2294)
- Issue an error when --build is used together with --make
- When given --build, always use GNU Make to perform the build
- Update documentation (examples were good as they were)
- Remove the broken t_flag_build_cmake test

Fixes #2280
2020-04-30 12:54:50 +01:00
Peter Horvath dc64b43152 Fix xcode clang bug workaround (#2295) 2020-04-30 07:20:31 -04:00
Geza Lore 209a585a68 Remove VL_NEGATE_{I,Q,E}, use C native unary '-' instead
This is to avoid slowing down -O0 models unnecessarily.
2020-04-30 01:05:52 +01:00
Geza Lore aa9cde22c8 Use SIMD intrinsics to render VCD traces (#2289)
Use SIMD intrinsics to render VCD traces.

I have measured 10-40% single threaded performance increase with VCD
tracing on SweRV EH1 and lowRISC Ibex using SSE2 intrinsics to render
the trace. Also helps a tiny bit with FST, but now almost all of the FST
overhead is in the FST library.

I have reworked the tracing routines to use more precisely sized
arguments. The nice thing about this is that the performance without the
intrinsics is pretty much the same as it was before, as we do at most 2x
as much work as necessary, but in exchange there are no data dependent
branches at all.
2020-04-30 00:09:09 +01:00
Wilson Snyder faf7255e83 Commentary 2020-04-29 18:42:28 -04:00
Wilson Snyder a6c97cc3bc Commentary 2020-04-29 18:41:00 -04:00
Wilson Snyder 977ceb404d Mention -march-native, #2289. 2020-04-29 18:10:43 -04:00
Wilson Snyder b44efe7ef7 Use 'suggest' for consistent wording. 2020-04-28 21:19:19 -04:00
Wilson Snyder 15ad3f46be Fix logical not optimization with empty begin, #2291. 2020-04-28 21:15:20 -04:00
Wilson Snyder c6d1a9858a Use clang-format 10.0.0 2020-04-28 18:47:59 -04:00
Wilson Snyder 77cc335c2d Commentary 2020-04-28 18:47:49 -04:00
Wilson Snyder a95eb53684 Commentary (#2290). 2020-04-28 18:46:59 -04:00
Wilson Snyder 910803e6db Fix error on unpacked connecting to packed, #2288. 2020-04-27 18:38:54 -04:00
Geza Lore dd967f7769 Improve trace buffer memory utilization and performance.
Convert trace buffer to 32-bit entries, rather than a union containing a
pointer type. Also tweaked trace entry layouts for a bit more
performance. This gains another 10% on SweRV EH1 CoreMark.
2020-04-27 19:00:17 +01:00
Geza Lore b79ef672e1 Various minor optimizations of VCD trace routines
- Change templated trace routines to branch table.

Removed templating from trace chgBus and fullBus and replaced them with
a branch table like the other there is a very small (< 1%) penalty for
this on SwerRV EH1 CoreMark, but this is less than the variability of
disk IO so it's worth it to keep the code simpler and smaller.

- Prefetch VCD suffix buffer at the top of emit*

- Increase ILP in VCD emit* routines

- Use a 64-bit unaligned store to emit the VCD suffix (on x86 only)

The performance difference with these is very small, but the changes
hopefully make this code more performance-portable across various
micro-architectures.
2020-04-27 18:44:53 +01:00
Wilson Snyder 70549e1a64 Internals: Parse lifetime directives; still unsupported. 2020-04-26 12:45:06 -04:00
Wilson Snyder 87e1c36e4a Support event data type (with some restrictions). 2020-04-25 15:37:46 -04:00
Geza Lore 9991b19610 Another attempt at flushing threaded VCD correctly. 2020-04-25 18:40:09 +01:00
Geza Lore 1381d3dbde Add -Wno-tautological-bitwise-compare to model build flags (#2285)
This appeases Clang 10.
2020-04-25 16:29:42 +01:00
Wilson Snyder 5e575f5906 Fix line numbers in tables. 2020-04-24 19:34:26 -04:00
Wilson Snyder e2cbcd37d8 Commentary 2020-04-24 18:43:02 -04:00
Wilson Snyder 3b37b5b92d Tests: Check output from some unsupported tests. 2020-04-24 08:22:19 -04:00
Geza Lore 10b4678ee6 Make vgen.pl deterministic 2020-04-24 04:53:33 +01:00
Geza Lore c1665818b9 Fix missing flush with threaded VCD tracing. (#2282)
VerilatedVcdC::openNext() failed to flush the tracing thread before
opening the next output file, which caused t_trace_cat.pl to fail
with --vltmt on occasion.
2020-04-24 03:09:26 +01:00
Geza Lore 27f4399c31 Fix tests failing on rerun after passing from clean. (#2281) 2020-04-23 21:27:06 -04:00
Wilson Snyder df52e481fb Collected minor output code cleanups. 2020-04-23 21:22:47 -04:00
Wilson Snyder f93ae707e0 Tests: Add bad option test. 2020-04-23 19:56:26 -04:00
Geza Lore 6ed10b7fde Fix --protect-lib generated library link rules (#2279)
We used to include a .cpp file on the link line for the shared library,
which was ignored, but generated a .d file for the .so which contained
the header files required by the .cpp file. This then caused a rebuild
where we included the .d in verilated.mk to included in the .h headers
among the prerequisites of the .so, yielding a clang error about treating
.h files as c++-header rather than c-header... Long story short, we don't
do that anymore. This used t cause t_a4_examples to fail on occasion.

Note there is no need for a separate compilation rule for the
<--protect-lib>.cpp, as it will jsut pick up the standard OPT_FAST rule.
2020-04-23 17:30:23 -04:00
Geza Lore 8208fe8a0e Fix test failures on Ubuntu 20.04 (#2278)
- Packaged SystemC lives in /usr so needed to update regex in test
driver
- Clang 10 complains about mixed named and positional initializers in
struct definitions.
2020-04-23 17:29:37 -04:00
Wilson Snyder ace35b3e81 Tests: Add -G test. 2020-04-23 08:05:14 -04:00
Wilson Snyder 2b58e834ee Tests: Rename IVERILOG define for consistency. No functional change. 2020-04-23 08:05:14 -04:00
Qingyao Sun 14643643c9 Fix compatibility problem with CMake policy CMP0025 (#2277)
Signed-off-by: Qingyao Sun <[email protected]>
2020-04-23 07:14:20 -04:00
Wilson Snyder 7176aee852 Internals: Parse fork and delays, but then still report unsupported. 2020-04-22 21:31:40 -04:00
Geza Lore c96a43b452 Fix unused variable in VL_READMEM_N (#2274) 2020-04-22 17:25:35 -04:00
Wilson Snyder 77915f78db Add experimental-only option. 2020-04-21 20:45:23 -04:00
Geza Lore c52f3349d1 Initial implementation of generic multithreaded tracing (#2269)
The --trace-threads option can now be used to perform tracing on a
thread separate from the main thread when using VCD tracing (with
--trace-threads 1). For FST tracing --trace-threads can be 1 or 2, and
--trace-fst --trace-threads 1 is the same a what --trace-fst-threads
used to be (which is now deprecated).

Performance numbers on SweRV EH1 CoreMark, clang 6.0.0, Intel i7-3770 @
3.40GHz, IO to ramdisk, with numactl set to schedule threads on different
physical cores. Relative speedup:

--trace     ->  --trace --trace-threads 1      +22%
--trace-fst ->  --trace-fst --trace-threads 1  +38% (as --trace-fst-thread)
--trace-fst ->  --trace-fst --trace-threads 2  +93%

Speed relative to --trace with no threaded tracing:
--trace                                 1.00 x
--trace --trace-threads 1               0.82 x
--trace-fst                             1.79 x
--trace-fst --trace-threads 1           1.23 x
--trace-fst --trace-threads 2           0.87 x

This means FST tracing with 2 extra threads is now faster than single
threaded VCD tracing, and is on par with threaded VCD tracing. You do
pay for it in total compute though as --trace-fst --trace-threads 2 uses
about 240% CPU vs 150% for --trace-fst --trace-threads 1, and 155% for
--trace --trace threads 1. Still for interactive use it should be
helpful with large designs.
2020-04-21 23:49:07 +01:00
Wilson Snyder 6ab51de96d Fix dockerfile 2020-04-21 18:37:53 -04:00
James Hanlon 97cbc10925 Add --flaten for use with --xml-only (#2270). 2020-04-21 18:14:08 -04:00
James Hanlon 65cd4f6047 Fix comment and add to CONTRIBUTORS (#2270). 2020-04-21 18:11:53 -04:00
Wilson Snyder 174fd1bf0e Codacy cleanups. No functional change. 2020-04-20 22:01:47 -04:00
Wilson Snyder b12413e42f Tests: Reenable some tests incorrectly marked unsupported. 2020-04-20 21:55:23 -04:00
Wilson Snyder 7709130d93 Fix Codacy badge 2020-04-20 21:52:29 -04:00
Wilson Snyder 15f7685755 Codacity cleanups. No functional change intended. 2020-04-20 21:43:05 -04:00
Wilson Snyder 83c6e9e821 Commentary commit for Codacity. 2020-04-20 21:13:43 -04:00
Veripool API Bot 1cacb1deab Commentary commit for Codacity. 2020-04-20 20:01:59 -04:00
Veripool API Bot 03bc8b7480 Commentary commit for Codacity. 2020-04-20 19:54:07 -04:00
Veripool API Bot 7d6668a3bd Commentary commit for Codacity. 2020-04-20 19:38:21 -04:00
Wilson Snyder def40fab9b Internals: Rename VSigning 2020-04-19 21:19:09 -04:00
Wilson Snyder fceedd9f4d Tests: Update static test. 2020-04-19 21:18:57 -04:00
Wilson Snyder 4272f2116e Tests: Update static test. 2020-04-19 20:10:07 -04:00
Geza Lore 39d903375b Factor out trace implementation common to all formats. (#2268)
This patch de-duplicates common functionality between the VCD and FST
trace implementation. It also enables adding new trace formats more
easily and consistently.

No functional nor performance change intended.
2020-04-19 23:57:36 +01:00
Wilson Snyder 9164eb03d5 Show that class parameters even if unused are unsupported. 2020-04-19 18:36:55 -04:00
Wilson Snyder 7b789fe02a Docker: Add ccache and libgoogle-perftools-dev 2020-04-19 12:59:38 -04:00
Wilson Snyder 4ae3d3af71 Fix docker build error 2020-04-19 12:43:20 -04:00
Geza Lore 6a54922044 Set FST timescale correctly. (#2266)
The FST trace timescale used to be set in the constructor via
set_time_unit, but at that point we haven't normally opened the
file yet so it was just dropped. On top of that, we actually want
to use set_time_resolution... FST trace timescales now match the VCD.
2020-04-19 08:47:22 -04:00
Wilson Snyder 466535abdc Support direct class member init. 2020-04-18 20:20:17 -04:00
Geza Lore efacac2e3d Tests: Ignore SystemC file paths in expected test results (#2265) 2020-04-18 18:56:19 -04:00
Geza Lore 74e16d85c5 Fix FST trace initial time stamp. (#2264)
If the first dump was not at time zero, then the FST trace used
to contain the initial values as if they were set at time zero. Now
they only appear at the time the first dump call is actually made,
and hence match the VCD trace exactly.
2020-04-18 18:54:02 -04:00
Wilson Snyder 39d7cbf412 Fix arrayed instances connecting to slices, #2263. 2020-04-17 19:30:53 -04:00
Wilson Snyder 8f7e463656 Tests: Fix makeflag test, was failing older makes. 2020-04-16 17:31:41 -04:00
Wilson Snyder e6f345e45d Internal: clang-tidy fixes. No functional change. 2020-04-15 21:47:37 -04:00
Wilson Snyder d4f7f5297a Support IEEE time units and time precisions, #234. (#2253)
Includes `timescale, $printtimescale, $timeformat.
VL_TIME_MULTIPLIER, VL_TIME_PRECISION, VL_TIME_UNIT have been removed
and the time precision must now match the SystemC time precision.
To get closer behavior to older versions, use e.g. --timescale-override
"1ps/1ps".
2020-04-15 19:39:03 -04:00
Wilson Snyder 9b8aebb00c Commentary on --build 2020-04-15 18:08:37 -04:00
Wilson Snyder 58091edd68 Tests: Fix cmake -j unknown 2020-04-15 18:08:31 -04:00
Yutetsu TAKATSUKASA 18412f9322 Add --build option to call make/cmake as subprocess (#2249)
* Add --build, -j, -MAKEFLAGS, and --no-verilate options
* Verilator: Can build on both gmake and cmake
2020-04-15 17:44:21 -04:00
Wilson Snyder 1883ab29cb clang-format 10.0 forward compatibility. No functional change. 2020-04-15 17:36:57 -04:00
Geza Lore 1a64c7d232 Fix run-time formatting of variable wider than 1023 bits (#2261) 2020-04-15 17:26:15 -04:00
Wilson Snyder f3308d236b clang-format remaining sources. No functional change. 2020-04-15 07:58:34 -04:00
Wilson Snyder 1b94e3b0e2 Internals: clang-format files needed for #2249. 2020-04-14 19:55:00 -04:00
Geza Lore 08b74e5ab9 Fix crash when formatting constant wider than 1023 bits (#2260) 2020-04-14 18:07:09 -04:00
Wilson Snyder 5c966ec510 clang-format many files. No functional change.
Use nodist/clang_formatter to reformat files that are now clean.
2020-04-13 22:52:23 -04:00
Geza Lore dc5c259069 Improve tracing performance. (#2257)
* Improve tracing performance.

Various tactics used to improve performance of both VCD and FST tracing:
- Both: Change tracing functions to templates to take variable widths as
  template parameters. For VCD, subsequently specialize these to the
  values used by Verilator. This avoids redundant instructions and hard
  to predict branches.
- Both: Check for value changes via direct pointer access into the
  previous signal value buffer. This eliminates a lot of simple pointer
  arithmetic instructions form the tracing code.
- Both: Verilator provides clean input, no need to mask out used bits.
- VCD: pre-compute identifier codes and use memory copy instead of
  re-computing them every time a code is emitted. This saves a lot of
  instructions and hard to predict branches. The added D-cache misses
  are cheaper than the removed branches/instructions.
- VCD: re-write the routines emitting the changes to be more efficient.
- FST: Use previous signal value buffer the same way as the VCD tracing
  code, and only call the FST API when a change is detected.

Performance as measured on SweRV EH1, with the pre-canned CoreMark
benchmark running from DCCM/ICCM, clang 6.0.0, Intel i7-3770 @ 3.40GHz,
and IO to ramdisk:

            +--------------+---------------+----------------------+
            | VCD          | FST           | FST separate thread  |
            | (--trace)    | (--trace-fst) | (--trace-fst-thread) |
------------+-----------------------------------------------------+
Before      |  30.2 s      | 121.1 s       |  69.8 s              |
============+==============+===============+======================+
After       |  24.7 s      |  45.7 s       |  32.4 s              |
------------+--------------+---------------+----------------------+
Speedup     |    22 %      |   256 %       |   215 %              |
------------+--------------+---------------+----------------------+
Rel. to VCD |     1 x      |  1.85 x       |  1.31 x              |
------------+--------------+---------------+----------------------+

In addition, FST trace size for the above reduced by 48%.
2020-04-14 00:13:10 +01:00
Wilson Snyder dc27a179e2 Always define VL_SIG etc; conditional definitions were long removed SystemPerl. 2020-04-13 19:07:56 -04:00
Wilson Snyder 236e6baa76 clang-format: Loops allowed on single line. 2020-04-13 17:44:19 -04:00
Wilson Snyder dba88bae3c Support class new. 2020-04-12 18:57:12 -04:00
Wilson Snyder d4b6e2b2b5 Internals: NodeModule for packages. 2020-04-12 14:53:10 -04:00
Wilson Snyder 1e2d73fc80 Internals: clang-format and refactor taskref pin handling. 2020-04-12 08:26:14 -04:00
Wilson Snyder ea3acc2d3a Fix --skip-identical broke recent commit. 2020-04-11 20:22:57 -04:00
Nathan Kohagen 152505e879 Fix make install/uninstall for examples/xml_py, #2252. 2020-04-11 18:11:53 -04:00
Wilson Snyder 8e6674066f Tests: Clean before rerunning failing test. 2020-04-11 11:40:15 -04:00
Geza Lore 8b2666cd04 Fix to make trace code allocation dense. (#2250)
This looks like a bits/bytes bug. The affected m_codeInc member
determines how many 32-bit words to allocate in a buffer used to store
previous values of the signal, but this was off by a factor of 8, so
we used to use too much memory.

SweRV VCD tracing speed +6.5% (excluding IO, clang 6.0), due mainly to
reduced D cache misses.
2020-04-11 16:00:43 +01:00
Wilson Snyder afa8e4c786 Internals: Favor const_iterator. No functional change. 2020-04-11 10:54:42 -04:00
Wilson Snyder ef211fc9e0 Make sure SystemC always included in -sc mode to prevent ordering issues. 2020-04-11 10:33:40 -04:00
Wilson Snyder 1a6c2fc55d Fix class members getting misoptimized away. 2020-04-10 21:10:21 -04:00
Wilson Snyder 15b40a97d9 Support `unconnected_drive 2020-04-09 23:26:03 -04:00
Wilson Snyder 343db78c03 Fix including verilated_sc in Syms to fix compile order problem exposed in #2237. 2020-04-09 23:03:47 -04:00
Nathan Myers 4c1ae4701a Add assertion for monotonic dump times #2103 (#2237) 2020-04-09 19:00:27 -04:00
Geza Lore 05f213c266 VCD tracing speed improvements (#2246)
* Don't inline VCD dump functions

Improves model speed with tracing. Measured on SweRW cmark:
- GCC 5.5      ~3% faster
- Clang 6.0    ~12% faster (!)

* Remove redundant test from VCD bit tracing.

Improves model speed with tracing. Measured on SweRW cmark:
 - GCC 5.5      ~7.5% faster
 - Clang 6.0    ~1.5% faster
2020-04-09 08:19:26 -04:00
Geza Lore 0f617988d4 Compile fast tracing code with OPT_FAST in single compile mode. (#2245)
When using the __ALL*.cpp based single compile mode (i.e.: without
VM_PARALLEL_BUILDS), the fast path tracing code used to be included in
__Allsup.cpp, which was compiled with OPT_SLOW, severely harming tracing
performance. We now have __ALLfast.cpp and __ALLslow.cpp instead of
__ALLcls.cpp and __ALLsup.cpp, so we can compile the fast support code
with OPT_FAST as well.
2020-04-08 21:05:43 -04:00
Wilson Snyder 1e0b37f4bc Commentary 2020-04-08 17:55:12 -04:00
Geza Lore 991d8b178b Fix FST tracing performance by removing std::map from hot path. (#2244)
This patch eliminates a major piece of inefficiency in FST tracing
support, by using an array to lookup fstHandle values corresponding
to trace codes, instead of a tree based std::map. With this change, FST
tracing is now only about 3x slower than VCD tracing. We do require
more memory to store the symbol lookup table, but the size of that is
still small, for the speed benefit.
2020-04-08 17:54:35 -04:00
Wilson Snyder 608d5a87d1 tests: Avoid assuming a timescale. 2020-04-07 20:55:47 -04:00
Wilson Snyder 914a6edd33 Add error if use SystemC 2.2 and earlier (pre-2011) as is deprecated. 2020-04-07 19:58:17 -04:00
Geza Lore 0cfa828572 Fix DPI import/export to be standard compliant, #2236. 2020-04-07 19:07:47 -04:00
Wilson Snyder 4556b6c022 Fix clang warning. 2020-04-07 12:17:48 -04:00
Wilson Snyder cba05480ba Fix clang warning. 2020-04-06 20:13:24 -04:00
Wilson Snyder 2abbae8dd0 Internals: Remove strncpy to appease codacity. 2020-04-06 19:26:31 -04:00
Wilson Snyder f13bd1aec4 Fix clang unused warning. 2020-04-06 08:53:19 -04:00
Wilson Snyder b6c21ad21a Fix duplicate traces with $dumpfile, part of #2237. 2020-04-06 08:33:51 -04:00
Wilson Snyder 26301a4133 Commentary 2020-04-06 08:19:32 -04:00
Wilson Snyder 383f9832d4 Tests: Standardize verilog indentation. 2020-04-05 21:53:24 -04:00
Wilson Snyder 50535a1894 Internals: cppcheck 1.90 fixes. No functional change intended. 2020-04-05 18:57:47 -04:00
Wilson Snyder ff31abe341 Commenary 2020-04-05 17:01:33 -04:00
Wilson Snyder 763f621d4c Deprecate VL_ULL. 2020-04-05 16:45:53 -04:00
Wilson Snyder d922cae0a2 Commentary 2020-04-05 16:13:41 -04:00
Wilson Snyder efaf375887 Configuring with ccache present now defaults to using it; see OBJCACHE in the manual. 2020-04-05 16:10:33 -04:00
Wilson Snyder 5932eae32a Commentary 2020-04-05 16:09:18 -04:00
Wilson Snyder a331397954 Fix real conversion from constant with X/Z. 2020-04-05 11:56:15 -04:00
Wilson Snyder a494ad5ec7 Support $ferror, #1638. 2020-04-05 11:22:05 -04:00
Wilson Snyder b617cd5549 Internals: Add V3ERROR_NA_RETURN. No functional change. 2020-04-05 10:26:53 -04:00
Wilson Snyder e55338f927 Support $fflush without arguments, #1638. 2020-04-05 10:11:28 -04:00
Wilson Snyder 6eadb8e771 Add simplistic class support with many restrictions, see manual, #377. 2020-04-05 09:30:23 -04:00
Wilson Snyder f6048cc9c1 Fix clang warning. No functional change. 2020-04-05 08:22:51 -04:00
Wilson Snyder 9fdb026e95 Add VM_C11 for future need of C++11 2020-04-04 20:48:03 -04:00
Wilson Snyder bf17bb4648 Fix codacity warnings 2020-04-04 20:08:58 -04:00
Veripool API Bot 4dc1f40856 Update contributors for codacity 2020-04-04 18:02:23 -04:00
Wilson Snyder 5302a9d0e6 Internals: clang-format cleanups. No functional change. 2020-04-04 17:55:37 -04:00
Wilson Snyder e07e9390f6 Internals: clang-format cleanups. No functional change. 2020-04-04 14:09:21 -04:00
Wilson Snyder a13eab55f5 Internals: Add missing VL_DO_CLEARs. No functional change. 2020-04-04 13:06:31 -04:00
Wilson Snyder b2228afd1a devel release 2020-04-04 08:50:56 -04:00
Wilson Snyder d3797ade95 Version bump 2020-04-04 08:40:47 -04:00
Wilson Snyder 19b472cf0b Internals: Cleanup unused nodep in visitors. No functional change intended. 2020-04-04 08:31:14 -04:00
Wilson Snyder 38a31ae168 Cleanup misc clang-tidy warnings. No functional change intended 2020-04-03 22:31:54 -04:00
Wilson Snyder 27516b565d Commentary 2020-04-03 20:08:24 -04:00
Wilson Snyder c288a7bfb9 Add GCC10-style line number prefix when showing source text for errors. 2020-04-03 20:07:46 -04:00
Maciej Sobkowski b44cd57866 Add myself to CONTRIBUTORS, #2223 2020-04-03 18:06:48 -04:00
Wilson Snyder b88a7f5152 Commentary - sort names. 2020-04-03 17:59:19 -04:00
Marco Widmer 7f9aa057bf Support split_var in vit files (#2219) 2020-04-03 08:08:23 -04:00
Marco Widmer 305b4f3c75 Fix configuration file documentation (#2221) 2020-04-02 17:32:06 -04:00
Wilson Snyder 6f4a8fe695 Fix Travis-CI failures. 2020-04-02 09:22:10 -04:00
Wilson Snyder 8aec436b5e Commentary 2020-04-02 08:26:06 -04:00
Wilson Snyder aef2b7ea3c Internals: clang-format cleanup. No functional change. 2020-04-02 08:25:44 -04:00
Wilson Snyder dcde026bac With --Wpedantic, report forward typedefs that are unused. 2020-04-02 07:39:14 -04:00
Wilson Snyder 926209706f Report REALCVT on $display format mistakes. 2020-04-01 20:42:47 -04:00
Wilson Snyder bd5d4c61c6 Suppress REALCVT for small whole real numbers. 2020-04-01 19:24:07 -04:00
Wilson Snyder 19abce5535 Suppress REALCVT for whole real numbers. 2020-04-01 18:43:53 -04:00
Wilson Snyder ab058c85bf Fix clang warning. 2020-04-01 12:40:49 -04:00
Wilson Snyder 4361c4b57a Add vlsint8_t types. 2020-03-31 21:30:18 -04:00
Wilson Snyder e6beab4037 Fix implicit conversion of floats to wide integers. 2020-03-31 20:42:07 -04:00
Wilson Snyder ebeb645539 Commentary 2020-03-30 20:09:55 -04:00
Wilson Snyder 5c72f01598 Fix assertions with unique case inside, #2199. 2020-03-30 18:13:51 -04:00
Wilson Snyder 0cf44a9c4f Internals: Refactor InsideRange common code. No functional change intended. 2020-03-30 18:12:50 -04:00
Sean Cross 1fe5d5db79 Fix mingw build (#2215)
* v3Os: include <windows.h> instead of <winnt.h>

The windows.h header file should be included prior to any other headers,
in order to ensure all definitions are available.  By only including
some headers, such as winnt.h, many "undefined symbol" messages are
generated.

Include "windows.h" to fix the build on msys2 under mingw64.

Signed-off-by: Sean Cross <[email protected]>

* configure: check for bcrypt and psapi on windows

These two libraries must be linked in order to have access to
BCryptGenRandom and GetProcessMemoryInfo respectively.

Signed-off-by: Sean Cross <[email protected]>
2020-03-29 12:29:40 -04:00
Sean Cross a1a2650f1e Modernize va args (#2214)
Verilator uses a form of variadic macros that are nonstandard, making it
unable to be compiled under MSVC.  Replace the old synax with the
standard syntax.  This fixes MSVC usage.

Signed-off-by: Sean Cross <[email protected]>
2020-03-29 10:29:12 -04:00
Wilson Snyder 07d00f26aa Fix docker exit status when Verilator fails, #2153. 2020-03-28 19:15:06 -04:00
Wilson Snyder 8d3d185e3b Fix docker exit status when Verilator fails, #2153. 2020-03-28 17:25:20 -04:00
Wilson Snyder 81a63b0c7d Commentary 2020-03-28 17:18:12 -04:00
Matthew Ballance 510be53521 Expose VPI cbNextDeadline via the public API (#2212)
Signed-off-by: Matthew Ballance <[email protected]>
2020-03-28 13:47:21 -04:00
Wilson Snyder 4145a38c47 Fix duplicate typedefs in generate for, #2205. 2020-03-26 18:10:20 -04:00
Wilson Snyder 590b1853d0 Fix packages as enum base types, #2202. 2020-03-24 17:57:12 -04:00
Wilson Snyder 08a51e3e09 Fix VCD open with empty filename, #2198. 2020-03-24 17:32:47 -04:00
Wilson Snyder 75ebe7a4be Update gtkwave from upstream. 2020-03-21 21:45:57 -04:00
Wilson Snyder 1e0e51edd3 Fix parameter type redeclaring a type, #2195. 2020-03-21 12:13:55 -04:00
Wilson Snyder 0ca07e4d58 Tests: Remove t_emit_memb_limit/vltmt as slow 2020-03-21 12:08:38 -04:00
Wilson Snyder 1ce360ed5b Add SPDX license identifiers. No functional change. 2020-03-21 11:24:24 -04:00
Wilson Snyder 172583eb03 Commentary - fix error regexp, #2191. 2020-03-17 15:39:50 -04:00
Wilson Snyder c2b49f0174 Internals: clang-format cleanups. No functional change. 2020-03-15 23:20:33 -04:00
Wilson Snyder 92d62a6568 Internals: clang-format cleanups for V3Inline. No functional change. 2020-03-15 22:30:20 -04:00
Wilson Snyder 5d9d1cc09f Internals: Favor const_iterator (in a few obvious spots, more needed). No functional change. 2020-03-15 18:34:09 -04:00
Wilson Snyder 57068b95ef Internals: Move code, no functional change. 2020-03-15 13:39:36 -04:00
Wilson Snyder 5f63b24c50 Change --quiet-exit to also suppress 'Exiting due to N errors'. 2020-03-15 08:09:51 -04:00
Wilson Snyder 81c659957e Add column numbers to errors and warnings. 2020-03-14 22:02:42 -04:00
Wilson Snyder ee8dd32c04 Check and document error format, #2191. 2020-03-14 21:48:26 -04:00
Wilson Snyder 0a755e6ecf Tests: Favor use of expect_filename. No functional change. 2020-03-14 17:42:15 -04:00
Wilson Snyder e6c91f59ab Tests: Allow --numsets 2/2 2020-03-09 17:57:27 -04:00
Wilson Snyder 9f947bcb5f Internals: Refactor flags in V3Undriven. No functional change intended. 2020-03-08 21:37:07 -04:00
Wilson Snyder 135ccf6595 Tests: Fix ormux on travis. 2020-03-08 09:48:13 -04:00
Wilson Snyder 9a2a3f8db7 Tests: Add t_gate_ormux, #2186, #2187. 2020-03-08 09:18:12 -04:00
Wilson Snyder 8ccc17f30b Add setting VM_PARALLEL_BUILDS=1 when using --output-split, #2185. 2020-03-08 09:03:29 -04:00
Wilson Snyder 9392eac6a7 devel release 2020-03-08 08:40:33 -04:00
Wilson Snyder 95c4b6aaba Version bump 2020-03-08 08:38:53 -04:00
Wilson Snyder 1c1319079b Tests: Add driver --hashset for Travis. 2020-03-07 22:02:03 -05:00
Wilson Snyder 328fef8190 Tests: Add driver --hashset for Travis. 2020-03-07 21:38:44 -05:00
Wilson Snyder e2dec043a0 Tests: Backout part of previous commit. 2020-03-07 21:01:36 -05:00
Wilson Snyder bd42e31b2a Tests: For travis, skip Bit::Vector and show intall dates. 2020-03-07 20:08:41 -05:00
Wilson Snyder 6d73237b27 Travis: Don't cpan test to save time. 2020-03-07 19:24:05 -05:00
Wilson Snyder 6c6d70a5e5 Fix FST when multi-model tracing. 2020-03-07 18:39:58 -05:00
Wilson Snyder 6f49f802b1 Tests: Add fst_identical. 2020-03-07 16:59:46 -05:00
Wilson Snyder 808c958d42 Internals: Add AstNodeCCall and other items towards classes. 2020-03-07 12:52:11 -05:00
Wilson Snyder 961ac49c5c Internals: Merge parse type from classes branch. No functional change intended. 2020-03-07 11:00:57 -05:00
Wilson Snyder 2d52f525c5 Add --structs-packed for forward compatibility, #1541. 2020-03-07 10:51:06 -05:00
Wilson Snyder e70cba77e6 Add support for dynamic arrays, #379. 2020-03-07 10:24:27 -05:00
Wilson Snyder 8054fc47ea Internals: Refectoring. No functional change intended. 2020-03-07 08:24:57 -05:00
Wilson Snyder e673875b3b Fix clang warning, last commit. 2020-03-06 07:31:56 -05:00
Wilson Snyder 29923b78fd Internals: Use VL_TO_STRING instead of to_string. 2020-03-05 23:28:41 -05:00
Wilson Snyder 135cbcd79a Internals: Move 'new' unsupported forward from parse into Ast. 2020-03-05 22:33:31 -05:00
Wilson Snyder 75ecad591a Implement $displayb/o/h, $writeb/o/h, etc, Closes #1637. 2020-03-05 21:49:25 -05:00
Wilson Snyder c108f5def9 Commentary, Closes #2177. 2020-03-05 19:09:58 -05:00
Wilson Snyder dab1cb610a Tests: Allow iv to run SystemVerilog tests 2020-03-05 18:12:10 -05:00
Wilson Snyder fd656f6cc1 Fix clang asserted missing lock on m_dumping. 2020-03-03 19:20:04 -05:00
Wilson Snyder a7e65379fa Ignore $dumpflush, think causes travis thread error. 2020-03-02 17:56:42 -05:00
Wilson Snyder 905067d13f Fix $dumpvar multithreaded assert, broke last commit. 2020-03-02 07:43:10 -05:00
Wilson Snyder 30a33a6104 Add support for and , #2126. 2020-03-01 21:39:23 -05:00
Wilson Snyder 0ca0e07354 Internals: Vcd doesn't need code when registering. No functional change intended. 2020-02-29 20:42:52 -05:00
Wilson Snyder aac02acf92 Tests: Rename 2020-02-29 10:06:52 -05:00
Wilson Snyder 082c9e0b1d Tests: Add two-design trace tests. 2020-02-29 09:44:51 -05:00
Wilson Snyder a7bd934fe3 Tests: Cleanup false used as 0. No functional change. 2020-02-29 08:56:49 -05:00
David Stanford e98a380b44 Tests: Update some tests to skip if prerequisites aren't installed (#2181) 2020-02-29 07:20:23 -05:00
Wilson Snyder 4878fe3a1f Add split_var metacomment to assist UNOPTFLAT fixes, #2066. 2020-02-28 19:15:08 -05:00
Wilson Snyder c6b755a12e Commentary 2020-02-27 19:35:49 -05:00
Wilson Snyder 991d81cd0a Recommend -Os. 2020-02-27 07:46:34 -05:00
Wilson Snyder c06a97a221 Remove OBJCACHE_HOSTS; dead code. 2020-02-27 07:18:15 -05:00
Wilson Snyder 6131bcdbb0 Verilator_gantt: Fix CPU count in report. 2020-02-27 07:12:50 -05:00
Wilson Snyder 68b6a0b667 Fix genblk naming with directly nested generate blocks, #2176. 2020-02-25 22:21:16 -05:00
Wilson Snyder 4c438bbc67 Commentary 2020-02-25 19:01:14 -05:00
Wilson Snyder 5b83484f20 Remove dead genblk code & some cleanups. 2020-02-25 18:57:51 -05:00
Wilson Snyder 93ac79981b Tests: Rename t_var_dotted. No functional change. 2020-02-24 18:51:44 -05:00
Wilson Snyder c9b74847d1 Docs: Tighter margins, save 10 pages. 2020-02-24 18:11:56 -05:00
Wilson Snyder 23eb96579c Fix duplicate __STDC_FORMAT_MACROS definition. 2020-02-24 18:11:41 -05:00
Todd Strader 8319ea6c73 Changes 2020-02-24 06:36:13 -05:00
Todd Strader 60f82961b4 De-tabify 2020-02-24 06:36:13 -05:00
Todd Strader f7d1c6ca72 emacs verilog-batch-indent 2020-02-24 06:36:13 -05:00
Todd Strader 4b4f10f5e6 Follow other clock gating examples 2020-02-24 06:36:13 -05:00
Todd Strader 120f62fe85 Fix is probably to mark as a clock 2020-02-24 06:36:13 -05:00
Todd Strader db6ecbd57e Test for #2169 2020-02-24 06:36:13 -05:00
Wilson Snyder 28e19cef90 Fix undeclared VL_SHIFTR_WWQ, #2114. 2020-02-23 19:33:37 -05:00
Tobias Wölfel 18f8cd0529 Allow assert disable (#2168)
* Add +verilator+noassert flag

This allows to disable the assert check per simulation argument.

* Add AssertOn check for assert

Insert the check AssertOn to allow disabling of asserts.
Asserts can be disabled by not using the `--assert` flag or by calling
`AssertOn(false)`, or passing the "+verilator+noassert" runtime flag.
Add tests for this behavior.
Bad tests check that the assert still causes a stop.
Non bad tests check that asserts are properly disabled and cause no stop
of the simulation.

Fixes #2162.

Signed-off-by: Tobias Wölfel <[email protected]>

* Correct file location

Signed-off-by: Tobias Wölfel <[email protected]>

* Add description for single test execution

Without this description it is not obvious how to run a single test from
the regression test suite.

Signed-off-by: Tobias Wölfel <[email protected]>
2020-02-15 18:17:23 -06:00
Wilson Snyder 02786b3f09 Commentary 2020-02-12 22:46:59 -05:00
Wilson Snyder 70358e8587 Fix compiler warning. 2020-02-08 10:58:07 -05:00
Wilson Snyder 95b66feeb8 devel release 2020-02-08 09:16:35 -05:00
Wilson Snyder 890cecc15b Version bump 2020-02-08 09:03:51 -05:00
Wilson Snyder f7bad37e88 Fix GCC 4.4.7 errors. 2020-02-08 07:09:41 -05:00
Wilson Snyder 134b5efd70 Tests: Ignore obj_iv. 2020-02-07 18:00:07 -05:00
Wilson Snyder 0d6ebf21b3 Suggest svSetScope, #2152. 2020-02-07 17:59:02 -05:00
Wilson Snyder 2d1b804e80 Fix OpenSolaris issues, #2154. 2020-02-07 17:35:04 -05:00
Todd Strader 77f1b3eef4 Support parameter access from arrays of interfaces, #2155. 2020-02-06 19:19:23 -05:00
Wilson Snyder 609a5dc26d Fix cppcheck warnings. No functional change intended. 2020-02-03 23:21:56 -05:00
Wilson Snyder 0aabe6ce00 Internals: Fix cppcheck warning including missing init. 2020-02-03 22:10:29 -05:00
Wilson Snyder 20cc4e57d5 tests: Driver style fix. 2020-02-03 18:43:56 -05:00
Wilson Snyder f3ebdc40c6 Fix some coverage lost when multithreaded, #2151. 2020-02-03 18:43:41 -05:00
Wilson Snyder 2ca9f73b31 Internals: Cleanup Emit towards constructor/destructor output. 2020-02-02 21:15:07 -05:00
Wilson Snyder 73f5e3f808 Internals: Add missing const. No functional change. 2020-02-02 10:34:29 -05:00
Wilson Snyder 8d3dad510f Fix unused variable. 2020-02-02 06:52:28 -05:00
Wilson Snyder 2576c136f6 Fix `pragma pedantic check to work with -E. 2020-02-01 22:03:18 -05:00
Wilson Snyder a8ad97eef2 Add VL_CACHE_LINE_BYTES and use 64 as defult. 2020-02-01 20:28:03 -05:00
Wilson Snyder ee7da1e690 Remove .h comments for empty sections. 2020-02-01 20:11:21 -05:00
Wilson Snyder 969a46faf6 Internals: V3Emit refactoring. No functional change intended. 2020-02-01 19:32:04 -05:00
Wilson Snyder 820df28ad9 Internals: V3CUse state refactoring. No functional change intended. 2020-02-01 19:11:19 -05:00
Yutetsu TAKATSUKASA 50fb7fc8b4 Tests: Resolve self assignment in t_unoptflat_simple_2, Closes #2149. 2020-02-01 19:07:02 -05:00
Wilson Snyder 119162912a Internals: Determine emit forward declaraions in new pass, towards classes. 2020-02-01 16:51:05 -05:00
Wilson Snyder 80d94891e1 Internals: Allow const & non-member CFuncs for class branch. No functional change. 2020-02-01 10:57:55 -05:00
Geza Lore f00ff61559 Link Verilator binary partially statically, Closes #2146.
The build is now by default configured to link performance critical
libraries (libgcc, libstdc++, libtcmalloc) statically. This improves
Verilation speed by between 4.5-7% based on my measurements as it
eliminates approx 20% of the mispredicted branches from the execution.
With partial static linking, the size of the .text section in
verilator_bin is increased by about 14%, and the binary is itself only
about 800KB bigger on disk, so hopefully this is not a big issue in
exchange for the faster compilation speed. A configure option
"--disable-partial-static" is provided to restore the old behaviour of
linking everything dynamically.

Note: This patch also changes to use libtcmalloc_minimal, which is all
we really need and itself has fewer dependencies.
2020-01-31 19:13:55 -05:00
Wilson Snyder 2d195ebae5 Cleanup IEEE references. 2020-01-30 20:23:57 -05:00
Wilson Snyder 9a6bc3ddcf Commentary 2020-01-30 19:52:58 -05:00
Wilson Snyder d218f1746c Add warning on genvar in normal for loop, #2143. 2020-01-29 21:16:44 -05:00
Yutetsu TAKATSUKASA 8d8eb1b9f3 Tests: Resolve racing among initial blocks in t_display_signed.v, #2144. 2020-01-29 17:07:45 -05:00
Wilson Snyder d4614c290e Fix WIDTH warning on </<= of narrower value, #2141. 2020-01-28 20:10:10 -05:00
Tobias Rosenkranz 027cce35c0 Support enum.next(k) with constant k > 1, #2125. 2020-01-27 17:25:25 -05:00
Wilson Snyder 9fd81b2c6b Support string character access via indexing. 2020-01-26 16:38:22 -05:00
Wilson Snyder 5430e4ac9b Cleanup more errors showing data types. 2020-01-26 15:54:57 -05:00
Wilson Snyder 619214b48f Support $sampled. 2020-01-26 13:38:15 -05:00
Wilson Snyder 68fa82fb14 Support $typename, and use to cleanup error messages. 2020-01-26 13:21:25 -05:00
Wilson Snyder cac50282eb Fix pattern replication without key. 2020-01-26 11:38:34 -05:00
Wilson Snyder b50ef9ff39 Tests: Disabled test for 5.9. 2020-01-26 11:23:52 -05:00
Wilson Snyder 8a8f1135b7 Support type(expression) operator, #1650. 2020-01-26 10:28:13 -05:00
Wilson Snyder f0b2336345 Internals: Fix cell recursion with future module-in-module. 2020-01-25 18:15:55 -05:00
Wilson Snyder 52907e7b02 astgen: Preserve #line, #2138. 2020-01-25 15:36:37 -05:00
Geza Lore ef5250f0ca Internals: Further performance improvement of AstNode type tests, #2138. No functional change intended.
Replace the virtual type() method on AstNode with a non-virtual, inlined
accessor to a const member variable m_type.  This means that in order to be
able to use this for type testing, it needs to be initialized based on the
final type of the node. This is achieved by passing the relevant AstType
value back through the constructor call chain. Most of the boilerplate
involved is auto generated by first feeding V3AstNodes.h through astgen to
get V3AstNodes__gen.h, which is then included in V3Ast.h. No client code
needs to be aware and there is no functional change intended.

Eliminating the virtual function call to fetch the node type identifier
results in measured compilation speed improvement of 5-10% as it
eliminates up to 20% of all mispredicted branches from the execution.
2020-01-25 15:29:44 -05:00
Wilson Snyder eafed88a6e Internals: Add assertions. No functional change intended. 2020-01-25 10:19:59 -05:00
Wilson Snyder d64e6b3f9c Internals: Refactoring towards classes. No functional change intended. 2020-01-25 09:33:43 -05:00
Wilson Snyder d68ffba8cd Internals: Rename to prefixNameProtect. No functional change intended. 2020-01-25 09:16:00 -05:00
Wilson Snyder f0f370490f Internals: Style cleanups. 2020-01-25 07:59:25 -05:00
Wilson Snyder 708fd36563 Tests: Show entering/exit so goto-error works on compile errors. 2020-01-24 22:40:19 -05:00
Wilson Snyder a4e8d39932 Spelling fixes 2020-01-24 20:10:44 -05:00
Wilson Snyder 8f0e8e0696 Fix FST tracing of enums inside structs. 2020-01-24 19:46:46 -05:00
Wilson Snyder 11380bc3b2 Merge from upstream gtkwave includes. 2020-01-23 17:48:27 -05:00
Geza Lore 7ab2bdb6bb Support libgoogle-perftools-dev's libtcmalloc if available. #2137.
As Verilator continuously allocates and releases small objects (e.g.:
AstNode, V3GraphVertex, V3GraphEdge), it spends a significant amount of
time in malloc/free and friends. This patch adds the --enable-tcmalloc
configure option to link Verilator against the high performance malloc
implementation library libtcmalloc. The default is to use libtcmalloc if
available on the system. Note that there are no source code change, we
are simply replacing the standard library memory allocation functions.

Measured major compilation speed improvement of 27% when running
Verilator with -O3 on a large design.
2020-01-23 17:32:19 -05:00
Pieter Kapsenberg 5d037c3c8c Docs: Add initial XML dovcument description. #2136. 2020-01-23 07:26:11 -05:00
Geza Lore c5d04631d1 Internals: More performance efficient AstNode casting. Closes #2133.
dynamic_cast can have large run-time cost, so here we implement type
tests for AstNode instances by checking the unique type() property, which
in turn is a constant generated by astgen. For leaf types in the AstNode
type hierarchy, this is a simple equality check. To handle intermediate
types, we generate the type ids of leaf types in a pre-order traversal of
the type hierarchy. This yields contiguous ranges of ids for sub-type
trees, which means we can check membership of a non-leaf type via 2
comparisons against a low and high id. This single patch makes Verilator
itself 6-13% faster (depending on which optimizations are enabled) on a
large design of over 250k lines of Verilog.
2020-01-22 19:07:48 -05:00
Pieter Kapsenberg 957c1d606b Add detailed XML location to cell elements, #2134, #2122.
This was accidentally omitted from the previous PR #2122.
2020-01-22 07:18:50 -05:00
Wilson Snyder 48dd358c03 Fix clang warnings from override. 2020-01-21 20:22:32 -05:00
Geza Lore 220daa5f33 Internals: Restore AstNode naming property. #2133.
The intention was that all subclasses of AstNode which are
intermediate must be abstract as well and called AstNode*. This was
violated recently by 28b9db1903. This
patch restores that property by:
- Renaming AstFile to AstNodeFile
- Introducing AstNodeSimpleText as the common base of AstText and
  AstTextBlock, rather than AstTextBlock deriving from AstText.
2020-01-21 19:54:14 -05:00
Wilson Snyder d76b5b7823 Fix C++11 intrusion. 2020-01-21 19:45:44 -05:00
Wilson Snyder 4266d31443 Internals: Add VL_OVERRIDE to includes. No functional change intended. 2020-01-21 18:02:23 -05:00
Yutetsu TAKATSUKASA fbdf5f2dad Internals: Mark all visit() with VL_OVERRIDE. Closes #2132.
* Add VL_OVERRIDE macro so that compiler can tell my typo when trying to override a function.

* Mark visit() with VL_OVERRIDE. No functional change intended.
2020-01-21 17:35:56 -05:00
Stefan Wallentowitz 8e26bdd098 Fix vpi scope naming (#2130)
Dedot and shorten the name so that public modules and interface cells
are accessible too via VPI.

Fixes #2109
2020-01-21 17:03:21 +01:00
Stefan Wallentowitz 22088c907f Set maximum number width (#2128)
Adjust the maximum number width to 64K. Add --max-num-width option to
adjust this setting.

Closes #2082
2020-01-21 12:17:31 +01:00
Matthew Ballance d87648c258 Correct FST-support issue with some GCC versions. Closes #2129. 2020-01-20 17:33:40 -05:00
Wilson Snyder abf3850d08 Internals: Misc cleanups for classes. 2020-01-20 16:53:27 -05:00
Pieter Kapsenberg 4a122fd0f2 Add detailed location to XML output (#2122)
* Add detailed location to XML output

* Fixing build failures

* less cryptic regulary expressions

* correcting typo in test

* Adding file letter to the location attribute, and cleaning up the regular expression in the tests.

* Add remaining test expected output files for XML changes

* spacing fix, adding documentation on changes
2020-01-20 14:08:13 -05:00
Wilson Snyder 0352ceea44 Internals: Refactor some emit code towards classes. No functional change intended. 2020-01-20 14:07:03 -05:00
Wilson Snyder e8ff191a17 Internals: Prepare for hierarchical NodeModule's. No functional change intended. 2020-01-20 13:27:27 -05:00
Wilson Snyder 5ae09daf5b Internals: Style cleanup. No functional change. 2020-01-20 11:56:08 -05:00
Wilson Snyder 1acff950d0 Commentary: Add deprecations section to docs. Closes #2081. 2020-01-20 10:06:45 -05:00
Stefan Wallentowitz f28d837930 Docker: Tag stable as latest (#2098) 2020-01-20 15:53:26 +01:00
Pieter Kapsenberg 1dd9a74b6c Internals: Move V3Global function definitions to their own files. No functional change intended. Closes #2120. 2020-01-19 07:23:26 -05:00
Pieter Kapsenberg 165833a97c Add compile_commands.json to .gitignore (#2119)
When running make with the "bear" command, the generated
compile_commands.json file shouldn't be considered new source. This file
allows clangd-based code completion tools (e.g. YouCompleteMe) to know
the flags that each file was compiled with.
2020-01-18 22:44:03 -05:00
Wilson Snyder 18e837336a Internals: Rename MethodCall. No functional change. 2020-01-18 14:11:05 -05:00
Wilson Snyder 835f668aaa Internals: Refactor statement tracking. No functional change intended. 2020-01-18 13:02:42 -05:00
Wilson Snyder 09199f79a6 Internals: Add VL_DO_CLEAR delete protections. No functional change intended. 2020-01-18 10:29:49 -05:00
Wilson Snyder 2f4954ca68 Commentary 2020-01-18 09:18:57 -05:00
Wilson Snyder 7024ea8cb6 Cleaner tristate error. #2117. 2020-01-18 07:56:50 -05:00
Wilson Snyder 623c4ec103 Internals: Create VL_DO_DANGLING. No functional change intended. 2020-01-16 20:17:11 -05:00
Wilson Snyder 023526ad4b Internals: Minor refactoring from class branch. 2020-01-15 20:18:12 -05:00
Wilson Snyder e2ba1c041f Commentary 2020-01-15 20:09:19 -05:00
Tobias Rosenkranz b41b9417b9 Fix sign compare warning. Closes #2112. 2020-01-15 07:40:22 -05:00
Pieter Kapsenberg 4443ab34fd Support left justified . Closes #2101. 2020-01-15 07:32:45 -05:00
Wilson Snyder e9a309ea8d Clang warning fix. 2020-01-15 07:27:04 -05:00
Wilson Snyder 81e8127168 Add parameter values in XML. #2110. 2020-01-14 18:51:20 -05:00
Wilson Snyder 47803c3591 Tests: Better message for contributors. 2020-01-14 17:49:04 -05:00
Wilson Snyder af38e8d387 Improve error on > 127 char modnames. #2106. 2020-01-14 07:33:12 -05:00
Wilson Snyder 67bb0c78c8 Codacity fix. 2020-01-14 07:13:35 -05:00
Wilson Snyder 918df2e618 Support / with assoc arrarys. Closes #2100. 2020-01-14 07:01:17 -05:00
Wilson Snyder 7bed17b14b Fix clang warning 2020-01-13 19:01:30 -05:00
Stefan Wallentowitz fad465abf1 Add lint_off -match waivers (#2102)
* Add more directives to configuration files

Allow to set the same directives in configuration files that can also
be set by comment attributes (such as /* verilator public */ etc).

* Add support for lint messsage waivers

Add configuration file switch '-match' for lint_off. It takes a string
with wildcards allowed and warnings will be matched against it (if
rule and file also match). If it matches, the warning is waived.

Fixes #1649 and #1514 
Closes #2072
2020-01-12 10:03:17 +01:00
Wilson Snyder 98fb7ec193 Commentary. 2020-01-11 21:08:20 -05:00
Wilson Snyder b71eb76252 For / allow 64-bit addressing. 2020-01-11 14:08:07 -05:00
Wilson Snyder 1d2a7b2f41 Style cleanups. No functional change. 2020-01-11 12:36:30 -05:00
Wilson Snyder cd38e88fb8 For travis, add VERILATOR_AUTHOR_SITE to get -Werror. Closes #2099. 2020-01-11 10:52:13 -05:00
Todd Strader a15aa0b82b Fix clang warning 2020-01-11 09:59:42 -05:00
Wilson Snyder fe94f9891b Add error on misused define. 2020-01-11 09:16:26 -05:00
Wilson Snyder fe9cf9bd42 devel release 2020-01-11 09:08:33 -05:00
Wilson Snyder 0c99bee4b1 Version bump 2020-01-11 06:54:36 -05:00
Wilson Snyder f66dacd185 Remove some make clean files. 2020-01-11 06:53:52 -05:00
Wilson Snyder 5f9ceb99a7 Cleanup spacing. 2020-01-10 21:37:53 -05:00
Wilson Snyder 2638f9db19 Error cleanups. 2020-01-10 19:18:27 -05:00
Wilson Snyder 8859cbf5bc Commentary 2020-01-10 19:12:45 -05:00
Wilson Snyder 16bb97687a Tests: Check for missing newlines at EOF. 2020-01-10 18:49:23 -05:00
Wilson Snyder 1234c83953 Fix some C++11 requirements. 2020-01-10 07:07:21 -05:00
Wilson Snyder 2982336ec2 Commentary 2020-01-09 20:29:36 -05:00
Wilson Snyder ca211c3b11 Commentary - Codacy badge fix. 2020-01-09 20:28:33 -05:00
Wilson Snyder 87d126de49 Commentary 2020-01-09 20:09:50 -05:00
Philipp Wagner 4a307742c4 Fix typo in help output (#2096)
The variable is named VM_PARALLEL_BUILDS, not VM_PARALLEL_BUILD.

Signed-off-by: Philipp Wagner <[email protected]>
2020-01-09 20:07:08 -05:00
Wilson Snyder a2911ed933 Fix shebang breaking some shells. Closes #2067. 2020-01-09 20:01:12 -05:00
Wilson Snyder 2a50fafef2 Fix %{number}s with strings. #2093. 2020-01-09 19:39:27 -05:00
Wilson Snyder 029ff69d30 Update .clang-format to allow 6.0.0 to work. 2020-01-09 19:39:14 -05:00
Wilson Snyder aac02c1ed1 Fix expand optimization slowing --lint-only. Closes #2091. 2020-01-09 18:04:49 -05:00
Stefan Wallentowitz 525c79bd0a Add Docker infrastructure (#2087)
This adds files to build and run two Docker images:

 - run: Build a Docker container that can be used as an executable
        drop-in for verilator. This can be useful to test behavior of
        older versions or a development version. The functionality is
        pretty simplistic at the moment for a start.

 - buildenv: Everything needed to build and test Verilator. Useful to
        run quick tests in the cloud or try other compilers. It can
        also serve as basis for further CI integration.
2020-01-09 23:22:15 +01:00
Yutetsu TAKATSUKASA b5c151863a Update .clang-format so that recent clang-format such as LLVM-8 works. (#2092)
Use C++03 because this project needs to compile with the standard.
2020-01-09 10:13:08 -05:00
Wilson Snyder 06247686c5 Codacy cleanups 2020-01-08 19:33:47 -05:00
Wilson Snyder 951a7d867a Commentary 2020-01-08 19:33:42 -05:00
Wilson Snyder 9978cbfa5c Fix tracing -1 index arrays. Closes #2090. 2020-01-08 07:32:31 -05:00
Wilson Snyder f23fe8fd84 Update copyright year. 2020-01-06 18:05:53 -05:00
Stefan Wallentowitz 37dc33a195 Deprecation (#2088)
* Add deprecation warning

* Deprecate -msg in configuration files

* Deprecate sc_clock
2020-01-03 17:27:51 +01:00
Stefan Wallentowitz 924fe235a9 No assign alias for unpacked public variables (#2089)
Public variables are all emitted in the C code and unpacked arrays
arrays are sliced up for this. After inlining public unpacked array
assignments should not be alias assignments but actual assignments, so
that they are sliced and hence emitted properly.

Fixes #2073
2020-01-03 13:44:45 +01:00
Todd Strader 1957b1ebbd Fix permissions on build_vcddiff.sh 2020-01-02 07:40:15 -05:00
Todd Strader b70d1c1349 Update gtkwave files 2020-01-02 07:39:24 -05:00
Stefan Wallentowitz b7665a88db Rename msg to rule in configuration files (#2080)
Rename the -msg switch to -rule in configuration files as it is more
clear.

resolves #2068
2019-12-30 19:15:43 +01:00
Kuba Ober 19c8d32263 Fix SystemC link in the documentation. (#2076) 2019-12-30 18:56:51 +03:00
Stefan Wallentowitz 7b384f7eb7 XML: Add variable attributes (#2079) 2019-12-30 12:55:36 +01:00
Kuba Ober 7bbce51f7b Add include guard to V3InstrCount.h. (#2075)
This is needed for cmake unity build to work.
2019-12-30 06:04:03 +03:00
Kuba Ober ac1cdf7cdf Implement APIs missing on Windows. (#12) 2019-12-28 19:44:24 +03:00
Wilson Snyder c753904a3f Internals: Copy into parser Verilog-Perl rules as comments. No functional change. 2019-12-24 16:15:48 -05:00
Wilson Snyder 8bd43d83b1 Internals: bisonpre should ignore commented BISONPRE lines. 2019-12-24 16:15:47 -05:00
Wilson Snyder ea5b01d9f3 Internals: Rename pexpr. No functional change intended. 2019-12-24 16:04:28 -05:00
Wilson Snyder f540dead79 Internals: new() support code, and misc stuff. 2019-12-24 12:47:27 -05:00
Wilson Snyder 40a847d613 Internals: Refactor some code. No functional change intended. 2019-12-24 10:23:43 -05:00
Wilson Snyder 37b9f254a2 Internals: Add origNameProtect. No functional change intended. 2019-12-24 08:47:30 -05:00
Wilson Snyder c8daab3b46 Internals: Refactor some member handling. No functional change intended. 2019-12-23 20:48:23 -05:00
Wilson Snyder a0d391d695 Tests: Less aggressive contributors check. 2019-12-23 19:01:29 -05:00
Wilson Snyder 5089f997cc Internals: Use standard function for include guards. No functional change intended. 2019-12-23 19:00:17 -05:00
Wilson Snyder 5c59fde92e Fix codacy warning 2019-12-23 18:56:08 -05:00
Wilson Snyder 81ee4930fc Github: Update issue templates 2019-12-23 17:40:50 -05:00
Wilson Snyder 350de3719e Github: Update issue templates 2019-12-23 17:39:38 -05:00
Wilson Snyder a37a127ef1 Github: Update issue templates 2019-12-23 17:37:48 -05:00
W Snyder dc8a0dfd5a Update issue templates 2019-12-23 17:36:26 -05:00
Wilson Snyder 0ca197ec1b Github: Add issue templates 2019-12-23 17:34:53 -05:00
Wilson Snyder f23a7bfdd7 Tests: Check for carriage returns 2019-12-23 17:34:43 -05:00
Peter Monsson 9b998cf6b3 Support implication operator "|->" in assertions, #2069.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-23 16:49:18 -05:00
Wilson Snyder 0f0c3d4684 Internals: Copy into parser Verilog-Perl rules as comments. No functional change. 2019-12-23 16:27:07 -05:00
Wilson Snyder bacbb4cafd Parse join_any/join_none still as unsupported. 2019-12-23 15:19:22 -05:00
Wilson Snyder 4afde8b478 Test class parsing (intended as part of last commit). 2019-12-23 15:18:55 -05:00
Wilson Snyder 2cbfe99ad5 Parse all class constructs, as still unsupported. 2019-12-23 15:03:04 -05:00
Julien Margetts c1fb938a61 Fix huge case statement performance. Closes #1644.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-23 07:47:57 -05:00
Wilson Snyder 49db4d2b66 Internals: Trivial spacing change to force CI rebuild. No functional change. 2019-12-22 20:02:37 -05:00
Wilson Snyder b087673254 Fix output endif spacing. No functional change. 2019-12-22 18:21:43 -05:00
Wilson Snyder 5c361efaea Internals: Minor format cleanups. No functional change. 2019-12-22 18:09:46 -05:00
Peter Monsson ea979c8f83 Fix disable iff in assertions. Closes #1404.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-22 15:49:10 -05:00
Wilson Snyder 3a70bbc70c Update Changes to reflect github issue numbers. 2019-12-22 15:33:45 -05:00
Kuba Ober 3f0e2f7d9d Fix argument in AstConst.m_num.width. (#9) 2019-12-21 10:25:05 -05:00
Kuba Ober c9ca390926 Fix missing <algorithm> header. Pull (#8) 2019-12-20 20:14:52 -05:00
Kuba Ober 4a31b69f84 Decrease the number of chained if-else blocks to fix MSVC build. Pull (#7)
MSVC has a limit of 128 blocks in a chain.
2019-12-20 20:07:50 -05:00
Kuba Ober ee184f3f39 Fix strcasecmp for windows, bug1651.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-20 06:58:05 -05:00
Wilson Snyder 9807025618 Fix infinite loop on some V3Ast internal errors. 2019-12-19 20:07:48 -05:00
Stefan Wallentowitz 9a54b2144b Fix queue issues, bug1643.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-18 18:17:18 -05:00
Wilson Snyder 0465b6a3b1 Fix example makefiles, 1648. 2019-12-18 17:58:24 -05:00
Julien Margetts cafb148a62 Commentary 2019-12-17 18:27:47 -05:00
Stefan Wallentowitz d738501c01 Fix queues as statements, bug1641. 2019-12-17 06:08:41 -05:00
Wilson Snyder 53c6b7df63 Internals: Rename NodeClassDType. No functional change. 2019-12-16 22:46:09 -05:00
Wilson Snyder f514049c04 Add cleaner error on version control conflicts in sources. 2019-12-16 21:54:20 -05:00
Wilson Snyder 83a1bd0675 Support immediate cover statements & refactor coverage internals. 2019-12-16 21:44:20 -05:00
Yutetsu TAKATSUKASA 8cdc0c4e00 Support string putc, getc, substr, bug1606.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-15 08:09:52 -05:00
Wilson Snyder 460e0541f3 Add error when `resetall inside module 2019-12-14 22:04:58 -05:00
Wilson Snyder 2408de16a0 Support bounded queues. 2019-12-14 21:39:47 -05:00
Wilson Snyder 2a1c57ada6 With -Wpedentic, warn about bad `pragma 2019-12-14 10:13:38 -05:00
Wilson Snyder 7387db506d GTKWave: Merge from upstream. 2019-12-14 09:25:36 -05:00
Stefan Wallentowitz 3ac6745658 Add vpiTimeUnit and allow to specify time as string, bug1636.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-13 19:11:37 -05:00
Wilson Snyder 39950d16d0 Ignore `uselib to end-of-line, bug1634. 2019-12-12 20:57:48 -05:00
Todd Strader c62c152048 Commentary 2019-12-12 07:53:08 -05:00
Wilson Snyder 6046b06b17 Tests: Fix no-email contributors. 2019-12-11 18:56:10 -05:00
Julien Margetts f7a06cb54a Fix little endian cell ranges, bug1631.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-11 17:15:45 -05:00
Wilson Snyder 521418d832 Update FST trace API for better performance. 2019-12-10 18:55:09 -05:00
Wilson Snyder 1c643916a3 Tests: Add copy_if_golden to harness. 2019-12-10 18:53:35 -05:00
Todd Strader 9cf5acc43e Install vcddiff for Travis, bug1600. 2019-12-10 05:27:34 -05:00
Yutetsu TAKATSUKASA c2037ddbc5 Support string compare, icompare, ato* methods, bug1606.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-09 19:17:52 -05:00
Wilson Snyder ca1b083d5c Fix clang warning. 2019-12-09 18:53:56 -05:00
Wilson Snyder c896a76fef Fix clang warning. 2019-12-09 18:25:59 -05:00
Wilson Snyder bd0eadb311 Fix handling user-botch of %d to print real. 2019-12-08 22:48:44 -05:00
Wilson Snyder 62b0d15d2e Add lint check for bad enum 4-state values. 2019-12-08 22:26:54 -05:00
Wilson Snyder 700f2072c0 Framework for WDatas being vectors of 64-bit EDatas, but not supporting this at this time. 2019-12-08 21:36:38 -05:00
Wilson Snyder cda5c53cf9 Add BOUNDED warning and promote bounded queues to unbounded. 2019-12-08 15:56:49 -05:00
Wilson Snyder 3be0eea995 devel release 2019-12-08 13:50:14 -05:00
Wilson Snyder 44ce83cd8e Version bump 2019-12-08 07:58:47 -05:00
Wilson Snyder c199930943 Commentary 2019-12-08 07:34:47 -05:00
Wilson Snyder 81fc1d48a6 Fix gate lvalue optimization error, bug831. 2019-12-07 16:49:11 -05:00
Wilson Snyder f330f16bf6 Internals: Additional debug dumps. 2019-12-07 16:41:34 -05:00
Wilson Snyder 10a6b566ef Fix error on unpacked concatenations, bug1627. 2019-12-07 15:53:34 -05:00
Driss Hafdi cff5485821 Tests: Unsupported test for bug1627.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-07 13:46:50 -05:00
Driss Hafdi dcbdac1b81 Tests: Unsupported test for bug1626.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-07 13:46:29 -05:00
Driss Hafdi a59777aa75 Tests: Unsupported test for bug1624.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-07 13:15:46 -05:00
Driss Hafdi d82b9128d0 Tests: Unsupported test for bug1623.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-07 12:59:00 -05:00
Driss Hafdi ab4f18c892 Tests: Unsupported test for bug1622.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-07 12:59:00 -05:00
Todd Strader 4480938b25 Fix interface reference tracing, bug1595. 2019-12-07 12:28:19 -05:00
Driss Hafdi 11a1b201a9 Tests: Unsupported on parameters in functions, bug1624. 2019-12-06 18:51:39 -05:00
Wilson Snyder 1a8b192e40 Unsupported on parameters in functions, bug1624. 2019-12-06 18:50:41 -05:00
Driss Hafdi aee3a32354 Added name to Contributors 2019-12-06 18:49:54 -05:00
Wilson Snyder 35e9489f33 Includes: Allow VCD trace of 64 bit array. 2019-12-05 22:25:30 -05:00
Wilson Snyder 5c6d74cd80 Fix assertion on dotted parameter arrayed function, bug1620. 2019-12-04 19:25:45 -05:00
Wilson Snyder 8611ff230d GTKWave: Merge from upstream. No functional change. 2019-12-04 05:31:38 -05:00
Wilson Snyder 8ef4097f00 Fix cppcheck warning. 2019-12-03 19:21:36 -05:00
Wilson Snyder fe684e8733 Allow redefining VL_PRINTF, bug1598. 2019-12-03 19:12:18 -05:00
Garrett Smith 96f8bbd023 Support float and shorts, bug1592, bug1619.
Signed-off-by: Wilson Snyder <[email protected]>
2019-12-03 18:26:22 -05:00
Wilson Snyder 95ffcad12e Fix t_queue crash on Trusty due to lifetime issue. 2019-12-03 07:18:59 -05:00
Wilson Snyder ebed1a9000 Fix 64-bit signed power with -1. 2019-12-03 06:58:38 -05:00
Wilson Snyder 2240f42bfa Fix 64-bit signed power with -1. 2019-12-03 06:26:17 -05:00
Wilson Snyder ac4f0da9ee Tests: Add output wire check. 2019-12-02 20:38:43 -05:00
Wilson Snyder 559852f60b Add error when number missing value. 2019-12-02 20:21:24 -05:00
Wilson Snyder b0669f3aca Fix false unused message on __Vemumtab, msg3180. 2019-12-02 19:03:33 -05:00
Todd Strader 00979ede14 Fix overly aggressive --protect-lib check 2019-12-02 08:33:44 -05:00
Todd Strader 13569ed98b Stop-gap CI email fix 2019-12-02 08:18:15 -05:00
Wilson Snyder 809a6de9cd Fix template brackets to avoid C++11, bug1617. 2019-12-02 06:19:33 -05:00
Wilson Snyder d65d8fda54 Optimize returns at end of functions. 2019-12-01 17:19:18 -05:00
Wilson Snyder 2076b0219d Fix labels on functions with returns, bug1614. 2019-12-01 17:19:03 -05:00
Wilson Snyder 32f93a8a1e Commentary, bug1615. 2019-12-01 12:43:41 -05:00
Wilson Snyder e28175108f Support queues (excluding {} notation and pattern assignments), bug545. 2019-12-01 12:35:49 -05:00
Wilson Snyder b81295230a Support associative arrays. 2019-12-01 11:52:48 -05:00
Wilson Snyder 6ae7f7b152 Last commit: Fix pattern mismatch crash. 2019-12-01 11:43:48 -05:00
Wilson Snyder 03026b63b9 Internals: Refactor huge pattern function. No functional change intended. 2019-12-01 11:03:53 -05:00
Wilson Snyder 38e586fabe Internals: Misc refectoring for assoc/queues. 2019-12-01 06:09:58 -05:00
Wilson Snyder 3d6e8e9eb0 Add -Wno-context.
Signed-off-by: Wilson Snyder <[email protected]>
2019-11-23 10:40:32 -05:00
Wilson Snyder df192f2b61 Support / with warning. 2019-11-23 09:16:06 -05:00
Wilson Snyder 17ad59394f Support shortreal as real, with a SHORTREAL warning. 2019-11-23 08:34:40 -05:00
Wilson Snyder 682c2a610f Fix $display("%p") to be closer to IEEE. 2019-11-21 19:29:46 -05:00
Wilson Snyder 59782266b9 Tests: Fix uninitalized data in t_vpi_time tests, bug1612. 2019-11-21 18:42:40 -05:00
Wilson Snyder 4885bcb93c Tests: Report core dumps on tests. 2019-11-21 18:42:40 -05:00
Todd Strader d47d3b5162 Fix CI typo 2019-11-21 08:31:18 -05:00
Wilson Snyder 99455a16bf Fix // in filenames, bug1610. 2019-11-20 21:23:03 -05:00
Wilson Snyder a86e1953eb Tests: Fix object order dependence, bug1611. 2019-11-20 06:57:39 -05:00
Matthew Ballance f63dfd7028 Fix VPI timed callbacks to be one-shot, pull5.
Signed-off-by: Matthew Ballance <[email protected]>
Signed-off-by: Wilson Snyder <[email protected]>
2019-11-19 22:44:33 -05:00
Matthew Ballance 7a413a121d Tests: Fix modelsim driver, pull 5.
Signed-off-by: Matthew Ballance <[email protected]>
Signed-off-by: Wilson Snyder <[email protected]>
2019-11-19 21:53:17 -05:00
Wilson Snyder 0f6b625db8 Fix hang on concat error, bug1608. 2019-11-19 19:23:40 -05:00
Wilson Snyder f134ac4f2f Black box some additional unsupported constructs. 2019-11-17 09:01:41 -05:00
Wilson Snyder 39eeda50c6 Internals: Rename MethodCall. No functional change. 2019-11-17 08:51:25 -05:00
Wilson Snyder 09ca4ce791 Internals: Assert proper AstArgs in place. 2019-11-17 08:43:04 -05:00
Wilson Snyder 2ff22d9050 Fix earlier +verilated+error+count to do all . 2019-11-17 08:12:39 -05:00
Wilson Snyder c726ad0142 Commentary 2019-11-17 07:53:30 -05:00
Wilson Snyder 0c0198cf55 Support string.toupper and string.tolower. 2019-11-17 05:05:09 -05:00
Wilson Snyder d480c2f033 Add +verilator+error+limit to see more assertion errors. 2019-11-16 18:25:47 -05:00
Wilson Snyder 8ebe86e54b Fix color assertion on empty if, bug1604. 2019-11-16 17:23:51 -05:00
Wilson Snyder 62af9dbed4 Fix member to method error messages. 2019-11-16 15:32:55 -05:00
Wilson Snyder 3eb0ff8aa0 Detect wrong number of args on method calls. 2019-11-16 15:18:57 -05:00
Wilson Snyder ce5a70fbca Internals: Split large method function. No functional change. 2019-11-16 14:40:45 -05:00
Wilson Snyder c36d9a68f5 Support $ungetc. 2019-11-16 12:55:10 -05:00
Wilson Snyder 8c5aa21a11 Support $rewind. 2019-11-16 12:21:35 -05:00
Wilson Snyder 47b5e36e60 Add -Wpedantic for compliance testing. 2019-11-16 11:59:21 -05:00
Wilson Snyder a481638edb Add error on redefining preprocessor directives. 2019-11-16 10:19:43 -05:00
Wilson Snyder de7caad710 Fix signed wildcard comparisons. 2019-11-16 09:58:01 -05:00
Wilson Snyder b1c14e485a Fix capital S signed numbers. 2019-11-16 09:39:41 -05:00
Wilson Snyder 66727670f9 Override gtkwave config in upstreamable way. No functional change. 2019-11-16 03:54:05 -05:00
Wilson Snyder b9322206d7 Update gtkwave files to latest 2019-11-16 03:44:51 -05:00
Wilson Snyder 617424e04a Internals: Fix cppcheck warning. No functional change. 2019-11-16 03:14:55 -05:00
Wilson Snyder e9c4ffa04e Fix for loop missing initializer, bug1605. 2019-11-15 18:24:55 -05:00
Todd Strader 30c2e53f9e Travis fixes 2019-11-14 17:54:57 -05:00
Sebastien Van Cauwenberghe a250decfaa Tests: Fix t_trace_cat when non-English sort. 2019-11-13 06:43:15 -05:00
Wilson Snyder 21a380def0 Rework variable emit to prep for other data types. 2019-11-12 21:52:25 -05:00
Wilson Snyder 77e30d4920 Internals: Remove dead code. No functional change. 2019-11-12 18:55:16 -05:00
Wilson Snyder 98dcbc6b3e Remove footprint comment when single threaded. 2019-11-11 22:21:37 -05:00
Wilson Snyder 6ce81698e7 devel release 2019-11-10 14:25:54 -05:00
Wilson Snyder 30be381aa8 Version bump 2019-11-10 14:13:46 -05:00
Wilson Snyder e04bc16ffa Codacity cleanup 2019-11-10 13:21:05 -05:00
Wilson Snyder 2b26ca2c07 Optimize mask/and above conditionals. 2019-11-10 13:17:29 -05:00
Wilson Snyder ce178ec987 Optimize modulus by power-of-two constants. 2019-11-10 12:12:57 -05:00
Wilson Snyder fcb733e8d0 Fix clang warning. 2019-11-09 21:47:27 -05:00
Wilson Snyder f87107e757 Tests etc: Cleanup some clang-format suggestions. No functional change. 2019-11-09 20:35:12 -05:00
Wilson Snyder cf9f466f0a Fix false uninit warning 2019-11-09 18:42:18 -05:00
Wilson Snyder 28cbf39995 Support some unpacked arrays in parameters, bug1315. 2019-11-09 18:31:24 -05:00
Wilson Snyder 4767083a72 Internals: Rework AstInitArray to have O(1) access. No functional change intended. 2019-11-09 17:12:26 -05:00
Wilson Snyder 704f40b1a2 Internals: Prep work for simulation of array parameters, bug1315. No functional change intended. 2019-11-09 15:27:10 -05:00
Wilson Snyder c5f859c9a3 Internals: Format cleanup. No functional change. 2019-11-09 15:27:10 -05:00
Todd Strader abe95f3ab3 Add interface port visibility in traces, bug1594. 2019-11-08 08:26:48 -05:00
Wilson Snyder 2eda38c4d1 Update URLs to https://verilator.org 2019-11-07 22:41:34 -05:00
Wilson Snyder 5811ec07e6 Update URLs to https://verilator.org 2019-11-07 22:33:59 -05:00
Wilson Snyder 8a5d13bce2 Commentary 2019-11-07 20:13:00 -05:00
Wilson Snyder 3232bdf016 Commentary 2019-11-07 19:55:11 -05:00
Wilson Snyder 7ef620dc64 Rewrite README and install.adoc 2019-11-07 19:52:56 -05:00
Wilson Snyder 8043a9c666 Tests: Test for bug1593. 2019-11-07 18:15:55 -05:00
Wilson Snyder f1b10e2b4c Improve error messages on DIDNOTSETTLE, bug1556. 2019-11-06 19:47:34 -05:00
Wilson Snyder c1a9ada279 Protect change request filenames. 2019-11-05 21:53:26 -05:00
Wilson Snyder 2aed499e00 Fix detecting missing reg types, bug1570. 2019-11-05 21:15:44 -05:00
Wilson Snyder b2c5f8e74e Commentary: No functional change. 2019-11-05 20:42:49 -05:00
Todd Strader 9ef200d5a3 Fix --protect-lib test concurrency issue, bug1580. 2019-11-05 08:49:43 -05:00
Wilson Snyder 8a3227697e Fix bad-syntax crashes, bug1579. 2019-11-04 22:00:20 -05:00
Wilson Snyder 530ab17c8b Fix bad-syntax crashes, bug1586, bug1587. 2019-11-04 21:51:20 -05:00
Wilson Snyder ca8da1f54f Fix bad-syntax crashes, bug1589. 2019-11-04 21:16:07 -05:00
Wilson Snyder cc4cb4e006 Avoid internal on unsupported; make tests more stable otherwise on internal. 2019-11-04 21:11:15 -05:00
Wilson Snyder e40ad4a095 Commentary; part of last commit. 2019-11-04 19:33:21 -05:00
Wilson Snyder 67a0ad02d2 Fix bad-syntax crasses, bug1591. 2019-11-04 19:27:31 -05:00
Wilson Snyder 055a978866 Fix bad-syntax crasses, bug1583, bug1585. 2019-11-04 19:06:55 -05:00
Wilson Snyder 67d52372e5 Fix bad-syntax crashes, bug1582. 2019-11-04 18:48:47 -05:00
Wilson Snyder a28896d967 Don't have examples require graphviz 2019-11-02 17:44:58 -04:00
Wilson Snyder 9ff5ef4ad5 Fix false CMPCONST/UNSIGNED warnings on inside, bug1581. 2019-11-02 16:56:37 -04:00
Wilson Snyder 25f08b29c6 Add XML examples. 2019-11-02 16:40:59 -04:00
Wilson Snyder 7febeab275 Tests: Use standard verilator.mk rules for tests. 2019-11-02 11:15:58 -04:00
Wilson Snyder c0c038c887 Remove false unoptimizable warning under debug 2019-11-02 11:15:08 -04:00
Wilson Snyder 8a5b8d5f38 Internals: Fix VFlagBitPacked giving 4-state types. 2019-11-01 20:10:45 -04:00
Wilson Snyder ff0dd26fe5 Fix --trace-coverage with randReset. 2019-11-01 20:09:57 -04:00
Wilson Snyder f781085755 Add --xml-output option. 2019-10-31 21:17:05 -04:00
Wilson Snyder 8f6efdaf5c Allow both -MMD and --no-MMD, and --no/--skip-identical to override default 2019-10-31 20:59:52 -04:00
Wilson Snyder 4b5f0fd173 Tests: Cleanup mis-die's 2019-10-31 20:45:17 -04:00
Wilson Snyder 1224c69126 Tests: Fix bad-syntax crashes, bug1577. 2019-10-31 19:34:13 -04:00
Wilson Snyder bcb766b4ce Fix bad-syntax crashes, bug1577. 2019-10-30 21:49:25 -04:00
Wilson Snyder 63373f6f4c Fix missing error when parameter assigned to type, bug1576. 2019-10-30 18:18:29 -04:00
Wilson Snyder 40bdd85a07 Fix minor output spacing issues. 2019-10-29 23:19:59 -04:00
Wilson Snyder 974bf1d643 Add .clang-format. Note this gets close, but isn't perfect, don't blindly use it. 2019-10-29 22:40:58 -04:00
Wilson Snyder 8ce60e955f Fix missing error when parameter assigned to type, bug1575. 2019-10-29 18:38:59 -04:00
Wilson Snyder 171960635e Add recursive define detection, bug1574. 2019-10-28 22:35:31 -04:00
Wilson Snyder 2ab819aef0 Fix bad-syntax crashes, bug1573 2019-10-28 18:46:13 -04:00
Wilson Snyder 647c321437 Suppress 'command failed' on normal errors. 2019-10-27 17:34:04 -04:00
Wilson Snyder 2bbb9dccb1 Less verbose ar messages 2019-10-27 11:30:25 -04:00
Wilson Snyder bac5d32582 Commentary; fix example here documents. 2019-10-27 11:30:12 -04:00
Wilson Snyder 3ebd6915f3 Commentary 2019-10-27 10:29:19 -04:00
Wilson Snyder f852ba8a33 Add --trace-coverage. 2019-10-27 09:27:18 -04:00
Wilson Snyder 8f6015aad5 Fix copy-and-paste error in undriven checks. 2019-10-24 22:50:50 -04:00
Wilson Snyder 352adbed74 Codacy/Cppcheck cleanups. 2019-10-24 22:40:15 -04:00
Wilson Snyder 0cbfd29ac5 Codacy/Cppcheck cleanups and badge. 2019-10-24 22:19:46 -04:00
Wilson Snyder 9f977ed419 Codacy/Cppcheck cleanups and badge. 2019-10-24 21:48:45 -04:00
Yves Mathieu baa6a2c31a Support quoted arguments in -f files, bug1535.
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-24 07:33:19 -04:00
Todd Strader 3b33438e91 Benchmark --protect-lib runtime, bug1519. 2019-10-23 10:03:37 -04:00
Wilson Snyder 17ee8579a4 Internals: Make cleanOut/sizeMatters const. No functional change intended. 2019-10-20 11:58:41 -04:00
Wilson Snyder 94f7133c6f Internals: make dump const. No functional change intended. 2019-10-20 11:49:41 -04:00
Wilson Snyder 6d58d32a0f Commentary 2019-10-19 22:37:08 -04:00
Wilson Snyder c9d000467b Tests: Allow test-by-test verbose. 2019-10-19 07:14:13 -04:00
Wilson Snyder e15d3afb7b Commentary 2019-10-19 07:08:18 -04:00
Ahmed El-Mahmoudy 712bc43a06 Commentary, bug1568. 2019-10-19 06:47:46 -04:00
Wilson Snyder 71fa09a25b Fix bad-syntax crashes, bug1563. 2019-10-18 21:30:34 -04:00
Wilson Snyder 89c3c5f952 Internals: Style cleanup. No functional change. 2019-10-18 20:28:59 -04:00
Wilson Snyder 7311c84937 Slightly faster FST tracing. 2019-10-18 19:48:27 -04:00
Wilson Snyder 8078fc0965 Commentary 2019-10-18 19:40:48 -04:00
Wilson Snyder 31a6a968cc Speedup compiler flags for Ubuntu 19.10. 2019-10-17 20:43:45 -04:00
Patrick Stewart 1e4f471049 Add cmake support, bug1363.
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-17 19:44:10 -04:00
Wilson Snyder 1232746395 Tests: Keep pass/unsup/skip count on retests. 2019-10-17 19:33:47 -04:00
Wilson Snyder 1852ae1cc8 Tests: Tweak driver to still print status every 15 seconds. 2019-10-16 23:17:31 -04:00
Eric Rippey 77f79f0114 Tests: Add fuzzing infrastructure.
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-16 22:18:35 -04:00
Wilson Snyder 6081c262f2 Fix misc bad-syntax crashes, bug1557-1560. 2019-10-16 20:05:29 -04:00
Todd Strader 46ab907f6a Refactor Verilator building in Travis, bug1547. 2019-10-16 05:32:59 -04:00
Todd Strader 8700564197 Build examples using only their Makefiles. 2019-10-16 05:30:51 -04:00
Todd Strader af8cc9127f driver.pl: Report possibly stalled tests. 2019-10-16 05:28:27 -04:00
Wilson Snyder c73336f8f5 Fix misc bad-syntax crashes, bug1548, bug1550-1553. 2019-10-15 19:06:00 -04:00
Patrick Stewart 4361fb838f Tests: Minor testbench fixes to prepare for CMake.
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-10 19:48:06 -04:00
Wilson Snyder 6b8afe8137 Commentary 2019-10-10 06:46:03 -04:00
Wilson Snyder a7c2037b7a Add --generate-key. 2019-10-09 18:53:30 -04:00
Todd Strader 9b09309f51 Commentary: Fix Changes 2019-10-09 08:28:53 -04:00
Todd Strader da0da9e258 Add --protect-lib to create protected libraries, bug1490. 2019-10-09 06:47:26 -04:00
Wilson Snyder 58a42834a6 Tests: Remove some old makefile rules. 2019-10-08 19:12:33 -04:00
Wilson Snyder 8c836e1222 Fix clang thread lint error. 2019-10-08 12:07:46 -04:00
Wilson Snyder ce179bd2e3 Fix clang mutex check. 2019-10-08 08:29:53 -04:00
Patrick Stewart 68e5c95b82 Tests: Rename harness flag. No functional change.
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-07 22:15:43 -04:00
Patrick Stewart 07db53e54f Commentary 2019-10-07 22:11:50 -04:00
Patrick Stewart 0ed58a4217 Fix multithreaded yield behavior when no work.
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-07 19:27:31 -04:00
Patrick Stewart 8e6d68147c Support multithreading on Windows.
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-07 19:23:06 -04:00
Wilson Snyder e08b9b84b5 Commentary 2019-10-07 17:31:33 -04:00
Wilson Snyder 2f28c5f5b4 Increase case duplicate/incomplete to 16 bit tables, bug1545. 2019-10-07 07:38:40 -04:00
Wilson Snyder 91f1acd85f Add --protect-ids to obscure information in objects, bug1521. 2019-10-06 13:24:21 -04:00
Wilson Snyder ed1e5fb509 Tests: When doing extended tests, run most examples under harness for better parallelism. 2019-10-06 10:58:16 -04:00
Wilson Snyder 99b2ab7540 Rename examples in prep for CMake. 2019-10-06 10:32:49 -04:00
Wilson Snyder 763b9909f1 devel release 2019-10-06 10:04:45 -04:00
Wilson Snyder dfcd412e5f Version bump 2019-10-06 09:40:36 -04:00
Wilson Snyder 307549e8a6 Internals: Fix some cppcheck warnings. 2019-10-06 08:20:02 -04:00
Wilson Snyder 09b79a731a Fix more output spacing issues. 2019-10-05 21:52:33 -04:00
Wilson Snyder 4544a2fd99 Fix extra declaration of trace() in submodules. 2019-10-05 20:16:33 -04:00
Wilson Snyder e09c918198 Fix indentation broke in 977a767477. 2019-10-05 18:00:45 -04:00
Wilson Snyder 9bf6135f6d Remove some output tabs. 2019-10-05 17:35:08 -04:00
Wilson Snyder d472ef63e9 Internals: Cleanup some misnamed classes. No functional change. 2019-10-05 08:17:21 -04:00
Wilson Snyder f1c04b5d25 Fix extra space in mtask comment. No functional change. 2019-10-04 22:54:57 -04:00
Wilson Snyder 1cf29c4d20 Fix truncation of comments, broke in f133c4d0b3. 2019-10-04 22:54:17 -04:00
Maarten De Braekeleer 977a767477 Avoid tabs in C output.
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-04 21:10:53 -04:00
Wilson Snyder 771a301f66 Commentary: Remove newlines, upsets some patches. No functional change. 2019-10-04 20:17:11 -04:00
Wilson Snyder a9954a71c3 Fix case statements with strings, bug1536. 2019-10-04 19:13:39 -04:00
Wilson Snyder 967dc24fda Commentary 2019-10-04 17:42:34 -04:00
Wilson Snyder e1e45cf13c Internals: Move option checks to notify(). 2019-10-03 22:18:29 -04:00
Wilson Snyder bd89c71694 Internals: Refactor to avoid V3Global requirements in V3String. No functional change intended. 2019-10-02 21:38:16 -04:00
Stefan Wallentowitz 633131b984 Return vpiModule when it is the scope.
Return the vpiModule when it is searched for by name and not the vpiScope,
now that we actually have it (one step further to supporting vpiModule in
complete).

Signed-off-by: Stefan Wallentowitz <[email protected]>
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-02 18:47:12 -04:00
Wilson Snyder 99db18b6c3 Commentary 2019-10-02 18:47:06 -04:00
Todd Strader 961a8e190f Internals: Remove rogue character. 2019-10-02 08:52:26 -04:00
Stefan Wallentowitz 045ff25f80 Support vpiModule, bug1469.
Add very basic support for vpiModule. Basically it allows to traverse
the module tree to find a variable etc. It does not support more than
vpi_iterate and vpi_scan for vpiModule along basic operations like
vpi_get_str on vpiModule.

The support is added non-intrusively to non-VPI verilator runs. It
essentially:

 - Tracks the creation of cell instances and keeps them alive until
   the emit phase. They are there converted to scopes if modules.

 - Emits empty (don't add anything during construction)
   VerilatedScopes for all inlined modules, only for those inlined
   modules that are on the hierarchical path to public variables.

 - Adds VerilatedHierarchy as abstraction to structure of the
   scopes. It is only created for VPI designs. It allows to traverse
   the hierarchy from the top (NULL).

Signed-off-by: Stefan Wallentowitz <[email protected]>
Signed-off-by: Wilson Snyder <[email protected]>
2019-10-01 21:57:45 -04:00
Wilson Snyder 66209d1114 Tests: Less verbose status. 2019-10-01 21:32:38 -04:00
Todd Strader 3f1fe2d18a Internals: Travis CI environment. 2019-10-01 06:05:11 -04:00
Wilson Snyder 8b6fb26272 Return good exit status on --help. 2019-09-30 23:15:10 -04:00
Wilson Snyder 881362bb04 Fix clang compile warnings. 2019-09-30 21:55:31 -04:00
Wilson Snyder 239ef1ae6d Fix misc bad-syntax crashes, bug1533. 2019-09-30 20:00:30 -04:00
Wilson Snyder 9eaec3b5c1 Fix misc bad-syntax crashes, bug1530. 2019-09-30 19:48:01 -04:00
Wilson Snyder dd4aa948ae Tests: Have driver report ETA. 2019-09-30 19:22:36 -04:00
Wilson Snyder 12fa085b26 Fix misc bad-syntax crashes, bug1529. 2019-09-30 19:22:14 -04:00
Wilson Snyder 9d6b0d7dd6 Tests: Fix broken contributors check. 2019-09-30 18:56:04 -04:00
Wilson Snyder a1405dac8e Fix misc bad-syntax crashes, bug1532. 2019-09-30 18:50:27 -04:00
Todd Strader cb115e1a15 Commentary 2019-09-30 09:33:17 -04:00
Wilson Snyder 1c7eb89df5 Commentary: Update contributing indentation. 2019-09-29 17:11:13 -04:00
Wilson Snyder 6e91f82a7d Commentary: Fix logo rendering 2019-09-29 17:09:03 -04:00
Wilson Snyder 17123cd0e0 Add contributing document. Convert internals to asciidoc format. Part of last commit. 2019-09-29 17:05:13 -04:00
Wilson Snyder 3f0c5b7550 WIP 2019-09-29 17:03:07 -04:00
Wilson Snyder f6e0e9adec Internals: Use SHA256 instead of insecure SHA1. 2019-09-28 13:32:28 -04:00
Wilson Snyder dea1531f40 Commentary 2019-09-28 11:38:23 -04:00
Wilson Snyder edcfaa888d Commentary 2019-09-28 11:13:30 -04:00
Todd Strader 28b9db1903 Add AstVFile and AstTextBlock, towards bug1490. 2019-09-27 04:24:38 -04:00
Todd Strader 9e64be71a7 Add XSim user run flags 2019-09-27 01:12:53 -04:00
Stefan Wallentowitz 99a8845a96 Fix VerilatedVpioVar vpiMemory/vpiReg accessor, bug1528.
Signed-off-by: Wilson Snyder <[email protected]>
2019-09-27 00:01:09 -04:00
Wilson Snyder be4692772c Ignore MCD fopenw with --bbox-unsup. 2019-09-26 23:37:22 -04:00
Wilson Snyder 4f315d9078 Fix ugly error on interface misuse, bug1525. 2019-09-25 21:53:01 -04:00
Wilson Snyder f133c4d0b3 Fix mis-indenting AstComments with C++ symbols. 2019-09-24 19:07:22 -04:00
Wilson Snyder 8490046028 Internals: AstComment optional suppression of at. No functional change intended. 2019-09-23 18:44:45 -04:00
Lukasz Dalek d6ac351dcb Add --public-flat-rw switch, bug1511.
This switch exposes VARs, PORTs and WIREs to C++ code. It must be use
with care as it has a significant performance impact and may result in
mis-simulation of generated clocks. Anyhow, it is prefered over
--public and useful for VPI.

Signed-off-by: Lukasz Dalek <[email protected]>
Signed-off-by: Stefan Wallentowitz <[email protected]>
Signed-off-by: Wilson Snyder <[email protected]>
2019-09-23 07:56:07 -04:00
Stefan Wallentowitz 502bd6cbd6 Tests: Set VM_PREFIX from test script.
Signed-off-by: Wilson Snyder <[email protected]>
2019-09-21 08:26:34 -04:00
Philipp Wagner d7b6b53c4d Make callCbs() public.
VerilatedVpi::callCbs() can be used by the user to signal
simulation-related callbacks, e.g.
VerilatedVpi::callCbs(cbStartOfSimulation).

The information if any callbacks have been called may be important to
drive an evaluation until no further changes are observed.

Signed-off-by: Lukasz Dalek <[email protected]>
Signed-off-by: Philipp Wagner <[email protected]>
Signed-off-by: Stefan Wallentowitz <[email protected]>
Signed-off-by: Wilson Snyder <[email protected]>
2019-09-21 07:43:20 -04:00
Stefan Wallentowitz 96725b3431 Tests: To allow reuse of cpp files, allow to set the PLI filename.
Signed-off-by: Wilson Snyder <[email protected]>
2019-09-19 18:46:45 -04:00
Stefan Wallentowitz 8686ed9b00 Fix vpiType accessor, bug1510.
Signed-off-by: Wilson Snyder <[email protected]>
2019-09-18 12:24:19 -04:00
Stefan Wallentowitz 32e1207782 Fix vpiType accessor, bug1509.
Signed-off-by: Wilson Snyder <[email protected]>
2019-09-18 07:22:59 -04:00
Wilson Snyder 900115bb2d Fix false warning on backward indexing, bug1507. 2019-09-17 15:17:23 -04:00
Wilson Snyder 3469c78153 Fix bad module name. 2019-09-16 21:09:18 -04:00
Wilson Snyder baa634343b Fix config_rev revision detection on old versions. 2019-09-13 07:20:26 -04:00
Wilson Snyder 1471f5691a Fix error on multidimensional cells, bug1505. 2019-09-12 19:06:26 -04:00
Wilson Snyder e556269692 Commentary - Spelling fixes 2019-09-12 07:22:22 -04:00
Todd Strader d1af69f91d Produce man files with 'make all' 2019-09-11 10:01:18 -04:00
Wilson Snyder fa904f386c Commentary - Spelling fixes 2019-09-09 07:50:21 -04:00
Todd Strader a4daae66de -LDLIBS isn't an option 2019-09-06 13:04:47 -04:00
Todd Strader c813026566 Make Syms file honor --output-split-cfuncs, bug1499. 2019-09-04 06:15:41 -04:00
Wilson Snyder 314cd92129 Support $fseek, $ftell, $frewind, bug1496. 2019-09-03 21:28:15 -04:00
Wilson Snyder 3bc260c55d Fix make test with no VERILATOR_ROOT, bug1494. 2019-09-01 11:15:42 -04:00
Wilson Snyder 4c0f95af10 devel release 2019-08-29 19:12:47 -04:00
Wilson Snyder 35fe205fd6 Version bump 2019-08-29 18:58:38 -04:00
Todd Strader 70cf2582d6 Add XSim support to driver.pl, bug1493. 2019-08-29 17:00:49 -04:00
Todd Strader ec620387af Add --dpi-hdr-only, bug1491. 2019-08-27 21:36:59 -04:00
Wilson Snyder e1e4bde125 Remove old V3ClkGater code 2019-08-27 17:51:06 -04:00
Todd Strader b947391662 Retain widthSized when simulating 2019-08-12 15:38:58 -04:00
Wilson Snyder edc0f442e4 Tests: Add tests for bug1487. 2019-08-09 05:45:44 -04:00
Wilson Snyder 562b9551bf Internals: Remove some unused arguments. No functional change intended. 2019-08-09 04:12:49 -04:00
Wilson Snyder f74af949da Remove trailing spaces. 2019-08-08 17:53:49 -04:00
Wilson Snyder 81e806e895 Fix elaboration time errors, bug1429. 2019-08-04 22:34:54 -04:00
Wilson Snyder 7d4958264a Support arbitrary-argument $warning/$info etc 2019-08-04 21:50:08 -04:00
Wilson Snyder 88b87429dc Tests: Add elaboration info test. 2019-08-04 21:31:06 -04:00
Wilson Snyder 429f463032 Don't check SYSTEMC environment, for part of CMake support, bug1363. 2019-08-04 20:21:58 -04:00
Wilson Snyder af4a39603c Makefile: Run hello world before other examples. 2019-08-04 20:20:29 -04:00
Wilson Snyder a13d230d8c Tests: Less verbosity 2019-08-04 15:04:34 -04:00
Wilson Snyder b7bd5956ea Concats should be unsigned 2019-08-04 14:48:17 -04:00
Wilson Snyder 1a36e05cc6 Fix core dump on v3Number replace'ed assertions. 2019-08-04 14:14:28 -04:00
Wilson Snyder 71265a8ec9 Internals: Rename unsized functions. No functional change. 2019-08-04 12:39:35 -04:00
Wilson Snyder 3a720204c2 Internals: Remove m_logicMap as m_detailedMap covers it. No functional change intended. 2019-08-04 08:16:24 -04:00
Wilson Snyder a95f58749f Fix internal error on gate optimization of assign, bug1475. 2019-08-03 21:49:39 -04:00
Wilson Snyder 9e58ede480 Internals: Rename V3Hashed functions for future commit. No functional change. 2019-08-03 19:05:59 -04:00
Wilson Snyder cf2ac30f66 Fix date. 2019-08-02 21:39:32 -04:00
Wilson Snyder 68b22a4a3d Tests: Summarize any skips. 2019-07-30 22:20:37 -04:00
Wilson Snyder 875dc9a27e --debug doesn't take an arg 2019-07-30 18:40:38 -04:00
Maarten De Braekeleer 1332446f2a Spelling fixes.
Signed-off-by: Wilson Snyder <[email protected]>
2019-07-30 18:27:36 -04:00
Wilson Snyder 6b798830c9 Fix spacing 2019-07-29 21:07:37 -04:00
Wilson Snyder ffa23b59b8 Tests: Add iff test, bug1482. 2019-07-26 19:31:02 -04:00
Maarten De Braekeleer 7d27461054 Spelling fixes.
Signed-off-by: Wilson Snyder <[email protected]>
2019-07-26 12:58:13 -04:00
Maarten De Braekeleer b3f318d8ab Add contributor certification. 2019-07-26 12:57:42 -04:00
Todd Strader 4a14788c9b When showing an error, show the instance location 2019-07-26 12:52:38 -04:00
Wilson Snyder 5560da2934 Commentary 2019-07-26 06:24:26 -04:00
Todd Strader 43ce048f9e Add rr support 2019-07-25 21:34:09 -04:00
Todd Strader b045111a67 Refactor SimulateVisitor to use AstConst 2019-07-23 13:58:17 -04:00
Todd Strader 654571bd1c V3Number cleanup 2019-07-22 15:07:08 -04:00
Todd Strader a3fd105acb Add more Travis coverage 2019-07-18 05:31:02 -04:00
Wilson Snyder 97561bf064 When showing an error, show source code. 2019-07-14 21:42:03 -04:00
Wilson Snyder a4820fc700 Misc minor error cleanups from show-source branch. 2019-07-14 20:59:56 -04:00
Wilson Snyder ee469eedaf Fix some errors reporting wrong objects. 2019-07-14 15:06:49 -04:00
Wilson Snyder a49d819437 Tests: Default test_regress to quiet 2019-07-14 15:04:19 -04:00
Wilson Snyder cbb9288cb1 Fix some errors reporting wrong objects. 2019-07-14 12:21:39 -04:00
Wilson Snyder 173efbc829 Offer suggestions on bad identifier errors. 2019-07-14 10:08:53 -04:00
Wilson Snyder 0fef3b02ec Fix some parse tokens having wrong fileline. 2019-07-13 12:01:26 -04:00
Wilson Snyder d1ee6689c4 Internals: Make V3LanguageWords a singleton. 2019-07-13 08:57:42 -04:00
Wilson Snyder b3eab9d78a Tests: Move t_math_synmul to extended tests. 2019-07-12 19:35:28 -04:00
Wilson Snyder defd05bdd7 Tests: Fix driver checking threads/gcc for extended tests. 2019-07-12 19:35:10 -04:00
Wilson Snyder a7e5cccf33 In errors, single quote signals and other from-user data. 2019-07-11 22:36:32 -04:00
Wilson Snyder 0f857ce423 In errors, single quote signals and other from-user data. 2019-07-11 22:09:30 -04:00
Wilson Snyder 83cf1882de Quote reserved word messages, and related internal cleanups. 2019-07-11 20:49:35 -04:00
Wilson Snyder e17543d6d8 Tests: Fill in some missing error coverage holes. 2019-07-11 20:18:36 -04:00
Wilson Snyder dacf45fea9 Fix error message continuations to avoid linenumber repetition 2019-07-11 19:15:40 -04:00
Wilson Snyder 13a20c5ee9 Internals: Fix inserted tabs. 2019-07-11 07:05:33 -04:00
Wilson Snyder 58dfe9d071 Internals: Detab and fix spacing style issues. No functional change.
When diff, recommend using "git diff --ignore-all-space"
When merging, recommend using "git merge -Xignore-all-space"
2019-07-11 06:57:49 -04:00
Wilson Snyder 6c5cc885a6 Internals: Cleanup FileLine constructors. No functional change intended. 2019-07-10 22:04:58 -04:00
Sebastien Van Cauwenberghe 2c44ab61ac Fix GDB returning wrong error code on Fedora 30
Signed-off-by: Wilson Snyder <[email protected]>
2019-07-10 06:47:20 -04:00
Sebastien Van Cauwenberghe 0847ea57ae Docs: Add name to contributors
Signed-off-by: Wilson Snyder <[email protected]>
2019-07-10 06:46:28 -04:00
Wilson Snyder 9af84c71f5 Internals: More UASSERT_OBJ conversions. No functional change intended. 2019-07-07 09:01:36 -04:00
Wilson Snyder 4ce77d3e68 Header mentions public use. 2019-07-07 09:00:57 -04:00
Philipp Wagner 3c67791624 docs: Document parse-order-dependency for config files, bug1474
Signed-off-by: Wilson Snyder <[email protected]>
2019-07-06 18:09:23 -04:00
Philipp Wagner a281c00752 docs: Contributor signoff
Signed-off-by: Wilson Snyder <[email protected]>
2019-07-06 18:08:22 -04:00
Wilson Snyder 2ca418288d Fix enum values not being sized based on parent, bug1442. 2019-07-06 16:26:44 -04:00
Wilson Snyder bea34d0ced Internals: Misc enum cleanups. No functional change. 2019-07-06 15:50:25 -04:00
Wilson Snyder a5f2ce0dad Tests: Disable t_leak on Travis-CI. 2019-07-06 13:47:17 -04:00
Gianfranco Costamagna 07ae7146e3 Honour system flags, this makes debug flags being injected correctly.
Signed-off-by: Wilson Snyder <[email protected]>
2019-07-06 13:02:36 -04:00
Wilson Snyder 8548ecfdac Internals: Add UASSERT_OBJ macro to replace hand-done ifs. No functional change intended.
This makes it easier to filter out correctly zero code-coverage lines.
2019-07-06 12:57:50 -04:00
Wilson Snyder 7e54ff1b37 Additional lcov code coverage. 2019-07-05 22:30:19 -04:00
Wilson Snyder a4b9745e6e Fix lifetime opt dropping 2019-07-05 22:30:19 -04:00
Wilson Snyder 8612ba2b8d Internals: Commentary and fix gate debug glibc warning 2019-07-05 22:30:19 -04:00
Todd Strader fea6e047e2 Add Travis badge 2019-07-05 05:26:08 -04:00
Wilson Snyder 01ef7122e9 Internals: Add lcov code coverage markers. 2019-06-30 22:37:03 -04:00
Wilson Snyder ac43e7322b Internals: Remove dead code. 2019-06-30 22:11:56 -04:00
Wilson Snyder 02a3f2089f Include filenames in savable error. 2019-06-30 22:01:53 -04:00
Wilson Snyder 33ad834106 Tests: Close some test coverage holes. 2019-06-30 22:00:18 -04:00
Wilson Snyder efe739c52f Tests: Cover --error-limit and update docs (found via coverage). 2019-06-30 21:36:57 -04:00
Wilson Snyder 5cd531a5e0 Tests: Fix glib warning 2019-06-30 21:35:55 -04:00
Wilson Snyder 0e8dfdbb71 Tests: Less verbosity. 2019-06-30 17:45:42 -04:00
Wilson Snyder ec32a9b976 Tests: Close some test coverage holes. 2019-06-30 17:38:41 -04:00
Wilson Snyder 1aae6df669 Internals: Run graph self tests on --debug-self-test 2019-06-30 17:36:58 -04:00
Wilson Snyder f7641d2ecc Change MULTITOP to warning to help linting, see manual. 2019-06-30 16:46:48 -04:00
Wilson Snyder 5f27c41ee3 Test driver: Cleanup rerun flags & status. 2019-06-29 21:36:33 -04:00
Wilson Snyder 51df77099a Test driver: With --quiet print summary every 15sec or Travis barfs. 2019-06-29 15:58:00 -04:00
Wilson Snyder b8b7e5c978 Test driver: Add --rerun and --quiet options 2019-06-29 15:24:56 -04:00
Wilson Snyder dddcfeb482 Test driver: Move one_test, no functional change. 2019-06-29 13:37:01 -04:00
Wilson Snyder 8d63f83177 Tests: Reduce verbosity unless use --verbose 2019-06-29 13:11:30 -04:00
Wilson Snyder d43e9aa2c5 Fix not in array context on non-power-of-two slices, msg2946. 2019-06-29 11:30:38 -04:00
Wilson Snyder a2c1b7f827 Tests: Fix t_flag_csplit skip on old make. 2019-06-29 08:25:50 -04:00
Wilson Snyder 2fff92fe78 Tests: Add array MDA test. 2019-06-29 08:12:00 -04:00
Wilson Snyder ba9af4aabf For internal messages, use <command-line> and <built-in> to match GCC. 2019-06-29 07:39:34 -04:00
Wilson Snyder ef02678305 tests: Fix default make test, broke earlier commit. 2019-06-29 07:22:19 -04:00
Wilson Snyder 6990db70fa Avoid unique internal fileline in selftest. 2019-06-28 22:34:01 -04:00
Wilson Snyder af5616c077 Fix line number in dup vars. 2019-06-28 22:34:01 -04:00
Todd Strader 009f053d6e Add initial Travis CI config 2019-06-27 11:26:25 -04:00
Wilson Snyder 6903c52ef7 Tests: Add coverage of missing include error. 2019-06-26 19:12:57 -04:00
Wilson Snyder aa65dfb1bc Tests: Use only 2 threads for t_gantt. 2019-06-26 19:06:52 -04:00
Wilson Snyder 84a2cd0ec7 Remove some old DIRPROJECT dead code. 2019-06-26 18:50:38 -04:00
Wilson Snyder 8e7559c6c9 Show included-from filenames in warnings, bug1439. 2019-06-22 17:01:39 -04:00
Wilson Snyder 951521320a Warnings: Suppress dup lines, and use lowercase note: to match gcc 2019-06-22 16:12:17 -04:00
Wilson Snyder abc0eb92a0 Debug: Show only first line of suppressed warnings 2019-06-22 14:25:31 -04:00
Wilson Snyder c514bb26e8 Always internal module wrapper TOP. 2019-06-22 13:43:49 -04:00
Wilson Snyder 5cb6474cc6 Fix not reporting some duplicate signals/ports, bug1462. 2019-06-22 12:43:48 -04:00
Wilson Snyder b8eb6368e9 Tests: Fix up duplicate var declarations. 2019-06-22 12:32:13 -04:00
Wilson Snyder 6239deb1df Tests: Disable t_flag_csplit with old make. 2019-06-19 08:44:40 -04:00
Wilson Snyder 89c2a6070a devel release 2019-06-16 10:01:09 -04:00
Wilson Snyder c53ea10c75 Version bump 2019-06-16 09:30:56 -04:00
Wilson Snyder 8fa54b1c4d Add .gitattributes 2019-06-15 21:49:49 -04:00
Wilson Snyder e5fae03364 docs: Move license files back to top out of docs to appease github. 2019-06-15 21:41:38 -04:00
Wilson Snyder 081fd3b789 Rename to LICENSE to appease github 2019-06-15 17:57:40 -04:00
Wilson Snyder 0edd3c9e95 Tests: Support remote test obj_ 2019-06-15 16:37:58 -04:00
Wilson Snyder 659c7b78d5 Warn only once if too few CPUs. 2019-06-15 09:17:51 -04:00
Wilson Snyder 34ef3c9c38 Internals: Assert V3Number ops have different pointers. 2019-06-15 08:10:17 -04:00
Wilson Snyder 90af180ec1 Fix constant function return of function var, bug1467. 2019-06-15 08:03:39 -04:00
Wilson Snyder 0d71c1154d Fix overshift error to have user's source line. 2019-06-15 07:44:03 -04:00
Alex Chadwick 5da5e32e86 Fix --savable invalid C++ on packed arrays, bug1465.
Signed-off-by: Wilson Snyder <[email protected]>
2019-06-14 18:42:27 -04:00
Wilson Snyder ea59a39661 Commentary 2019-06-13 20:53:39 -04:00
Wilson Snyder f5ca1a04cc Docs: Rewrite README 2019-06-13 20:51:06 -04:00
Wilson Snyder b6c905dffc Move files into docs directory. 2019-06-13 07:19:44 -04:00
Wilson Snyder e4a3f9b38c Tests: Remove tabs from golden-output tests. No functional change. 2019-06-12 22:41:51 -04:00
Wilson Snyder b3e2d26e35 Tests: Remove tabs from golden-output tests. No functional change. 2019-06-12 22:22:36 -04:00
Wilson Snyder 79e9fbaeb7 Tests: Add additional .out files instead of expects. 2019-06-12 21:49:40 -04:00
Wilson Snyder f5f5cd522b Tests: Make standard lint() to replace inconsistent compile() 2019-06-12 21:05:02 -04:00
Wilson Snyder e713c8ce57 Fix not reporting some duplicate signals, bug1462. 2019-06-12 19:17:10 -04:00
Wilson Snyder 94ed817897 Fix debug over-verbosity. 2019-06-12 19:11:26 -04:00
Wilson Snyder ff360738b5 XML: Remove extranious space on dtypes. 2019-06-12 07:19:14 -04:00
Wilson Snyder f7f73a0825 Internals: Standardize internal FileLine filenames. 2019-06-12 07:00:56 -04:00
Wilson Snyder 2cedd14d43 Fix build error on MinGW, bug1460. 2019-06-11 21:38:17 -04:00
Wilson Snyder 77c2d49d1a Internals: Move code out of verilog.y. No functional change. 2019-06-11 21:19:44 -04:00
Wilson Snyder dd8d5ef687 Internals: Move code out of verilog.l. No functional change. 2019-06-11 21:03:03 -04:00
Wilson Snyder cfb05cd70a Whitespace cleanup. No functional change. 2019-06-11 20:20:04 -04:00
Todd Strader 6f2f668449 Fix dotted references to type parameter sizes, bug1458.
Signed-off-by: Wilson Snyder <[email protected]>
2019-06-11 19:00:24 -04:00
Wilson Snyder 6ffbb7cabf Internals: Remove extra semicolons. No functional change. 2019-06-11 18:31:06 -04:00
Wilson Snyder 6c1782e4de Add contributors and test. 2019-06-10 20:29:58 -04:00
Todd Strader 10e3cc6e3b Tests: Better checking for type param hash fix.
Signed-off-by: Wilson Snyder <[email protected]>
2019-06-06 19:57:31 -04:00
Todd Strader 34424e70d8 Fix sameHash error on type parameters, bug1456.
Signed-off-by: Wilson Snyder <[email protected]>
2019-06-05 20:39:42 -04:00
Wilson Snyder 38ad8727af Tests: Remove CRs. 2019-06-04 20:37:16 -04:00
Wilson Snyder 4e115d4b69 Fix performance when mulithreaded on 1 CPU, bug1455. 2019-06-03 19:13:03 -04:00
Wilson Snyder f6f8073058 Support logical equivalence operator <->. 2019-06-01 19:40:06 -04:00
Wilson Snyder 902ba752a3 Move many unsupported errors from lex to parser so can --bbox-unsup ignore them. 2019-05-31 21:05:50 -04:00
Wilson Snyder 97d9de3dad Support deferred assertions, bug1449. 2019-05-31 07:33:57 -04:00
Todd Strader 97fef7c60b Tests: Fix t_dist_whitespace.pl --golden, bug1451
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-30 20:36:13 -04:00
Wilson Snyder a58e7d94ec Error continuation lines no longer have %Error prefix. 2019-05-30 20:30:59 -04:00
Wilson Snyder c0be8bcefb Internals: Remove some pointless V3Number temporaries. No functional change intended. 2019-05-29 23:18:47 -04:00
Wilson Snyder 8846b365f4 Fix some memory leaks in V3Const/V3Unroll. 2019-05-29 22:43:26 -04:00
Kanad Kanhere 72eb361131 Fix invalid XML output due to special chars, bug1444.
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-29 18:41:03 -04:00
Wilson Snyder b83b606267 Internals: Detab and fix spacing style issues. No functional change.
When diff, recommend using "git diff --ignore-all-space"
When merging, recommend using "git merge -Xignore-all-space"
2019-05-19 16:13:13 -04:00
Wilson Snyder 59d7d9e8c3 Fix real parameter assignment, bug1427. 2019-05-17 20:50:57 -04:00
Kanad Kanhere 3411279294 Internals: Relocate quoteNameControls, part of bug1444.
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-16 21:44:01 -04:00
Wilson Snyder 8d6bea8975 nodist: Fix git_untabify --narrow. 2019-05-16 21:32:50 -04:00
Wilson Snyder 01725f662f Fix $display with string without %s, bug1441. 2019-05-16 21:21:38 -04:00
Wilson Snyder d841e68f4f Fix parameter function string returns, bug1441. 2019-05-16 21:16:20 -04:00
Wilson Snyder 13ecb8e177 Fix fault on with %t, bug1443. 2019-05-16 19:35:10 -04:00
Todd Strader 26436cf4dd Tests: Fix files ignored by t_dist_manifest, bug1438.
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-15 19:02:17 -04:00
Wilson Snyder 96c70ea2df Internals: Fix some long lines in include files. No functional change.
When merging, recommend using "git merge -Xignore-all-space"
2019-05-14 22:49:32 -04:00
Wilson Snyder c8849094fc Fix spacing of last commit. 2019-05-14 22:05:37 -04:00
Wilson Snyder afea6d84e3 Mark infrequently called functions with GCC cold attribute. 2019-05-14 22:03:50 -04:00
Wilson Snyder 1fb0af7fba Internals: Fix some -Wsuggest-attribute=const suggestions. 2019-05-14 21:46:19 -04:00
Wilson Snyder 8ad1a68420 Fix OSX compile issue with -Winvalid-noreturn, bug1440. 2019-05-14 20:51:28 -04:00
Wilson Snyder 6ef7d5f0fd Internals: Fix spacing of last commit 2019-05-14 06:56:20 -04:00
Todd Strader d0fbdfac07 Add --quiet-exit, bug1436.
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-14 06:47:51 -04:00
Sergey Kvachonok 16997d153f Fix sign-compare warning in verilated.cpp, bug1437.
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-14 06:07:16 -04:00
Wilson Snyder 7777d10e9b Tests: Check for and remove trailing newlines 2019-05-13 19:47:52 -04:00
Wilson Snyder 00214f738f Tests: New scope-relevant tests, towards bug1305. 2019-05-13 19:31:24 -04:00
Wilson Snyder 07e6bc17db Fix error message showing pointer 2019-05-13 19:31:00 -04:00
Wilson Snyder afdfa4df87 Support VerilatedFstC set_time_unit, bug1433. 2019-05-12 08:19:49 -04:00
Wilson Snyder 1f714c6813 Commentary: Spelling fixes. 2019-05-11 18:42:27 -04:00
Wilson Snyder 5df3032b11 gtkwave: Merge from upstream. 2019-05-09 20:38:48 -04:00
Todd Strader eac3458647 Internals: V3Number tracks node information, part of bug1305.
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-09 20:03:19 -04:00
Wilson Snyder 00efa05b50 devel release 2019-05-08 21:39:23 -04:00
Wilson Snyder cc1d380864 Version bump 2019-05-08 21:15:56 -04:00
Wilson Snyder f96942a526 Internals: Detab and fix spacing style issues in include files. No functional change.
When merging, recommend using "git merge -Xignore-all-space"
2019-05-08 21:13:38 -04:00
Wilson Snyder b23fc06388 Internals: Detab and fix spacing style issues in some include files. No functional change. 2019-05-07 23:30:24 -04:00
Wilson Snyder f818ddc71c Internals: Detab and fix spacing style issues in tests and scripts. No functional change. 2019-05-07 22:34:09 -04:00
Wilson Snyder 37c8cc82b2 Auto-extend and WIDTH warn on unsized X/Zs, bug1423. 2019-05-07 21:57:38 -04:00
Wilson Snyder 03ebd5554f Fix table compile error with multiinterfaces, bug1431. 2019-05-06 19:33:54 -04:00
Wilson Snyder a2a7021914 Reorder VCD codes for better viewer packing. 2019-05-06 18:55:38 -04:00
Wilson Snyder c6650f88e1 Internals: Remove some uses of AstConst taking V3Number. No functional change intended. 2019-05-03 21:21:18 -04:00
Wilson Snyder 55a25674a2 Add --trace-fst-thread. 2019-05-02 20:33:05 -04:00
Wilson Snyder 05c3d520a6 Test: Ignore tabs on new .out 2019-05-02 20:32:50 -04:00
Wilson Snyder 6b3304320b For FST tracing use LZ4 compression. 2019-05-02 19:55:16 -04:00
Wilson Snyder 8d15276625 Tests: Use golden_filename consistently. 2019-05-02 19:02:40 -04:00
Todd Strader 354f107fed Tests: Converting tests to golden files for bug1305.
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-02 18:45:32 -04:00
Wilson Snyder 1ff55c20e0 Support "'dx" constants, bug1423. 2019-05-01 20:02:28 -04:00
Todd Strader 9583f0d3cc Add .git file (not directory) to MANIFEST.SKIP for git worktrees
Signed-off-by: Wilson Snyder <[email protected]>
2019-05-01 19:48:27 -04:00
Wilson Snyder 3acb85a005 Fix FST enums not displaying, bug1426. 2019-05-01 19:18:45 -04:00
Wilson Snyder 08d041cb93 Add error when use parameters without value, bug1424. 2019-04-30 19:16:41 -04:00
Wilson Snyder 274b2002c2 Fix GTKWave register warning, bug1421. 2019-04-29 05:28:30 -04:00
Todd Strader 681e91f9d8 Fix FST documentation, bug1419.
Signed-off-by: Wilson Snyder <[email protected]>
2019-04-28 17:53:58 -04:00
Wilson Snyder 6e333bd9ab Fix test problems when missing fst2vcd, bug1417. 2019-04-10 20:51:38 -04:00
Larry Lee 6a331e37fc Fix missing VL_SHIFTL_ errors, bug1412, bug1415.
Signed-off-by: Wilson Snyder <[email protected]>
2019-04-05 19:32:25 -04:00
Sergey Kvachonok d8a020905a Fix MinGW GCC 6 printf formats, bug1413.
Signed-off-by: Wilson Snyder <[email protected]>
2019-04-02 18:24:36 -04:00
Wilson Snyder efa6f4cd95 Fix extraction, part of fix missing VL_SHIFTL_QQW error, bug1412. 2019-03-28 19:46:39 -04:00
Larry Lee ca537dc3ed Fix missing VL_SHIFTL_QQW error, bug1412.
Signed-off-by: Wilson Snyder <[email protected]>
2019-03-28 19:11:46 -04:00
Wilson Snyder 3b64f54cea Support '#' comments in , bug1411. 2019-03-27 07:40:14 -04:00
Wilson Snyder 32c1e38b84 devel release 2019-03-23 21:14:30 -04:00
Wilson Snyder a7aa8820e1 Version bump 2019-03-23 21:00:07 -04:00
Wilson Snyder 2582a83376 Unsupported error on select of concatenation 2019-03-13 19:52:23 -04:00
Wilson Snyder 0094cd7a81 Internals: Spacing fixes. No functional change. 2019-03-13 19:47:47 -04:00
Wilson Snyder d9b33d74a4 Support void' cast on functions called as tasks, bug1383. 2019-03-10 15:12:20 -04:00
Wilson Snyder 539a773ea7 Add IGNOREDRETURN warning. 2019-03-10 14:57:01 -04:00
Wilson Snyder b1831d7e33 Fix +1364-1995ext flags applying too late, bug1384. 2019-03-10 14:09:22 -04:00
Wilson Snyder b8ccb7a4c1 Fix maintainer test when no Parallel::Forker, msg2630. 2019-03-10 12:14:58 -04:00
Wilson Snyder 0eb75a41bb Fix perl 5.38 warning. 2019-03-10 12:14:02 -04:00
Wilson Snyder 4cc47e3297 Tests: Cleanup spacing/style. No functional change. 2019-03-10 09:25:23 -04:00
Wilson Snyder 7bf3366041 Support . 2019-03-07 20:56:53 -05:00
Wilson Snyder c4b9f4bccf Tests: Remove old verilator_file_descriptor 2019-03-07 18:29:44 -05:00
Wilson Snyder 455c552132 Fix MSVC compile error, bug1406. 2019-03-04 20:29:01 -05:00
Wilson Snyder f26fb51509 Commentary, bug1339. 2019-03-01 20:14:48 -05:00
Wilson Snyder ab3c6576ed Report PORTSHORT errors on concat constants, bug 1400. 2019-02-27 21:06:07 -05:00
Wilson Snyder d1bd994113 Commentary, bug1399. 2019-02-26 18:56:13 -05:00
Wilson Snyder d1548b1161 Commentary 2019-02-26 18:24:46 -05:00
Wilson Snyder 8a43f41ed6 Fix $value$plus$args missing verilated_heavy.h. 2019-02-15 18:33:52 -05:00
Wilson Snyder 42759e4011 Fix VERILATOR_GDB being ignored, msg2860. 2019-02-12 18:20:40 -05:00
Wilson Snyder 27fa19eb94 Add +verilator+seed, bug1396. 2019-02-04 20:28:17 -05:00
Wilson Snyder 426ed8589b devel release 2019-01-28 07:30:42 -05:00
Wilson Snyder 44e53129a0 Version bump 2019-01-27 21:31:05 -05:00
Wilson Snyder cf2e8f7a9c Add sizeof checks on types. 2019-01-25 18:26:14 -05:00
Wilson Snyder 46be6d32c9 Add unsupported for loops error, msg2692. 2019-01-22 19:25:00 -05:00
Wilson Snyder 93d1fd6bb5 Commentary, msg2820 2019-01-22 18:46:47 -05:00
Wilson Snyder f700a73b3e Fix cygwin warning on fstapi, msg2770. 2019-01-20 14:16:09 -05:00
Wilson Snyder abd69167ef Commentary 2019-01-18 18:15:07 -05:00
Wilson Snyder 60f2f176a2 Fix DPI export void compiler error, bug1391. 2019-01-16 00:38:42 -05:00
Wilson Snyder 3a51e84ebc For XML, fix extends, bug1372. 2019-01-13 20:59:15 -05:00
Wilson Snyder a2a09253a2 Internals: Show static funcs. 2019-01-12 09:43:24 -05:00
Wilson Snyder ef884143d1 Add circular typedef error, bug1388. 2019-01-12 09:33:57 -05:00
Wilson Snyder 62a7d713a7 Fix internal error on xrefs into unrolled functions, bug1387. 2019-01-06 17:38:27 -05:00
Wilson Snyder aaf5b7c2c0 Fix uninitialized data in unroller, bug1386. [Al Grant] 2019-01-06 16:56:56 -05:00
Wilson Snyder 30aa180211 Internals: Use pushDelete for empty unrolls. Theoretical problem only. 2019-01-05 06:53:26 -05:00
Wilson Snyder 0d4270c979 Turn off temporary debug message. 2019-01-05 06:01:22 -05:00
Wilson Snyder 3505486ec8 Internals: Spacing; fix assertion 2019-01-05 05:46:37 -05:00
Wilson Snyder 9b0f2cce86 Copyright year update 2019-01-05 05:46:23 -05:00
Wilson Snyder 0e1f8db0d1 Fix uninitialized data in verFiles.dat, bug1385. 2019-01-05 04:58:14 -05:00
Wilson Snyder 8a4aeddbb0 Copyright year update. 2019-01-03 19:17:22 -05:00
Wilson Snyder e8636f987f Fix missing too many digits warning, bug1380. 2019-01-03 19:03:27 -05:00
Wilson Snyder 0198a2e9f3 Fix error when no modules in , bug1381. 2019-01-02 18:38:49 -05:00
Wilson Snyder db92ab47ba For --xml, add additional information, bug1372. 2019-01-02 07:16:37 -05:00
Wilson Snyder 47107a5a36 Fix FST tracing of wide arrays, bug1376. 2018-12-18 20:49:44 -05:00
Wilson Snyder e01c9df35e Fix error when pattern assignment has too few elements, bug1378. 2018-12-18 20:41:14 -05:00
Wilson Snyder 8f16557499 Tests: Less verbose 2018-12-12 22:19:33 -05:00
Wilson Snyder 89fb57e54f For --xml, add additional information, bug1372. 2018-12-12 22:12:31 -05:00
Wilson Snyder 8a3e9748b3 For --xml, add additional information, bug1372. 2018-12-10 19:11:35 -05:00
Wilson Snyder 66b23be746 For --xml, add additional modport information, bug1372. 2018-12-10 07:25:44 -05:00
Wilson Snyder f0cdae129e Removed --trace-lxt2, use --trace-fst instead. 2018-12-06 19:06:20 -05:00
Wilson Snyder ede7236945 For --xml, add additional var information, bug1372. 2018-12-06 07:12:39 -05:00
Wilson Snyder a226111829 Fix fst_config compile error on MINGW, msg2670. 2018-12-06 07:12:21 -05:00
Wilson Snyder 49edcbc2ac Internals: Misc cleanup. No functional change. 2018-12-06 06:56:39 -05:00
Wilson Snyder 6050ab311e Commentary 2018-12-05 20:14:22 -05:00
Wilson Snyder 83b5c981d0 devel release 2018-12-01 15:07:31 -05:00
Wilson Snyder 2685037ca2 Version bump 2018-12-01 14:52:21 -05:00
Wilson Snyder 940dc98c66 Add CONTASSREG error on continuous assignments to regs, bug1369. 2018-12-01 10:12:10 -05:00
Wilson Snyder 49353784fd Fix __Slow files getting compiled with OPT_FAST, bug1370. 2018-11-29 20:35:21 -05:00
Wilson Snyder 2e5919549c Tests: Separate make_main flag from verilator_make_gcc flag. 2018-11-29 19:50:09 -05:00
Wilson Snyder 8170391573 Internals: Fix spacing of comments. No functional change. 2018-11-28 19:59:10 -05:00
Wilson Snyder 61e4b0a472 Add IMPORTSTAR warning on import::* inside scope. 2018-11-28 18:25:34 -05:00
Wilson Snyder 15af706286 Fix crash due to cygwin bug in getline, bug1349. 2018-11-26 19:09:08 -05:00
Wilson Snyder 2a43410fa6 Tests: Fix buggy size test. 2018-11-26 18:22:20 -05:00
Wilson Snyder 5cc11839b5 Add PROCASSWIRE error on behavioral assignments to wires, msg2737. 2018-11-26 17:58:18 -05:00
Wilson Snyder d1bfeae026 Tests: Ignore obj_vcs 2018-11-25 21:08:16 -05:00
Wilson Snyder e0b2c46664 Internals: Function return values act as vars, not wires. 2018-11-25 19:50:53 -05:00
Wilson Snyder ea61559ab5 Internals: Cleaner name for var. No functional change. 2018-11-25 19:10:18 -05:00
Wilson Snyder 6a5a2a56d7 Internals: Favor AstNetlist for global thread errors, and allow 0 line number error suppression. 2018-11-16 20:49:17 -05:00
Wilson Snyder 5cbf80918f Tests: Favor golden files over long regexps. No functional change. 2018-11-03 14:59:04 -04:00
Wilson Snyder 196e3a9712 Tests: Reduce timeout when single-threaded testing. 2018-11-03 09:07:28 -04:00
Wilson Snyder 3798b80091 Tests: Fix test instability. 2018-11-03 09:07:11 -04:00
Wilson Snyder 689e4cf1d3 Tests: Have files_identical fail on error 2018-11-01 21:58:39 -04:00
Wilson Snyder 64f11251b6 Fix verilator_coverage not sorting output 2018-11-01 21:39:37 -04:00
Wilson Snyder 6cd2bd2972 Tests: Add golden_filename. 2018-11-01 21:04:19 -04:00
Wilson Snyder d396c55e34 In --xml-only show module_files and cells ala Verilog-Perl vhier, msg2716. 2018-11-01 19:53:26 -04:00
Wilson Snyder 45c9939a5e Fix hang on bad pattern keys, bug1364. 2018-11-01 19:03:52 -04:00
Wilson Snyder ad2929dff0 Support "ref" and "const ref" pins and functions, bug1360. 2018-10-30 20:50:09 -04:00
Wilson Snyder d3e1dfd3f5 Tests: Add VERILATOR_MAKE override variable. 2018-10-30 20:28:39 -04:00
Wilson Snyder 14b48140bd In --xml-only show the original unmodified names, msg2716. 2018-10-30 18:17:37 -04:00
Wilson Snyder 7be1678fb0 Fix --trace-lxt2 compile error on MinGW, msg2711. 2018-10-30 07:35:30 -04:00
Wilson Snyder d464ce1477 Fix unneeded emit comment. No functional change. 2018-10-29 20:48:50 -04:00
Wilson Snyder 0a04f79576 Commentary 2018-10-28 08:16:19 -04:00
Wilson Snyder b8098098d8 Internals: Refactor input/output to new class in prep for ref support. 2018-10-27 17:29:00 -04:00
Wilson Snyder dc26815b1c Tests: Report wide line numbers. 2018-10-27 17:21:07 -04:00
Wilson Snyder f2028b60af Internals: Expand git_untabify lines touched. 2018-10-27 16:48:42 -04:00
Wilson Snyder 06c7d8ce3b Internals: Fix whitespace issues. No functional change, use -b to diff 2018-10-27 10:03:28 -04:00
Wilson Snyder 160505c5a4 devel release 2018-10-27 08:48:12 -04:00
Wilson Snyder 3df9b4230b Version bump 2018-10-27 08:27:10 -04:00
Wilson Snyder 13163aef24 make distclean should remove .1 files as not in distribution 2018-10-27 08:26:25 -04:00
Wilson Snyder 5c2b5bd782 Internals: Expand git_untabify lines touched 2018-10-26 19:49:36 -04:00
Wilson Snyder da1ebcb4e4 Add --pp-comments, msg2700. 2018-10-25 21:17:25 -04:00
Wilson Snyder 8dbfc940ba Internals: Refactor comment parsing. No functional change intended. 2018-10-25 20:46:23 -04:00
Wilson Snyder e0654dc218 Add --dump-defines. 2018-10-25 19:47:07 -04:00
Patrick Stewart 74a92e739f Internals: Fix missing static. No functional change.
Signed-off-by: Wilson Snyder <[email protected]>
2018-10-24 19:40:07 -04:00
Wilson Snyder 304a24d03a Internals: Fix many clang-tidy issues. No functional change intended. 2018-10-14 18:39:33 -04:00
Wilson Snyder 5ae1ce90ad Internals: Refactor into cvtToHex function. No functional change. 2018-10-14 16:25:36 -04:00
Wilson Snyder d87b9d25ca Internals: Cleanup and standardize include order. No functional change intended. 2018-10-14 13:59:40 -04:00
Wilson Snyder 9bc8d77f39 Includes: Move version to implementation only. 2018-10-14 11:21:09 -04:00
Wilson Snyder b7e4083e70 Internals: Cleanup temp string inserts for clang-tidy. No functional change. 2018-10-14 11:10:11 -04:00
Wilson Snyder 595419b370 Internals: Sort includes for clang-tidy. No functional change intended. 2018-10-14 07:04:18 -04:00
Wilson Snyder 442e4f35f0 Internals: Cleanup empty string constructors for clang-tidy. No functional change. 2018-10-13 23:06:36 -04:00
Wilson Snyder e8b8b33ff6 Internals: Cleanup find with chars for clang-tidy. No functional change. 2018-10-13 22:28:59 -04:00
Wilson Snyder e4d638c73d Internals: Cleanup string casts. No functional change. 2018-10-13 22:02:39 -04:00
Wilson Snyder bccb9f794c Fix Windows .exe not found, bug1361. 2018-10-12 19:13:50 -04:00
Wilson Snyder fe0dae74c1 include: Upstream update for GTKWave 2018-10-12 06:55:12 -04:00
Wilson Snyder b59c23d346 Move some unsupported syntax to parser for cleaner errors. 2018-10-11 21:57:07 -04:00
Wilson Snyder 6047049fc7 Fix --trace-lxt2 compile error on MinGW, msg2684. 2018-10-11 21:03:49 -04:00
Wilson Snyder 08e650a2b4 Commentary 2018-10-11 21:00:29 -04:00
Wilson Snyder 11d4d6562f Commentary 2018-10-10 17:10:59 -04:00
Wilson Snyder 5c9da65606 Fix --trace-lxt2 compile error on MinGW, msg2667. 2018-10-10 06:54:51 -04:00
Wilson Snyder 97d89cce35 Move some unsupported syntax to parser for cleaner errors. 2018-10-08 22:18:09 -04:00
Wilson Snyder cc45a3dd72 For --trace-fst, save enum decoding information, bug1358. 2018-10-08 07:21:22 -04:00
Wilson Snyder 870918a788 Tests: Dump and test FST trace attributes. 2018-10-07 22:04:49 -04:00
Wilson Snyder 41be66af95 Indent output C code '= {' blocks. 2018-10-07 21:23:45 -04:00
Wilson Snyder 9ad252be34 For --trace-fst, instead of *.fst.hier, put data into *.fst. 2018-10-07 20:47:26 -04:00
Wilson Snyder 1f344ac99e Fix whitespace on trace function calls. Output changed, but no functional change. 2018-10-07 18:17:45 -04:00
Wilson Snyder 8b738c0022 Compute struct/union/enum names from surrounding typedefs. 2018-10-07 18:07:42 -04:00
Wilson Snyder 57fbf38fb2 Internals: Don't detabify gtkwave files. 2018-10-07 18:00:04 -04:00
Wilson Snyder 4cd01bc99a Deprecate --trace-lxt2. 2018-10-06 14:13:38 -04:00
Wilson Snyder fc0cf00b1d devel release 2018-10-06 10:12:31 -04:00
Wilson Snyder 4333c201f1 Version bump 2018-10-06 09:51:57 -04:00
Wilson Snyder 1f5913a83c Internals: V3Simulate refactoring prep for future work. No functional change. 2018-10-05 20:26:54 -04:00
Wilson Snyder 159c653b4b Internals: V3Simulate refactoring prep for future work. No functional change. 2018-10-05 20:06:08 -04:00
Wilson Snyder 47a2e2aeb9 Commentary 2018-10-05 18:47:46 -04:00
Wilson Snyder 98b0d19363 Tests: Add enum to trace test. 2018-10-05 18:38:52 -04:00
Wilson Snyder 24a0873f6d Commentary 2018-10-05 06:47:18 -04:00
Wilson Snyder c5fee7c456 Fix flex warning 2018-10-04 20:51:20 -04:00
Wilson Snyder d11592cadd Support signal types in FST dumps, bug1358. 2018-10-04 20:24:41 -04:00
Wilson Snyder 8ef9ac7dba Support in/out directions in FST dumps, bug1358. 2018-10-03 19:51:05 -04:00
Sergi Granell a5aa0e2b0a Add GTKWave FST native tracing, bug1356.
Signed-off-by: Wilson Snyder <[email protected]>
2018-10-02 18:42:53 -04:00
Wilson Snyder f8ae08c0c2 Internals: Fix whitespace. 2018-10-02 06:31:11 -04:00
Wilson Snyder 72f5d39ace Rename include/lxt2 to include/gtkwave. 2018-10-01 18:29:04 -04:00
Sergi Granell 5c9801d42c Commentary
Signed-off-by: Wilson Snyder <[email protected]>
2018-09-30 17:34:47 -04:00
Wilson Snyder c9ee425ed5 Fix replication of 64-bit signal change detects. 2018-09-28 08:36:37 -04:00
Wilson Snyder 1871e2b541 Commentary 2018-09-27 19:58:17 -04:00
Wilson Snyder 3e39c55a97 Tests: Check mod-prefix subnames. 2018-09-27 19:58:13 -04:00
Wilson Snyder e4d6fa0e3b include: Update license from GTKWave upstream. 2018-09-27 19:55:00 -04:00
Wilson Snyder 9f8dbc91f2 Support restrict, bug1350. 2018-09-23 15:20:12 -04:00
Wilson Snyder 0e37747d2c Support $past. 2018-09-23 15:20:01 -04:00
Wilson Snyder a8519a7a53 Fix MinGW compile issues, msg2636. 2018-09-20 18:09:19 -04:00
Kevin Kiningham d4159811d2 configure: Fix test for c++03 etc. 2018-09-17 21:47:35 -04:00
Kevin Kiningham b2ca4995ab Fix Mac OSX 10.13.6 / LLVM 9.1 compile issues, bug1348. 2018-09-17 18:35:23 -04:00
Wilson Snyder 7876fe94ad Fix Mac OSX 10.13.6 / LLVM 9.1 compile issues, bug1348. 2018-09-17 06:39:43 -04:00
Wilson Snyder cc9f7d1ac3 devel release 2018-09-17 06:24:18 -04:00
Wilson Snyder 94c295f26a Version bump 2018-09-16 17:02:50 -04:00
Wilson Snyder 8c51b5a980 Docs: Add logo to PDF 2018-09-16 17:01:45 -04:00
Wilson Snyder 4f98f84da9 Fix duplicate symbol error on generate tri, bug1347. 2018-09-14 06:56:59 -04:00
Wilson Snyder 63a429dd64 pod2latex: Cleanup latex build in prep for logo 2018-09-13 20:06:10 -04:00
Wilson Snyder 9c3331927b Fix man files misinstalling; cleanup mkinstalldirs 2018-09-13 19:09:35 -04:00
Wilson Snyder 3a6edae59d Fix string ?: conditional type resolution, bug1345. 2018-09-12 19:20:15 -04:00
Wilson Snyder 75794e2eaa Fix number parsing with newline after radix, bug1340. 2018-09-12 19:19:48 -04:00
Wilson Snyder 24efa6c19a Fix compile error on tracing of string arrays, bug1338. 2018-09-08 01:16:07 -04:00
Wilson Snyder 7a8c5ecfe1 Disable GCC2017, bug1339. 2018-09-03 08:19:43 -04:00
Wilson Snyder 4684f1d4cc Include sys/types to make sure __WORDSIZE is set, bug1333. 2018-08-31 06:52:12 -04:00
Wilson Snyder ef5c31b4c9 Fix first clock edge and --x-initial-edge, bug1327. 2018-08-30 20:05:13 -04:00
Wilson Snyder 9d21c5441b tests: Fix strange verilated-debug flag 2018-08-30 20:04:55 -04:00
Wilson Snyder 24fe724e0b Commentary 2018-08-30 18:51:02 -04:00
johnjohnlin acf4a3fa99 Add GTKWave LXT2 native tracing, bug1333.
Signed-off-by: Wilson Snyder <[email protected]>
2018-08-28 06:41:17 -04:00
Wilson Snyder 3ed8d968ff Commentary and spacing. No functional change. 2018-08-28 06:30:30 -04:00
Wilson Snyder 45c09f3fae Fix LLVM thread_safety function 2018-08-27 18:25:58 -04:00
Wilson Snyder c93d28050e Fix mkdir on MSYS2, msg2614. 2018-08-27 18:07:52 -04:00
Wilson Snyder 15abb4d590 Fix OS X compile issues, bug1332. 2018-08-27 06:15:12 -04:00
Wilson Snyder ae98e87222 Fix OS X compile issues, bug1332. 2018-08-26 19:55:02 -04:00
Wilson Snyder 77f6b8cf5f Use local algorithm for random, bug1332. 2018-08-26 07:07:01 -04:00
Wilson Snyder 573e79a329 Fix OS X compile issues, bug1332. 2018-08-25 17:54:27 -04:00
Wilson Snyder aaac5d4685 Support string.atoi and similar methods, bug1289. 2018-08-25 13:49:37 -04:00
Wilson Snyder b02e353ad1 Internals: Fix VERILATOR_NO_OPT_BUILD, broken in recent commit. 2018-08-25 13:11:28 -04:00
Wilson Snyder 80a269f49a Tests: Add t_param_array3 test, bug1315 2018-08-25 10:36:31 -04:00
Wilson Snyder 75f28fd446 Internals: Fix spacing of function calls. No functional change. 2018-08-25 09:52:45 -04:00
Wilson Snyder ec538c02d8 MAJOR: Merge develop-v4 into master 2018-08-25 08:01:15 -04:00
Wilson Snyder f7b93c8718 Fix install test. 2018-08-25 07:55:48 -04:00
Wilson Snyder 18ae08e14a Commentary 2018-08-25 07:54:06 -04:00
Wilson Snyder bffe658026 Commentary 2018-08-25 07:53:17 -04:00
Wilson Snyder 789917cd06 Fix Ubuntu 18 warnings. 2018-08-24 18:47:38 -04:00
Wilson Snyder 8f838433df Internals: Fix spacing and style of v4 changes. No functional change. 2018-08-23 05:22:34 -04:00
Wilson Snyder 0b84222500 Includes: Fix spacing and style in prep for new LXT2. No functional change. 2018-08-22 19:14:06 -04:00
Wilson Snyder aad5c3ae75 Merge from master 2018-08-22 18:50:19 -04:00
Wilson Snyder b586e071fb devel release 2018-08-22 18:49:30 -04:00
Wilson Snyder c8e437c45c Version bump 2018-08-22 18:09:06 -04:00
Wilson Snyder 4d034d774d Merge from master 2018-08-22 17:58:02 -04:00
Wilson Snyder 4627716aa4 Remove extra space in generated func call. 2018-08-21 18:14:32 -04:00
Wilson Snyder 847dbbbaf0 Fix function inlining inside certain while loops, bug1330. 2018-08-21 18:09:40 -04:00
Wilson Snyder c011842edf Commentary: Rewrite TODO 2018-07-24 07:37:39 -04:00
Wilson Snyder aabb7394c3 Merge from master 2018-07-23 19:05:17 -04:00
Wilson Snyder d90064eaee Change MODDUP errors to warnings, msg2588. 2018-07-23 18:57:34 -04:00
Wilson Snyder ec8dbbffed MAJOR: Add multithreaded model generation. 2018-07-22 20:54:28 -04:00
Wilson Snyder 0070520edb Fix cppcheck warnings. 2018-07-22 20:41:46 -04:00
Wilson Snyder 8e646bc55f configure: Add URL 2018-07-22 19:44:03 -04:00
Wilson Snyder e97dbf9537 Add UNOPTTHREADS, for threads branch. 2018-07-22 12:09:27 -04:00
Wilson Snyder 0ef3baa87d Merge from master 2018-07-22 11:53:58 -04:00
Wilson Snyder 3a777c2a37 Verilated: Always define VL_RDTSC, though unused; useful for benchmarking. 2018-07-22 11:53:35 -04:00
Wilson Snyder 237f4806bf Fix doxygen old dir refs. 2018-07-20 19:45:58 -04:00
Wilson Snyder 8ec8c0ea76 Merge from master 2018-07-18 22:43:22 -04:00
Wilson Snyder dfe66a2b77 Fix whitespace after functions in generated files. 2018-07-18 22:42:05 -04:00
Wilson Snyder a18d6c8159 Merge from master 2018-07-18 21:34:38 -04:00
Wilson Snyder a0b09b6450 Remove tabs inside generated files/quotes. 2018-07-18 21:25:21 -04:00
Wilson Snyder ca24357611 Fix gcc 4.4.7 compile errors 2018-07-16 20:38:31 -04:00
Wilson Snyder 78c16081a4 Assume most branches in bounds, and use branchpred for instruction estimation. 2018-07-15 22:35:44 -04:00
Wilson Snyder e37dce9d85 Internals: Add new graph algs for future partitioning. 2018-07-15 22:09:27 -04:00
Wilson Snyder 43694ec87c Continued... Show file and line info when possible on internal graph errors. 2018-07-14 20:44:43 -04:00
Wilson Snyder 22939d7473 Merge from master 2018-07-14 19:27:51 -04:00
Wilson Snyder 9e3a88c41d Inability to write a file is typically user, not internal error. 2018-07-14 19:22:50 -04:00
Wilson Snyder cf4bf9b7a5 Show file and line info when possible on internal graph errors. 2018-07-14 18:45:06 -04:00
Wilson Snyder d065662afc Internals: Add new UASSERT. Currently unused. No functional change. 2018-07-14 17:44:55 -04:00
Wilson Snyder 70e2538436 Internals: V3InstrCount now shows critical path only for branch. Still not used in develop-v4. 2018-07-14 17:31:36 -04:00
Wilson Snyder 338ebcd6f0 Internal: Minor style cleanups for next merge. No functional change. 2018-07-14 17:27:05 -04:00
Wilson Snyder ea8b416e91 Internals: Rename recent template. No functional change. 2018-07-09 21:32:10 -04:00
Wilson Snyder de81593e98 Internals: Template GraphAlg to allow const. No functional change. 2018-07-09 19:15:46 -04:00
Wilson Snyder 84562f98de Internals: Add GraphWay methods for future graph algs. No functional change. 2018-07-08 22:01:16 -04:00
Wilson Snyder 5520759d9e Internals: Track dpi import wrapper creation. No functional change. 2018-07-07 08:02:29 -04:00
Wilson Snyder 9156a0e400 Internals: Allow override of initial value for vl_unordered_set() 2018-07-05 20:39:03 -04:00
John Coiner 736bf75a50 tests: Allow cmdline args to override test args. 2018-07-05 18:52:25 -04:00
Wilson Snyder 81ef9b5dd2 Internals: Add V3InstrCount, for threads branch. 2018-07-04 21:52:15 -04:00
Wilson Snyder 2f18a52118 Ignore automake flags passed by Ubuntu builds 2018-07-04 17:09:59 -04:00
Wilson Snyder f3ed36840e Update error, bug1322. 2018-07-04 17:09:59 -04:00
Wilson Snyder 129610821f Ignore automake flags passed by Ubuntu builds 2018-07-03 21:34:50 -04:00
Wilson Snyder 4cd0310516 Update error, bug1322. 2018-07-02 09:11:20 -04:00
Wilson Snyder 8b245138ee Merge from master 2018-07-01 21:48:18 -04:00
Wilson Snyder 4f962bddd8 Fix std:: build error, bug1322. 2018-06-28 18:55:36 -04:00
Wilson Snyder 02738ec4ea Warn if using pre-C++11 so find out who needs it. 2018-06-26 17:57:57 -04:00
Wilson Snyder e8a23cf8bc Fix to ignore Unicode UTF-8 BOM sequences, msg2576. 2018-06-26 17:57:57 -04:00
Wilson Snyder 39ecfd9900 Internals: rank() public for future optimizers. 2018-06-26 17:57:57 -04:00
Wilson Snyder d6a7073a2b Commentary 2018-06-26 17:57:57 -04:00
Wilson Snyder 45eddfb335 Warn if using pre-C++11 so find out who needs it. 2018-06-26 07:33:55 -04:00
Wilson Snyder d4b9b5aba6 Fix to ignore Unicode UTF-8 BOM sequences, msg2576. 2018-06-26 07:11:56 -04:00
Wilson Snyder b1bf742544 Internals: rank() public for future optimizers. 2018-06-24 18:47:08 -04:00
Wilson Snyder ebab30d864 Fix new reloop misinserting Vars 2018-06-24 11:22:56 -04:00
Wilson Snyder cdd70ff8fc Commentary 2018-06-24 08:08:34 -04:00
Wilson Snyder ad4c8ee955 Add new reloop optimization for repetitive assignment compression. 2018-06-23 17:07:22 -04:00
Wilson Snyder 2edfe7b8a8 Internals: Ordering internals realigned with thread branch. 2018-06-22 23:01:50 -04:00
Wilson Snyder 3444dad9ce Internals: Refactoring in prep for next commit. No functional change. 2018-06-22 22:56:58 -04:00
Wilson Snyder b8842f7e55 Fix clocker attributes to not propagate on concats. 2018-06-22 19:46:27 -04:00
Wilson Snyder 86d85412e1 Merge from master 2018-06-22 18:51:02 -04:00
Wilson Snyder 2b56acb39a Add git_untabify utility 2018-06-22 07:09:21 -04:00
Wilson Snyder 35a40b4930 Commentary 2018-06-22 06:35:27 -04:00
Wilson Snyder c1f2b2cf93 *Ordering Change*: Separate initial and settle when ordering. From threads branch. 2018-06-21 23:12:11 -04:00
Wilson Snyder 011e9f3b0a Internals: Reorder some functions in prep for threads. No functional change. 2018-06-21 23:08:56 -04:00
Wilson Snyder dddc51b75c Internals: Rename templated types to be T_*. Use Euler hashing. 2018-06-21 21:14:38 -04:00
Wilson Snyder 5187096bf9 Merge from master 2018-06-21 20:29:24 -04:00
Wilson Snyder ae33a1ceb1 Tests: Add t_gate_tree test 2018-06-21 20:27:33 -04:00
Wilson Snyder d225e46e4a Fix define argument stringification, broke since 3.914. 2018-06-21 08:19:59 -04:00
Wilson Snyder dcf946b437 Rework V3LifePost to be similar to threading algorithm's. 2018-06-20 23:44:58 -04:00
Wilson Snyder 2a5123f318 Internals: Spacing change in prep for LifePost rewrite from branch. No functional change. 2018-06-20 20:24:11 -04:00
John Coiner 43d07235c9 Tests: Fix sc_main compilation errors.
Signed-off-by: Wilson Snyder <[email protected]>
2018-06-20 19:01:19 -04:00
Wilson Snyder 1fad055286 Internals: Add TSP solver, for future threads branch. 2018-06-17 21:06:41 -04:00
Wilson Snyder e89cb1b9f7 Internals: For unordered set, add constant accessor. No functional change. 2018-06-17 10:31:27 -04:00
Wilson Snyder 4c7a397dc4 Merge from master 2018-06-16 18:05:26 -04:00
Wilson Snyder 047a08c999 Internals: Clean some UASSERTs. No functional change. 2018-06-16 18:00:21 -04:00
Wilson Snyder 1d74657bbb Internals: Remove dead code 2018-06-16 17:59:57 -04:00
Wilson Snyder 7085fdbc27 Internals: Refactor var sorting, merge from threads branch. 2018-06-16 07:45:30 -04:00
Wilson Snyder 4c9c39bd08 Merge from master 2018-06-16 07:32:32 -04:00
Wilson Snyder ec82243ee6 Fix shrinking new unordered_set_map to save memory. No end-result change intended. 2018-06-15 20:57:07 -04:00
Wilson Snyder 65bb93a6c5 Add OBJCACHE envvar support to examples and generated Makefiles. 2018-06-15 07:13:18 -04:00
Wilson Snyder 6e7f28785e Internals: Cleanup graph includes. No functional change. 2018-06-15 06:54:03 -04:00
Wilson Snyder 35654b5355 Tests: Backward port from threads branch. 2018-06-15 06:28:33 -04:00
Wilson Snyder efb2801eeb Internals: Add orderPreRanked. No functional change. 2018-06-14 20:29:54 -04:00
Wilson Snyder 9f5a4c9b22 Fix cppcheck warnings. No functional change intended. 2018-06-14 19:04:52 -04:00
Wilson Snyder 7fc565a1bd Merge from master 2018-06-14 19:04:36 -04:00
Wilson Snyder 0eb1d0a84e Fix cppcheck warnings. No functional change intended. 2018-06-14 18:59:24 -04:00
Wilson Snyder 5d26bca55c Internals: Remove unneeded returns on asserts. 2018-06-13 18:05:00 -04:00
John Coiner ba69297c33 Merge branch 'develop-v4' of ssh://git-verilator-jcoiner/git/verilator into develop-v4 2018-06-13 08:23:40 -04:00
John Coiner 8b5dc0b678 Fix nasty performance bug in rehash() that could lead to rehashing everything into one giant bucket, but only for tables with >256K elements, so we never saw it in regression. 2018-06-13 08:20:19 -04:00
Wilson Snyder 5988bba9fb Merge from master 2018-06-12 21:25:26 -04:00
Wilson Snyder a15e6f68dd devel release 2018-06-12 21:22:01 -04:00
Wilson Snyder 77e7e2bf1c Version bump 2018-06-12 21:20:12 -04:00
Wilson Snyder 1c5c9e2435 cppcheck fixes 2018-06-12 21:14:20 -04:00
Wilson Snyder adfb903469 Merge from master 2018-06-12 05:23:13 -04:00
John Coiner 3e739db7fa Fix linear searches. bug1316. 2018-06-11 22:05:45 -04:00
John Coiner c124fe6d0c Add clones of std::unordered_map and std::unordered_set for pre-C++11 compilers. 2018-06-11 22:05:15 -04:00
James Hutchinson f0ed4346b2 Fix to be in verilog 2005, bug1319.
Signed-off-by: Wilson Snyder <[email protected]>
2018-06-08 08:01:22 -04:00
John Coiner 94c8064798 Fix linear search; this is part of the fix for issue 1316. 2018-06-07 12:43:19 -04:00
Wilson Snyder 95da5f90c7 Tests: Fix runflag test stability. 2018-05-29 20:33:04 -04:00
Wilson Snyder e4a79d643d Fix error without nodep. 2018-05-29 20:03:58 -04:00
Wilson Snyder 27c7d0c95b Merge from master 2018-05-29 20:02:07 -04:00
Wilson Snyder cf0464c263 Internals: Cleanup V3EmitC common code. No functional change. From threads branch. 2018-05-29 19:55:42 -04:00
Wilson Snyder 05a8a9ee28 Remove NULL checks of this, as upsets some compilers. 2018-05-26 08:28:19 -04:00
Wilson Snyder 6268db643c Commentary 2018-05-25 07:17:38 -04:00
Wilson Snyder fd98d231e4 Tests: Fix determinism of randomization. 2018-05-25 07:15:29 -04:00
Wilson Snyder b1ab48b9fc Include: Fix command line parser hang when threaded. 2018-05-25 07:02:15 -04:00
Wilson Snyder e4e3294363 Merge from master 2018-05-24 22:18:09 -04:00
Wilson Snyder 92649ba494 includes: Fix VL_RDTSC & misc stuff. 2018-05-24 22:17:44 -04:00
Wilson Snyder 9afa1f7fb9 Commentary 2018-05-20 09:16:37 -04:00
Wilson Snyder c253b7769e Merge from master 2018-05-20 09:14:30 -04:00
Wilson Snyder 0efe343494 Renamed --profile-cfuncs to --prof-cfuncs. 2018-05-20 09:12:29 -04:00
Wilson Snyder f3c9b4fb03 Add runtime arguments. 2018-05-20 08:40:35 -04:00
Wilson Snyder 26c31db75e Merge from master 2018-05-20 08:37:03 -04:00
Wilson Snyder 84335b9580 Verilated: Cleanup command line parsing. Backport from pending v4 change. 2018-05-20 08:36:39 -04:00
Wilson Snyder e8b2c57610 Commentary 2018-05-19 14:50:28 -04:00
Wilson Snyder 3d49136e27 Merge from master 2018-05-19 09:32:15 -04:00
Wilson Snyder 5e22ca77ec Tests: Fix misc multithreaded issues, merge from threads branch. 2018-05-19 09:30:54 -04:00
Wilson Snyder b6e8133a4d When tracing, use scalars on single bit arrays to appease vcddiff. 2018-05-19 07:52:07 -04:00
Wilson Snyder 02a22c12ea Internals: Add missing [] to delete call in verilated_vcd_c.cpp, bug1309 2018-05-17 07:08:11 -04:00
Wilson Snyder cd4e6b35b3 Internals: Standardize debug() function generation. No functional change intended. 2018-05-14 06:50:47 -04:00
Wilson Snyder 4abf5be9ce Detect linker requirements for multithreaded runtime. 2018-05-13 19:47:35 -04:00
Wilson Snyder 9ba6fc9279 Merge from master 2018-05-13 19:39:30 -04:00
Wilson Snyder fe917ba7f4 include: Merge misc thread runtime support. 2018-05-13 19:30:51 -04:00
Wilson Snyder 2c568603f6 Fix latex warning & misc Commentary 2018-05-13 19:21:08 -04:00
Wilson Snyder 05db8ce6c8 Internals: Move iterators to AstNVisitor to avoid null this. 2018-05-10 20:55:37 -04:00
Wilson Snyder 51422e3ee8 Fix parsing error on bad missing #, bug1308. 2018-05-09 18:32:12 -04:00
Wilson Snyder 489f58011b Merge from master 2018-05-08 21:43:55 -04:00
Wilson Snyder 0ef3c10931 Pull some thread include changes from thread branch. 2018-05-08 21:43:32 -04:00
Wilson Snyder 1759b0826e Merge from master 2018-05-08 19:43:26 -04:00
Wilson Snyder 35be80f789 Tests: Use vlt_all for any Verilator test. 2018-05-08 19:39:32 -04:00
Wilson Snyder 5f3c9cca11 Merge from master 2018-05-07 20:58:30 -04:00
Wilson Snyder c29e7619eb Tests: Support multiple scenario testing. 2018-05-07 20:42:28 -04:00
Wilson Snyder a265417727 Tests: Cleanup Perl indentations. No functional change. 2018-05-06 22:39:18 -04:00
Wilson Snyder b69af164f7 Commentary 2018-05-06 20:40:23 -04:00
Wilson Snyder ff61bb509c Tests: Fix race and dead code. 2018-05-05 07:44:52 -04:00
Wilson Snyder f02b99c709 Merge from master 2018-04-30 20:36:26 -04:00
Wilson Snyder c8ba51581f Commentary 2018-04-30 20:34:52 -04:00
Wilson Snyder 29f1a9208e Commentary 2018-04-30 20:00:38 -04:00
John Coiner 542cf9b6e1 Remove errant assert from V3Split 2018-04-13 06:54:53 -04:00
Wilson Snyder 8b954dc381 Additional debug prints 2018-04-12 22:00:34 -04:00
Wilson Snyder 2f7002c5ec Merge from master 2018-04-10 22:11:49 -04:00
John Coiner 767ac2547d Misc clang warning fixes.
Signed-off-by: Wilson Snyder <[email protected]>
2018-04-10 22:05:55 -04:00
Wilson Snyder a46aa2d62b Fix verilator_profcfunc on old gprofs. 2018-04-10 22:05:17 -04:00
Todd Strader 9219ddaece Report interface ports connected to wrong interface, bug1294. 2018-04-04 21:03:43 -04:00
Wilson Snyder c7c99d8553 Fix parsing "output signed" in V2K port list, msg2540. 2018-03-29 20:10:27 -04:00
John Coiner 422c915c1d Fix a nondeterminism issue in the new V3Split 2018-03-29 14:03:18 -04:00
Wilson Snyder 1f04d17e77 Merge from master 2018-03-17 12:03:08 -04:00
Wilson Snyder e3354a0191 devel release 2018-03-17 12:01:59 -04:00
Wilson Snyder df3d1a4da9 Version bump 2018-03-17 11:56:37 -04:00
Wilson Snyder 3963fe4384 Fix GCC-8 compile error. 2018-03-17 11:33:47 -04:00
Wilson Snyder 38261ac649 Tests: Ignore history file. 2018-03-17 09:25:38 -04:00
Wilson Snyder e49539fb4c Internals: Put cell assigns near cell. No functional change intended except statement order. 2018-03-17 08:43:19 -04:00
Wilson Snyder 3cd96cf558 Tests: Print error line in summary file. 2018-03-16 19:54:25 -04:00
Wilson Snyder 02f18fc21b Merge from master 2018-03-15 23:31:59 -04:00
Wilson Snyder 1bcaaa0f0d Internals: Cleanup V3Inst unused argument. No functional change intended. 2018-03-15 23:19:43 -04:00
Wilson Snyder 7922a1de28 Internals: Misc cleanups related to V3LinkDot. No functional change intended. 2018-03-15 19:46:05 -04:00
John Coiner e897c862f2 Tests: t_foreach now checks that all foreach loops get unrolled and evaluated statically. 2018-03-15 19:06:32 -04:00
John Coiner f55040a38b Fix severe runtime performance bug in certain foreach loops. 2018-03-15 08:59:52 -04:00
Wilson Snyder 2d580e6939 Support IEEE 1800-2017 as default language. 2018-03-12 22:26:34 -04:00
John Coiner fc48008c1c Support 2018-03-12 16:44:01 -04:00
Wilson Snyder 4cf2e4024f verilator_difftree: Better error. 2018-03-11 16:49:40 -04:00
Wilson Snyder 57c7d77af3 Tests: Future reduction or test. 2018-03-11 16:33:38 -04:00
Wilson Snyder 5652867316 Merge from master 2018-03-11 10:42:44 -04:00
Wilson Snyder c8cf2afb15 Support assert properties, bug785, bug1290. 2018-03-11 10:37:20 -04:00
Wilson Snyder d08a91b71e Fix GCC lint complaint of calling NULL->cloneTree. No functional change intended. 2018-03-10 17:44:17 -05:00
Wilson Snyder 2c30aecc5b Merge from master 2018-03-10 16:51:34 -05:00
Wilson Snyder 770045676f Internals: Split some extremely long lines. No functional change. 2018-03-10 16:32:04 -05:00
Wilson Snyder 68cca0e114 Commentary, bug1288 2018-03-10 14:16:37 -05:00
Wilson Snyder 0a1b775ed6 Fix various small node leaks. 2018-03-10 14:10:41 -05:00
Wilson Snyder 54a101acbe Internals: Fix -DLEAK_CHECKS failing due to visitor destructor being too late. 2018-03-10 12:57:50 -05:00
John Coiner db1af07d72 On convergence errors, show activity. 2018-03-10 12:52:11 -05:00
John Coiner ff82f75023 Add --no-debug-leak to reduce memory use under debug. 2018-03-10 12:18:19 -05:00
Wilson Snyder 9ae54786e4 Commentary, bug1288. 2018-03-09 00:04:00 -05:00
Wilson Snyder 22ff760f0b Support calling system functions as tasks, bug1285. 2018-03-08 23:40:19 -05:00
John Coiner 86fe6ac3a8 Fix quoting of quoted arguments.
Signed-off-by: Wilson Snyder <[email protected]>
2018-03-08 22:43:29 -05:00
Wilson Snyder 3dccd89c18 Fix missing include for gcc6.4 2018-03-08 21:46:20 -05:00
Tymoteusz Blazejczyk 9f52e23158 Fix verilator_coverage --annotate-min, bug1284. 2018-03-07 19:52:29 -05:00
Wilson Snyder aed3307214 Enable GCC debug when in debug build 2018-03-03 20:43:14 -05:00
John Coiner ef3c7bb6a2 Better optimize large always block splitting, bug1244.
Signed-off-by: Wilson Snyder <[email protected]>
2018-02-28 06:58:41 -05:00
John Coiner 0a887c29f1 Internals: Fix V3LifePost recording assignPre variables.
Signed-off-by: Wilson Snyder <[email protected]>
2018-02-28 06:57:08 -05:00
Wilson Snyder e1410775fb Fix CC warning with flex 2.5.35. 2018-02-28 06:34:03 -05:00
Wilson Snyder f0ba17a19b Merge from master. 2018-02-27 07:24:31 -05:00
John Coiner a7a790416e Internals: Fix passing bool as int. No functional change.
Signed-off-by: Wilson Snyder <[email protected]>
2018-02-27 07:16:16 -05:00
Patrick Stewart fe5c4df079 Support trig functions (() etc), bug1281.
Signed-off-by: Wilson Snyder <[email protected]>
2018-02-26 04:25:07 -05:00
Wilson Snyder 1376e5de92 Fix pullup/pulldowns on bit selects, bug1274. 2018-02-10 19:08:07 -05:00
Wilson Snyder 7f5b1a402c Internals: Part of last change, spacing. 2018-02-07 20:29:58 -05:00
Wilson Snyder 22573d238b Internals: Fix GCC8 cppcheck warnings. No functional change. 2018-02-07 20:16:53 -05:00
Wilson Snyder 32859d9fc2 Fix GCC 8.0 issues 2018-02-07 18:58:21 -05:00
Wilson Snyder 597d28b505 Fix internals to make null-pointer-check clean. Also add more const's. No functional change intended, but likely something will break. 2018-02-01 21:32:58 -05:00
Wilson Snyder 94e8cf1de9 Internals: Use explicit std:: instead of using namespace std. No functional change intended. 2018-02-01 21:24:41 -05:00
Wilson Snyder 33d6205e20 Prepare for version 4 branch 2018-02-01 21:21:21 -05:00
Wilson Snyder 1b12800b8f devel release 2018-02-01 20:14:40 -05:00
Wilson Snyder 13d11b037a Version bump 2018-02-01 20:09:58 -05:00
Wilson Snyder 0ca0854cac Fix compile error with --public and interface bind, bug1264. 2018-02-01 20:07:46 -05:00
Wilson Snyder 1726c71649 Commentary 2018-02-01 19:20:08 -05:00
Wilson Snyder fd8c29f981 Commentary 2018-02-01 19:18:00 -05:00
Wilson Snyder e07ee559a0 Tests: Fix gcc7.2 warnings. 2018-01-31 19:27:42 -05:00
Wilson Snyder 097107bd0b Support 'assume' similar to 'assert', bug1269. 2018-01-31 07:33:10 -05:00
Wilson Snyder b40b152b87 Fix missing edge type in xml output, msg2480. 2018-01-31 07:29:14 -05:00
Wilson Snyder 3c7fef68c0 Internals: Sort EmitXml visitors. No functional change. 2018-01-31 07:25:10 -05:00
Wilson Snyder b2322ae873 Fix tracing example file output, bug1268. 2018-01-29 19:07:49 -05:00
Wilson Snyder e3f137875b Fix spacing of trace func decls. No functional change. 2018-01-29 19:04:37 -05:00
Wilson Snyder 71fcf45d73 Fix gate optimization out of memory, add --gate-stmts, bug1260. 2018-01-27 15:06:51 -05:00
Wilson Snyder 652b68a5a0 Fix compile error on public real parameters by suppressing, bug1261. 2018-01-24 22:30:30 -05:00
John Coiner 3e0401de1c Misc harmless cleanups from thread branch.
Signed-off-by: Wilson Snyder <[email protected]>
2018-01-24 20:20:26 -05:00
Stefan Wallentowitz c164024f38 Remove c++filt and fix status code of Makefile, bug1265
In the generated Makefile the linker output is piped through c++filt
which was very useful for older linkers. But unfortunately the status
code is lost during the piping. So when the make process is embedded
in a larger setup a failure will not manifest to the outside flow.

As modern linkers do the job of c++filt, this removes it from the
generated Makefile. It will also produce a proper status code then.

Signed-off-by: Wilson Snyder <[email protected]>
2018-01-18 21:25:43 -05:00
Wilson Snyder bd1f1e8699 Fix compile error on public real parameters by suppressing, bug1261. 2018-01-16 19:53:50 -05:00
Wilson Snyder 7ee6efab74 devel release 2018-01-02 18:13:45 -05:00
Wilson Snyder 3788e90644 Version bump 2018-01-02 18:06:05 -05:00
Wilson Snyder 8e65d93d6d Copyright year update. No functional change. 2018-01-02 18:05:06 -05:00
Wilson Snyder 4901668f13 Add INFINITELOOP warning, bug1254. 2017-12-26 21:35:08 -05:00
Wilson Snyder f98940e40a Fix cppcheck warnings. No functional change. 2017-12-17 18:44:35 -05:00
Wilson Snyder 49fe4d081c Support DPI open arrays, bug909, bug1245. 2017-12-17 16:28:58 -05:00
Wilson Snyder 3054b36a8d Internals: Avoid cleaning arrays in prep for openarrays. 2017-12-17 12:53:22 -05:00
Wilson Snyder b888158907 Fix DPI svGetBitselLogic and svPutPartselLogic. 2017-12-17 12:19:40 -05:00
Tymoteusz Blazejczyk 173f71dca6 Fix SystemC 2.3.2 compile error, bug1251.
Signed-off-by: Wilson Snyder <[email protected]>
2017-12-17 08:23:22 -05:00
Wilson Snyder 37a931feb4 Internals: Refactor some V3Task code in prep for openarrays. No functional change intended. 2017-12-16 15:46:21 -05:00
Wilson Snyder 79f5c7fbda Internals: Split verilated_syms.h and rename some methods. No functional change intended. 2017-12-16 10:52:43 -05:00
Wilson Snyder bf3f111ca4 Internals: Move VLVF flags to common function. No functional change. 2017-12-16 10:07:15 -05:00
Wilson Snyder 9a2a5d3155 Internals: Unroll V3Width task processing, in prep for openarrays. No functional change intended. 2017-12-16 09:36:07 -05:00
Wilson Snyder 2a7c61cd6d Commentary 2017-12-16 09:35:28 -05:00
Wilson Snyder 51787d68b9 Add error if always_comb has sensitivity list. 2017-12-13 19:49:37 -05:00
Wilson Snyder 33eb0db6f8 Fix resolving inline nested interface names, bug1250. 2017-12-13 19:42:49 -05:00
Wilson Snyder a0b2727c59 Use power-of-two number of members to align structs 2017-12-11 19:16:49 -05:00
Wilson Snyder d1b8f53711 Support DPI time and svLogicVal.
Note older version incorrectly assumed svBitVal even for logicals.
2017-12-09 20:17:37 -05:00
Wilson Snyder 27b5bfe9b1 DPI: Implement IEEE DPI copy routines. 2017-12-09 17:05:32 -05:00
Wilson Snyder ea91b10086 Internals: Add charIQWN. Proper capitalization. 2017-12-09 14:44:55 -05:00
Wilson Snyder 08da777b33 Tests: Fix illegal dpi return types, and other cleanups 2017-12-09 14:44:25 -05:00
Wilson Snyder 345657ab32 Workaround GCC/clang bug with huge compile times, bug1248. 2017-12-09 11:52:35 -05:00
Wilson Snyder 1b605ade94 Tests: Fix internal run scripts 2017-12-08 19:40:16 -05:00
Wilson Snyder b11fa372b1 Fix constant propagation across DPI imports of inout strings. 2017-12-07 20:10:27 -05:00
Wilson Snyder 662ebece71 Support string len() method. 2017-12-07 19:57:11 -05:00
Wilson Snyder 6b6e8dc83e Use VL_UNCOPYABLE in emitted code. No functional change intended. 2017-12-06 23:26:27 -05:00
Wilson Snyder d215149c7c Fix false ALWCOMBORDER on interface references, bug1247. 2017-12-06 21:29:10 -05:00
Wilson Snyder 895fc0911a Support > 64 bit decimal $display. 2017-12-02 22:10:58 -05:00
Wilson Snyder 754527edfd verilated internals: Add VL_BITRSHIFT_W. No functional change. 2017-12-02 08:17:20 -05:00
John Coiner f0217edef1 Internals: Keep a ptr to _eval in AstNetlist, make it easier to find.
Signed-off-by: Wilson Snyder <[email protected]>
2017-11-30 18:53:57 -05:00
Wilson Snyder 8f1798cc6f Fix modport outputs being treated as inputs, bug1246. 2017-11-28 19:11:41 -05:00
John Coiner 631bda395d Avoid duplicated scans of CFuncs.
Trace into non-entry-point functions (most of them) at their call
sites. We'll trace into entry-point functions (like eval) from their parent
scope. We must trace eval_ to reach the tree of calls beneath it.

Signed-off-by: Wilson Snyder <[email protected]>
2017-11-28 18:38:19 -05:00
John Coiner 791d02a753 Internals: Remove dead code. No functional change.
Signed-off-by: Wilson Snyder <[email protected]>
2017-11-28 18:29:14 -05:00
Wilson Snyder 54b3f92951 Commentary 2017-11-28 18:21:43 -05:00
Wilson Snyder 45de0599d7 Commentary 2017-11-27 20:11:34 -05:00
John Coiner 331ecdc2e7 Commentary
Signed-off-by: Wilson Snyder <[email protected]>
2017-11-27 19:23:55 -05:00
Wilson Snyder 339a7640a8 devel release 2017-11-27 18:50:14 -05:00
Wilson Snyder 0478dbdd1f Version bump 2017-11-25 15:42:11 -05:00
Wilson Snyder 38b0e8a777 Fix some clang-analyzer warnings 2017-11-25 15:41:49 -05:00
Wilson Snyder fe9f1add6f examples: Fix wide signal overflow, and stop on errors. 2017-11-25 15:14:31 -05:00
Wilson Snyder ae9179f412 Fix partial slicing with pattern assignments, bug991. 2017-11-23 14:55:32 -05:00
Wilson Snyder 4c35a76cdb Tests: bug795 2017-11-23 11:38:09 -05:00
Wilson Snyder 8ca3428fb6 Tests: Add split tests, towards bug1244 2017-11-23 11:30:35 -05:00
Wilson Snyder 7369500bb7 Fix cppcheck warnings 2017-11-23 10:43:34 -05:00
Wilson Snyder 45702e319b Support $size/$bits/etc on type references. 2017-11-23 10:17:56 -05:00
Wilson Snyder 813468bfe6 Work around bison 3.0 bug printing wrong debug token names 2017-11-23 09:50:15 -05:00
Wilson Snyder 78192308e1 Tests: Favor make -C over cd+make. No functional change. 2017-11-23 08:56:13 -05:00
John Coiner cb72390b57 Internals: Remove dead loop-related code in V3Order.cpp and V3OrderGraph.h
Signed-off-by: Wilson Snyder <[email protected]>
2017-11-23 08:26:36 -05:00
John Coiner 71b2eeef67 Internals: V3GenClk should scan CFunc internals only at the CCall
Signed-off-by: Wilson Snyder <[email protected]>
2017-11-23 08:21:20 -05:00
Wilson Snyder 57c8590b21 When resolving module names, only use defines if no other choice. 2017-11-22 18:44:19 -05:00
Wilson Snyder f8ad0a0923 Fix false DECLFILENAME on recursive modules. 2017-11-21 22:01:28 -05:00
Wilson Snyder 7c443ab108 Fix error on "unique case" with no cases. 2017-11-21 21:52:37 -05:00
Wilson Snyder 0d645757e7 Less debug verbosity 2017-11-21 21:52:22 -05:00
Wilson Snyder dd37c2ea86 Support $error/$warning in elaboration time blocks. 2017-11-21 21:10:42 -05:00
Wilson Snyder d3032bfc21 Fix flex warning. 2017-11-21 21:10:14 -05:00
Wilson Snyder bd6ecdfa6f Fix mis-showing debug message. 2017-11-21 20:04:29 -05:00
Wilson Snyder 3558e70722 Commentary 2017-11-18 17:52:06 -05:00
Wilson Snyder a579e9273b Support self-recursive modules, bug659. 2017-11-18 17:42:35 -05:00
Wilson Snyder 21369bec95 Internals: Renames in prep for recursion. No functional change. 2017-11-18 17:40:10 -05:00
Wilson Snyder d119d10569 Add BSSPACE and COLONPLUS lint warnings. 2017-11-15 20:19:12 -05:00
Wilson Snyder 38988c005c Fix false unused warning on interfaces, bug1241. 2017-11-14 20:10:25 -05:00
Wilson Snyder 8cc4b588b2 Add error when driving input-only modport. 2017-11-14 19:50:31 -05:00
Wilson Snyder 12607abb33 Remove tabs from --xml output. 2017-11-13 18:24:18 -05:00
Wilson Snyder 562f17ea4b Fix xml tags on typedefs. 2017-11-13 18:04:13 -05:00
Wilson Snyder 0aea9b7709 Update references to coverage.dat, msg2412. 2017-11-13 07:20:36 -05:00
Wilson Snyder c0afe96b80 Fix addition of data types to --xml. 2017-11-09 18:04:16 -05:00
John Coiner 5c919cd0de Fix null dereference crash in width process.
Signed-off-by: Wilson Snyder <[email protected]>
2017-11-09 07:43:30 -05:00
Wilson Snyder f555c93c11 Add data types to --xml. 2017-11-08 21:27:15 -05:00
Wilson Snyder cbb7cd16d0 Detect MSB overflow when under VL_DEBUG, bug1238. 2017-11-05 21:47:55 -05:00
Wilson Snyder 4d074b5414 Commentary 2017-11-05 13:05:50 -05:00
Wilson Snyder dfd22b2b07 Examples: Add +trace flag at runtime 2017-11-05 06:51:29 -05:00
John Coiner 6edaef9598 Internals: Fix debugging with null logicp() graphs.
Signed-off-by: Wilson Snyder <[email protected]>
2017-11-04 18:12:29 -04:00
John Coiner f63e946f04 Internals: Add consts. No functional change.
Signed-off-by: Wilson Snyder <[email protected]>
2017-11-02 18:02:11 -04:00
Wilson Snyder add5cc8b56 Internals: Add VL_UNCOPYABLE to make classes uncopyable. No functional change intended. 2017-11-01 18:51:41 -04:00
John Coiner 2a4e830bee Tests: Fix over sensitive line number.
Signed-off-by: Wilson Snyder <[email protected]>
2017-10-31 21:22:35 -04:00
Wilson Snyder eb87232472 Fix stats critical fast path calculation. 2017-10-30 22:38:47 -04:00
Wilson Snyder 52c3031a82 Internals: Rename selfTest, no functional change. 2017-10-30 19:01:58 -04:00
John Coiner df471e87eb Internals: Break unnecessary dependencies in V3Order.
Signed-off-by: Wilson Snyder <[email protected]>
2017-10-28 13:31:04 -04:00
Wilson Snyder ec6fae5d1a Internals: Add const to same() methods. No functional change. 2017-10-28 10:26:34 -04:00
Wilson Snyder cb422a9a02 Internals: Number astgen from 1 as 0p looks like Op. No functional change. 2017-10-28 08:48:24 -04:00
Wilson Snyder f91bac7b31 Rewrite include libraries to support VL_THREADED towards future threading 2017-10-26 21:51:51 -04:00
Wilson Snyder d542921ff7 Tests: Detect old GCC and skip unsupported tests. 2017-10-26 21:48:45 -04:00
Wilson Snyder ad693d67b2 Mark Verilated functions with multithreaded status. No functional change. 2017-10-26 20:05:42 -04:00
Wilson Snyder 350932e9c0 Fix false failure on clang 3.8 2017-10-26 19:14:05 -04:00
John Coiner 4e98d96755 Internals: Add const's. No functional change intended.
Signed-off-by: Wilson Snyder <[email protected]>
2017-10-26 18:42:50 -04:00
Wilson Snyder c17a9eb5f1 Tests: Fix driver when VERILATOR_ROOT not set. 2017-10-26 07:34:02 -04:00
Wilson Snyder 252ed4c1ae Fix clang warning 2017-10-26 07:27:47 -04:00
Wilson Snyder f9fd634fae Internals: Fix VL_DBG_MSGF va_list corruption in last commit. 2017-10-25 23:01:45 -04:00
Wilson Snyder c17c81254e Internals: Use = delete via a macro for a bit of C++11 forward compatibility 2017-10-25 20:00:38 -04:00
Wilson Snyder 5ead61dc7b Unify format of VL_DEBUG print messages 2017-10-24 22:56:58 -04:00
Wilson Snyder e403db5877 tests: Simplify includes; HARNESS_UPDATE_GOLDEN to whitespace fix 2017-10-24 19:58:52 -04:00
Wilson Snyder 32874fa848 Internals: Misc VCD code cleanups. No functional change. 2017-10-21 17:53:23 -04:00
Wilson Snyder b90f383cfe Add --threads option through to makefiles, unadvertised for now. 2017-10-21 16:41:43 -04:00
Wilson Snyder eb65984368 Tests: Additional display merge tests. No functional change. 2017-10-21 13:50:31 -04:00
Wilson Snyder 10e0d34140 Refactor verilated_vpi.h to move most code to .cpp. No functional change intended. 2017-10-19 21:33:22 -04:00
Wilson Snyder f4b00d3c64 Call VL_PRINTF/vl_stop/vl_finish/vl_fatal through wrappers as hook for future MT use. 2017-10-19 19:40:51 -04:00
Wilson Snyder cc0b780412 Internals: More use of unordered_map/set. No functional change intended. 2017-10-18 18:22:58 -04:00
Wilson Snyder fbbbe4ec87 Commentary 2017-10-18 17:54:39 -04:00
Wilson Snyder 1372d62186 Remove duplicate class forward declarations. 2017-10-18 17:38:10 -04:00
Ahmed El-Mahmoudy a69936de74 Spelling fixes
Signed-off-by: Wilson Snyder <[email protected]>
2017-10-16 21:58:47 -04:00
Wilson Snyder f5dfa1e9c3 Fix MacOS portability, bug1232. 2017-10-15 10:36:50 -04:00
Wilson Snyder 5fb21c2159 devel release 2017-10-14 20:47:25 -04:00
Wilson Snyder 132f61e900 Fix version 2017-10-14 16:20:17 -04:00
Wilson Snyder 0e9be8eea0 Version bump 2017-10-14 16:15:07 -04:00
Wilson Snyder 96f5f66c26 Move generated objects into bin/ to match --prefix installations 2017-10-14 16:09:02 -04:00
Wilson Snyder bbed4d50ab Fix clang and cppcheck warnings. 2017-10-14 14:51:57 -04:00
Wilson Snyder 4b7ee8267b Slicing: Fix off-by-one error earlier this version. 2017-10-14 14:04:15 -04:00
Wilson Snyder f6a745a4c2 Fix clang warnings. 2017-10-14 14:03:12 -04:00
Wilson Snyder a23a5505c4 configure: Check compiler works. 2017-10-14 13:20:58 -04:00
Wilson Snyder 21030f0a4f Internals: C++ style casts. No functional change intended. 2017-10-14 13:00:42 -04:00
Wilson Snyder d21824cbae Internals: Refactor verilated_vcd to move singleton into only .cpp. No functional change intended. 2017-10-14 13:00:25 -04:00
Wilson Snyder 124786ad1b Tests: Require newest compiler with thread test. 2017-10-14 12:57:42 -04:00
Wilson Snyder f81daac9c0 Fix MacOS portability, bug1231. 2017-10-14 12:56:16 -04:00
Wilson Snyder db8e8392fa Fix MacOS portability, bug1230. 2017-10-14 09:00:39 -04:00
Wilson Snyder 5bc2f87d3e Fix --skip-identical to handle closer timestamps looking at ctime. 2017-10-13 20:34:36 -04:00
Wilson Snyder de35c90847 Fix float-conversion warning, bug1229. 2017-10-11 19:01:37 -04:00
Wilson Snyder bc813fddcc tests: Fix examples when VERILATOR_ROOT not set 2017-10-11 19:01:02 -04:00
Wilson Snyder 13c91f5fce Internals: Refactor VerilatorSerialize to remove intermediate class. No functional change intended. 2017-10-11 18:55:31 -04:00
Wilson Snyder ac4690d74b Internals: Add const's. No functional change 2017-10-10 22:22:17 -04:00
Wilson Snyder a1a8f17617 Internals: Add const's. No functional change 2017-10-10 20:24:10 -04:00
Wilson Snyder 12be852a43 Fix ` expansion of defines, bug1227, bug1228. 2017-10-10 18:44:10 -04:00
Wilson Snyder 440fbef79b Untabify examples. No functional change. 2017-10-10 07:18:01 -04:00
Wilson Snyder e1c221a4d5 Tests: Add t_dist_tabs.pl 2017-10-09 22:08:22 -04:00
Wilson Snyder e1f1c82d4e Fix -E duplicating output, bug1226. 2017-10-09 21:08:50 -04:00
Wilson Snyder 3c1b82255e Change VL_THREADED to use C++11, and compute and test related GCC flags automatically 2017-10-07 21:29:57 -04:00
Wilson Snyder 6bd47b54df Tests: Add t_include_all. Fix GCC warning when DPI with VPI. 2017-10-07 21:21:12 -04:00
Wilson Snyder 3261a45ec1 configure: Add new _MY_CXX_CHECK_SET. No functional change. 2017-10-07 15:25:23 -04:00
Wilson Snyder 0ac116bb4e Internals: Favor C++ cast style. No functional change intended. 2017-10-07 15:01:19 -04:00
Wilson Snyder 221e4ff6fe Fix ` expansion of empty defines, bug1225. 2017-10-07 14:09:33 -04:00
Wilson Snyder fe80499f9c Internals: Move preproc DEV expansion when in ifndef, cleanup prep for bug1225. 2017-10-07 14:09:31 -04:00
Wilson Snyder d3d1f3ab60 Internals: Cleanup preproc in prep for bug1225. No functional change. 2017-10-07 14:09:17 -04:00
Chris Randall 264b888ef2 Add /*verilator tag*/ for XML extraction applications.
Signed-off-by: Wilson Snyder <[email protected]>
2017-10-06 07:33:52 -04:00
John Coiner ba270e09a4 Add --no-relative-cfuncs and related default optimization, bug1224.
Signed-off-by: Wilson Snyder <[email protected]>
2017-10-05 18:18:11 -04:00
Wilson Snyder 8281ee1520 Optimize arrayed if assignments 2017-10-04 22:10:44 -04:00
Wilson Snyder 75aab4e9d2 Fix conditional slices and add related optimizations. 2017-10-04 21:27:34 -04:00
Wilson Snyder b532a47e4a Internals: Prep for V3Slice rewrite. No functional change intended. 2017-10-04 21:15:19 -04:00
Wilson Snyder 77a3d683e3 Fix unnecessary Vdly variables, bug1224 partial. 2017-10-03 21:26:42 -04:00
Wilson Snyder c132d0e1fe Fix extra duplicate multiclk blocks when dtypes differ 2017-10-02 22:58:34 -04:00
Wilson Snyder 1a6348f113 Optimize display+display statements. 2017-10-02 20:25:10 -04:00
Wilson Snyder 89ac6ab594 Fix memory leak in VerilatedVcd dumps, bug1222 partial. 2017-10-02 18:49:00 -04:00
Wilson Snyder 3d1012b73b Allow disabling BLKLOOPINIT (Intentionally undocumented), part of last commit 2017-10-01 23:36:19 -04:00
Wilson Snyder c98ad79e68 Allow disabling BLKLOOPINIT (Intentionally undocumented) 2017-10-01 23:23:02 -04:00
Wilson Snyder 82460b0da3 Commentary 2017-10-01 23:06:16 -04:00
Wilson Snyder 0bdc57a14a Fix lost .tree debug file extensions in recent commit. 2017-10-01 22:17:37 -04:00
Wilson Snyder 33780a09df Add --x-initial option 2017-10-01 21:31:40 -04:00
John Coiner a9c9d5ca4b Fix over-aggressive inlining, bug1223.
Signed-off-by: Wilson Snyder <[email protected]>
2017-10-01 18:02:58 -04:00
Wilson Snyder ab07dbdb9d Fix over-aggressive inlining, bug1223. 2017-10-01 18:00:27 -04:00
Wilson Snyder 6dd6750985 Remove empty _configure_coverage in emitted code. 2017-10-01 16:44:53 -04:00
John Coiner 59aa0f43d5 Tests: In t_dist_whitespace, indicate what line has errant whitespace
Signed-off-by: Wilson Snyder <[email protected]>
2017-10-01 16:09:56 -04:00
Wilson Snyder 04ca6a4307 Fix compiler warning when WIDTH warning ignored on large compare. 2017-10-01 10:21:27 -04:00
John Coiner c7cbe11ba4 Fix Ubuntu 17.10 issues, bug1223 partial.
Signed-off-by: Wilson Snyder <[email protected]>
2017-09-30 13:33:14 -04:00
Wilson Snyder 4794093aba Replaced test_c/test_sc with new examples/ directory. 2017-09-23 21:18:07 -04:00
Wilson Snyder 46e300b2c5 Add --getenv option. 2017-09-23 18:03:39 -04:00
Wilson Snyder c693e52f6c Fix false unused warning on line coverage objects 2017-09-23 18:00:44 -04:00
Wilson Snyder 4e2ec09f9a Tests: The internal test_verilated test directory is moved to be part of test_regress. 2017-09-23 10:49:29 -04:00
Wilson Snyder cdbae456d5 devel release 2017-09-23 10:11:06 -04:00
Wilson Snyder 379177d2f4 Version bump 2017-09-23 10:04:52 -04:00
Wilson Snyder fb193d6172 Internals: Ignore gmon.out 2017-09-23 09:52:06 -04:00
Wilson Snyder 16234bb713 Tests: Call driver's run instead of private _run. 2017-09-23 08:50:39 -04:00
Wilson Snyder 3f14e649b5 Internals: Use singleton in place of global 2017-09-23 07:44:52 -04:00
Wilson Snyder c2e8062f84 Verilated headers no longer "use namespace std;" 2017-09-23 07:32:37 -04:00
Wilson Snyder 5d3fef21b0 Cleanup misc spacing and unneeded stuff in emitted headers. 2017-09-22 22:27:03 -04:00
Wilson Snyder b64e1b4a49 Fix inverted sync/async message. 2017-09-22 18:57:53 -04:00
Wilson Snyder 89f414b185 Less verbosity for IEEE warnings in earlier commit this rev. 2017-09-21 22:07:49 -04:00
Wilson Snyder 47e13cfdf4 Optimize concat/replicate+replicate. 2017-09-21 21:05:42 -04:00
Wilson Snyder 48d3ce46d8 Commenary 2017-09-21 18:39:23 -04:00
Wilson Snyder 89c8449ec0 Support package export, bug1217. 2017-09-20 21:04:59 -04:00
Xavier Delacour 331fcb633e Update .gitconfig 2017-09-20 07:57:09 -04:00
Wilson Snyder bffc2233a0 Commentary about IMPERFECTSCH. Add test. 2017-09-19 21:01:03 -04:00
Wilson Snyder 393b5d48b2 Better optimize Shift-And constructs. 2017-09-19 20:56:17 -04:00
Wilson Snyder 6006cdff2c Fix wide array indices causing compile error. 2017-09-19 20:04:45 -04:00
Wilson Snyder d6b10465f3 Improve more errors to note IEEE 2017-09-18 23:06:31 -04:00
Wilson Snyder b3cf5c4f5f Improve error to note common :: package errors 2017-09-18 22:54:54 -04:00
Wilson Snyder 3862f2f022 Note IEEE in 32 bit decimal oversized 2017-09-18 22:50:26 -04:00
Wilson Snyder 38ab22bf1d Simplify VL_CONST_W macro generation for faster compiles. 2017-09-18 21:36:18 -04:00
Wilson Snyder ce16f7689d Fix clang 3.8 warnings 2017-09-18 20:05:56 -04:00
Wilson Snyder b06a329466 Fix GCC 4.4 false warning 2017-09-18 08:30:04 -04:00
Wilson Snyder c5b24f3850 Internals: Remove dead code, bug1215. 2017-09-18 07:13:58 -04:00
Wilson Snyder 103b956581 Default to -O2 for Verilator itself, for 20%+ 2017-09-17 23:25:20 -04:00
Wilson Snyder 63361fc56e Add performance information to --stats file. 2017-09-17 22:52:57 -04:00
Wilson Snyder 1e9e334929 Internals: Name cleanup. No functional change. 2017-09-16 11:06:35 -04:00
Wilson Snyder f30d71b0c5 Internals: Better prefetching for ~5%. 2017-09-16 07:55:48 -04:00
Wilson Snyder fee4aba9ec Internals: Fix GCC constant warnings. 2017-09-15 18:26:09 -04:00
Wilson Snyder f1960273a0 Internals: Fix over-aggressive debug 2017-09-15 18:25:52 -04:00
Wilson Snyder 778564e63b Compling: Turn on -Wextra when using --enable-ccwarn 2017-09-14 23:28:02 -04:00
Wilson Snyder cf6a69da27 Internals: Fix some cast and fallthrough warnings. No functional change 2017-09-14 23:27:06 -04:00
Wilson Snyder 960b2ed023 Internals: Fix some shadow and other warnings. No functional change 2017-09-14 23:26:23 -04:00
Mike Popoloski 74420550e6 Fix .name connections on interfaces, bug1214.
Signed-off-by: Wilson Snyder <[email protected]>
2017-09-14 21:24:13 -04:00
Mike Popoloski cb5887b376 Support module port parameters without defaults, bug 1213.
Signed-off-by: Wilson Snyder <[email protected]>
2017-09-14 21:20:20 -04:00
Wilson Snyder 41b40157d8 Fix non-colon array of interface modports, bug1212. 2017-09-14 21:15:56 -04:00
Wilson Snyder b11b693c08 Fix constant function default parameters, bug1211. 2017-09-13 19:47:11 -04:00
Wilson Snyder 256eb4bba0 Support or/and/xor array intrinsic methods, bug1210. 2017-09-13 19:37:47 -04:00
Wilson Snyder 77804b4d38 Fix GCC noreturn compile error, bug1209. 2017-09-13 19:27:59 -04:00
Wilson Snyder 8c9ca7a1b3 Fix LITENDIAN warning on arrayed cells, bug1202. 2017-09-13 19:09:49 -04:00
Wilson Snyder 9d055f8c13 Fix ordering of arrayed cell wide connections, bug1202 partial. 2017-09-12 19:34:10 -04:00
Wilson Snyder 3dacd87dfb Fix enum ranges without colons, bug1204. 2017-09-12 18:53:57 -04:00
Wilson Snyder 691fbb0c42 Tests: Support newer VCS. 2017-09-12 18:42:58 -04:00
Wilson Snyder c28a6eef3b Fix whitespace issues, bug1203. 2017-09-11 19:18:58 -04:00
Wilson Snyder 17fed3fedd devel release 2017-09-07 21:15:48 -04:00
Wilson Snyder 1448cc56fc Version bump 2017-09-07 21:10:22 -04:00
Wilson Snyder 074689b5de SystemPerl mode (-sp-deprecated) has been removed. 2017-09-07 21:08:49 -04:00
Wilson Snyder 8dd612a0a0 Commentary, bug1198. 2017-09-06 20:45:21 -04:00
Wilson Snyder 22fdbba0b5 Update keywords for C++11 etc, msg2325 2017-09-02 21:01:50 -04:00
Wilson Snyder 39b787670b Update keywords for C++11 etc, msg2325 2017-09-02 20:59:03 -04:00
Wilson Snyder a221278c05 Commentary 2017-08-31 19:45:53 -04:00
Wilson Snyder 5f26b9ec66 Internals: Remove dead putAlign, bug1093. 2017-08-28 23:01:19 -04:00
Wilson Snyder 48778d0a77 devel release 2017-08-28 22:51:53 -04:00
Wilson Snyder 42d2cbad41 Version bump 2017-08-28 22:46:43 -04:00
Wilson Snyder cb82c42e35 Test for bug1191. 2017-08-28 22:41:38 -04:00
Wilson Snyder f13fb330ed Reenable -Wchar-subscripts and sort flag list 2017-08-14 20:15:24 -04:00
Wilson Snyder d4bae48ca2 Fix GCC7.1 warning on new alignment 2017-08-14 19:59:21 -04:00
Wilson Snyder 590ad964b1 Add assertion on bad formed lvalues, used to debug bug1187. 2017-08-13 18:08:44 -04:00
Wilson Snyder d4595df8a4 Fix internal error on unconnected inouts, bug1187. 2017-08-13 18:08:24 -04:00
Wilson Snyder 7b642bcbb4 Support packed struct DPI imports, bug1190. 2017-08-11 19:07:47 -04:00
Wilson Snyder ca26596695 Fix undefined VL_POW_WWI. 2017-07-12 20:08:32 -04:00
Wilson Snyder 88cf5e5d98 Fix realloc leak on out-of-memory 2017-07-12 18:54:27 -04:00
Wilson Snyder 13f790360d Fix compile error on unused VL_VALUEPLUSARGS_IW, bug1181. 2017-07-07 07:50:45 -04:00
Wilson Snyder 70daadf987 Fix cpp-check warnings; support XML format 2 2017-07-06 20:25:59 -04:00
Wilson Snyder 9d5004db1c Fix GCC 7 warnings. 2017-07-06 19:49:34 -04:00
Wilson Snyder ea82bfcced Fix GCC 6 warnings. 2017-07-06 19:07:23 -04:00
Wilson Snyder 00a502942e Fix valueplus exceeding array bounds. 2017-07-06 19:01:35 -04:00
Wilson Snyder 2031bc7fc4 Commentary 2017-07-05 19:06:22 -04:00
Wilson Snyder 3adb22e971 Support x in , 2017-07-05 18:51:06 -04:00
Wilson Snyder 331ea5116f devel release 2017-06-22 18:36:29 -04:00
Wilson Snyder 1da5a33f88 Version bump 2017-06-22 18:31:22 -04:00
Wilson Snyder 6c87724af8 Support set_time_unit/set_time_precision in C traces, msg2261. 2017-06-20 19:33:58 -04:00
Wilson Snyder c7a5ff5e82 Tests: Fix broken vgen test, commentary. 2017-06-20 19:10:18 -04:00
Wilson Snyder abf2fcf820 Fix .* on interface pins, bug1176. 2017-06-20 18:40:18 -04:00
Wilson Snyder 644c22b08f Fix extract of packed array with non-zero LSB, bug1172. 2017-06-06 20:06:23 -04:00
Wilson Snyder c54024a5e6 Fix constant shifts by more than 32-bit numbers, bug1174 continued. 2017-06-05 21:15:31 -04:00
Wilson Snyder 97093fdf81 Fix power operator on wide constants, bug761. 2017-06-05 20:30:01 -04:00
Wilson Snyder 50c4f60c68 Internals: Favor preincrement. No functional change. 2017-06-05 20:16:51 -04:00
Wilson Snyder f0fb3b78d1 Internals: New VL_ZERO_W for faster inline. Prefer WData for wide. No functional change intended. 2017-06-05 20:04:09 -04:00
Wilson Snyder 9b06178f35 Fix shifts by more than 32-bit numbers, bug1174. 2017-06-05 07:56:59 -04:00
Wilson Snyder a01c96140b devel release 2017-05-30 22:04:58 -04:00
Wilson Snyder 02530172e7 Version bump 2017-05-30 22:01:21 -04:00
Wilson Snyder 447d803800 Fix internal clang warnings. 2017-05-24 23:51:15 -04:00
Wilson Snyder 6b04901c4d Fix testplusargs false width warning, bug1165. 2017-05-19 07:20:41 -04:00
Wilson Snyder 7fb29621c3 Fix interface functions returning wrong parameters, bug996. 2017-05-18 22:49:17 -04:00
Wilson Snyder b032fce962 Support $value$plusargs with variables, bug1165. 2017-05-18 22:41:43 -04:00
Wilson Snyder ce879122bb Fix --assert with complex case statements, bug1164. 2017-05-17 20:15:40 -04:00
Todd Strader 2fa16708b7 Fix non-arrayed cells with interface arrays, bug1153.
Signed-off-by: Wilson Snyder <[email protected]>
2017-05-10 19:05:42 -04:00
Todd Strader 54bc8608e3 Add stack trace when can't optimize function, bug1158.
Signed-off-by: Wilson Snyder <[email protected]>
2017-05-09 18:54:15 -04:00
Todd Strader 706a7802cc Fix non-cutable ordering loops on clock arrays, bug1009.
Signed-off-by: Wilson Snyder <[email protected]>
2017-05-09 08:05:21 -04:00
Wilson Snyder 9dc01cf540 Support arrayed parameter overrides, bug1153. 2017-05-02 19:16:54 -04:00
Wilson Snyder 8943ad5966 internals: Remove extra newlines on v3fatalSrc. No functional change. 2017-04-28 20:09:27 -04:00
Wilson Snyder deb7a1c9c0 Fix non-arrayed cells with interface arrays, bug1153. 2017-04-28 20:03:38 -04:00
Wilson Snyder 96a5445d44 Support ports of array of reals, bug1154. 2017-04-28 06:10:14 -04:00
Wilson Snyder d693065afb Fix backwards array interface error message 2017-04-27 06:36:14 -04:00
Wilson Snyder bdeee35669 Add warning on mis-sized literal, bug1156. 2017-04-26 18:34:01 -04:00
Wilson Snyder 62b3deb90d Tests: Improve vams to attach wire. 2017-04-04 19:15:15 -04:00
Wilson Snyder 9df9ff59e0 Commentary 2017-04-03 20:02:19 -04:00
Wilson Snyder 23a3271c06 devel release 2017-04-02 08:49:31 -04:00
Wilson Snyder f4a5aa2e94 Version bump 2017-04-02 08:43:53 -04:00
Wilson Snyder bdd54eed1c Commentary 2017-04-02 08:39:33 -04:00
Wilson Snyder c6a20a72f2 Turn off parser debug in optimized build, msg2203 2017-03-31 17:46:15 -04:00
Wilson Snyder d7a54b3632 Fix nested structure parameter selects, bug1150. 2017-03-30 19:05:55 -04:00
Wilson Snyder be6a3d0f10 Fix wreal not handling continuous assign, bug1150. 2017-03-30 18:32:37 -04:00
Wilson Snyder e9125a3a22 Fix error on parameters with dotted references, bug1146. 2017-03-28 19:55:20 -04:00
Wilson Snyder c27a60658f Add error on duplicate pattern assignments, bug1145. 2017-03-23 18:15:03 -04:00
Wilson Snyder 8f2bc6e028 Patch to fix for bug1135. 2017-03-22 17:34:47 -04:00
Wilson Snyder a6b78cbbee Fix error on improperly widthed default function, bug984. 2017-03-21 19:27:42 -04:00
Wilson Snyder 182a7076fd Fix missing error on interface size mismatch, bug1143. 2017-03-21 19:19:28 -04:00
Wilson Snyder 17a9b22dce Fix cell ranges without colons. 2017-03-21 19:17:15 -04:00
Wilson Snyder f190d12802 Internals: Avoid coredump debugging bug1135. 2017-03-21 18:22:32 -04:00
Wilson Snyder b12dd526f9 Fix calling sformatf to display, and elab , bug1139. 2017-03-17 18:40:16 -04:00
Wilson Snyder 473d555dc1 Fix ugly interface-to-non-interface errors, bug1112. 2017-03-17 18:35:53 -04:00
Wilson Snyder fa9208ccdd Fix ugly interface-to-non-interface errors, bug1112. 2017-03-17 18:33:49 -04:00
Wilson Snyder 4aa088eb2f Fix realpath compile issue on MSVC++, bug1141. 2017-03-15 20:08:19 -04:00
Wilson Snyder 8f8147d646 Fix internal error on interface arrays, bug1135. 2017-03-15 20:03:53 -04:00
Wilson Snyder e637dd2390 Fix internal error on initializing parameter array, bug1131. 2017-03-06 07:20:30 -05:00
Wilson Snyder c90960fc88 Fix LDFLAGS and CFLAGS not preserving order, bug1130. 2017-02-13 18:11:40 -05:00
Wilson Snyder da86a1c9f2 Fix previous commit warning 2017-02-13 18:11:22 -05:00
Wilson Snyder 0adb789238 Add --relative-includes. 2017-02-09 18:33:18 -05:00
Wilson Snyder 15082a178b Add -FI option to force includes,msg2146. 2017-02-09 07:44:36 -05:00
Wilson Snyder 4a0db26c36 Commentary 2017-02-04 13:53:08 -05:00
Wilson Snyder ad3ea636d5 Fix 2009 localparam syntax, msg2139. 2017-01-26 22:41:32 -05:00
Wilson Snyder 6a238b0514 devel release 2017-01-26 22:41:05 -05:00
Wilson Snyder e6d7e7e329 Version bump 2017-01-15 12:13:13 -05:00
Wilson Snyder f942aba855 Support old-style (), bug467. 2017-01-09 19:19:21 -05:00
Wilson Snyder 2f34132275 Fix bad code when tracing array of structs, bug1122. 2017-01-06 18:44:37 -05:00
Wilson Snyder 663b2be065 Tests: bug1104, unsupported. 2016-12-21 21:00:40 -05:00
Wilson Snyder a1e4d676c3 Fix parsing sensitivity with &&, bug934. 2016-12-21 18:23:14 -05:00
Wilson Snyder 6f28d21207 With --bbox-unsup, suppress desassign and mixed edges, bug1120. 2016-12-21 17:43:19 -05:00
Wilson Snyder 9f115e056e Commentary 2016-12-21 17:21:44 -05:00
Wilson Snyder 8352ba4af4 Commentary, bug1116 2016-12-03 15:01:55 -05:00
Wilson Snyder 9b06310cbe Fix internal error on unique casez with --assert, bug1117. 2016-12-03 14:49:51 -05:00
Wilson Snyder 77fe33e57f Fix internal error on double-for loop unrolling, bug1044. 2016-11-29 20:40:58 -05:00
Wilson Snyder df58eb9bc7 Commentary 2016-11-27 16:37:51 -05:00
Wilson Snyder 2d0084308d Internals: Convert AstNUser to non-pointer to avoid NULL call. No functional change intended. 2016-11-27 09:40:12 -05:00
Wilson Snyder 7efa40966a Internals: Remove second argument to visitors. No functional change intended. 2016-11-27 08:11:38 -05:00
Wilson Snyder 6d644dc764 Internals: V3Width now iterates like others, replacing arg passing. No functional change intended. 2016-11-25 16:48:36 -05:00
Wilson Snyder b0de0b1176 devel release 2016-11-25 10:55:28 -05:00
Wilson Snyder c72d473e96 Version bump 2016-11-25 10:35:45 -05:00
Wilson Snyder c8a91bd46f Commentary 2016-11-18 21:42:06 -05:00
Wilson Snyder 498f19a6a1 Use VERILATOR_INCLUDE in generated files to allow relocation. 2016-11-18 21:13:56 -05:00
Wilson Snyder c7a2138ece Commentary 2016-11-18 20:31:41 -05:00
Wilson Snyder 4078902543 Compiling: Fix flexfix adding new warning back in flex 2.5.35 2016-11-18 19:40:39 -05:00
Wilson Snyder 9e38ed9a39 configure: Better prune unknwon gcc -Wno- flags. 2016-11-18 19:27:29 -05:00
Wilson Snyder 183cabc77d Internals: Have cloning return node's type to avoid casts. No functional change. 2016-11-08 21:16:22 -05:00
Wilson Snyder b582e481c6 Commentary in Makefile.in 2016-11-08 18:12:05 -05:00
Wilson Snyder ad39931e87 Internals: Cleanup uses of accept in V3Width. No functional change. 2016-11-07 19:14:45 -05:00
Wilson Snyder 1ae22e1365 Internals: Cleanup some casts. No functional change. 2016-11-06 11:39:09 -05:00
Wilson Snyder b748ddfe06 Fix flex 2.6.2 bug, bug1103. 2016-11-06 08:14:05 -05:00
Wilson Snyder e52f5f1b63 Internals: Remove extraneous castNode() calls. No functional change. 2016-11-05 10:06:43 -04:00
Wilson Snyder bda4b326ab Internals: Use mixed case for AstType enums. No functional change. 2016-11-05 09:47:56 -04:00
Wilson Snyder 70ddf32719 Fix error on referencing variable in parent, bug1099. 2016-11-05 08:37:18 -04:00
Stefan Wallentowitz 3edba7b662 Fix type parameters with low optimization, bug1101.
Signed-off-by: Wilson Snyder <[email protected]>
2016-11-04 22:58:21 -04:00
Wilson Snyder f74ef650ac Honor --output-split on coverage constructors, bug1098. 2016-10-23 14:27:57 -04:00
Wilson Snyder f093c3d78b Fix error on bad interface name, bug1097. 2016-10-22 08:05:27 -04:00
Wilson Snyder d933f33bdb devel release 2016-10-14 19:51:30 -04:00
Wilson Snyder 813d62005d Version bump 2016-10-14 19:42:18 -04:00
Wilson Snyder 411de9bddf Commentary. 2016-09-30 18:16:56 -04:00
Wilson Snyder bd28945374 Untabify 2016-09-30 18:14:42 -04:00
Wilson Snyder 1e4c3751e1 Support foreach, bug1078. 2016-09-19 22:00:13 -04:00
Wilson Snyder 5b6f47cd0f If VM_PARALLEL_BUILDS=1, use OPT_FAST and OPT_SLOW. 2016-09-19 19:31:09 -04:00
Wilson Snyder bec8c5bf4c Commentary 2016-09-19 17:55:43 -04:00
Johan Bjork 15495bb200 Improve Verilation performance on trace duplicates, msg2017.
Signed-off-by: Wilson Snyder <[email protected]>
2016-09-19 17:54:42 -04:00
Wilson Snyder 999f278971 Fix concats with wide width, bug1088 continued. 2016-09-16 18:54:28 -04:00
Wilson Snyder 7ca1d35a4e New test. 2016-09-16 18:15:32 -04:00
Wilson Snyder 2117fe414e Fix error on wide numbers that represent shifts, bug1088. 2016-09-14 20:27:20 -04:00
Wilson Snyder 7d8c51181d With --no-decoration also shrink output code indents. 2016-09-13 22:53:09 -04:00
Wilson Snyder c30211cb27 Add --no-decoration to remove output comments, msg2015. 2016-09-13 22:28:07 -04:00
Johan Bjork 901da118e5 Internals: Move prettyName invocation to after option checks in trace and coverage
Signed-off-by: Wilson Snyder <[email protected]>
2016-09-12 21:52:40 -04:00
Wilson Snyder f11757e43a Fix error on wide shift, msg2005. 2016-09-12 18:31:45 -04:00
Wilson Snyder 3f143317a6 Add error on DPI functions > 32 bits, msg1995. 2016-09-10 08:14:17 -04:00
Wilson Snyder 45d7312dfc Improve Verilation performance on internal strings, msg1975. 2016-09-08 22:04:14 -04:00
Wilson Snyder 26774eb045 Fix error on wide numbers that represent small msb/lsb, msg1991. 2016-09-08 21:30:35 -04:00
Wilson Snyder 6789d247e2 Fix SystemC compiles with VPI, bug1081. 2016-08-23 18:05:29 -04:00
Johan Bjork 462bc3d707 Clean up disabled tests for bugs already fixed.
Signed-off-by: Wilson Snyder <[email protected]>
2016-08-23 06:45:25 -04:00
Wilson Snyder e1755ea6a8 devel release 2016-07-30 10:18:52 -04:00
Wilson Snyder b4a7e4697e Version bump 2016-07-30 10:10:35 -04:00
Wilson Snyder cd61b1d045 Usage check. 2016-07-30 10:05:55 -04:00
Wilson Snyder 24dc36ba4c Fix comparison of unpacked arrays, bug1071. 2016-07-23 16:58:30 -04:00
Wilson Snyder e8e4f1777d Internals: Add cloneType method. Unused - for next checkin. 2016-07-23 16:54:36 -04:00
Wilson Snyder ae38a26af3 Internals: Cleanup some slice code. No functional change. 2016-07-21 23:07:22 -04:00
Wilson Snyder 8ee94dd7aa Tests: Smaller verilated test. 2016-07-21 23:03:54 -04:00
Wilson Snyder e741a29d36 Commentary 2016-07-13 22:51:40 -04:00
Wilson Snyder be1d275151 Fix Ubuntu 16.04 test failures. 2016-07-12 21:43:16 -04:00
David Horton 31c9e26e2e Fix compiler warning in GCC 6.
Signed-off-by: Wilson Snyder <[email protected]>
2016-07-09 04:09:34 -04:00
Wilson Snyder 20ed1ada03 Spelling fixes. 2016-07-09 03:31:22 -04:00
Wilson Snyder 891214fa72 Fix enum values of 11-16 bits wide using .next/.prev, bug1062. 2016-06-15 22:46:34 -04:00
Wilson Snyder e819e285e2 Fix false warnings on non-power-2 enums using .next/.prev. 2016-06-15 20:13:52 -04:00
Wilson Snyder 171c175e54 devel release 2016-05-18 21:15:33 -04:00
Wilson Snyder 675cbce8cb Version bump 2016-05-18 21:10:56 -04:00
Wilson Snyder 4f1398f773 Add commandArgsAdd, msg1890. 2016-05-16 22:04:21 -04:00
Wilson Snyder ae89e399a3 Fix to string, msg1890. 2016-05-16 21:57:49 -04:00
Wilson Snyder 2c9716c64c Try 2. Fix core dump on Arch Linux/GCC 6.1.1, bug1058. 2016-05-16 21:40:49 -04:00
Wilson Snyder bc58245abf Fix core dump on Arch Linux/GCC 6.1.1, bug1058. 2016-05-14 17:56:04 -04:00
Johan Bjork 8c4aa8517e Fix --output-split of constructors, bug1035.
Signed-off-by: Wilson Snyder <[email protected]>
2016-05-12 07:19:02 -04:00
Johan Bjork c0b7a54bb9 Fix removal of empty packages, modules and cells, bug1034.
Signed-off-by: Wilson Snyder <[email protected]>
2016-05-11 21:44:55 -04:00
Wilson Snyder 6b32bb635d Change --l2-name default to remove 'v' naming. 2016-05-07 14:10:33 -04:00
Wilson Snyder 691de22ae3 Add --l2-name option for controlling 'v' naming, bug1050. 2016-05-07 14:01:02 -04:00
Wilson Snyder e64b2d3372 Internals: user#inc now has optional increment value. 2016-05-06 22:26:15 -04:00
Johan Bjork e190af9d87 Avoid extra clean ANDs after CCalls.
Signed-off-by: Wilson Snyder <[email protected]>
2016-05-06 21:18:48 -04:00
Johan Bjork 8d14463b18 Fix emitting public enumerations.
Signed-off-by: Wilson Snyder <[email protected]>
2016-05-05 22:48:53 -04:00
Wilson Snyder 04977ef721 Internals: Show clocker in debug dumps. Part of bug1009. 2016-05-05 22:40:19 -04:00
Wilson Snyder d84e6875c5 Test case 2016-04-06 19:18:59 -04:00
Wilson Snyder 80678ae7bc Fix clang 3.8.0 warnings. 2016-03-31 22:26:49 -04:00
Stefan Wallentowitz 482bdab0e0 Support command-line -G/+pvalue param overrides, bug1045.
Signed-off-by: Wilson Snyder <[email protected]>
2016-03-24 19:14:15 -04:00
Stefan Wallentowitz b2623b9841 Internals: Add success parameter to parseDouble. No functional change intended.
Signed-off-by: Wilson Snyder <[email protected]>
2016-03-23 07:48:32 -04:00
Wilson Snyder 9ae40d64f0 Support parameter type, bug376. 2016-03-14 21:51:31 -04:00
Wilson Snyder cef097b7b7 Internals: Refactoring prep for parameter type branch. No functional change intended. 2016-03-12 20:54:52 -05:00
Wilson Snyder b840334ad2 devel release 2016-03-01 19:14:04 -05:00
Wilson Snyder acff683e8e Version bump 2016-03-01 19:12:14 -05:00
Stefan Wallentowitz c5332de86d Support SV strings to readmemh, bug1040.
Signed-off-by: Wilson Snyder <[email protected]>
2016-03-01 18:57:15 -05:00
Wilson Snyder 90ecf14a0a Fix pattern assignment width propagation, bug1037. 2016-02-21 23:00:21 -05:00
Wilson Snyder 4945282369 Fix slicing mix of big and little-endian, bug1033. 2016-02-09 22:16:12 -05:00
Wilson Snyder ca532d23f0 Suppress null compares to avoid compile errors until bug1030 fixed 2016-02-08 22:16:05 -05:00
Wilson Snyder a509b6a21c Internals: Fix compares to null, ongoing part of bug1030. No functional change intended. 2016-02-08 22:15:44 -05:00
Wilson Snyder 46229473cb Fix crash on very deep function trees, bug1028. 2016-02-04 20:47:55 -05:00
Johan Bjork 65be2448dc Fix elaboration-time display warnings, bug1032.
Signed-off-by: Wilson Snyder <[email protected]>
2016-02-04 18:38:59 -05:00
Johan Bjork be74806044 Fix read-after-free error detected by valgrind, bug1031.
Signed-off-by: Wilson Snyder <[email protected]>
2016-02-04 18:34:08 -05:00
Wilson Snyder b488666c1e Fix cppcheck 1.71 issues. No functional change intended. 2016-02-04 18:30:21 -05:00
Wilson Snyder d1acaea611 Internals: Fix compares to null, ongoing part of bug1030. No functional change intended. 2016-02-03 20:44:31 -05:00
Wilson Snyder db6e5ce7cf Internals: Misc code cleanups. No functional change. 2016-02-03 20:43:05 -05:00
Wilson Snyder d56179df17 Internals: Fix compares to null, part of bug1030. No functional change intended. 2016-02-02 21:02:00 -05:00
Wilson Snyder 850100c9c2 Fix compares to null, part of bug1030. 2016-02-02 19:35:44 -05:00
Wilson Snyder 0725999f0a flexfix: Match Verilog-perl fix for new gcc. 2016-02-02 19:32:17 -05:00
Johan Bjork cb2d8259f2 Fix stats and debug print, bug1029
Signed-off-by: Wilson Snyder <[email protected]>
2016-01-28 22:20:31 -05:00
Johan Bjork 61a1f3d817 Support inlining interfaces, bug1018.
Signed-off-by: Wilson Snyder <[email protected]>
2016-01-21 19:11:53 -05:00
Johan Bjork 63f111b7f3 Fix unrolling complicated for-loop bounds, bug677.
Signed-off-by: Wilson Snyder <[email protected]>
2016-01-21 19:00:19 -05:00
Wilson Snyder e061eb3003 Fix using short parameter names on negative params, bug1022. 2016-01-20 22:09:11 -05:00
Johan Bjork 29daa58222 Fix stats file containing multiple unroll entries, bug1020.
Signed-off-by: Wilson Snyder <[email protected]>
2016-01-06 20:53:48 -05:00
Johan Bjork 340cc02171 Avoid dynamic_cast for classes with no children, bug1021.
Signed-off-by: Wilson Snyder <[email protected]>
2016-01-06 20:47:44 -05:00
Wilson Snyder b738d1960a Copyright year update 2016-01-06 20:36:41 -05:00
Wilson Snyder 38f5b780d7 devel release 2016-01-06 20:33:25 -05:00
Wilson Snyder fa9dac29e8 Version bump 2015-12-19 10:26:14 -05:00
Wilson Snyder afc432042f Fix ternary operation with unpacked array, bug1017. 2015-12-18 18:02:25 -05:00
Wilson Snyder 21cb29baf0 Fix arrayed instances to unpacked of same size, bug1015. Fix slices of unpacked arrays with non-zero LSBs. 2015-12-15 22:37:49 -05:00
Wilson Snyder e8b5001cfe Fix model restore crash, bug1013. 2015-12-14 19:58:22 -05:00
Wilson Snyder 849c1e46a2 Fix constant propagation, bug1012. 2015-12-08 22:22:42 -05:00
Wilson Snyder ebad6cde36 Fix error instead of warning on large concat, msg1768. 2015-12-08 21:25:43 -05:00
Johan Bjork f920b3945e Fix dotted generated array error, bug1005.
Signed-off-by: Wilson Snyder <[email protected]>
2015-12-05 19:58:58 -05:00
Wilson Snyder 178028a70a Commentary; part of last commit 2015-12-05 19:45:45 -05:00
Todd Strader 5e54d3e41a Fix interface inside generate, bug1001, bug1003.
Signed-off-by: Wilson Snyder <[email protected]>
2015-12-05 19:39:40 -05:00
Wilson Snyder f0af8726e3 Internals: Fix some spacing. No functional change. 2015-12-05 17:12:03 -05:00
Todd Strader 57f2fe77ea Fix cell [#] to mean # cells.
Signed-off-by: Wilson Snyder <[email protected]>
2015-12-01 18:23:11 -05:00
Todd Strader d56ca25089 Tests: Fix false hidden module warning.
Signed-off-by: Wilson Snyder <[email protected]>
2015-12-01 18:17:26 -05:00
Wilson Snyder d39ce17dea Makefiles: Turn off make built-in suffixes. 2015-11-28 17:33:01 -05:00
Johan Bjork 373a68ec8b Fix dtype indexing into arrays, bug1007.
Signed-off-by: Wilson Snyder <[email protected]>
2015-11-24 21:34:07 -05:00
Johan Bjork 5613758ee3 Fix array slicing of non-const indexes, bug1006.
Signed-off-by: Wilson Snyder <[email protected]>
2015-11-24 21:28:04 -05:00
Johan Bjork 2102f86909 Fix genvar constant propagation, bug1003.
Signed-off-by: Wilson Snyder <[email protected]>
2015-11-22 21:16:13 -05:00
Wilson Snyder d5ea785de7 Commentary; last commit was bug1004 2015-11-22 21:13:16 -05:00
Johan Bjork 9edd28d2ed Fix genvar constant propagation from package, bug1003.
Signed-off-by: Wilson Snyder <[email protected]>
2015-11-22 20:46:26 -05:00
Wilson Snyder 7698af5178 Tests 2015-11-14 20:53:36 -05:00
Wilson Snyder 52ae451f5c Fix interface inside generate, bug998. 2015-11-14 09:06:09 -05:00
Wilson Snyder 9254443cd4 Fix casts under generates, bug999. 2015-11-12 22:29:42 -05:00
Johan Bjork 4e4bc7b90f Fix constant function assigned to packed structs, bug997.
Signed-off-by: Wilson Snyder <[email protected]>
2015-11-11 20:49:45 -05:00
Johan Bjork c7e0f2e196 Fix function calls on arrayed interface, bug994.
Signed-off-by: Wilson Snyder <[email protected]>
2015-11-11 20:40:24 -05:00
Wilson Snyder acabaab6ac Internals: Avoid tristate coredump. 2015-11-11 20:37:52 -05:00
Wilson Snyder b0a249f338 Fix display %u, %v, %p, %z, bug989. 2015-11-10 21:12:15 -05:00
Wilson Snyder 0cb5d5cc5a Internals: Upgrade some C strings to C++ 2015-11-10 18:59:48 -05:00
Wilson Snyder 9208c87f91 Tests: Better upper-case display formats. 2015-11-10 07:09:53 -05:00
Johan Bjork 0081ce4a75 Fix size-changing cast on packed struct, bug993.
Signed-off-by: Wilson Snyder <[email protected]>
2015-11-06 19:12:17 -05:00
Todd Strader 7850f49963 Fix t_scope_map --verbose test, bug955.
Signed-off-by: Wilson Snyder <[email protected]>
2015-11-06 18:58:48 -05:00
Wilson Snyder c72ee41142 Add z to param values to avoid conflicts. 2015-11-05 07:00:04 -05:00
Wilson Snyder bf5dee955d Fix real parameters causing bad module names, bug992. 2015-11-04 22:01:21 -05:00
Wilson Snyder 3df23a148a devel release 2015-11-01 08:20:17 -05:00
Wilson Snyder 0a1b55c296 Version bump 2015-11-01 08:18:54 -05:00
Wilson Snyder 14b8efe4bb Version bump 2015-11-01 08:14:44 -05:00
Wilson Snyder 64162efebd Fix commit 379bfd06, crash in commandArgsPlusMatch 2015-11-01 08:14:18 -05:00
Wilson Snyder faf5e1de51 Internals: Remove some unneeded c_str() calls. No functional change. 2015-10-29 22:19:51 -04:00
Wilson Snyder 0d7b1a7dc7 Remove VlCovCvtToCStr to avoid scary scope issues. 2015-10-29 21:58:00 -04:00
Wilson Snyder fa63bc6b78 Fix error message on missing interface, bug985. 2015-10-29 21:44:02 -04:00
Wilson Snyder 379bfd062f Fix crash in commandArgsPlusMatch, bug987. 2015-10-29 21:07:49 -04:00
Jamey Hicks 49108c23f0 Support with non-format arguments, bug467.
Signed-off-by: Wilson Snyder <[email protected]>
2015-10-27 20:58:31 -04:00
Wilson Snyder 4475060268 Ignore %l in , bug983. 2015-10-27 20:37:52 -04:00
Wilson Snyder 4f269e336d With --bbox-ignore, don't warn about always order. 2015-10-24 07:24:53 -04:00
Wilson Snyder 4464b13163 Fix dot indexing into arrayed inferfaces, bug978. 2015-10-23 23:06:24 -04:00
Wilson Snyder 215d5f68b0 Fix struct.enum.name method calls, bug855. 2015-10-23 22:57:15 -04:00
Wilson Snyder 281f4e04ee Fix $fwrite to constant stderr/stdout, bug961. 2015-10-23 21:53:16 -04:00
Wilson Snyder 17a3f9691d Fix package:scope.scope variable references. 2015-10-23 21:03:35 -04:00
Wilson Snyder 4fde6ee7af Support elaboration assertions, bug973. 2015-10-23 18:13:25 -04:00
Wilson Snyder 040b1b06d5 Support genvar indexes into arrayed cells, bug517. 2015-10-22 20:13:49 -04:00
Wilson Snyder b16ea8b719 Tests: With --benchmark, don't time directory change. 2015-10-21 06:54:03 -04:00
Wilson Snyder cc22847bc3 For --xml, decrease block indent to 2 spaces. 2015-10-20 21:22:00 -04:00
Johan Bjork 3702e17b2e Backout bug978 fix as is incomplete.
Signed-off-by: Wilson Snyder <[email protected]>
2015-10-10 07:54:45 -04:00
Wilson Snyder 7abc220fb3 Fix C++ 2014 compile warnings. No functional change. 2015-10-04 13:41:45 -04:00
Wilson Snyder 4fc9a906f6 Internals: Fix cppcheck warnings; add VL_DANGLING. No functional change. 2015-10-04 13:16:35 -04:00
Wilson Snyder 5de83c9805 Internals: Fix cppcheck warnings. No functional change. 2015-10-04 13:11:32 -04:00
Johan Bjork f71d904a9b Fix internal error on interface array, bug978.
Signed-off-by: Wilson Snyder <[email protected]>
2015-10-04 11:17:58 -04:00
Wilson Snyder 318ded4198 Internals: Cleanup cppcheck warnings. 2015-10-03 22:33:06 -04:00
Wilson Snyder f1874b211f Support , bug977. 2015-10-03 07:12:56 -04:00
Wilson Snyder c60ffd7fd9 Fix enum constant propagation, bug970. 2015-10-01 21:15:01 -04:00
Todd Strader dc57282168 Internal: Fix setBit from earlier commit, bug971.
Signed-off-by: Wilson Snyder <[email protected]>
2015-09-30 07:02:39 -04:00
Todd Strader 3c336e179f Fix structure parameter constant propagation, bug968.
Signed-off-by: Wilson Snyder <[email protected]>
2015-09-29 21:02:33 -04:00
Todd Strader 6bda57da5d Internals: Fix setBit not clearing X mask.
Signed-off-by: Wilson Snyder <[email protected]>
2015-09-29 20:59:17 -04:00
Wilson Snyder 9a16001e51 Add --vpi flag, and fix VPI linkage, bug969. 2015-09-25 22:57:28 -04:00
Todd Strader 34870e899f Add VerilatedScopeNameMap for introspection, bug966.
Signed-off-by: Wilson Snyder <[email protected]>
2015-09-24 21:08:58 -04:00
Wilson Snyder d0653f72e2 Fix very long module names, bug937. 2015-09-19 20:12:35 -04:00
Wilson Snyder 64748b7b1d Internals: Replace FNV hashes with SHA1 2015-09-19 18:49:54 -04:00
Wilson Snyder 7163c8d048 Fix internal error on dotted refs into generates, bug958. 2015-09-18 20:57:27 -04:00
Wilson Snyder d0ec991bb2 Fix mis-optimizing public DPI functions, bug963. 2015-09-18 19:06:15 -04:00
Wilson Snyder d458af4454 Commentary, bug965. 2015-09-11 20:18:41 -04:00
Wilson Snyder 9e9e7c33ae Install commentary, msg1678. 2015-09-03 21:20:19 -04:00
Wilson Snyder ce7de5ed30 Commentary, bug951 2015-08-16 11:48:05 -04:00
Wilson Snyder 776d8edf52 devel release 2015-08-12 21:42:08 -04:00
Wilson Snyder 5f21385e41 Version bump - commentary fix 2015-08-12 21:40:55 -04:00
Wilson Snyder 94fed93f54 Version bump 2015-08-12 21:34:59 -04:00
Wilson Snyder a950e4816d Support extraction of enum bits, bug951. 2015-08-12 21:33:40 -04:00
Wilson Snyder c87c66efb1 Fix size casts as second argument of cast item, bug950. 2015-08-12 19:37:25 -04:00
Jie Xu 5a5a0006fe Fix parameters with function parameter arguments, bug952.
Signed-off-by: Wilson Snyder <[email protected]>
2015-08-12 19:29:06 -04:00
Wilson Snyder 60b48a6830 Fix coverage documentation, bug954. 2015-08-12 19:18:58 -04:00
Wilson Snyder 5e41350588 Fix makefile with --coverage, bug953. 2015-08-12 19:06:15 -04:00
Wilson Snyder ff9f5b62ac bug951 testcase 2015-08-12 08:36:23 -04:00
Wilson Snyder 882913f0ca Add tracing_on, etc to vlt files, bug932. 2015-07-22 20:14:58 -04:00
Wilson Snyder 2062f7e97b Fix hashed error with typedef inside block, bug948. 2015-07-22 19:52:11 -04:00
Wilson Snyder 445c83a60d Fix with SV string, bug947. 2015-07-21 18:36:27 -04:00
Wilson Snyder 1891cfd79a Fix rounding in trace , bug946. 2015-07-21 13:22:08 -04:00
Wilson Snyder 06d5a7b2bf Internals: Allow hashing nulls; misc cleanup 2015-07-06 19:37:20 -04:00
Wilson Snyder 5af8a8aa4c Internals: Hash nulls 2015-07-05 20:31:30 -04:00
Wilson Snyder dc6b085d8b Fix MinGW compiler error, bug927. 2015-06-21 21:01:02 -04:00
Wilson Snyder 00759f777e Fix dpi imports inside generates. 2015-06-16 19:27:18 -04:00
Wilson Snyder 95ac0e61b2 Fix MinGW compiler error, bug927. 2015-06-16 07:13:45 -04:00
Wilson Snyder 6c5884853f Fix string-to-int space conversion, bug931. 2015-06-12 07:28:44 -04:00
Wilson Snyder 7578ef889f Fix .c files to be treated as .cpp, bug930. 2015-06-09 07:28:51 -04:00
Wilson Snyder da254af8d5 Fix MinGW compiler error, bug929. 2015-06-08 07:24:04 -04:00
Wilson Snyder 98123dc422 Verison fix 2015-06-06 14:02:06 -04:00
Wilson Snyder 466909b3d9 devel release 2015-06-06 14:00:23 -04:00
Wilson Snyder 0d4305192a Version bump 2015-06-06 13:58:26 -04:00
Wilson Snyder 9e61b9f696 Fix width propagation on sized casts, bug925. 2015-06-06 13:43:14 -04:00
Wilson Snyder 491539ff32 Fix MSVC++ compiler error, bug927. 2015-06-04 19:37:03 -04:00
Wilson Snyder 4c29a13a6e Fix include, part of bug919. 2015-05-16 18:08:20 -04:00
Wilson Snyder b66e1bdb9e Fix Ubuntu 15.04 compile warning. 2015-05-15 20:03:29 -04:00
Wilson Snyder 7312de6bc2 Fix sign extension in large localparams, bug910. 2015-05-14 21:46:07 -04:00
Wilson Snyder 1d6bcda014 Add pkg-config .pc file, bug919. 2015-05-13 21:21:29 -04:00
Wilson Snyder 5a747bad7d Fix width extension on mis-width ports, bug918. 2015-05-13 20:59:13 -04:00
Wilson Snyder 9542783a7e Internals: Refactor V3Inst static class. No functional change. 2015-05-13 20:56:16 -04:00
Wilson Snyder a59639413d Fix part-select in constant function, bug916. 2015-05-09 14:01:54 -04:00
Wilson Snyder d5eb92a071 Fix preprocessing stringified newline escapes, bug915. 2015-05-07 21:41:54 -04:00
Wilson Snyder 994cde57af Fix Cygwin uint32 compile, bug914. 2015-05-07 20:41:53 -04:00
Wilson Snyder 238a5809bf Fix truncation warning with -pins-bv, bug912. 2015-04-28 21:31:25 -04:00
Wilson Snyder 49fa65c0dd Match Verilog-Perl: Fix Preproc loop under Perl-Tk, bug913. 2015-04-28 15:54:34 -04:00
Wilson Snyder 49123f169c Fix core dump in sync-async warnings, bug911. 2015-04-27 06:47:29 -04:00
Wilson Snyder 4dc64c387f Part of prev commit, fix installing missing manpages, bug908. 2015-04-27 06:47:15 -04:00
Wilson Snyder 98a63711dd Fix installing missing manpages, bug908. 2015-04-09 19:03:01 -04:00
Wilson Snyder cb95cf4745 devel release 2015-04-09 19:00:02 -04:00
Wilson Snyder acd48fa61d Commentary, bug907. 2015-04-09 18:58:01 -04:00
Wilson Snyder cb7abcbaea Commentary 2015-04-09 18:57:25 -04:00
Wilson Snyder 793c974480 Version bump 2015-04-05 10:56:20 -04:00
Wilson Snyder 78a321925f Add Parser useProtected argument to aid runtime, Verilog-Perl bug899. 2015-04-05 10:54:56 -04:00
Wilson Snyder 643572595e Fix compile warning, msg1613. 2015-03-16 10:08:59 -04:00
Wilson Snyder fb4d462325 Rename readme for github. Commentary. 2015-03-14 13:45:00 -04:00
Wilson Snyder c0df07c86f Commentary: Update contributor list 2015-03-13 07:38:17 -04:00
Wilson Snyder e918d945f2 Fix order of C style arrays. 2015-03-13 07:06:06 -04:00
Wilson Snyder 0ee5743853 Add --dump-treei-<srcfile>, bug894. 2015-03-12 19:48:04 -04:00
Wilson Snyder 486d69da5f Add --clk and related optimizations, msg1533. 2015-03-12 19:20:46 -04:00
Wilson Snyder 005b4b7609 Updated - add VerilatedVcdFile to allow real-time waveforms, bug890. 2015-03-05 20:21:48 -05:00
Wilson Snyder a0fd065dcf Add VerilatedVcdFile to allow real-time waveforms, bug890. 2015-03-05 08:54:57 -05:00
Wilson Snyder 751384cb5c Fix compile error on MinGW, bug887. 2015-02-26 20:40:45 -05:00
Wilson Snyder 6ac672b4a3 Fix SystemC arrayed bit vectors, bug886. 2015-02-25 21:09:55 -05:00
Wilson Snyder a89502be9f Fix comma-separated instantiations with parameters, bug884. 2015-02-22 11:41:10 -05:00
Wilson Snyder 04e7b3bd4d devel release 2015-02-12 20:39:20 -05:00
Wilson Snyder 9ebb37b6a5 Version bump 2015-02-12 20:37:44 -05:00
Wilson Snyder 052a7e3deb Fix sign extension of pattern members, bug882. 2015-02-12 07:47:45 -05:00
Wilson Snyder 108c0f6bb8 Fix configure selecting switches that give warnings. 2015-02-11 21:24:01 -05:00
Wilson Snyder 6ed89b6ca5 New test for bug882. 2015-02-11 19:46:19 -05:00
Wilson Snyder 27ccaffb37 Fix mis-optimizing gate assignments in unopt blocks, bug881. 2015-02-11 19:36:34 -05:00
Wilson Snyder a001babad2 Fix executable bit on driver.pl from recent change. 2015-02-11 18:14:08 -05:00
Wilson Snyder 32a76c5255 Fix clang warnings. 2015-02-10 22:38:05 -05:00
Wilson Snyder 099f797975 Fix slice connections of arrays to ports, bug880. 2015-02-10 20:24:21 -05:00
Wilson Snyder b7df3e24b4 Tests: Support -ms for modelsim testing, bug878 2015-02-10 20:16:03 -05:00
Wilson Snyder 8323092a0c Fix cppcheck warnings. No functional change. 2015-02-09 21:05:27 -05:00
Wilson Snyder e5af46d3fb Add warning on slice selection out of bounds, bug875. 2015-01-25 16:32:46 -05:00
Wilson Snyder a6743588b6 Fix UNOPTFLAT change detect on multidim arrays, bug872. 2015-01-21 20:43:21 -05:00
Wilson Snyder 90cbcd2dfd Fix non-ANSI modport instantiations, bug868. 2015-01-17 15:35:45 -05:00
Wilson Snyder a36b7afba5 Fix VM_PARALLEL_BUILDS broke in 3.868, bug870. 2015-01-17 13:31:27 -05:00
Wilson Snyder 4c91ade61d Copyright year update 2015-01-07 18:25:53 -05:00
Wilson Snyder f2a17b9b70 Fix $sccanf from string, bug866. 2014-12-24 21:50:38 -05:00
Wilson Snyder b71b9ccb57 Fix member select error broke in 3.868, bug867. 2014-12-24 19:27:46 -05:00
Wilson Snyder 8b0af19351 Support cast operator with expression size, bug865. 2014-12-23 22:11:31 -05:00
Wilson Snyder 9f7c473376 Suppress COMBDLY when inside always_latch, bug854. 2014-12-23 21:42:33 -05:00
Wilson Snyder 0206767478 devel release 2014-12-20 16:49:42 -05:00
Wilson Snyder 1a3378e0f5 Add --stats-vars, bug851. 2014-12-20 08:28:31 -05:00
Wilson Snyder 5c3eee34a1 Fix underscores in real literals, bug863. 2014-12-19 18:14:32 -05:00
Wilson Snyder 2b5017e610 Fix tracing SystemC signals with structures, bug858. Remove SC tracing of wrapper. 2014-12-10 22:33:28 -05:00
Wilson Snyder e755c7fdcc Internals: Rename to avoid off-by-one 2014-11-29 08:56:07 -05:00
Wilson Snyder 8d463b33cd Fix enum name off-by-one, bug854. 2014-11-29 08:47:03 -05:00
Wilson Snyder 7d9b21a874 Commentary 2014-11-28 21:37:47 -05:00
Wilson Snyder a118921b21 Fix bare generates in interfaces, bug789. 2014-11-28 21:32:57 -05:00
Wilson Snyder a1aefd2330 Tests: Check for bug509. 2014-11-28 20:54:55 -05:00
Wilson Snyder 8b511379ac Tests: Disabled test for static vars 2014-11-28 20:44:07 -05:00
Wilson Snyder c1593f856d Support enum.first/name and similar methods, bug848. 2014-11-28 20:34:23 -05:00
Wilson Snyder 93f1d7643d Fix duplicate Vdimtables and rename 2014-11-28 20:25:58 -05:00
Wilson Snyder ce4dfb4296 Fix misc string handling issues. 2014-11-28 20:24:42 -05:00
Wilson Snyder 2e5f5010f7 Internals: Make V3Width dimensionValue more generic. No functional change. 2014-11-28 15:51:35 -05:00
Wilson Snyder 7c588c2e30 Tests: Rename test. 2014-11-28 15:11:03 -05:00
Wilson Snyder 43be4cf2b5 Add 'string' printing and comparisons, bug746, bug747, etc. 2014-11-28 15:01:50 -05:00
Wilson Snyder 8b457b9b66 Internal: Rename string functions. No functional change. 2014-11-28 13:50:37 -05:00
Wilson Snyder 25efee2e62 Fix loss of data types in V3Premit. From strings branch. 2014-11-28 10:43:05 -05:00
Wilson Snyder 546c91a940 Fix runtime error with autoflush. 2014-11-28 07:56:21 -05:00
Wilson Snyder 85ebc5f7bd Fix called with narrow output strings 2014-11-27 12:32:41 -05:00
Wilson Snyder e002b0e25f Fix new inlining to be less aggressive 2014-11-27 12:04:16 -05:00
Wilson Snyder 4944383769 Fix to install verilator_coverage manpage. 2014-11-27 11:44:06 -05:00
Wilson Snyder 68c6f0ff07 Inline C functions that are used only once, msg1525. 2014-11-27 10:52:38 -05:00
Wilson Snyder 5078152292 Tests: Fix sigstop on parallel tests 2014-11-27 10:48:27 -05:00
Wilson Snyder 9837b40330 Remove SystemPerl tests 2014-11-27 08:30:54 -05:00
Jeremy Bennett cb645c9a74 Add missing header.
Signed-off-by: Wilson Snyder <[email protected]>
2014-11-26 16:46:16 -05:00
Wilson Snyder 87573a9fef Part of earlier commit - no SystemPerl now for coverage. 2014-11-24 18:37:55 -05:00
Wilson Snyder 7c486e27ba Tests: Remove unneeded SystemPerl dependencies. 2014-11-24 07:53:33 -05:00
Wilson Snyder 4a3bdc340d Tests: Remove unneeded SystemPerl dependencies. 2014-11-23 22:18:07 -05:00
Wilson Snyder 903ee0622d Remove test_vcs directory. 2014-11-23 22:04:09 -05:00
Wilson Snyder d33ad7600b Commentary. Cleanup stale SystemPerl references. 2014-11-23 22:00:00 -05:00
Wilson Snyder 9ec35a2348 New verilator_coverage and infrastructure to replace SystemPerl's vcoverage. 2014-11-23 21:06:10 -05:00
Wilson Snyder 6da13c6486 Internals: Split V3Error into V3FileLine. No functional change. 2014-11-22 11:48:39 -05:00
Wilson Snyder 87a47a5ca0 Remove PSL support 2014-11-22 10:14:14 -05:00
Wilson Snyder c682f1c16a Commentary and internal cleanups. 2014-11-22 09:04:14 -05:00
Wilson Snyder 591075a8ed Fix sc_main test to make trace data. 2014-11-18 19:43:44 -05:00
Wilson Snyder 41701673a0 devel release 2014-11-15 08:43:27 -05:00
Wilson Snyder 55f0d4ddd8 Version bump 2014-11-15 08:38:44 -05:00
Wilson Snyder 6d66fcaa57 Fix +define+A+B to define A and B to match other simulators, bug847. 2014-11-13 19:05:07 -05:00
Wilson Snyder 26e79ca889 Fix quoted comment slashes in defines, bug845. 2014-11-12 16:37:51 -05:00
Wilson Snyder 62eb247c1e Optimize SUB/ADD together. 2014-11-09 18:33:54 -05:00
Wilson Snyder c5fd583b2c Fix select when partially out-of-bound, bug823. 2014-11-09 18:29:52 -05:00
Wilson Snyder 117db3e11c Trace_off now operates on cells, bug826. 2014-11-08 14:15:10 -05:00
Wilson Snyder 3f82fd2f37 Add public enums, bug833. 2014-11-07 07:50:11 -05:00
Wilson Snyder e9c46afcf7 Fix public parameters in unused packages, bug804. 2014-11-06 17:53:01 -05:00
Wilson Snyder 3234fa15ef Fix trace overflow on huge arrays, bug834. 2014-11-05 22:22:27 -05:00
Jie Xu 7ef84df852 Add optimization of wires from arrayed cells, msg1447.
Signed-off-by: Wilson Snyder <[email protected]>
2014-11-05 21:09:35 -05:00
Jie Xu 4e2884b509 Optimize e.g. {(b<<4)[7:4], (b<<4)[3:0]}. From assignmerge tree.
Signed-off-by: Wilson Snyder <[email protected]>
2014-11-05 20:58:36 -05:00
Wilson Snyder 03100020ab Fix not tracing modules following primitives, bug837. 2014-11-04 07:49:03 -05:00
Wilson Snyder 8bfb5cc5e9 Internals: Add sameGateTree. 2014-11-02 19:52:49 -05:00
Wilson Snyder cf6d07aafa Add optimization of operators between concats, msg1447. 2014-10-22 21:44:41 -04:00
Wilson Snyder 85c3179dbd Commentary 2014-10-21 19:11:46 -04:00
Wilson Snyder bfbca34eb0 Fix cast-to-size context-determined sizing, bug828. 2014-10-17 19:01:04 -04:00
Wilson Snyder b73edc0564 Fix generate unrolling with function call, bug830. 2014-10-15 21:29:37 -04:00
Wilson Snyder 6ba90e3a50 devel release 2014-09-21 09:06:40 -04:00
Wilson Snyder e8edbad18c Version bump 2014-09-21 09:04:36 -04:00
Wilson Snyder c86fec5307 Fix string formats under deep expressions, bug820. 2014-09-21 08:52:09 -04:00
Wilson Snyder 6e476255ca Support power operator with real, bug809. 2014-09-21 08:24:44 -04:00
Wilson Snyder 27af9b6b06 Fix clang warnings, bug818. 2014-09-11 21:28:53 -04:00
Wilson Snyder f8208fa961 Print Aborting before aborting, bug819 2014-09-05 21:40:04 -04:00
Wilson Snyder 87b9cb49ad Fix / multi-argument ordering, bug816. 2014-09-04 22:25:19 -04:00
Wilson Snyder b2da0772e6 Commentary 2014-09-04 22:15:11 -04:00
Wilson Snyder 4f73e0850e Improve verilator_profcfunc time attributions. 2014-08-28 22:10:39 -04:00
Wilson Snyder b6a39db627 Fix optional parameter keyword in module #(), bug810. 2014-08-27 07:57:20 -04:00
Wilson Snyder 3a83b06572 Fix over-shift structure optimization error, bug803. 2014-07-28 07:31:01 -04:00
Wilson Snyder fe5bf01b25 Fix dpiGetContext in dotted scopes, bug740. 2014-07-21 20:55:52 -04:00
Wilson Snyder 5559ec903b Fix error when tracing public parameters, bug722. 2014-07-21 20:44:33 -04:00
Wilson Snyder 18750028b2 Fix mis-optimization of bit-swap in wide signal, bug800. 2014-07-04 09:13:59 -04:00
Wilson Snyder 6b88648c67 Commentary, bug799 2014-07-02 21:04:51 -04:00
Wilson Snyder 58ee803cb4 Fix test GCC warning, bug794. 2014-06-26 21:45:14 -04:00
Wilson Snyder 894ff73c7d Internals: Fix clang warning, bug791. 2014-06-19 18:02:42 -04:00
Wilson Snyder 8031f0ed7f Fix duplicate anonymous structures in , bug788. 2014-06-15 11:18:47 -04:00
Wilson Snyder 3a56b5da47 devel release 2014-06-10 20:43:10 -04:00
Wilson Snyder fedcb6d26a Version bump 2014-06-10 20:39:51 -04:00
Wilson Snyder eed3c5e543 Tests: Add t_tri_array and enable t_sv_cpu. 2014-06-10 20:02:18 -04:00
Wilson Snyder e26ab67e25 Report tristate errors closer to code which created them. 2014-06-10 19:58:51 -04:00
Wilson Snyder e77b7427b4 Fix shift corner-case, bug 774. 2014-06-10 19:13:55 -04:00
Wilson Snyder 475e4207cc Fix late constant division by zero giving X error, bug775. 2014-06-09 22:27:04 -04:00
Wilson Snyder 71b2eed32c Fix false name conflict on cells in generate blocks, bug749. 2014-06-09 22:00:45 -04:00
Wilson Snyder 6cf50e6579 Fix string corruption, bug780. 2014-06-08 21:36:18 -04:00
Wilson Snyder 69468708e2 Fix DETECTARRAY error on packed arrays, bug770. 2014-06-07 09:53:40 -04:00
Wilson Snyder 5da5678e64 Fix pattern assignment to conditionals, bug769. 2014-06-06 21:52:16 -04:00
Wilson Snyder a428e7f618 Fix pattern assignment to arrayed basic type, bug769. 2014-06-06 21:14:44 -04:00
Wilson Snyder 0eb5a0a539 Add -P to suppress `line and blanks with preprocessing, bug781. 2014-06-06 20:22:20 -04:00
Wilson Snyder a1c1ff9981 Fix seg-fault with variable of parameterized interface, bug692. 2014-05-28 07:33:40 -04:00
Wilson Snyder 2029ade18c Change SYMRSVDWORD to print as warning rather than error. 2014-05-28 07:24:02 -04:00
Wilson Snyder 5f8f474c0c Fix shift with XOR mis-optimization, bug776. 2014-05-26 18:16:52 -04:00
Wilson Snyder f705f9b275 Fix C compiler interpreting signing, bug773. 2014-05-24 08:00:01 -04:00
Wilson Snyder 91e706ec1f Fix X shift issue, bug772. 2014-05-24 07:05:23 -04:00
Wilson Snyder dcf351f847 Copyright 2014-05-20 06:12:08 -04:00
Wilson Snyder 06744b664a Fix huge shifts to zero with -Wno-WIDTH, bug768. 2014-05-16 07:09:43 -04:00
Wilson Snyder d3049d9c89 Fix huge shifts to zero with -Wno-WIDTH, bug766. 2014-05-15 21:49:43 -04:00
Wilson Snyder 1f2abb9c0f Fix gate primitives with arrays and non-arrayed pins. 2014-05-15 20:57:09 -04:00
Wilson Snyder 9f0d7e50a5 Using command line -Wno-{WARNING} now overrides file-local lint_on. 2014-05-15 20:54:45 -04:00
Wilson Snyder 5f262a8f11 Fix ENDLABEL warnings on escaped identifiers. 2014-05-15 20:52:22 -04:00
Wilson Snyder f62bc6a2e5 Support SV 2012 package import before port list. 2014-05-15 20:50:42 -04:00
Wilson Snyder d7e4bc1379 Fix huge shifts to zero with -Wno-WIDTH, bug765. 2014-05-13 08:10:59 -04:00
Wilson Snyder cd2d6575c6 devel release 2014-05-11 16:58:01 -04:00
Wilson Snyder b46f656d17 Version bump. 2014-05-11 16:51:56 -04:00
Wilson Snyder 58fd602bbd Fix flex warning 2014-05-11 09:36:39 -04:00
Wilson Snyder 9cc95704cd Tests: Add t_inst_dff parameter width change test. 2014-05-11 09:18:04 -04:00
Wilson Snyder 5f5a3dbb0a Tests: More width testing. 2014-05-10 21:51:21 -04:00
Wilson Snyder f8f53df4ec Fix X/Z extension with WIDTH param mismatch, bug764. 2014-05-10 21:38:36 -04:00
Wilson Snyder 56b85cc63c Suppress WIDTH warnings on 'x = 1<<a' 2014-05-10 17:19:57 -04:00
Wilson Snyder 90aca97e66 Internals: Flip sense of warnOn. No functional change intended. 2014-05-10 17:12:04 -04:00
Wilson Snyder 6ce2a52c5f Fix shift-right optmiization, bug763. 2014-05-10 16:38:20 -04:00
Wilson Snyder 1f56312132 Fix -Wno-UNOPTFLAT change detection with 64-bits, bug762. 2014-05-10 12:40:35 -04:00
Wilson Snyder 3aa290cddb Add error on power > 64-bits, bug761. 2014-05-10 08:24:51 -04:00
Wilson Snyder 1d1eb4fedb Testcase for bug756. 2014-05-10 08:20:10 -04:00
Wilson Snyder 266ff41386 For --cdc, don't show data types in dump file. 2014-05-10 07:50:04 -04:00
Wilson Snyder 02331e5536 Fix begin_keywords 1800+VAMS, msg1211. 2014-05-08 07:15:44 -04:00
Wilson Snyder 621c51589a Fix shift by x, bug760. 2014-05-04 08:50:44 -04:00
Wilson Snyder 4a58e859a4 Fix concats with no argments mis-sign extending, bug759. 2014-05-03 20:20:15 -04:00
Wilson Snyder 48d393d8f5 Tests: test_verilated must match signs on == sides. 2014-05-03 20:11:38 -04:00
Wilson Snyder 321552d998 Fix wide modulus uninit var 2014-05-03 20:09:45 -04:00
Wilson Snyder a985a1f9f5 Fix >>> sign extension based on expression, bug754. 2014-05-03 09:25:12 -04:00
Wilson Snyder d532a36739 Fix change detection error on unions, bug758. 2014-05-02 08:14:23 -04:00
Wilson Snyder b631b5927b Fix shift width extension, broke recent commit, bug754. 2014-04-30 22:47:01 -04:00
Wilson Snyder adb39ceb98 Internals: cppcheck clean and add cppcheck_filtered 2014-04-29 22:59:38 -04:00
Wilson Snyder 84b91b19ca Commentary 2014-04-29 22:02:48 -04:00
Wilson Snyder aaea68d3d6 Rewrite V3Width for better spec adherence when -Wno-WIDTH. 2014-04-29 22:01:50 -04:00
Wilson Snyder 2accba2e71 Update WIDTH warning message formats to match future commit. 2014-04-29 21:11:57 -04:00
Wilson Snyder 8f4f4eb5ae Fix coredump on undriven vector[-1]. 2014-04-29 21:09:44 -04:00
Wilson Snyder c5aabb3c6e Tests: Move most old test_v tests into test_regress. 2014-04-29 19:47:26 -04:00
Wilson Snyder 60c2d136e1 Internals: V3Width renames. Fix CASEEQ signing. 2014-04-26 16:52:09 -04:00
Wilson Snyder cae6ec16ba Commentary 2014-04-26 13:59:50 -04:00
Wilson Snyder 30601c77d4 tests: Add driver --unsupported 2014-04-22 20:50:22 -04:00
Wilson Snyder b0f4cf3c9c Support {} in always sensitivity lists, bug745. 2014-04-21 19:39:28 -04:00
Wilson Snyder c41dfcf6ad Fix assertions broken from bug725, bug743. 2014-04-16 22:33:25 -04:00
Wilson Snyder 2e10555f03 Fix tracing of packed arrays without --trace-structs, bug742. 2014-04-15 20:20:45 -04:00
Wilson Snyder 6b2ee0fcf3 Fix reporting struct members as reserved words, bug741. 2014-04-15 19:35:44 -04:00
Wilson Snyder 0dbdbffba7 Fix double I/O port warnings. 2014-04-15 18:50:04 -04:00
Wilson Snyder 9c5dd8d767 Fix RHEL5.6 compile warnings. 2014-04-15 18:18:36 -04:00
Glen Gibb fff0ebb5f3 Internals: Add AstReplicate dtype init.
Signed-off-by: Wilson Snyder <[email protected]>
2014-04-10 17:54:52 -04:00
Glen Gibb d34275150c Support streaming operators, bug649.
Signed-off-by: Wilson Snyder <[email protected]>
2014-04-09 20:29:35 -04:00
Wilson Snyder d04eb977c2 Fix mis-extending red xor/xand operators. 2014-04-09 07:58:46 -04:00
Wilson Snyder fb4928b2f5 Fix power calculation; setAllOnes should not set hidden state bits in V3Number. 2014-04-08 20:28:16 -04:00
Wilson Snyder 5c39420d91 Re-fix bug729 due to bug733; other internal sign extension cleanups too. 2014-04-07 21:34:00 -04:00
Wilson Snyder 14fcfd8a40 Fix signed extension problem with -Wno-WIDTH, bug729. 2014-04-05 15:52:05 -04:00
Wilson Snyder ff19dd94f9 Fix power operator calculation, bug730. 2014-04-05 15:44:49 -04:00
Wilson Snyder b6913ff9b3 With high c-splits, even split blank functions. 2014-04-05 12:41:00 -04:00
Wilson Snyder 4573fd3069 Tests: Fix unsupported items. 2014-04-03 22:03:03 -04:00
Wilson Snyder 6cf6d9f7e1 Fix modport function import not-found error. 2014-04-03 21:53:39 -04:00
Wilson Snyder 28e35a64ea Support parameter arrays, bug683. 2014-04-01 23:16:16 -04:00
Wilson Snyder 091818483a Order initial statements based on variables used. Merge from bug683 branch. 2014-04-01 22:01:25 -04:00
Wilson Snyder 3b43556c41 Internals: Remove dead NEW_ORDERING code. 2014-03-31 20:29:35 -04:00
Wilson Snyder ed39c66715 Internals: Make const iterator to fix missed-edits on dump. Merge from bug683 branch. 2014-03-31 20:24:05 -04:00
Wilson Snyder 446b0e4e5e Support '{} assignment pattern on arrays, bug355. 2014-03-30 20:41:20 -04:00
Wilson Snyder 6e3e8318d0 Internals: Add dtype to InitArray; misc Slice cleanups. From bug355 branch. 2014-03-30 20:28:51 -04:00
Wilson Snyder 17b8b660f0 Internals: Fix assignment pattern replication. From bug355 branch. 2014-03-30 10:20:12 -04:00
Wilson Snyder 40bceea68a Fix missing coverage line on else-if, bug727. 2014-03-29 11:04:13 -04:00
Holger Waechtler b655c17c09 Fix Mac OS-X test issues.
Signed-off-by: Wilson Snyder <[email protected]>
2014-03-29 08:30:08 -04:00
Wilson Snyder a3813f94fc Add PINCONNECTEMPTY warning. 2014-03-27 21:36:52 -04:00
Wilson Snyder c70540a825 Fix Mac OS-X include compile issue. 2014-03-27 21:07:59 -04:00
Holger Waechtler 9caffe330b Fix Mac OS-X test issues.
Signed-off-by: Wilson Snyder <[email protected]>
2014-03-24 20:19:43 -04:00
Wilson Snyder 8d8c5da812 Add assertions on 'unique if', bug725. 2014-03-16 21:38:29 -04:00
Wilson Snyder 55bb766c15 Fix escaped newline in assertion failures. 2014-03-16 20:57:15 -04:00
Wilson Snyder c18df68ead Fix C++-2011 warnings. 2014-03-15 14:50:03 -04:00
Wilson Snyder 3996e94c39 Fix Bison 4.0 warnings. From Verilog-Perl. 2014-03-15 14:23:19 -04:00
Wilson Snyder 1bdf017f9e PSL is no longer supported, please use System Verilog assertions. 2014-03-14 21:14:24 -04:00
Wilson Snyder 93790c1dc6 Fix tracing of package variables and real arrays. 2014-03-14 20:36:47 -04:00
Wilson Snyder ba8c11b25d Fix scope creating extra vars for package variables. See next trace commit for test. 2014-03-14 20:24:21 -04:00
Wilson Snyder ca57edfa0b Fix assignment temporaries not using real types. 2014-03-14 20:22:06 -04:00
Wilson Snyder ccb6545c32 tests: Fix bogus set of output. 2014-03-14 20:19:56 -04:00
Wilson Snyder d146dbc9d7 Commentary. 2014-03-14 20:13:41 -04:00
Glen Gibb b4eaaccc88 Documentation fixes, bug723.
Signed-off-by: Wilson Snyder <[email protected]>
2014-03-14 07:17:03 -04:00
Wilson Snyder c9ed9e74f2 Add --no-trace-params. 2014-03-13 20:08:43 -04:00
Wilson Snyder 587c7c70f5 devel release 2014-03-11 19:52:28 -04:00
Wilson Snyder 749ff021b6 Version bump 2014-03-11 19:48:57 -04:00
Wilson Snyder 85c5765c00 Fix parsing "#0 'b0", bug256. 2014-03-11 19:07:58 -04:00
Wilson Snyder 9e76078939 Fix signed shift right optimization, bug715. 2014-03-09 21:28:28 -04:00
Wilson Snyder 334e0e1ca6 Internals: Debug message. 2014-03-09 21:22:01 -04:00
Wilson Snyder dce4519995 Optimizer: Put constants on left side of compares to match other AstBiOps and extend optimizations. No runtime result change intended. 2014-03-09 17:13:37 -04:00
Wilson Snyder 45bbae80e7 Add parameters into trace files, bug706. 2014-03-08 15:36:04 -05:00
Wilson Snyder d37709a922 test driver: Update VCDs when given HARNESS_UPDATE_GOLDEN 2014-03-08 15:34:42 -05:00
Wilson Snyder 2560ae9bc1 Fix slice extraction from packed array, bug717. 2014-03-08 14:55:05 -05:00
Wilson Snyder 2bdd3ca353 Internals: Refactoring V3WidthSel. No functional change. 2014-03-08 14:41:11 -05:00
Wilson Snyder 8a8aab1aae Internals: Shrink AstSelPlus code. No functional change. 2014-03-08 14:17:39 -05:00
Wilson Snyder 85d790ff79 Fix inside statement EQWILD error, bug718. 2014-03-08 13:33:44 -05:00
Wilson Snyder 68afc96a9f Fix internal error on "input x =" syntax error, bug716. 2014-03-08 12:26:34 -05:00
Wilson Snyder 94efaa7675 Commentary 2014-02-14 08:11:49 -05:00
Wilson Snyder 180af74a50 Fix missing VL_SHIFTRS_IQI with WIDTH warning, bug514. 2014-02-13 18:13:30 -05:00
Wilson Snyder 88af0d3509 Fix --skip-identical mis-detecting on OS-X, bug707. 2014-02-09 16:32:49 -05:00
Wilson Snyder 97633f7bed Fix array bound checks on real variables. 2014-02-09 09:19:05 -05:00
Wilson Snyder 053e016388 Add unsupported test, bug711. 2014-01-25 09:49:56 -05:00
Wilson Snyder 2d61e0270e Support case inside, bug708. 2014-01-20 21:59:53 -05:00
Wilson Snyder 3a23afb0bc devel release 2014-01-20 21:55:27 -05:00
Wilson Snyder 470f12ff46 Version bump 2014-01-18 13:16:08 -05:00
Wilson Snyder 4422de0c6c Copyright year update. 2014-01-06 19:28:57 -05:00
Wilson Snyder 8a708f52f7 Tests: Merge from pattern branch. 2013-12-21 08:29:04 -05:00
Wilson Snyder bcefc17631 Support modport import, bug696. 2013-12-21 06:51:15 -05:00
Wilson Snyder daf19e241e Fix struct trace coredump from recent commit. 2013-12-21 06:46:48 -05:00
Wilson Snyder b5f5b1fdf9 Fix wire declarations with size and not range, bug466. 2013-12-14 19:50:55 -05:00
Wilson Snyder 801b718953 Add --trace-structs to show struct names, bug673. 2013-12-14 19:13:31 -05:00
Wilson Snyder f571658aa4 Commentary 2013-12-14 18:07:55 -05:00
Wilson Snyder 5d233b8c09 Fix parameter pin vs. normal pin error, bug704. 2013-12-14 18:04:10 -05:00
Wilson Snyder 00724597f4 Fix tracing of packed structs, bug705. 2013-12-14 16:51:08 -05:00
Wilson Snyder c659940ea8 Internals: Use VNumRange for AstTraceDecl 2013-12-14 12:17:31 -05:00
Wilson Snyder 23539eb55c Fix some delayed assignments of typedefed unpacked arrays. See following trace test. 2013-12-14 10:33:08 -05:00
Wilson Snyder e69bf418de Fix --lint-only with MinGW, msg1283. 2013-11-29 08:28:48 -05:00
Wilson Snyder 0e1fcd38bb Version bump 2013-11-26 19:52:19 -05:00
Wilson Snyder e74186565d Add --compiler clang to work around compiler bug, bug694. 2013-11-26 18:46:55 -05:00
Wilson Snyder 7e54281e26 Fix array assignment from const var, bug693. 2013-10-31 22:39:26 -04:00
Wilson Snyder 15f512bdee Debug: With --debug, run check tree at all steps even if no --dump-more 2013-10-30 23:25:54 -04:00
Wilson Snyder ecfe0283e2 Fix crash with coverage of structures, bug691. 2013-10-29 20:15:01 -04:00
Wilson Snyder 3b874f759c Fix of last commit, bug689. 2013-10-28 21:57:52 -04:00
Wilson Snyder 9c9b4ed4e0 Fix vpi_remove_cb inside callback, bug689. 2013-10-28 21:00:40 -04:00
Wilson Snyder 4f6d80c602 Add UNPACKED warning to convert unpacked structs. 2013-10-28 20:41:05 -04:00
Wilson Snyder b50542531d Fix enum value extension of '1. 2013-10-28 20:24:31 -04:00
Wilson Snyder 8ab28d1d12 Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2013-10-28 11:15:33 -04:00
Wilson Snyder 9567da22f8 Compiler warning fix. 2013-10-28 11:14:13 -04:00
Wilson Snyder 36814b7681 Support vpi_get_time, bug688. 2013-10-22 22:02:53 -04:00
Wilson Snyder 82235e6c6f Fix vpi_get of vpiSuppressVal, bug687. 2013-10-22 22:01:19 -04:00
Wilson Snyder a8310f35f2 Fix evaluation of chained parameter functions, bug684. 2013-10-18 07:06:32 -04:00
Rich Porter 85989af031 Fix vpi_get of vpiSize, bug680.
Signed-off-by: Wilson Snyder <[email protected]>
2013-10-13 20:05:57 -04:00
Rich Porter cf9ffd16dd tests: For icarus, exit on stop. Merge from RPORTER/vpi-vpiSize-680.
Signed-off-by: Wilson Snyder <[email protected]>
2013-10-11 21:34:48 -04:00
Wilson Snyder 0602537cce Fix t/t_select_index2 test. 2013-10-11 21:29:54 -04:00
Wilson Snyder 24e32420b7 Fix multiple VPI variable callbacks, bug679. 2013-10-03 07:24:50 -04:00
Wilson Snyder 39c494260b devel release 2013-09-30 16:56:52 -04:00
Wilson Snyder 761b9c9290 Version bump 2013-09-30 16:53:45 -04:00
Wilson Snyder 27686d8c2f Add --no-order-clock-delay to work around bug613. 2013-09-30 16:52:43 -04:00
Wilson Snyder d2b007005d devel release 2013-09-29 20:56:19 -04:00
Wilson Snyder f1ef30a5bb Version bump 2013-09-29 20:52:29 -04:00
Wilson Snyder f1d9437c55 Report SELRANGE warning for non-generate if, bug675. 2013-09-10 07:16:13 -04:00
Wilson Snyder bcba5075e8 Fix ordering of , msg1229. 2013-09-07 16:43:43 -04:00
Wilson Snyder d6e8b0263c Fix crash on 32-bit Ubuntu, bug670. 2013-09-03 21:40:43 -04:00
Wilson Snyder 9aba617bad Fix --output-split-cfunc to count internal functions. 2013-09-03 19:35:32 -04:00
Wilson Snyder c24f7b1391 Support named function and task arguments. 2013-08-17 20:34:49 -04:00
Wilson Snyder d4e27b635f devel release 2013-08-15 08:43:37 -04:00
Wilson Snyder c996d2870c Version bump 2013-08-15 08:39:46 -04:00
Wilson Snyder bbd59f8a22 Support passing strings to DPI imports. 2013-08-14 21:37:13 -04:00
Wilson Snyder d3d359e757 Fix clang warnings, bug668. 2013-08-08 19:39:39 -04:00
Wilson Snyder ae763ea93d Internals: Debugs for bug666. 2013-08-08 07:05:21 -04:00
Wilson Snyder 236b9e9761 Fix parameter real conversion from integer. 2013-07-29 22:03:47 -04:00
Wilson Snyder e42c9dfd84 Grammar 2013-07-29 21:53:43 -04:00
Wilson Snyder bebf5b291b Fix final duplicate declarations when non-inlined, bug661. 2013-07-29 21:47:23 -04:00
Wilson Snyder 1e3dcd203d Fix clang warning, bug668. 2013-07-29 10:37:58 -04:00
Wilson Snyder cc7da63dec Tests: Add t_mod_recurse. 2013-06-23 22:39:08 -04:00
Wilson Snyder 1baa2a2558 Fix interface ports with comma lists, msg1058. 2013-06-13 19:38:18 -04:00
Wilson Snyder e63ff77b15 VPI internals: Rename VerilatedRange left/right to match IEEE + VNumRange. No functional change. 2013-06-13 08:05:38 -04:00
Wilson Snyder 6cf9468477 Fix vpi_iterate on memory words, bug655. 2013-06-13 07:58:52 -04:00
Jeremy Bennett b277bc8750 Fix ordering of clock enables with delayed assigns, bug613.
Signed-off-by: Wilson Snyder <[email protected]>
2013-06-05 23:35:47 -04:00
Wilson Snyder ba9da64207 Fix t_trace_cat test, bug654. 2013-06-03 19:08:15 -04:00
Wilson Snyder 9cb9f9c80b devel release 2013-06-02 14:52:19 -04:00
Wilson Snyder 7a65df7636 Version bump 2013-06-02 14:47:36 -04:00
Wilson Snyder eab46d547d Version bump. 2013-06-02 14:38:53 -04:00
Wilson Snyder 3dd552c4a2 Duplicate clock gate optimization on by default, use -Od to disable 2013-05-27 22:39:59 -04:00
Wilson Snyder 23bb045a72 Support interfaces and modports, bug102. 2013-05-27 21:39:19 -04:00
Wilson Snyder 7c834ad118 Internals: Misc cleanups from interface branch. No functional change. 2013-05-27 20:56:20 -04:00
Wilson Snyder 8e2617ab8d Internals: V3Inline support for future hard-no-inline. No functional change. 2013-05-26 11:17:42 -04:00
Wilson Snyder 24fcae4f49 Internals: When broken link fatal, say which rule violated 2013-05-25 17:05:22 -04:00
Wilson Snyder ce18674d88 Internals: (see last) also dump on first non-fatal 2013-05-25 13:31:17 -04:00
Wilson Snyder 6b8d9b5c36 Internals: If registered, dump symtable on any error 2013-05-25 12:15:38 -04:00
Wilson Snyder 81bf95763c Internals: Refactor V3Inline to simplify if(m_cellp) out. No functional change. 2013-05-25 10:42:44 -04:00
Wilson Snyder 2d64077fd0 Internals: Prep to allow future move of wrapping. No functional change. 2013-05-25 10:15:10 -04:00
Wilson Snyder 38faebcf20 Fix packed array select internal error, bug652. 2013-05-24 21:32:54 -04:00
Wilson Snyder 48d177a9d0 Fix packed array select internal error, bug652. 2013-05-24 21:14:42 -04:00
Wilson Snyder 3b3a7f7354 Commentary 2013-05-24 19:09:41 -04:00
Wilson Snyder 99cd2818a1 Tests: Allow driver to find 't' signals when not first in file. 2013-05-23 22:00:55 -04:00
Wilson Snyder 5765e099a6 Debug: More digits for debug file sorting. 2013-05-23 20:50:48 -04:00
Wilson Snyder 175d59ecba Fix GCC version runtime changes, bug651. 2013-05-23 20:19:51 -04:00
Wilson Snyder 3bd3d01968 Tests: Move driver.pl tee into perl to avoid process issue, bug650. 2013-05-23 20:08:39 -04:00
Wilson Snyder 85e2a6bb45 Tests 2013-05-21 22:38:35 -04:00
Wilson Snyder 84efd239a5 Fix arrayed input compile error, bug645. Try 2. 2013-05-18 20:17:17 -04:00
Wilson Snyder 6a69813326 Internals: Renames for interfaces. No functional change. 2013-05-18 19:45:52 -04:00
Wilson Snyder 2c9dcc3913 Fix arrayed input compile error, bug645. 2013-05-15 22:00:28 -04:00
Wilson Snyder 20ea1ca018 devel release 2013-05-11 16:16:22 -04:00
Wilson Snyder 0abde90933 Version bump 2013-05-11 16:11:38 -04:00
Wilson Snyder e01b69198a driver: Fix if no forker. 2013-05-11 16:11:26 -04:00
Wilson Snyder 53cd9d2403 Fix nested union crash, bug643. 2013-05-10 21:02:48 -04:00
Wilson Snyder 3d0f5fc078 Fix packed array non-zero right index select crash, bug642. 2013-05-10 07:09:25 -04:00
Wilson Snyder 54eedcc739 Support signal[vec]++. 2013-05-06 08:02:16 -04:00
Wilson Snyder ae6f5844da Add Verilated::internalsDump() 2013-05-04 10:29:54 -04:00
Wilson Snyder 1bea845ceb Fix simulation error when inputs and MULTIDRIVEN, bug634. 2013-05-02 08:23:17 -04:00
Wilson Snyder d581582339 Add ALWCOMBORDER warning. 2013-04-30 22:55:28 -04:00
Wilson Snyder 4eabc1992e Fix gcc 4.1.2 compile warnings 2013-04-30 22:55:03 -04:00
Wilson Snyder 316eb24bbb Example test 2013-04-28 18:58:04 -04:00
Jeremy Bennett f0a8824efc Commentary, bug639.
Signed-off-by: Wilson Snyder <[email protected]>
2013-04-28 09:04:04 -04:00
Wilson Snyder 345a5d5646 Add --pins-sc-uint and --pins-sc-biguint, bug638. 2013-04-26 21:02:32 -04:00
Wilson Snyder 464679c78b Fix module resolution with __, bug631. 2013-03-12 07:27:17 -04:00
Wilson Snyder 28eeec1cf4 devel release 2013-03-09 16:48:10 -05:00
Wilson Snyder 7d0dce3267 Version bump 2013-03-09 16:44:48 -05:00
Wilson Snyder 9e29625207 Fix UNOPTFLAT circular array bounds crossing, bug630. 2013-03-08 19:25:20 -05:00
Wilson Snyder a767da4f3f Support <number>'() sized casts, bug628. 2013-03-05 22:13:22 -05:00
Wilson Snyder 7bd96c2876 Internals: Tristate commentary 2013-02-27 22:59:17 -05:00
Wilson Snyder 70fd64dcd6 IEEE 1800-2012 is now the default language. This adds 4 new keywords and updates the svdpi.h and vpi_user.h header files. 2013-02-26 23:01:19 -05:00
Jeremy Bennett bb2822f4b5 Add --report-unoptflat, bug611.
Signed-off-by: Wilson Snyder <[email protected]>
2013-02-26 22:26:47 -05:00
Wilson Snyder ad21108b63 Internals: Create graph clone methods. 2013-02-25 21:03:50 -05:00
Wilson Snyder e6808a787c Fix opening a VerilatedVcdC file multiple times, msg1021. 2013-02-23 21:10:25 -05:00
Wilson Snyder 1fb2762725 Tests: Clocking test to consider bug623. 2013-02-22 21:00:37 -05:00
Wilson Snyder cce55941d3 Makefile: Distribute .gdbinit 2013-02-22 17:24:15 -05:00
Wilson Snyder 6c8d95e0e2 Nice message on fopen with missing argument. 2013-02-22 17:14:27 -05:00
Wilson Snyder 216a178b28 Makefile: Distribute .gdbinit 2013-02-22 17:13:31 -05:00
Wilson Snyder 6594a54a95 Fix wrong dot resolution under inlining. 2013-02-21 23:38:29 -05:00
Wilson Snyder a9a4cf061a Fix tristate duplicate __Vcellinp declaration 2013-02-20 22:28:56 -05:00
Wilson Snyder b7f0e204cb Spelling fixes 2013-02-20 21:51:39 -05:00
Varun Koyyalagunta e6a15f233b Internals: GateDedupe: Use visitor per msg980.
Signed-off-by: Wilson Snyder <[email protected]>
2013-02-20 20:26:53 -05:00
Varun Koyyalagunta e0edb596ea Add duplicate clock gate optimization, msg980.
Experimental and disabled unless -OD or -O3 used (for now),
Please try it as may get some significant speedups.

Signed-off-by: Wilson Snyder <[email protected]>
2013-02-20 20:14:15 -05:00
Varun Koyyalagunta f2fb77c15a Internals: New Hashed/Graph functions towards msg980.
Signed-off-by: Wilson Snyder <[email protected]>
2013-02-19 18:49:36 -05:00
Wilson Snyder 772a3a97eb Internals: Functions in order. No functional change. 2013-02-18 12:15:50 -05:00
Wilson Snyder 6c310836a1 Internals: Track original signal name. No functional change. 2013-02-18 11:22:24 -05:00
Wilson Snyder 75416a3016 Commentary 2013-02-18 11:05:47 -05:00
Wilson Snyder ebef78a13e Tests 2013-02-18 10:17:34 -05:00
Wilson Snyder e71baca39b Internals: Make propagateAttrClocksFrom. No functional change. 2013-02-16 08:07:18 -05:00
Wilson Snyder 18eb210313 Support bind in , bug602. 2013-02-14 06:55:09 -05:00
Wilson Snyder 7d38a5e1f9 Test bug424. 2013-02-13 21:10:17 -05:00
Wilson Snyder 4386077e2d Support pattern assignments with data type labels, bug618. 2013-02-13 20:52:38 -05:00
Wilson Snyder 49dbfd2131 Support pattern assignments in function calls, bug617. 2013-02-13 20:32:25 -05:00
Wilson Snyder a80fce5ac1 Support pattern assignments to const variables, bug616. 2013-02-13 19:32:36 -05:00
Wilson Snyder 891b981cab Fix LITENDIAN on unpacked structures, bug614. 2013-02-13 19:03:10 -05:00
Rich Porter 2dd87b8384 Fix 32-bit OS VPI scan issue, bug615.
Signed-off-by: Wilson Snyder <[email protected]>
2013-02-11 07:17:18 -05:00
Jeremy Bennett 062eb85075 Fix DETECTARRAY on packed structures, bug610.
Signed-off-by: Wilson Snyder <[email protected]>
2013-02-10 09:54:27 -05:00
Wilson Snyder e1f6802f5f tests: Fix bootstrap wouldn't cd for test_regress/t/t_dist_portability.pl. 2013-02-10 09:29:35 -05:00
Wilson Snyder 6cfcd50f12 devel release 2013-02-04 22:19:37 -05:00
Wilson Snyder bcadb0b3b3 Version bump 2013-02-04 22:12:21 -05:00
Wilson Snyder 0df561f873 Fix whole slices of arrays, bug609. 2013-02-04 22:11:10 -05:00
Wilson Snyder 238fc24684 Remove slow sync() call for NFS flushing. 2013-02-04 21:21:55 -05:00
Wilson Snyder 936855c81c Fix elimination, bug610 _2 test. 2013-02-03 14:13:16 -05:00
Jeremy Bennett 61ad9d4651 Commentary, bug610.
Signed-off-by: Wilson Snyder <[email protected]>
2013-02-03 13:29:37 -05:00
Wilson Snyder f07f6a26a8 cppcheck fixes 2013-02-03 13:27:37 -05:00
Wilson Snyder 4a5a56f8ef Tests: Fix t_vpi_var uninitialized 2013-02-03 12:21:48 -05:00
Wilson Snyder 7d44bba95c Better packed-array misconnect error message 2013-02-02 19:22:02 -05:00
Wilson Snyder 6e6f1045b8 Fix per-bit array output connection error, bug414. 2013-02-02 18:33:10 -05:00
Wilson Snyder 5dd3221759 Fix complete selection of array ports 2013-02-02 16:52:08 -05:00
Wilson Snyder 09edb467f6 Fix CDC report causing out-of-memory 2013-02-02 15:40:59 -05:00
Wilson Snyder ffb187ae15 Fix enums in sensitivity lists 2013-02-02 14:37:18 -05:00
Wilson Snyder b4a8be07f3 Fix enum items under packages. 2013-02-02 14:11:50 -05:00
Wilson Snyder 4968a2abc5 Support inside expressions. 2013-02-02 12:55:48 -05:00
Wilson Snyder 91159da30d Fix enums with X values. Test in next commit. 2013-02-02 12:43:28 -05:00
Wilson Snyder c9ad61b4fb Support wires with data types, bug608. 2013-02-02 09:33:04 -05:00
Wilson Snyder 3f0dcd8c0e Tests: Redo check macro. 2013-02-02 09:28:45 -05:00
Wilson Snyder e1eb41fe77 Fix segfault on multidimensional dotted arrays, bug607. 2013-01-25 21:27:19 -05:00
Wilson Snyder 498ab23355 Commentary 2013-01-20 13:00:02 -05:00
Wilson Snyder 5d6a053f98 Fix internal error on array pin mismatch, bug393. 2013-01-20 12:59:27 -05:00
Wilson Snyder 929aeebf12 Support , and related functions, bug448. 2013-01-20 12:19:22 -05:00
Wilson Snyder 00bd947385 Tests: Additional unsupported iface tests 2013-01-19 14:40:35 -05:00
Wilson Snyder d4ef86afc0 Fix signed/unsigned parameter misconversion, bug606. 2013-01-18 21:35:43 -05:00
Wilson Snyder 1856cad816 Maintain little endian indication for multidimensional arrays 2013-01-17 23:21:07 -05:00
Wilson Snyder 91e2d1d2a0 Tests: Make struct test pass. 2013-01-17 22:45:35 -05:00
Wilson Snyder f29f30dce0 Fix struct +: slices, bug605. 2013-01-17 21:48:35 -05:00
Wilson Snyder e7ba6ef492 Support VPI product info, warning calls, etc, bug588. 2013-01-17 21:40:37 -05:00
Wilson Snyder de4016dcff Internals: Ast classes create declRange(). 2013-01-17 20:41:45 -05:00
Wilson Snyder bbeb382cbb Internals: Rename range lo/hi to match IEEE. 2013-01-17 20:29:20 -05:00
Wilson Snyder 385c166830 Fix package logic var compile error. 2013-01-17 19:04:36 -05:00
Wilson Snyder 410e6ff203 Fix DECLFILENAME warning on . 2013-01-17 18:38:51 -05:00
Jeremy Bennett 8b47c4e307 Fix loosing logic/bit difference and -x-initial-edge fallout, bug604.
Signed-off-by: Wilson Snyder <[email protected]>
2013-01-17 07:16:19 -05:00
Wilson Snyder 6d1b42bedb Fix implicit one bit parameter selection, bug603. 2013-01-16 20:58:48 -05:00
Wilson Snyder f0a4bd28b6 Comment about -x-initial-edge and logic/bit. 2013-01-16 20:47:22 -05:00
Wilson Snyder 2879684f21 Define SYSTEMVERILOG, SV_COV_START and other IEEE mandated predefines. 2013-01-16 19:11:56 -05:00
Wilson Snyder 0437d0abea Fix pin width mismatch error, bug595. 2013-01-15 19:26:35 -05:00
Wilson Snyder 0286f588bf Tests: bind by modname 2013-01-15 19:23:46 -05:00
Wilson Snyder 042fb76837 Tests 2013-01-14 23:39:56 -05:00
Wilson Snyder 795e66eac9 Support bind, to module names only, bug602. 2013-01-14 23:19:44 -05:00
Wilson Snyder aae0615ffd Commentary 2013-01-14 21:51:02 -05:00
Wilson Snyder 8127a79cb1 Fix nested packed arrays and structs, bug600.
IMPORTANT: Packed arrays are now represented as a single linear vector in
Verilated models this may affect packed arrays that are public or accessed via the VPI.
2013-01-14 21:49:22 -05:00
Wilson Snyder 057ca497dd tests: Fix Xs on vector data 2013-01-14 21:38:16 -05:00
Wilson Snyder 66b1611649 In debug, show node dump after errors. 2013-01-14 21:37:55 -05:00
Wilson Snyder 7f5220a6ca Internals: Fix marking of packed vs unpacked wires. 2013-01-13 22:18:57 -05:00
Wilson Snyder e41e26717b Commentary 2013-01-13 19:51:15 -05:00
Wilson Snyder 7a8184d206 Internals: Remove dimension and use only dtypes for V3Width. 2013-01-13 15:21:38 -05:00
Wilson Snyder 13bf2f19ac Internals: Have V3Unknown/Const use only dtypes for selects. 2013-01-13 14:54:12 -05:00
Wilson Snyder 1d5ebfd0b1 Internals: Have V3WidthSel use only dtypes for select promotion. 2013-01-13 14:49:53 -05:00
Wilson Snyder dfc11da2ce Internals: Dump array bounds in tree file. 2013-01-13 14:30:56 -05:00
Wilson Snyder 191af2e87b Internals: Make SelPlus consistent with other branches. No functional change intended. 2013-01-13 11:30:05 -05:00
Wilson Snyder 0985b82760 Commentary 2013-01-13 09:48:12 -05:00
Wilson Snyder 26f4b5a69a Stats: Count only unpacked 2013-01-12 16:26:26 -05:00
Wilson Snyder 5c7a6e278f Internals: Split into packed and unpacked array types 2013-01-12 16:19:25 -05:00
Wilson Snyder ae1ab8aaaa Fix array slice selection of msb==lsb. 2013-01-12 15:34:09 -05:00
Wilson Snyder 18c25d1b6f Commentary 2013-01-12 14:51:16 -05:00
Wilson Snyder 5888a2c399 Internals: Move V3WidthSel::range into V3Width. No functional change intended. 2013-01-12 14:23:56 -05:00
Wilson Snyder c00603704e Commentary 2013-01-11 07:05:25 -05:00
Wilson Snyder 786bc4b04f devel release 2013-01-09 22:27:36 -05:00
Wilson Snyder 5eca20f849 Version bump 2013-01-09 22:08:30 -05:00
Wilson Snyder 0a3a582949 Fix array extraction of implicit vars, bug601. 2013-01-09 19:00:12 -05:00
Wilson Snyder 08fec0534d Fix package import preventing local var, bug599. 2013-01-08 19:06:52 -05:00
Wilson Snyder 5bf92c9d3a Fix task inlining under case values, bug598. Note this reorders high level operations, so may change loose some optimizations. 2013-01-02 18:35:21 -05:00
Wilson Snyder a8bbf7231b Copyright year update. 2013-01-01 09:42:59 -05:00
Wilson Snyder 83c171012d Test added 2012-12-31 19:06:49 -05:00
Wilson Snyder 229d854607 Fix package resolution of parameters, bug586. 2012-12-31 17:05:13 -05:00
Wilson Snyder 562460606f Internals: Add V3LinkDot m_ds structure, towards bug586. No functional change. 2012-12-31 14:00:04 -05:00
Wilson Snyder 46f70b1cbb Fix implying dotted wire names 2012-12-31 13:50:44 -05:00
Wilson Snyder a547133efe Internals: Remove VAR_MEM to match Verilog-Perl, towards bug586. 2012-12-31 13:47:34 -05:00
Wilson Snyder cf445898ce Internals: Move VARRESET rule to match Verilog-Perl and prevent next change conflict, towards bug586. No functional change. 2012-12-31 13:43:54 -05:00
Wilson Snyder 98f68e46d6 Fix package import of package imports, partial bug592. 2012-12-17 20:26:40 -05:00
Wilson Snyder 27660b271d Fix package import of non-localparam parameter, bug591. 2012-12-17 19:07:23 -05:00
Wilson Snyder 895e374860 Test for last commit. 2012-12-17 18:41:54 -05:00
Wilson Snyder 4c7f051247 Fix task inlining under , bug589. 2012-12-15 21:41:37 -05:00
Wilson Snyder e68afa53a8 Fix non-integer vpi_get_value, bug587. 2012-12-06 09:40:16 -05:00
Wilson Snyder cc47ba2404 Support "unsigned int" DPI import functions, msg966. 2012-12-03 20:43:13 -05:00
Wilson Snyder 2238fa46ed Show fileline in bison debug. 2012-12-02 18:03:34 -05:00
Wilson Snyder de8b040e31 bisonpre: Add colon to states for searching 2012-12-02 16:19:31 -05:00
Wilson Snyder 4ffc48d194 devel release 2012-12-02 16:19:26 -05:00
Wilson Snyder 2433848408 Version bump - changelog 2012-12-01 16:38:21 -05:00
Wilson Snyder e602f7febc Version bump 2012-12-01 16:15:40 -05:00
Wilson Snyder f607b32938 Fix crash on dotted references into dead modules, bug583. 2012-11-30 06:57:36 -05:00
Wilson Snyder c7a088faa5 Fix mis-optimized identical submodule subtract, bug581. Take 2. 2012-11-28 20:18:41 -05:00
Wilson Snyder 30f6c0e105 Fix mis-optimized identical submodule subtract, bug581. 2012-11-28 07:36:47 -05:00
Wilson Snyder 38b9fa7b93 driver: Print message when no Parallel::Forker. 2012-11-21 07:09:29 -05:00
Jeremy Bennett 39a31fc17f Fix --debug overriding preceding --dump-treei, bug580.
Signed-off-by: Wilson Snyder <[email protected]>
2012-11-21 06:55:28 -05:00
Wilson Snyder 899a7df14a Fix VerilatedSave compile issue on MSVCC, bug577. 2012-11-13 20:36:20 -05:00
Wilson Snyder 7a8c425103 Add +1364-1995ext and similar language options, bug532. 2012-11-13 20:12:23 -05:00
Wilson Snyder 0e8ce59022 Fix svdpi compile issue on MSVCC, bug571. 2012-11-05 10:22:19 -05:00
Wilson Snyder 77ac76a158 devel release 2012-11-03 20:19:31 -04:00
Wilson Snyder 8108b97050 Version bump 2012-11-03 20:16:01 -04:00
Wilson Snyder a1c3491dea Display speed ups, bug574. 2012-11-03 20:11:53 -04:00
Wilson Snyder 8bba96a84e Tests 2012-11-03 09:23:34 -04:00
Wilson Snyder 6cd9b25a53 Fix array of struct references giving false error, bug566. 2012-11-03 09:17:42 -04:00
Wilson Snyder 0431b1909c Fix name collision on task inputs, bug569. 2012-11-03 08:01:19 -04:00
Wilson Snyder 907665e2e8 Fix name collision on unnamed blocks, bug567. 2012-11-02 20:30:47 -04:00
Wilson Snyder 61e8836fbd Add -x-initial-edge, bug570. by Jeremy Bennett; from BENNETT/initial-edge branch. 2012-11-02 19:55:34 -04:00
Wilson Snyder 0e921b5dff Speed display, bug373. 2012-11-02 17:54:14 -04:00
Wilson Snyder 7ef37d6e17 Fix missing var access functions when no DPI, bug572. 2012-10-30 03:02:35 -04:00
Wilson Snyder dce227684a Fix mangling on GCC 4.7, msg927. 2012-10-28 17:35:48 -04:00
Wilson Snyder 158e112752 Internals: Resolve misc bison comments with Verilog-Perl. No functional change. 2012-10-08 21:20:13 -04:00
Wilson Snyder ec992c7f5e Internals: Resolve misc bison comments with Verilog-Perl 2012-10-08 20:45:39 -04:00
Wilson Snyder e7d63c7644 Fix large shift error on large shift constants. 2012-10-08 07:05:54 -04:00
Wilson Snyder 6464e8fee6 Misc code cleanups. Merge from assignment pattern branch. No functional change. 2012-09-25 19:27:00 -04:00
Wilson Snyder 047d66a657 Slice code cleanup. No functional change. 2012-09-25 19:17:57 -04:00
Wilson Snyder 55c23360d9 Commentary 2012-09-24 18:28:19 -04:00
Wilson Snyder c378d32c85 Fix parameter pins interspersed with cells broke in 3.840. 2012-09-07 19:51:41 -04:00
Wilson Snyder 3d9540c58c devel release 2012-09-03 20:32:32 -04:00
Wilson Snyder 39724eb916 Version bump 2012-09-03 20:03:25 -04:00
Jeremy Bennett 48dddd4ae7 Debug: Use dot label rather than a custom nTITLE node to label the graph. Generate all graph level attributes as attributes of the graph entity. bug555.
Signed-off-by: Wilson Snyder <[email protected]>
2012-08-27 19:02:27 -04:00
Wilson Snyder 9c00fd10de Add --savable to support model save/restore. 2012-08-26 21:19:43 -04:00
Jeremy Bennett 9309d0b00f Commentary on internals.pod, bug554.
Signed-off-by: Wilson Snyder <[email protected]>
2012-08-25 12:47:59 -04:00
Wilson Snyder 038b5d32a3 Commentary 2012-08-25 12:18:06 -04:00
Jeremy Bennett 706920ba19 Tests: t_vpi_var: Fix vector length, bug553.
Signed-off-by: Wilson Snyder <[email protected]>
2012-08-25 12:05:08 -04:00
Jeremy Bennett 39492a0726 Tidy up .gitignore and MANIFEST.SKIP, bug552.
Signed-off-by: Wilson Snyder <[email protected]>
2012-08-25 07:52:07 -04:00
Wilson Snyder df1170fea9 Test 2012-08-23 13:26:12 -04:00
Wilson Snyder f0e1d204fa Fix triangle symbol resolution error broke in 3.840, bug550.
This requires the parse symbol table persist across all parse runs. This is
probably more correct than before, but may result in some fallout if people
relied on data types not being persistant across separately parsed cells.
2012-08-15 21:28:30 -04:00
Wilson Snyder 8ece0a8a5f Create V3ParseSym. No functional change. 2012-08-15 21:14:20 -04:00
Wilson Snyder 1373b81e7c Include: Allow external progs to test command args 2012-08-14 20:37:15 -04:00
Wilson Snyder d3601dd561 Support '{} assignment pattern on structures, part of bug355. 2012-08-12 15:15:21 -04:00
Wilson Snyder f685cf1d0c Fix duplicate begin error broke in 3.840, bug548. 2012-08-10 19:39:18 -04:00
Wilson Snyder d5fcf0c153 Test for bug349 2012-08-08 22:15:07 -04:00
Wilson Snyder 5f9810070d Fix imports under multiple instantiated cells, bug542. 2012-08-08 21:59:17 -04:00
Wilson Snyder 923efa004b New tests 2012-08-07 20:59:34 -04:00
Wilson Snyder 869e8eab3c tests; check package to package refs 2012-08-07 20:37:28 -04:00
Wilson Snyder b51d197117 Fix defparam in generate broke in 3.840, bug543. 2012-08-07 18:24:51 -04:00
Wilson Snyder e4f0a8952c Fix double-deep parameter cell WIDTHs, bug541. 2012-08-02 07:02:57 -04:00
Wilson Snyder 072ee425f4 Fix previous mis-commit 2012-08-02 07:00:12 -04:00
Wilson Snyder a4c2819be2 Commentary 2012-07-31 19:23:19 -04:00
Wilson Snyder 2a274f9c19 Devel version 2012-07-31 18:53:51 -04:00
Wilson Snyder b4d5a20670 Version bump 2012-07-31 18:09:00 -04:00
Wilson Snyder 6339159b04 MAJOR: Support packed structures and unions, bug181. 2012-07-29 10:16:20 -04:00
Wilson Snyder aec019991c Tests: Misc fixes from struct branch. 2012-07-28 14:05:30 -04:00
Wilson Snyder 33e6a17747 Internals: Look at tree state instead of back for AstAttr. No functional change. 2012-07-28 10:52:29 -04:00
Wilson Snyder ecf508ec23 Fix replicate verilog dump being backwards 2012-07-28 08:25:27 -04:00
Wilson Snyder a5bcfc0509 Tests: Rename t_structure 2012-07-27 21:14:13 -04:00
Wilson Snyder 1899096ff4 Internals: Width debug and null print check 2012-07-27 21:12:06 -04:00
Wilson Snyder 6e219f5831 Internals: Rework V3WidthSel func for non-vars. No functional change intended. 2012-07-25 07:26:41 -04:00
Jeremy Bennett de1bb5aeb6 Tests: fix driver.pl not tracing time 0, bug536.
Signed-off-by: Wilson Snyder <[email protected]>
2012-07-24 18:48:51 -04:00
Wilson Snyder b52d94273c Internals: Move variable referencing into LinkDot in support of structs. 2012-07-24 06:26:35 -04:00
Wilson Snyder e655c85489 Internals: findBit etc can be const. No functional change. 2012-07-23 21:29:53 -04:00
Wilson Snyder dee7210231 Debug: add GDB dtf function to dump tree to file 2012-07-23 20:21:04 -04:00
Wilson Snyder cbd073ed08 Commentary: pthread 2012-07-23 10:12:43 -04:00
Wilson Snyder 09ebc0c163 Internals: Fix 0x tree debug suffix. Misc merges from struct. No functional change. 2012-07-22 22:48:39 -04:00
Wilson Snyder d2ede75c71 Fix compile error under git submodules, bug534. 2012-07-22 19:51:14 -04:00
Wilson Snyder 3e03fef3e3 Tests: Add t_var_notfound_bad 2012-07-22 09:09:53 -04:00
Wilson Snyder 0f583f4b33 Internals: Remove dead varref code, part of last change. 2012-07-21 21:23:57 -04:00
Wilson Snyder f175db74a5 Internals: Rework implicit handling to make room for ParseRef vs. VarRef 2012-07-21 21:18:07 -04:00
Wilson Snyder 8d5e37a413 Internals: Move trace check up. No functional change. 2012-07-21 20:33:24 -04:00
Wilson Snyder 8b9b7178a2 Internals: MAJOR CHANGE. Combine V3Link and V3LinkDot stages for structures.
Functionality should be similar, but may introduce instability in resolving variables/cells.
Final merge from dot.
2012-07-21 17:12:42 -04:00
Wilson Snyder a2f49063e2 Internals: Rename LinkDot methods. Merge from dot. No functional change 2012-07-21 09:27:57 -04:00
Wilson Snyder f3f34baa73 debug: Avoid identical skip in driver debug 2012-07-21 09:16:19 -04:00
Wilson Snyder abe9ecd225 Internals: Move AstBegin code below GenFor. No functional change. 2012-07-21 07:28:39 -04:00
Wilson Snyder 67409af38d Fix valgrind uninitialized bits. 2012-07-19 22:26:15 -04:00
Wilson Snyder b7d1c34aa6 Internals: Add more sym table debug, renames. Merge from dot. No functional change 2012-07-19 21:18:39 -04:00
Wilson Snyder 92809b95c9 driver: Sort results. Merge from dot. 2012-07-19 21:02:36 -04:00
Wilson Snyder b18690cbe2 Linking renames. Merge from dot. No functional change. 2012-07-17 21:29:10 -04:00
Wilson Snyder 96155365b2 Fix GCC 4.7.0 compile warnings, bug530. 2012-07-15 12:27:36 -04:00
Wilson Snyder 3e5067feb1 Fix svdpi.h for apple. 2012-07-15 11:33:27 -04:00
Wilson Snyder 3ec687a0cf Internals: Merge from struct branch, rework LinkDot symbol table. No functional change intended. 2012-06-20 06:13:28 -04:00
Wilson Snyder 365034d7dd Internals: Merge from struct branch, rename SymTable calls. No functional change intended. 2012-06-20 06:09:07 -04:00
Wilson Snyder 09aa9f87d8 Internals: Move initial resolution to V3LinkParse. No functional change intended. 2012-06-13 23:08:45 -04:00
Wilson Snyder 97963fb8c9 Internals: Move DECLFILENAME code to LinkCells. 2012-06-13 22:18:12 -04:00
Wilson Snyder ee1643ce39 Fix false UNUSED warning on file system calls. 2012-06-03 08:20:12 -04:00
Wilson Snyder a82cdcfe48 Add --converge-limit option. 2012-05-31 18:56:31 -04:00
Wilson Snyder 1b439703ff Fix leak issues, bug521 2012-05-30 23:17:55 -04:00
Wilson Snyder 4cc5943f90 Leak fix - Null sense item shouldn't disable event 2012-05-30 23:15:25 -04:00
Wilson Snyder 5fad666678 Fix +: and -: memory leak. 2012-05-29 23:16:13 -04:00
Wilson Snyder e12bf35996 Fix leak check compile and run, bug521. 2012-05-29 22:59:17 -04:00
Wilson Snyder d34fccec22 Internals: Remove typedefFwd earlier to simplify Link 2012-05-28 10:23:47 -04:00
Wilson Snyder 429437f1b9 Internals: Reorder code. No functional change. 2012-05-28 09:19:51 -04:00
Wilson Snyder c6e7d87960 Commentary - Remove author lines as amany contributors now 2012-05-24 19:19:48 -04:00
Wilson Snyder 716320f3ca Extra debug check 2012-05-24 19:15:28 -04:00
Wilson Snyder 1d12b47cb8 Fix internal readWholefile error check, bug518. 2012-05-22 10:20:35 -04:00
Wilson Snyder 1bc1ee9e08 Fix duplicate warnings/errors, bug516. 2012-05-21 21:31:52 -04:00
Wilson Snyder 53f50463bc Internals: Add warnMore() for all continued messages. 2012-05-21 21:24:17 -04:00
Jeremy Bennett 7ab91e660f Tests: Add t_sv_enum_type_methods, bug515.
Signed-off-by: Wilson Snyder <[email protected]>
2012-05-21 18:39:45 -04:00
Wilson Snyder 2f0e230522 Tests: New struct tests. Merge from branch. 2012-05-16 22:27:59 -04:00
Wilson Snyder 280f674ce9 Fix signed extending biops with WIDTH warning off, bug511. 2012-05-16 22:18:52 -04:00
Wilson Snyder a92c66d512 Internals: Pass expected dtype in width. No functional change intended. 2012-05-16 20:58:15 -04:00
Wilson Snyder c45eedcb02 Tests: New t_inst_signed test 2012-05-16 20:21:02 -04:00
Wilson Snyder a9a49345ba Fix loop error message to report line, bug513. 2012-05-16 19:31:24 -04:00
Wilson Snyder 8d960a2eb9 Tests: Add t_sv_cpu, bug473. By Jeremy Bennett. 2012-05-16 18:38:01 -04:00
Wilson Snyder 3e623b8959 Fix GCC 4.6.3 warning 2012-05-15 19:28:07 -04:00
Wilson Snyder 1b1991d53d Fix output with select hitting tristate, bug514. 2012-05-15 19:26:20 -04:00
Wilson Snyder 6d0f39d841 Fix sign-extension underneath boolean operators. (In theory shouldn't matter, since comparing to zero.) 2012-05-11 18:26:45 -04:00
Wilson Snyder 3087501b6c Tests: file_grep prints failing expected value when possible. 2012-05-11 18:24:49 -04:00
Wilson Snyder b429319bc0 Portability fixes for gcc 4.6.3 2012-05-10 22:04:53 -04:00
Wilson Snyder 247e855dbf Fix not showing internal error when no coredump. 2012-05-10 21:58:02 -04:00
Wilson Snyder 1aec645510 Internals: Fix dead parameter calls. No functional change. 2012-05-09 23:06:43 -04:00
Wilson Snyder 3ea2038d3d Internals: Fix dead parameter calls. No functional change. 2012-05-09 23:04:20 -04:00
Wilson Snyder 942cb5e87e Internals: Make findDtype functions use this. No functional change. 2012-05-09 22:12:57 -04:00
Wilson Snyder 37a3a7cdce Fix tristate bug512, broken with tristate commit. 2012-05-09 20:34:15 -04:00
Wilson Snyder 435a27b66a Tristate: Major rework to support Z tieoffs, bug499, bug510. 2012-05-08 21:53:22 -04:00
Wilson Snyder b31a7cdcbf Internals: Fix uninitialized m_alhs 2012-05-08 20:05:43 -04:00
Wilson Snyder ac61548e6a Optimize tristate structure OR(AND(x,y),AND(z,y)). 2012-05-08 19:20:23 -04:00
Wilson Snyder f5ace0f72a Tests: Add bug508, bug509 examples 2012-05-08 17:41:42 -04:00
Wilson Snyder e498b73933 Internals: Misc tristate merges. Pins renamed but... No functional change intended. 2012-05-07 23:43:19 -04:00
Wilson Snyder ff69bdbc6f Debug: Add @ to end of dtype to avoid miscutting 2012-05-07 19:01:45 -04:00
Wilson Snyder 0c1e184cb7 Fix newlines in radix values, bug507. 2012-05-07 08:58:29 -04:00
Wilson Snyder e97541dcbc Internals: Minor tristate changes from branch. No functional change. 2012-05-06 16:52:08 -04:00
Wilson Snyder 7b3eb22865 Fix compile warning 2012-05-06 14:05:56 -04:00
Wilson Snyder d55f065ce2 Internals: Tristate join AND/OR visitor pull setter. No functional change 2012-05-05 15:04:33 -04:00
Wilson Snyder 86af244636 Internals: Tristate common pull setter. No functional change 2012-05-05 15:03:00 -04:00
Wilson Snyder 2c9e2b2e3c Internals: Common insert function in tristate. No functional change. 2012-05-05 14:55:35 -04:00
Wilson Snyder 33c8bf886e Debug: Assume PDF output for dot. 2012-05-05 14:50:11 -04:00
Wilson Snyder ef71a089a6 Internals: Spacing. No functional change 2012-05-05 14:49:43 -04:00
Wilson Snyder 5fc98cce0d Fix parameters not supported in constant functions, bug474. 2012-05-03 21:59:47 -04:00
Wilson Snyder b9101c3d6a Better message for display-like format warnings, bug500. 2012-05-02 21:04:50 -04:00
Wilson Snyder 6aab0f627c Fix input and real loosing real data type, bug501. 2012-05-02 20:53:38 -04:00
Wilson Snyder 6b97673d0a Internals: Fix dtype() dead code drop on assign varrefs 2012-05-02 20:53:19 -04:00
Wilson Snyder 5d8c1ce84e Internals: Avoid broken recusion 2012-05-02 20:52:10 -04:00
Wilson Snyder 33c9591a4b Internals: Move widthPow2. No functional change. 2012-04-29 11:34:25 -04:00
Wilson Snyder 87e8736823 IMPORTANT: Major internal changes for supporting complex data types.
Adds dtype() to every node, keep global table of dtypes and remove duplicates.
Final merge from dtype branch.
2012-04-29 10:14:13 -04:00
Wilson Snyder c0da16bfcd Internals: Create dtypeFrom. Merge from dtype. No functional change. 2012-04-29 09:42:17 -04:00
Wilson Snyder a4ddc5b3ac Internals: Create user1SetOnce(). No functional change. 2012-04-29 08:55:33 -04:00
Wilson Snyder 91e4010039 Internals: Rename AstRefDType subDTypep. Merge from dtype. No functional change. 2012-04-29 08:38:53 -04:00
Wilson Snyder 486b6580d8 Internals: Rename VSignedState. Merge from dtype. No functional change. 2012-04-29 08:30:02 -04:00
Wilson Snyder 9c4ef27d49 Internals: Cleanup dead function names. Merge from dtype. No functional change. 2012-04-29 08:24:32 -04:00
Wilson Snyder 33577eaa68 Tests: Less sensitivity to XML change 2012-04-29 08:23:24 -04:00
Wilson Snyder d5e19661bd Debug: Tree compare between versions; merge from dtype branch. No functional change. 2012-04-28 13:00:44 -04:00
Wilson Snyder 799afac05b Internals: V3Hashed cleanups; merge from dtype branch. No functional change. 2012-04-28 12:33:51 -04:00
Wilson Snyder 3ba36dc30c Debugging: Show tree file writes, commentary 2012-04-28 12:22:38 -04:00
Wilson Snyder 641024c235 Fix generated inouts with duplicated modules, bug498. 2012-04-27 19:41:13 -04:00
Wilson Snyder d9598db117 Internals: In debug dumps, show user pointers 2012-04-27 19:01:08 -04:00
Wilson Snyder 2e4da07a15 Fix ITOD internal error on real conversions, bug491. 2012-04-26 22:30:22 -04:00
Wilson Snyder 40f4411b69 Fix tristate connection to unconnected input, bug494, bug495. 2012-04-26 21:11:48 -04:00
Wilson Snyder c75de0f37c Add INITIALDLY warning on initial assignments, bug478. 2012-04-26 20:40:13 -04:00
Wilson Snyder 74c4c1bf44 Internals: Pass unconnected pins through structures. No functional change intended. 2012-04-26 19:01:11 -04:00
Wilson Snyder 60a637921c Add PINMISSING and PINNOCONNECT lint checks. 2012-04-26 18:46:44 -04:00
Wilson Snyder 22312b3c9c Internals: Remove dead code. No functional change intended. 2012-04-26 18:42:02 -04:00
Wilson Snyder 2e26e44538 Commentary, bug497. Merge from Bennett. 2012-04-26 07:10:49 -04:00
Wilson Snyder 24e79ecc68 Fix coredump on constant connect 2012-04-25 22:51:31 -04:00
Wilson Snyder 5b532a1812 Fix generate if, broke in earlier committ, bug492. Merge from Bennett. 2012-04-25 18:17:10 -04:00
Wilson Snyder f3867d7f80 Fix imports causing symbol table error, bug490. 2012-04-24 21:21:26 -04:00
Wilson Snyder fb90e47e70 Tests: Add t_udp_noname, bug468 2012-04-24 20:43:15 -04:00
Wilson Snyder 68046244dd Fix 'output tri0' 2001 declaration; Var characteristics must be attributes 2012-04-24 07:45:02 -04:00
Wilson Snyder b1507060ad Fix output with tri1, but489 2012-04-24 07:12:51 -04:00
Wilson Snyder ffbd595d88 Support nmos and pmos, bug488. 2012-04-23 20:13:07 -04:00
Wilson Snyder ed5bc1e69c Internals: Rename arrayp to rangep(). No functional change intended. 2012-04-22 19:18:51 -04:00
Wilson Snyder 9734931f67 IMPORTANT: Rewrite tristate handling, tri0, tri1, etc. 2012-04-21 21:45:28 -04:00
Wilson Snyder 0048b04540 Merge from Tristate branch, part 1 of 2. No functional change intended 2012-04-21 19:30:08 -04:00
Wilson Snyder c361932fe2 Commentary: Test documentation, bug486. Merge from Bennett. 2012-04-21 12:58:46 -04:00
Wilson Snyder 2d8feabe54 Fix generate operators not short circuiting, bug413. Merge from Jeremy Bennett. 2012-04-19 22:53:52 -04:00
Wilson Snyder 1b511dd130 Internals: Add opLogIf(f). No functional change. Merge from Jeremy Bennet. 2012-04-19 21:02:08 -04:00
Wilson Snyder 52024f4d80 Makefile: Correct tag file selection. Merge from Jeremy Bennet. 2012-04-19 21:00:58 -04:00
Wilson Snyder 735fa6287f Fix linking suppressing duplicate var and block name errors 2012-04-19 20:51:21 -04:00
Wilson Snyder 7eb407fe2b driver.pl: Add --no-verilation option 2012-04-16 20:28:24 -04:00
Wilson Snyder 897d5c58b3 Devel version 2012-04-16 20:20:58 -04:00
Wilson Snyder dc9086512b Doxygen logo and commentary 2012-04-16 07:31:27 -04:00
Wilson Snyder 0029d068c7 Version bump 2012-04-15 16:21:31 -04:00
Wilson Snyder de388b3dc8 Part of last commit 2012-04-15 16:14:18 -04:00
Wilson Snyder fb904d53cd Add doxygen comments, bug482 2012-04-15 15:44:32 -04:00
Wilson Snyder 600cc02de3 Commentary 2012-04-15 15:08:13 -04:00
Wilson Snyder 946d0cd219 Add readme.pdf and internal.pdf 2012-04-15 14:51:04 -04:00
Wilson Snyder 4d0b964e36 Internals: Merge from dtype. Create subDTypep. No functional change intended. 2012-04-14 12:43:03 -04:00
Wilson Snyder 2b12ab4d5a Internals: Merge from dtype. Add hasDType; still unused. No functional change. 2012-04-14 11:03:38 -04:00
Wilson Snyder 8114957e6d Internals: Merge from dtype. Rename isSigned to dtypeChgSigned. No functional change. 2012-04-14 10:45:24 -04:00
Wilson Snyder 50edef4ab2 Add Emacs indentation line. No functional change 2012-04-12 21:08:20 -04:00
Wilson Snyder e5a991988f Tests added 2012-04-12 20:13:35 -04:00
Wilson Snyder e85eb6d0f4 Tests: Add t_enum_type_methods, bug473 2012-04-12 18:21:08 -04:00
Wilson Snyder 6949f35f22 Tests: Add t_array_query, t_sv_conditional, bug473 2012-04-12 18:15:39 -04:00
Wilson Snyder e0391b93c4 Commentary 2012-04-12 06:48:02 -04:00
Wilson Snyder 4a5e775a2b Fix change detections on arrays. 2012-04-09 20:17:51 -04:00
Wilson Snyder 323f019350 Tests: Add t_interface, bug481. Merge from JERAS/test_sv. 2012-04-08 18:13:56 -04:00
Wilson Snyder 98053c2d4c Tests: Add t_param_type, bug480. Merge from JERAS/test_sv. 2012-04-08 17:59:46 -04:00
Wilson Snyder aab338760c Increase VL_VALUE_STRING_MAX_WIDTH, bug479 2012-04-05 21:46:55 -04:00
Wilson Snyder ab9a2b1728 Internal: Prevent possible buffer overrun 2012-04-05 21:46:03 -04:00
Wilson Snyder 6a38d3bcf3 Add SELRANGE as warning instead of error, bug477. 2012-04-04 21:55:20 -04:00
Wilson Snyder 76f3cbdf4c Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2012-04-02 22:05:40 -04:00
Wilson Snyder d45d58b6bf Fix real constant parameter functions, bug475. 2012-04-02 21:58:40 -04:00
Wilson Snyder f32a422330 Tests: New test 2012-04-02 19:38:42 -04:00
Wilson Snyder 74d4be28dd Commentary 2012-04-02 07:17:37 -04:00
Wilson Snyder b4a31bd292 Internals: Merge AstCCast minwidth set. No functional change intended 2012-04-01 21:17:58 -04:00
Wilson Snyder cc1adf9b38 Internals: merge V3Hashed cleanups. No functional change intended 2012-04-01 21:04:28 -04:00
Wilson Snyder 1601b3b6b0 Internals: Merge VFlagChildDtype calls. No functional change intended. 2012-03-31 11:22:19 -04:00
Wilson Snyder 61cbdd1a19 Internals: Merge VFlag rename. No functional change. 2012-03-31 11:10:34 -04:00
Wilson Snyder a3ee6131a3 Internals: Merge using dtypeSetLogicSized. No functional change intended 2012-03-31 10:53:53 -04:00
Wilson Snyder 6dfddaa453 Internals: Rename dtypeChg to dtypeSet. No functional change 2012-03-31 10:19:27 -04:00
Wilson Snyder de696b7092 Debug: Print dtype big endian correctly 2012-03-30 21:50:37 -04:00
Wilson Snyder 9165233657 Fix OpenSolaris compile error. 2012-03-30 07:26:00 -04:00
Wilson Snyder aa3a417e97 Tests: Add t_dpi_accessors 2012-03-27 20:06:59 -04:00
Wilson Snyder 996f48fcf0 Fix processing unused parametrized modules, bug470. 2012-03-24 15:54:06 -04:00
Wilson Snyder 81d83f629f Tests: default_nettype is ok 2012-03-24 15:15:32 -04:00
Wilson Snyder 5e3b0bf348 tests: Add unsupported as target type; additional tests 2012-03-24 11:10:17 -04:00
Wilson Snyder 4a31463299 Fix genvar and begin under generate, bug461. 2012-03-23 08:49:47 -04:00
Wilson Snyder 8a5471e175 Tests: skip test for bug462 2012-03-22 22:35:24 -04:00
Wilson Snyder 605fd9f8e1 Tests: Skip test for bug461 2012-03-22 22:15:35 -04:00
Wilson Snyder 2bda43875d Support += and -= in standard for loops, bug463. 2012-03-22 21:02:38 -04:00
Wilson Snyder 11edc9e7a7 Debug: Add --dump-treei option 2012-03-20 22:45:35 -04:00
Wilson Snyder 3b9b823511 tests: Fix missing manifest from earlier test commit 2012-03-20 22:45:00 -04:00
Wilson Snyder da0ecf59c6 Tests: Rename t_mem_packed_assign_bad since fails 2012-03-20 20:55:16 -04:00
Wilson Snyder e5b1fdf668 Tests: Added additional SystemVerilog tests.
Squashed commit of the following:

commit c1eeda7d472fc14a0ffd5c1712ae7f7c614073a1
Author: Iztok Jeras <[email protected]>
Date:   Tue Mar 20 16:39:44 2012 +0100

- fixed assignment operator in t_array_packed_write_read.v from = to <=
- added tests for enumerations (existing tests do not use methods like
next(), num(), ...)
- added t_sv_bus_mux_demux test, with packed arrays, structures and unions
2012-03-20 19:28:35 -04:00
Wilson Snyder 204fb82975 Add very experimental --xml option 2012-03-20 16:13:10 -04:00
Wilson Snyder 37839e2709 Cleanup trailing whitespace. No functional change 2012-03-20 16:01:53 -04:00
Wilson Snyder dbaedb5995 Internals: Add XML output internals, unused. No functional change. 2012-03-20 15:57:29 -04:00
Wilson Snyder 0a832e90bd Internals: Rename left/right to match IEEE. No functional change. 2012-03-19 21:32:05 -04:00
Wilson Snyder b4e908d04d Fix warning on gcc 4.6.1 2012-03-16 18:06:32 -04:00
Wilson Snyder 4619d29b78 Commentary; bug457 2012-03-15 18:44:08 -04:00
Wilson Snyder c63b697636 Fix signed array warning, bug456. 2012-03-12 20:29:00 -04:00
Wilson Snyder 06d29d6fda Commentary 2012-03-10 10:56:48 -05:00
Wilson Snyder c0f7bc4b5e Tests: Parameter bug case 2012-03-09 19:35:37 -05:00
Wilson Snyder 7139c9ae59 Fix and document --gdb option, bug454. 2012-03-09 18:37:38 -05:00
Wilson Snyder 0ae00fc921 Commentary; bug452. 2012-03-08 18:36:51 -05:00
Wilson Snyder fe456cb83d Devel version 2012-03-07 23:02:24 -05:00
Wilson Snyder a8432ed4a4 Version bump 2012-03-07 22:50:13 -05:00
Wilson Snyder 04f910b747 Fix V3Tristate t_tri_select crash 2012-03-07 22:42:47 -05:00
Wilson Snyder 1c3de70155 Internals: Debug merge. No functional change 2012-03-07 21:48:02 -05:00
Wilson Snyder b73642f8a8 Report ENDLABEL on mismatching end labels, bug450. 2012-03-07 20:14:18 -05:00
Wilson Snyder 479b497528 Tests: Add new tests from Iztok Jeras, bug446, bug450. 2012-03-07 20:00:09 -05:00
Wilson Snyder 31b55d3844 Tests: Fix running different simulators simultaneously 2012-03-06 20:58:23 -05:00
Wilson Snyder dbf4e08d09 Tests 2012-03-06 20:12:47 -05:00
Wilson Snyder 274359e6ee Tests: Bit extraction from non-logic types 2012-03-04 17:17:57 -05:00
Wilson Snyder 8687dcbce1 Internals: Add isRanged, more debug. No functional change. 2012-03-04 16:18:41 -05:00
Wilson Snyder 03dfbdb7b1 Fix inheriting signed type across untyped parameters. 2012-03-03 21:03:34 -05:00
Wilson Snyder 3c8519f245 Fix inheriting real type across untyped parameters. 2012-03-03 16:29:06 -05:00
Wilson Snyder 4d2cc3ebdd Tests: New param value test 2012-03-03 15:44:56 -05:00
Wilson Snyder 6e2758ae26 Internals: Minor refactorings from dtype branch. No functional change. 2012-03-03 12:10:29 -05:00
Wilson Snyder 4637e06ad2 Fix backward widths in function output warning 2012-03-03 12:09:01 -05:00
Wilson Snyder 764399256c Internals: Rename gdb dump utilities, add fileline dump 2012-03-03 11:29:09 -05:00
Wilson Snyder f4ca4edc64 Debug: Add default .gdbinit file 2012-03-02 20:59:47 -05:00
Wilson Snyder 872a1216a7 Internals: Fix enum widthTotalBytes. 2012-03-02 06:58:19 -05:00
Wilson Snyder 8c75674591 Internals: V3Dead: Avoid iterating over vars we can't remove. 2012-02-29 23:05:11 -05:00
Wilson Snyder e6244ca204 Internals: Move dimension accessors from AstVar to AstNodeDType. 2012-02-28 21:33:17 -05:00
Wilson Snyder f540362e36 Fix expansion of back-slashed escaped macros, bug441. 2012-02-25 21:31:36 -05:00
Wilson Snyder 2be6699a6a Internals: Make covergroup parsing closer to normal types 2012-02-23 22:09:51 -05:00
Wilson Snyder 09c10492ab Fix hang on recursive substitution `defines, bug443. 2012-02-23 21:54:37 -05:00
Wilson Snyder c8e4b1fc84 Fix functions inside generate for block. 2012-02-21 22:23:06 -05:00
Wilson Snyder 0de7cece5b Fix hang when functions inside begin block. 2012-02-21 21:25:11 -05:00
Wilson Snyder a3413a6749 Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2012-02-21 08:03:07 -05:00
Wilson Snyder b104ab9491 Internals: AstRefDType points to type _below_ AstTyperef. No functional change 2012-02-21 07:27:17 -05:00
Wilson Snyder 269c5dce60 Internals: Use dtypeChgLogicBool(). No functional change. 2012-02-20 20:51:24 -05:00
Wilson Snyder a39c81c63f Internals: Remove width() on AstCaseItem. No functional change. 2012-02-20 16:48:52 -05:00
Wilson Snyder d699247269 Internals: In AstBasicDType avoid use of Range for constants. No functional change. 2012-02-20 11:48:31 -05:00
Wilson Snyder 7caafb4014 Internals: Use dtype functions; changes to integer to match spec 2012-02-20 09:55:20 -05:00
Wilson Snyder f1546abf09 Fix error when using UDPs without --bbox-unsup 2012-02-20 09:02:59 -05:00
Wilson Snyder 3083562f6f tests: Avoid massive make parallelism. 2012-02-17 21:40:52 -05:00
Wilson Snyder da2ee70462 Makefile: Print build done in right parallel spot 2012-02-16 20:39:13 -05:00
Wilson Snyder 7e9dda3c5e Fix false command not found warning in Makefiles. 2012-02-16 07:17:08 -05:00
Wilson Snyder 0b96f88875 Fix bisonpre documentation 2012-02-12 20:53:43 -05:00
Wilson Snyder f13ffe2098 Internals: Merge from VHDL branch. Minor stuff, no functional change. 2012-02-11 20:40:58 -05:00
Wilson Snyder bca5d26583 Backout ca927fe5; snps isn't supported in DC. 2012-02-10 22:36:19 -05:00
Wilson Snyder 660bc757f1 Tests: Remove debug 2012-02-04 20:00:36 -05:00
Wilson Snyder ca927fe587 Support snps directives 2012-02-02 10:26:45 -05:00
Wilson Snyder 9df8966f4a Support arrayed SystemC I/O pins. 2012-02-01 20:20:43 -05:00
Wilson Snyder 3429f41489 Typo 2012-01-29 18:26:39 -05:00
Wilson Snyder 0c7c4924ee Fix core dump with over 100 deep UNOPTFLAT, bug432. 2012-01-26 20:20:23 -05:00
Wilson Snyder 8f40d6617e For generated variables, opt towards 2-state so zero init 2012-01-26 08:29:55 -05:00
Wilson Snyder af9e85bda1 Fix memory delayed assignments from multiple clock domains. 2012-01-26 08:10:50 -05:00
Wilson Snyder 717f45d117 Devel version 2012-01-25 19:23:58 -05:00
Wilson Snyder 35c53865fb Check c style array 2012-01-25 19:23:41 -05:00
Wilson Snyder a1d1d6d3d4 Version bump 2012-01-20 07:02:39 -05:00
Wilson Snyder d17f812827 Fix BLKSEQ warnings on variables declared inside always. 2012-01-19 21:15:21 -05:00
Wilson Snyder 3916758529 readme.texi is very old 2012-01-19 20:32:32 -05:00
Wilson Snyder 2396181bc5 Add SYSTEMC_INCLUDE and SYSTEMC_LIBDIR 2012-01-19 20:30:41 -05:00
Wilson Snyder 6e8640bf1b SystemC 2.3.0 support 2012-01-19 19:48:37 -05:00
Wilson Snyder c2c7c7bd9a Copyright year update 2012-01-15 10:26:28 -05:00
Wilson Snyder 071a1c4adb Internals: Fix cppcheck warning 2011-12-27 12:15:20 -05:00
Wilson Snyder d5b2dda2e8 Fix loop iterator 2011-12-26 18:32:40 -05:00
Wilson Snyder 2ac281eb3e Commentary 2011-12-23 19:32:56 -05:00
Wilson Snyder 5e81543448 Internals: Use width when widthMin is the same. No functional change intended 2011-12-22 21:10:28 -05:00
Wilson Snyder b32f925468 Internals: remove extra width sets 2011-12-22 19:08:49 -05:00
Wilson Snyder fdeb6bcae0 Internals: Progress towards proper short-circuit evaluation 2011-12-22 08:33:16 -05:00
Wilson Snyder 76232cd9e7 Internals: Separate pure from branching. No functional change. 2011-12-15 22:23:11 -05:00
Wilson Snyder 4da9b5e491 Internals: Rename isSplittable->isPure. No functional change 2011-12-15 19:13:54 -05:00
Wilson Snyder c4504a9221 tests: Fix t_dist_install breaking corunning test 2011-12-15 18:39:51 -05:00
Wilson Snyder 65de8359e7 Internals: Comment out unused code, no funtional change 2011-12-15 18:39:29 -05:00
Wilson Snyder f6fab74436 tests: GHDL test driver support 2011-12-09 19:58:14 -05:00
Wilson Snyder 350ba264e8 Internals: Create bools/doubles with dtypeChg functions. No functional change. 2011-11-30 19:32:33 -05:00
Wilson Snyder 29e24818a1 Internals: Rename and cleanup some width() usages. No functional change. 2011-11-30 18:50:21 -05:00
Wilson Snyder 71cd6f7b90 Spelling fixes 2011-11-30 18:20:19 -05:00
Wilson Snyder 84ba253791 Last commit - don't allow error overrides if not lint 2011-11-30 18:07:11 -05:00
Wilson Snyder fce158b8ad Make DETECTARRAY so can turn off for lint 2011-11-30 16:20:43 -05:00
Wilson Snyder da13ba6c67 Internals: Use elementsConst for AstRange width. 2011-11-30 07:51:05 -05:00
Wilson Snyder 7618133298 Internals: Renames towards common dtype. No functional change. 2011-11-29 22:36:51 -05:00
Wilson Snyder 0d1698f81d Internals: Allow v3Global in V3Ast.h. No functional change. 2011-11-29 22:29:16 -05:00
Wilson Snyder 362d642c87 Support "generate for (genvar i=0; ...". 2011-11-29 18:23:18 -05:00
Wilson Snyder e4c96d5be5 Fix array of instantiations with sub-range output, bug414. 2011-11-28 22:10:43 -05:00
Wilson Snyder f488701adc Fix dpi exports with > 32 bit but < 64 bit args, bug423. 2011-11-28 21:15:57 -05:00
Wilson Snyder 8ff2bf51c5 Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2011-11-28 09:48:14 -05:00
Wilson Snyder a2490a55a9 tests: Test $countones on other simulators 2011-11-28 09:48:01 -05:00
Wilson Snyder 20189f5191 Fix empty generate region, bug422. 2011-11-28 07:49:36 -05:00
Wilson Snyder 06b796c6bd Suppress VARHIDDEN on dpi import arguments. 2011-11-27 12:03:22 -05:00
Wilson Snyder ad4edf6c68 Postrelease 2011-11-27 10:39:30 -05:00
Wilson Snyder 4100f20a69 Version bump 2011-11-27 10:37:23 -05:00
Wilson Snyder bedf946fb2 Support V-AMS wreal 2011-11-27 10:31:06 -05:00
Wilson Snyder b9e67157c6 With "--language VAMS" support a touch of Verilog AMS. 2011-11-25 00:49:38 -05:00
Wilson Snyder b30b2a183b Support . 2011-11-20 02:01:48 -05:00
Wilson Snyder 9ab3bcdde3 Support with %g. 2011-11-20 01:01:02 -05:00
Wilson Snyder 5df3bbe188 Fix $display with %d following %g. 2011-11-20 00:45:59 -05:00
Wilson Snyder 8cf12416c0 Commentary 2011-11-18 13:33:31 -05:00
Wilson Snyder b7c2c83c88 Fix bad result with if-else-return optimization, bug420. 2011-11-12 08:07:30 -05:00
Wilson Snyder 3b6da93331 Reuse goto labels inside functions, bug420a 2011-11-10 19:13:32 -05:00
Wilson Snyder b4642d3fd4 Show examples with timestamps as 64 bits 2011-11-06 11:54:17 -05:00
Wilson Snyder 88a2b0b911 Support constants in sensitivity lists, bug412. 2011-11-02 18:34:17 -04:00
Wilson Snyder 954e127f1d Commentary: Report children node types 2011-11-01 19:33:11 -04:00
Wilson Snyder 7654add5e5 Indicate 'exiting due to errors' if errors, not warnings. 2011-10-31 21:39:15 -04:00
Wilson Snyder 85a37ea53f Search for user -y paths before default current directory. 2011-10-28 18:57:40 -04:00
Wilson Snyder b337acebcc When multiple tops, show example 2011-10-28 18:19:04 -04:00
Wilson Snyder fb9ca54c95 Fix reporting not found modules if generate-off, bug403. 2011-10-27 20:56:38 -04:00
Wilson Snyder 1a15d41523 Support jumps in program modules 2011-10-27 19:13:24 -04:00
Wilson Snyder e378cc5791 Add sc_bv attribute to force bit vectors, bug402. 2011-10-26 08:57:27 -04:00
Wilson Snyder 748c189c79 Devel version 2011-10-25 19:11:45 -04:00
Wilson Snyder b89be6c4b9 Version bump 2011-10-25 18:59:40 -04:00
Wilson Snyder df207807b6 Add ASSIGNIN as suppressable error. 2011-10-25 18:57:49 -04:00
Wilson Snyder 1f2b40cff1 Fix 3.823 constructor core dump on Debian, bug401. 2011-10-25 18:41:04 -04:00
Wilson Snyder 734400fd37 Fix version number mistake 2011-10-25 18:11:06 -04:00
Wilson Snyder f19979d928 Fix "always @ (* )", bug403, bug404. 2011-10-25 18:08:24 -04:00
Wilson Snyder 19be7a53da List unsupported on delays 2011-10-21 07:13:38 -04:00
Wilson Snyder e56af34fb0 Post release 2011-10-20 21:18:16 -04:00
Wilson Snyder 7737aa20e8 Version bump 2011-10-20 21:13:42 -04:00
Wilson Snyder ead046201c Fix make info tex warning 2011-10-20 21:13:33 -04:00
Wilson Snyder 0aa7c3f659 Add -Wall reporting ASSIGNDLY on assignment delays. 2011-10-20 20:50:42 -04:00
Wilson Snyder 4aa7222022 tests: use verilator_flags and skip more widely 2011-10-12 23:03:53 -04:00
Wilson Snyder 86e3c78776 configure: Test for compiler flags, and remove old config checks 2011-10-12 19:04:57 -04:00
Wilson Snyder 40076287ea Internals: In .tree files show filename as letter 2011-10-11 07:17:39 -04:00
Wilson Snyder ca81db8edf Remove dead node types; make report of node usage. No functional change 2011-10-10 18:13:42 -04:00
Wilson Snyder ae68a80e98 Fix fflush 2011-10-10 18:13:17 -04:00
Wilson Snyder beb7c58375 Fix DPI import false BLKSEQ warnings. 2011-10-07 20:04:15 -04:00
Wilson Snyder e080b9d565 Fix DPI import output of 64 bits, bug398. 2011-10-07 19:47:10 -04:00
Wilson Snyder ca2db37039 Fix UNDRIVEN warnings inside DPI import functions. 2011-10-07 08:29:34 -04:00
Wilson Snyder 194825f78e Add configure options for cc warnings and extended tests. 2011-10-07 06:48:40 -04:00
Wilson Snyder 55bd765ea0 Find config_rev when under git in remote config dir 2011-10-05 18:36:44 -04:00
Wilson Snyder b03d61e2cf Use EXEEXT to fix make warning 2011-10-05 17:07:10 -04:00
Wilson Snyder 6fc0e5167b Commentary 2011-10-05 17:06:08 -04:00
Wilson Snyder 0065be011f Fix errors when building from git outside of kit directory 2011-10-05 10:47:05 -04:00
Wilson Snyder 3f7cbce58c Move version to configure.ac 2011-10-05 09:50:14 -04:00
Wilson Snyder 246b62e322 Tests: Add runtime 2011-10-05 09:50:00 -04:00
Wilson Snyder 7c2fdd1ee9 Fix --help output to go to stderr, not stdout, bug397. 2011-10-04 10:08:16 -04:00
Wilson Snyder f77aa2623c Fix autoconf suggestions 2011-10-04 10:07:46 -04:00
Wilson Snyder 20847a3ff5 Fix autoconf warnings, bug396. 2011-10-04 08:48:37 -04:00
Wilson Snyder eb6d42acf9 Support $ceil, $floor, etc. 2011-09-28 21:35:26 -04:00
Wilson Snyder 094d676a8b Fix MSVC compile warning with trunc/round, bug394. 2011-09-21 09:08:05 -04:00
Wilson Snyder 71306ceb1d Devel version 2011-09-14 21:44:54 -04:00
Wilson Snyder 8bbfc7fc22 Version bump 2011-09-14 21:12:40 -04:00
Wilson Snyder 19baba12b1 Commentary 2011-09-14 21:11:14 -04:00
Wilson Snyder 15b8819136 Avoid warning on older flex/gcc systems (lion) 2011-09-12 20:26:34 -04:00
Wilson Snyder 3fae8ade05 Fix PowerPC runtime error, bug288 2011-08-22 21:02:09 -04:00
Wilson Snyder f9bbf31d65 Fix internal error on integer casts, bug374. 2011-08-09 19:56:22 -04:00
Wilson Snyder df1da3dda9 Internals: Fix cppcheck warnings; no functional change intended 2011-08-04 21:58:45 -04:00
Wilson Snyder c83f2a4abd Internals: Fix preincrements to reduce cppcheck warnings 2011-08-04 21:15:24 -04:00
Wilson Snyder ad53833040 Version bump 2011-07-28 19:53:54 -04:00
Wilson Snyder bc8c85668a Support coverage in -cc and -sc output modes. 2011-07-28 19:41:05 -04:00
Wilson Snyder d12a3dde45 Fix cast compile warning 2011-07-28 07:59:30 -04:00
Wilson Snyder 301c878c0f Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2011-07-28 07:56:44 -04:00
Wilson Snyder bd55bfa071 Support more vpi file functions 2011-07-28 07:05:40 -04:00
Wilson Snyder 6d2f09b579 Fix vpi_register_cb using bad s_cb_data, bug370. 2011-07-27 13:03:49 -04:00
Wilson Snyder 4bfea7f54d Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2011-07-26 18:30:25 -04:00
Wilson Snyder 55906486d8 Support 'real' numbers and related functions. 2011-07-24 15:01:51 -04:00
Wilson Snyder d5478e6e08 tests: Print status to stderr 2011-07-24 15:01:36 -04:00
Wilson Snyder d88d85c172 Internals: Real2: Create numeric class; no functional change intended 2011-07-23 19:58:34 -04:00
Wilson Snyder 59c3c536c7 Internals: Real1: properly lex doubles 2011-07-23 08:25:41 -04:00
Wilson Snyder a007458cb8 Internals: Rename float/double to match real branch. No functional change. 2011-07-21 22:10:25 -04:00
Wilson Snyder d051912f21 Internals: Rename functions to match real branch. No functional change. 2011-07-21 21:32:31 -04:00
Wilson Snyder a547158a50 bisonpre: Merge from Verilog-Perl 2011-07-21 20:34:33 -04:00
Wilson Snyder 95f2351aa0 Tests: %t formatting 2011-07-21 19:37:53 -04:00
Wilson Snyder 698aaffb0b Fix missing leading zeros in %0d, bug367 2011-07-14 07:39:11 -04:00
Wilson Snyder 73eccecbf8 Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2011-07-11 08:10:28 -04:00
Wilson Snyder ae4a261463 Internals: Rename UnaryMin to Negate. No functional change. 2011-07-08 06:03:07 -04:00
Wilson Snyder c9f0d0cec2 Recognize pragma synthesys to match vhier 2011-07-07 13:30:27 -04:00
Wilson Snyder 4fa1e45d45 Internals: Move width internals to inside class; move WidthCommit. No functional change 2011-07-06 19:03:40 -04:00
Wilson Snyder 1b3d252bfe Internals: Cleanup Dead code 2011-07-06 18:46:41 -04:00
Wilson Snyder a9ba4a9fcd Internals: Cleanups in V3Signed towards reals; no functional change 2011-07-05 21:05:35 -04:00
Wilson Snyder 7f49619875 Fix VL_FCLOSE declaration, broke two commits ago, bug363 2011-07-05 20:42:33 -04:00
Wilson Snyder 696660639a Support 'const' variables in limited cases; similar to enums. 2011-07-02 12:45:26 -04:00
Wilson Snyder da4323062d Commentary 2011-07-01 15:23:09 -04:00
Wilson Snyder a901e171b2 Support $fopen and I/O with integer instead of `verilator_file_descriptor. 2011-07-01 13:41:21 -04:00
Wilson Snyder 6e41d532fe Use 'vluint64_t' for SystemC instead of (same sized) 'uint64' for MSVC++. 2011-06-29 19:19:01 -04:00
Wilson Snyder 4fc78ffb58 Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2011-06-29 14:22:59 -04:00
Wilson Snyder 8137f41fc3 Support disable for loop escapes. 2011-06-28 21:26:49 -04:00
Wilson Snyder 2e9471797d Version to devel 2011-06-28 21:11:29 -04:00
Wilson Snyder 344248cea0 Version bump 2011-06-28 20:52:04 -04:00
Wilson Snyder 2789e3dba5 Fix 96 bit DPI input/outputs, bug359 2011-06-28 20:45:50 -04:00
Wilson Snyder cca759a41e Tests: Example embedding 2011-05-22 08:43:36 -04:00
Wilson Snyder 4f7b3d8882 Fix out of memory on slice syntax error, bug354. 2011-05-21 08:19:33 -04:00
Wilson Snyder 2b330b78b7 Support bit vectors > 64 bits wide in DPI import and exports. 2011-05-20 21:33:31 -04:00
Wilson Snyder d47ca1912b tests: Fix invocation scripts for new site standard 2011-05-20 20:47:15 -04:00
Wilson Snyder 3fd2108b10 Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2011-05-20 15:34:30 -04:00
Wilson Snyder 96e2a407f4 Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2011-05-20 13:40:18 -04:00
Wilson Snyder cdf18c96f4 driver: Allow getting verilator flags in tests 2011-05-19 21:25:23 -04:00
Wilson Snyder 53acaa05b8 Commentary 2011-05-18 07:10:12 -04:00
Wilson Snyder fb85679068 Fix DPI bit vector compile errors, bug347. 2011-05-12 07:35:28 -04:00
Wilson Snyder 9558e14479 Fix DPI undeclared svBitVecVal compile error, bug346. Additional change. 2011-05-12 06:59:13 -04:00
Wilson Snyder 4af0af93bf Fix DPI undeclared svBitVecVal compile error, bug346. 2011-05-12 06:32:29 -04:00
Wilson Snyder df4bc950fe Cleanup trailing whitespace 2011-05-09 23:58:38 -04:00
Wilson Snyder 250394f72b Fix compiler warnings on SPARC, bug288 2011-05-09 23:49:17 -04:00
Wilson Snyder ca83fd6dc1 CDC: edge report under debug 2011-04-20 10:11:35 -04:00
Wilson Snyder d5e9e7cd2b Remove dead code 2011-04-19 19:02:03 -05:00
Wilson Snyder 9a96f621ef Fix CDCRSTLOGIC report showing endpoint flops without resets. 2011-04-18 10:47:02 -04:00
Wilson Snyder 5d7ce096c6 Fix error on enum references to other packages, bug339. 2011-04-13 19:34:14 -04:00
Wilson Snyder c9f8109c06 Pre-version 2011-04-13 19:33:58 -04:00
Wilson Snyder a20b4f2864 Version bump 2011-04-06 07:33:44 -04:00
Wilson Snyder 44a19d2a0a Fix missing test files 2011-04-06 07:33:32 -04:00
Wilson Snyder 02f3beb8db Add V3Number rotate functions; unused as yet 2011-03-30 21:31:29 -04:00
Wilson Snyder 3269cc3d90 Add +libext+.sv default 2011-03-30 21:30:36 -04:00
Wilson Snyder fb70a1f4ab Add --Wno-fatal to turn off abort on warnings. 2011-03-22 18:09:39 -04:00
Wilson Snyder df0aa483ce Support ${...} and $(...) env variables in .vc files 2011-03-21 12:25:31 -04:00
Wilson Snyder c83f12a55c Support simple cast operators, bug335. 2011-03-17 22:25:49 -04:00
Wilson Snyder 9704f59566 Internals: Rename AstCast to AstCCast 2011-03-17 21:09:52 -04:00
Wilson Snyder 2923893d34 Support loop unrolling on width mismatches, bug 333 2011-03-12 07:45:04 -05:00
Wilson Snyder 890dab0742 Write logfile on each failure 2011-03-12 07:44:29 -05:00
Wilson Snyder 607e26b041 Commentary 2011-03-08 06:49:45 -05:00
Wilson Snyder ea75290f65 Add error on circular parameter definitions, bug329 2011-03-07 20:44:19 -05:00
Wilson Snyder a176054118 Add --trace-max-width and --trace-max-array, bug 319. 2011-02-23 21:58:27 -05:00
Wilson Snyder 9a697dc5f5 Accelerate bit-selected inversions. 2011-02-23 21:36:38 -05:00
Wilson Snyder cfdb852843 Fix concatenates and vectored bufif1, bug326. 2011-02-23 21:21:59 -05:00
Wilson Snyder 2e67a91982 Support $bits(data_type), bug327. 2011-02-23 19:04:15 -05:00
Wilson Snyder 074ca9330d Make width violation on function outputs a fatal error 2011-02-18 20:52:26 -05:00
Wilson Snyder f0d7cdcb20 Commentary 2011-02-18 07:11:03 -05:00
Wilson Snyder 40d961e059 Version bump 2011-02-14 19:05:55 -05:00
Wilson Snyder e5de759236 Report error on function call output tied to constant.
Fix internal error on functions called as SV tasks.
2011-02-14 19:25:30 -05:00
Wilson Snyder e26a75c59d Fix internal error on non-inlined inout pins. 2011-02-07 19:15:58 -05:00
Wilson Snyder 8701145b40 Fix error on constants connected to outputs, bug323. 2011-01-31 07:05:04 -05:00
Wilson Snyder a2558886c8 Report errors on empty pins, bug321 2011-01-29 18:00:48 -05:00
Wilson Snyder f818ee86ae Report errors on duplicated pins, bug321. 2011-01-29 17:01:06 -05:00
Wilson Snyder ad0dbdaa9c CDC: Print nice net names instead of ___5f 2011-01-19 11:44:23 -05:00
Wilson Snyder a9f14b294f Internals: Cdc notes; marking submodules won't work 2011-01-18 21:37:53 -05:00
Wilson Snyder a435ae98f9 Throw UNUSED/UNDRIVEN only once per net in a parametrized module. 2011-01-18 21:28:51 -05:00
Wilson Snyder 481b261458 Internals: add a few userIncs, No functional change 2011-01-18 21:19:12 -05:00
Wilson Snyder 48df52d743 Reduce use of CRELINE so line numbers more closely match first parsed location 2011-01-18 21:12:31 -05:00
Wilson Snyder 0af0d3b171 Cleanup CDC reports, remove TOP-> signal prefixes 2011-01-17 14:58:58 -05:00
Wilson Snyder 8287cf35e7 Fix warnings to point to lowest net usage, not upper level ports. 2011-01-17 14:10:01 -05:00
Wilson Snyder fab7924cc2 Fix block comment not separating identifiers, bug311. 2011-01-11 18:46:21 -05:00
Wilson Snyder 0ab739e8b1 Fix false BLKSEQ on non-unrolled for loop indexes. 2011-01-06 06:46:19 -05:00
Wilson Snyder 2dcd4d171b Version bump 2011-01-03 13:32:16 -05:00
Wilson Snyder e7f4d18c3d First test is verilator -V 2011-01-03 13:30:33 -05:00
Wilson Snyder 1611362c22 Add --unused-regexp 2011-01-01 19:43:22 -05:00
Wilson Snyder 2327698160 driver: Allow --site specific tests 2011-01-01 19:18:32 -05:00
Wilson Snyder 71c1f00ec2 Copyright year update 2011-01-01 18:21:19 -05:00
Wilson Snyder 6574a126ef spdiff: Ignore copyright differences 2011-01-01 18:20:30 -05:00
Wilson Snyder 1e68086355 Fix defparam test failing after make clean 2011-01-01 18:12:29 -05:00
Wilson Snyder 326cc8fd67 Fix DLYSYNC with for loop variables 2010-12-31 20:18:21 -05:00
Wilson Snyder 4afcb421bd With --Wall, add BLKSEQ warning on blocking assignments in seq blocks. 2010-12-31 18:36:29 -05:00
Wilson Snyder 8d21917035 Add SYNCASYNCNET 2010-12-31 07:51:14 -05:00
Wilson Snyder 4ca7f8834c Fix test ignores 2010-12-30 21:20:58 -05:00
Wilson Snyder b43299c8da Fix suppression of messages under debug 2010-12-30 08:41:23 -05:00
Wilson Snyder b763809f5e Fix last commit; allow multiple exprs 2010-12-30 08:26:36 -05:00
Wilson Snyder 2cb97f7475 For UNUSED, ignore black boxed sys calls 2010-12-30 07:55:31 -05:00
Wilson Snyder 6283df7491 Vlt lint off now has optional msgname 2010-12-30 06:58:02 -05:00
Wilson Snyder acc4490370 For UNUSED, skip primitive tables 2010-12-29 20:24:31 -05:00
Wilson Snyder f85c1a995a For UNUSED, better by-bit warnings 2010-12-29 19:59:07 -05:00
Wilson Snyder 809e5fda8a Ignore DECLFILENAME on library files 2010-12-29 19:34:33 -05:00
Wilson Snyder dce245da5a Allow wildcards in vlt config files 2010-12-29 19:14:49 -05:00
Wilson Snyder d261c4cd27 For UNUSED warning, ignore genvars 2010-12-29 18:10:02 -05:00
Wilson Snyder c33299d542 Add UNUSED and UNDRIVEN warnings 2010-12-29 08:06:05 -05:00
Wilson Snyder ebdf8a5f3c Internals: Constify tristates with ConstLive, unused so no functional change 2010-12-29 07:56:22 -05:00
Wilson Snyder c8852d183f Internals: Add V3Const preserving liveness, no functional change 2010-12-28 21:23:16 -05:00
Wilson Snyder 9f161b20ef Internals: Avoid passing vars from V3Const visitor; no functional change 2010-12-28 20:46:13 -05:00
Wilson Snyder 40f9d64973 Commentary 2010-12-27 17:25:28 -05:00
Wilson Snyder 4a2e68a0fd Avoid -wall 2010-12-26 15:26:04 -05:00
Wilson Snyder bcd90d3401 Constify LSB subtractions immediately, no functional change intended 2010-12-26 15:20:57 -05:00
Wilson Snyder 114af7d33f Make UNUSED/UNDRIVEN -Wall only 2010-12-26 10:17:35 -05:00
Wilson Snyder 7b83d2de49 Commentary 2010-12-26 09:40:17 -05:00
Wilson Snyder 850de5913d With --Wall, add IFDEPTH warning on deep if statements. 2010-12-26 09:31:09 -05:00
Wilson Snyder bb9ee46f40 Use 'suggest' in INCABSPATH warning 2010-12-26 08:19:45 -05:00
Wilson Snyder e94fc1305b Support unique0; track internally with new attributes 2010-12-26 08:09:25 -05:00
Wilson Snyder 3e4e8feb29 With --Wall, add DECLFILENAME warning on modules not matching filename. 2010-12-25 16:31:22 -05:00
Wilson Snyder fedf347b1a With --Wall, add INCABSPATH warning on `include with absolute paths. 2010-12-25 15:50:07 -05:00
Wilson Snyder 285277a50b Add -Wall; move VARHIDDEN to style warnings 2010-12-25 15:28:13 -05:00
Wilson Snyder 323c96f42f Add -Wwarn-style, -Wno-style, and DEFPARAM warnings 2010-12-25 15:13:56 -05:00
Wilson Snyder 7dee344ea9 Add limited support for VPI access to public signals, see docs. 2010-12-25 14:39:41 -05:00
Wilson Snyder 65bce588e4 Add fatalSrc debug dump check 2010-12-24 13:15:46 -05:00
Wilson Snyder 233ff1b744 --gdbbt now documented, and uses return-child-results
Use this in first test_c to backtrace if any problems.
2010-12-17 20:14:25 -05:00
Wilson Snyder 0837e39787 With -V, print VERILATOR_BIN env var 2010-12-17 19:40:08 -05:00
Wilson Snyder 86db565a21 Fix extra / in binary name 2010-12-14 18:08:41 -05:00
Wilson Snyder d6ac5e5001 Support ++,--,+= etc as standalone statements. 2010-12-07 20:18:47 -05:00
Wilson Snyder e6443f1981 Fix manifest tsub error, broke earlier 2010-12-07 11:45:31 -05:00
Wilson Snyder d13e6c73db When running with VERILATOR_ROOT, optionally find binaries under bin. 2010-12-07 11:43:43 -05:00
Wilson Snyder 79ca7f3cb5 Commentary 2010-12-07 09:30:52 -05:00
Wilson Snyder cfd07ccd34 Suppress WIDTH warnings when adding/subtracting 1'b1. 2010-12-02 14:00:43 -05:00
Wilson Snyder 48047d523a Remove dead code ifdef, bug299 2010-11-03 12:38:26 -04:00
Wilson Snyder eeb8fc2626 Add -F option to read relative option files, bug297. 2010-11-03 07:21:34 -04:00
Wilson Snyder 3d1baf3f2f Version bump 2010-11-02 21:11:02 -04:00
Wilson Snyder 4e382d6765 tests: add --golden flag 2010-11-02 21:10:52 -04:00
Wilson Snyder 582963375d tests: fix pipe bad golden 2010-11-02 21:10:44 -04:00
Wilson Snyder 56c7c1bcc8 Add warning when directory contains spaces, msg378 2010-10-28 09:51:36 -04:00
Wilson Snyder f88e57ddb8 Fix DPI export name not found, msg369. 2010-10-22 13:10:31 -04:00
Wilson Snyder 9d98e012e4 Fix segfault on SystemVerilog "output wire foo=0", bug291. 2010-10-04 07:48:09 -04:00
Wilson Snyder d305a774f0 Fix wrong filename on include file errors, bug289 2010-09-28 09:33:59 -04:00
Wilson Snyder 16b0c8d353 Commentary 2010-09-25 07:59:18 -04:00
Wilson Snyder 55da4fdbf6 Typo fixes. 2010-09-25 07:46:09 -04:00
Wilson Snyder ed2fbd8f25 Version bump 2010-09-20 15:46:17 -04:00
Wilson Snyder 42199bc8e5 Fix preprocessor `` of existing base define, bug283. 2010-09-20 15:20:16 -04:00
Wilson Snyder 7c5318768c Reduce debug verbosity (match Verilog-Perl) 2010-09-20 13:13:31 -04:00
Wilson Snyder aba25aab19 On core dump, print debug suggestions. 2010-09-20 09:21:29 -04:00
Wilson Snyder f99bd33f91 Support tracing/coverage of underscore signals, bug280. 2010-08-29 19:28:46 -04:00
Wilson Snyder a6a6ce83f0 Internals: Use branch prediction in asserts 2010-08-10 11:19:45 -04:00
Wilson Snyder f4908a9758 Increase define recursions before error 2010-08-10 11:18:53 -04:00
Wilson Snyder 5e4ca4b76a Version bump 2010-07-10 18:41:23 -04:00
Wilson Snyder 1e938d0e90 Update preprocessor to match next Verilog-Perl version.
Fix preprocessor preservation of newlines across macro substitutions.
Fix preprocessor stringification of nested macros.
Fix preprocessor whitespace on define arguments
2010-07-10 18:30:16 -04:00
Wilson Snyder f3704f4c05 Tests: Rename includes to .vh extensions 2010-07-08 20:51:54 -04:00
Wilson Snyder 8800efe953 Internals: Rename incLineno to match Verilog-Perl, no functional change. 2010-07-08 20:31:41 -04:00
Wilson Snyder a320c4584e Fix do {...} while() not requiring final semicolon. 2010-07-07 19:15:51 -04:00
Wilson Snyder 3841850168 Preproc: fix pass-through of `line enter-exit codes.
Internals: Merge Verilog-Perl preproc changes through d450722.
2010-07-06 20:29:12 -04:00
Wilson Snyder beb3885840 Add t_clk_2in test 2010-06-21 20:40:34 -04:00
Wilson Snyder 06967c0c46 Fix some constant parameter functions causing crash, bug253. 2010-05-25 19:37:45 -04:00
Wilson Snyder 9a382c572c Commentary, bug251 2010-05-02 06:29:02 -04:00
Wilson Snyder 44b6c371db Version bump 2010-05-01 14:18:56 -04:00
Wilson Snyder 00970be996 Fix bit reductions on multi-packed dimensions, bug227/patch0004. 2010-04-22 09:40:53 -04:00
Wilson Snyder aca4ab015f Fix removing if assigned to unused var, bug248. 2010-04-19 19:38:22 -04:00
Wilson Snyder 68b63d5783 Increase unrollStmts, bug247, due to unreleased change. 2010-04-19 13:59:15 -04:00
Wilson Snyder 4b499f2bb1 Commentary, bug246 2010-04-19 09:44:48 -04:00
Wilson Snyder ed17581f92 Fix loop unroller out of memory; change --unroll-stmts. 2010-04-17 08:01:22 -04:00
Wilson Snyder a46c4ec912 Accelerate and reduce memory usage of V3Expand 2010-04-15 21:05:21 -04:00
Wilson Snyder 930cbeec17 Internals: Create user#Inc routines 2010-04-15 20:56:54 -04:00
Wilson Snyder 10689ffaba Fix carrage return purging, broke in pre-release only 2010-04-10 09:11:52 -04:00
Wilson Snyder 29b0ea0af9 Debug: Allow --debugi-V3PreShell to turn on flex debug 2010-04-10 08:20:28 -04:00
Wilson Snyder 57d00946be Fix MSVC compile issues 2010-04-10 06:46:24 -04:00
Wilson Snyder ef51de72c9 Fix word size to match uint64_t on -m64 systems, bug238. 2010-04-09 21:51:15 -04:00
Wilson Snyder c807bf1e0e Internals: Fix useless rule and flex warning 2010-04-09 21:06:16 -04:00
Byron Bradley 2525b3fb05 Fix bit reductions on multi-packed dimensions, bug227
Signed-off-by: Wilson Snyder <[email protected]>
2010-04-09 21:05:46 -04:00
Byron Bradley 9163ce0f6e Internals: modify AstVar::dimensions() to return a pair, bug227
Signed-off-by: Wilson Snyder <[email protected]>
2010-04-09 20:43:25 -04:00
Byron Bradley d776638f53 Internals: Mark packed dimensions in arrays, bug227
Signed-off-by: Wilson Snyder <[email protected]>
2010-04-09 20:40:41 -04:00
Wilson Snyder 83fff41312 Fix installing data files as non-executable, bug168. 2010-04-09 20:21:00 -04:00
Wilson Snyder dd7d9bc95b Fix some spelling mistakes in verilator executable & manpage, bug240 2010-04-09 19:45:46 -04:00
Wilson Snyder f8eabbc100 From Verilog-Perl: Fix parsing single files > 2GB. 2010-04-06 20:20:44 -04:00
Wilson Snyder 7ed18ac62d Internals: Track Verilog-Perl 3.240 parser changes 2010-04-06 18:55:54 -04:00
Wilson Snyder 3ac707c645 Tests: Fix vpi_user addition failure 2010-04-06 18:43:24 -04:00
Wilson Snyder 8e9a1e0bf3 Add standard vpi_user.h file 2010-04-05 20:08:13 -04:00
Wilson Snyder bc31b5d27a Commentary 2010-04-05 20:08:07 -04:00
Wilson Snyder 936738b750 Add /*verilator public_flat_rw*/ for timing-specific public access. 2010-04-05 20:01:17 -04:00
Wilson Snyder 7c3048ab9c Report errors when extra underscores used in meta-comments. 2010-03-24 22:08:59 -04:00
Wilson Snyder 64719f3ace Makefile: Add local install-cadtools rule 2010-03-24 16:09:29 -04:00
Wilson Snyder a11a5f04d5 Default Verilated::debug() to off 2010-03-23 20:31:22 -04:00
Wilson Snyder eb5c035dde Internals: Fix some missing branch prediction 2010-03-22 19:07:03 -04:00
Wilson Snyder c3887efbf3 Internals: Remove dead code 2010-03-22 19:06:30 -04:00
Wilson Snyder 495585830d Fix trace files with empty modules crashing some viewers. 2010-03-22 18:38:24 -04:00
Wilson Snyder 6715cb9880 Improve error handling on slices of arrays, bug226. 2010-03-20 21:29:16 -04:00
Wilson Snyder 41b167d23c Fix DPI display bogus error 2010-03-20 07:13:52 -04:00
Wilson Snyder 7ea8b54210 Tests: Support atsim and cleanup verilator-only tests 2010-03-18 12:03:08 -04:00
Wilson Snyder bcea39a858 Fix "make install" with configure outside srcdir. 2010-03-17 20:20:40 -04:00
Wilson Snyder fb560abac4 Commentary 2010-03-17 19:57:38 -04:00
Wilson Snyder ba93a08b40 Support runtime access to public signal names 2010-03-17 08:22:49 -04:00
Wilson Snyder 2be6b3481c Pre-version 2010-03-17 08:05:07 -04:00
Wilson Snyder 6ef44a6fbb Version bump 2010-03-17 07:59:12 -04:00
Wilson Snyder 2afe40a0b5 verilated: Add debug pointers to scopeDump() 2010-03-16 19:28:29 -04:00
Wilson Snyder e57d004718 Fix clock-gates with non-AND complex logic, bug220. 2010-03-16 18:50:26 -04:00
Wilson Snyder d780d0aabb Fix flushing VCD buffers on . 2010-03-12 20:00:08 -05:00
Wilson Snyder 0f9e3f0767 Cleanup flex compiles again - remove yyleng from preproc.cpp 2010-03-05 12:02:56 -05:00
Wilson Snyder 381972c923 Fix Mac OS-X compile issues, bug217. 2010-02-26 19:50:44 -05:00
Wilson Snyder 845d7ad718 Commentary 2010-02-26 18:57:34 -05:00
Wilson Snyder f1b6c0c559 Support "`default_nettype none|wire". 2010-02-23 09:27:16 -05:00
Wilson Snyder e39eddf3fe Fix parametrized defines with empty arguments. 2010-02-21 07:20:39 -05:00
Wilson Snyder 72218fb475 Defines with // comments still need continuation - spec ambiguity 2010-02-18 20:57:46 -05:00
Wilson Snyder 9a3e497c22 Fix specparam defaults 2010-02-18 08:43:16 -05:00
Wilson Snyder 85d510cd48 Fix vl_mc_scan_plusarg returning stack based pointer 2010-02-16 11:54:39 -05:00
Wilson Snyder 786c65ea5f Makefile: reconfigure when src/*.in changes 2010-02-15 07:34:55 -05:00
Wilson Snyder 10e6f61125 Commentary 2010-02-14 19:23:29 -05:00
Wilson Snyder cdd06e7236 Support "break", "continue", "return". 2010-02-14 10:01:21 -05:00
Wilson Snyder 48603c0ee2 Commentary 2010-02-10 08:50:41 -05:00
Wilson Snyder 63f30492be Skip SystemC tests if not installed. 2010-02-08 20:51:43 -05:00
Wilson Snyder 0e8772290d Fix make uninstall, bug216 2010-02-08 09:28:40 -05:00
Wilson Snyder 6cfc5798b0 Tests: Move sc_main.cpp as there's more sc than sp users 2010-02-08 08:10:07 -05:00
Wilson Snyder 6be275f5d4 Post release version bump 2010-02-08 06:27:07 -05:00
Wilson Snyder 716f237c4c Version bump 2010-02-07 07:01:13 -05:00
Wilson Snyder 2a192be4f5 Tests: add skips 2010-02-07 07:00:59 -05:00
Wilson Snyder 2679185a09 Commentary 2010-02-07 06:40:48 -05:00
Wilson Snyder b85e7ab0b1 Commentary 2010-02-06 20:00:13 -05:00
Wilson Snyder 29c9804843 Fix including verilated.h before systemperl 2010-02-04 21:46:48 -05:00
Wilson Snyder 56d8ddbaaf Fix MSVC compile warning 2010-02-04 20:31:13 -05:00
Wilson Snyder 8b324249b1 Fix -mno-cygwin warnings 2010-02-04 08:38:00 -05:00
Wilson Snyder 59cc61529b Fix DPI pointer size warnings under -m32 2010-02-04 08:15:33 -05:00
Wilson Snyder 3912e5ef0b Allow empty top-level module name, to match standalone simulation 2010-02-03 19:19:18 -05:00
Wilson Snyder e40fbf1470 Verilated: Add missing VL_UNLIKELYs 2010-02-03 06:56:20 -05:00
Wilson Snyder 56a03e1a10 Add vl_mc_scan_plusargs 2010-02-03 06:33:00 -05:00
Wilson Snyder 5d5952d354 Allow top name to be '' for invisible shells 2010-02-02 21:09:11 -05:00
Wilson Snyder 53fda88d4c VCD_VERSION is unused 2010-02-01 21:41:47 -05:00
Wilson Snyder c4f306c145 Create vltstd to isolate duplicated headers 2010-02-01 21:39:50 -05:00
Wilson Snyder e01d7fcefc Commentary: fewer chapters 2010-02-01 21:35:40 -05:00
Wilson Snyder aec04b07e0 Commentary: sort flags better 2010-02-01 21:12:00 -05:00
Wilson Snyder b1872a8e21 Internals: Add enum prefixes to reduce MSVC macro conflicts 2010-02-01 20:15:48 -05:00
Wilson Snyder 634816d378 V3Delayed warnings now per-scope, bug102 part 2+3 2010-02-01 18:55:32 -05:00
Wilson Snyder 2fd5a6d47f Internals: enum size doesn't apply to non-SystemPerl 2010-02-01 18:37:18 -05:00
Wilson Snyder 8dca56521b Fix MinGW compilation printing %lls, bug214 2010-02-01 09:28:53 -05:00
Wilson Snyder a41aefe77d Fix conditional assignments of slices where conditional is an array, bug215 2010-02-01 06:52:48 -05:00
Wilson Snyder 46dbc7157d Redo MingW ifdefs to also work on generic WIN32, MSVC++ 2010-02-01 06:41:17 -05:00
Wilson Snyder 59261113d8 Internals: Remove one of many ERROR define conflicts 2010-02-01 06:40:30 -05:00
Wilson Snyder fc2834cf04 Link: -lfl not needed, upsets cygwin 2010-02-01 06:37:39 -05:00
Wilson Snyder a15633053b Fix recent verilated.mk.in changes lost by editing non .in 2010-01-30 10:05:21 -05:00
Wilson Snyder 60a06eef19 Internals: Merge getopt top & bottom, no functional change 2010-01-30 09:43:45 -05:00
Wilson Snyder 7fd6ddc25b Add -o option to specify executable name 2010-01-30 09:42:44 -05:00
Wilson Snyder c49e0ac5c8 Add -CFLAGS, -LDFLAGS, <file>.a, <file>.o, and <file>.so options. 2010-01-28 19:33:02 -05:00
Wilson Snyder a51e95d052 Tests: Better example, test for null file in vcd open 2010-01-28 18:16:59 -05:00
Wilson Snyder 4df9d70e4a Support 1800-2009 /*comments*/ in define values. Match Verilog-Perl 2010-01-28 09:41:24 -05:00
Wilson Snyder 78d490d5e4 Preproc: Strip all CRs up front 2010-01-28 09:31:29 -05:00
Wilson Snyder 2f6002b197 Tests: Add t_math_msvc_64, from bug214 2010-01-27 23:51:11 -05:00
Wilson Snyder abcb95b8a1 Fix order of packed arrays, bug216 2010-01-26 08:06:39 -05:00
Wilson Snyder bf435cae7c Fix tracing issues and commentary 2010-01-25 09:48:35 -05:00
Wilson Snyder 4b38acd540 Fix 2D wire decls, bug206 2010-01-25 07:52:07 -05:00
Wilson Snyder f71749c3c4 Fix some MSVC++ warnings 2010-01-24 20:53:24 -05:00
Wilson Snyder cbc90e7ffb Tests: Less verbosity 2010-01-24 20:49:36 -05:00
Wilson Snyder 62866dc8be Repair includes that should be C++ instead of C flavor 2010-01-24 19:00:34 -05:00
Wilson Snyder 11e702c430 SystemPerl is no longer required for tracing.
Applications must use VerilatedVcdC class in place of SpTraceVcdC.
2010-01-24 18:37:01 -05:00
Wilson Snyder 3e6e6ec0a5 Remove duplicate error prefixes 2010-01-24 18:17:27 -05:00
Wilson Snyder 898c08c8e0 Rename new include/verilated files for readability 2010-01-24 08:38:17 -05:00
Wilson Snyder 88fba101a3 Fix _change_request data type to save instruction 2010-01-24 07:58:28 -05:00
Wilson Snyder b0f431e1a2 Fix MSVC++ 2008 compile issues, bug209. 2010-01-24 07:52:43 -05:00
Wilson Snyder 42a7aca504 Tests: fix dpi_export with other simulators 2010-01-22 22:49:52 -05:00
Wilson Snyder c017f2e7c4 Commentary 2010-01-22 19:14:32 -05:00
Wilson Snyder d17bcd8afe Allow 'global' reserved identifier in 1800-2009 when possible 2010-01-22 19:08:20 -05:00
Wilson Snyder 874673f64f Don't override CXX, bug212 2010-01-22 07:33:03 -05:00
Wilson Snyder e052d73321 Update svdpi.h to 1800-2009 2010-01-21 22:17:43 -05:00
Wilson Snyder 58efab5cdf Add SystemVerilog 1800-2009 keywords 2010-01-21 21:58:45 -05:00
Wilson Snyder 4360fe492e Fix initial values for local variables, bug210 2010-01-21 20:08:45 -05:00
Wilson Snyder 295faf726b Fix wrong error point, bug210 2010-01-21 18:22:08 -05:00
Wilson Snyder 2da9d46ca6 Internals: Rename AstVar::initp to valuep as it's a constant, not initial value 2010-01-21 18:20:47 -05:00
Wilson Snyder e4f1e5f4c3 Internals: Rename AstType enum to fix Cygwin define conflict 2010-01-21 18:04:36 -05:00
Wilson Snyder c695af31b8 Add experimental config files to filter warnings outside of the source. 2010-01-21 06:11:30 -05:00
Wilson Snyder 24753c8c6a Tests: Add t_var_rsvd_port test 2010-01-20 18:29:58 -05:00
Wilson Snyder 6196cf09ff Add experimental --pipe-filter to filter all Verilog input. 2010-01-20 07:15:51 -05:00
Wilson Snyder 28eb5b9bc4 Internals: Eliminate extra constructor call in FileLine warn off, and commentary. 2010-01-19 21:30:12 -05:00
Wilson Snyder bb20331f9e Fix signals in a concatenation on the LHS aren't created implicitly, bug206 2010-01-19 19:35:05 -05:00
Wilson Snyder d2bce042a5 Fix for variable typing, bug205. 2010-01-19 19:27:36 -05:00
Wilson Snyder 5d57263a15 Internals: remove cfilename, no functional change 2010-01-19 18:59:45 -05:00
Wilson Snyder bded8755a1 Support multi-dimensional arrays as inputs/outputs 2010-01-19 13:18:40 -05:00
Wilson Snyder 2e9ade61b2 Fix leak in setenvStr, bug184 2010-01-19 12:55:34 -05:00
Wilson Snyder 89e03a86b7 Support assignments of multidimensional slices, bug170 2010-01-19 10:52:11 -05:00
Wilson Snyder 48e88e4e74 Fix unused var compiler warning 2010-01-19 10:29:13 -05:00
Wilson Snyder d182ecb2d3 Support spaces in verilator flags 2010-01-18 20:37:20 -05:00
Wilson Snyder 27e4503dc6 DPI: Constify new $sformatf 2010-01-17 20:06:08 -05:00
Wilson Snyder 72b596efb3 DPI $display like sformat metacomment and $sformatf 2010-01-17 19:13:44 -05:00
Wilson Snyder 0d1de96dbc Internals: Add AstSFormatF 2010-01-17 15:53:12 -05:00
Wilson Snyder 788f69a8c9 DPI: Support strings in DPI Imports 2010-01-17 15:10:37 -05:00
Wilson Snyder 08b63b4f01 Tests: Add --gdbbt, and abort on V3ERROR_NA in V3Ast 2010-01-17 14:48:39 -05:00
Wilson Snyder ba07dc1804 Internals: Use D for double; fix t_dist_uint 2010-01-16 20:30:29 -05:00
Wilson Snyder d46074e0ad CDC: --cdc now implies early exit, to allow eventual set_logic_0/1 on sigs 2010-01-16 20:14:52 -05:00
Wilson Snyder d651063749 Fix Cygwin 1.7.x compiler error with uint32_t, bug204. 2010-01-16 11:53:08 -05:00
Wilson Snyder f60f8396bb Use vluint32_t where possible, aid bug204 2010-01-15 20:27:01 -05:00
Wilson Snyder 919fdd70b8 CDC: Fix compile warning 2010-01-15 20:16:48 -05:00
Wilson Snyder ab2702070b Remove extra warning newlines 2010-01-15 20:07:16 -05:00
Wilson Snyder 057e1a1aff CDC: Don't report paths to just clocks; resorting senitems in earlier commit messed us up 2010-01-15 15:57:48 -05:00
Wilson Snyder a2af4e1284 CDC: Repress duplicate paths through same signal 2010-01-15 14:04:15 -05:00
Wilson Snyder 97adede70b CDC: Fix columns mis-aligning when large filename paths 2010-01-15 09:30:20 -05:00
Wilson Snyder b6447a9032 Internal cleanup: Prep for strings 2010-01-15 08:20:25 -05:00
Wilson Snyder e40b5819bd Speed compiles by avoiding including the STL iostream header. 2010-01-14 21:03:06 -05:00
Wilson Snyder 16926edf18 Define VERILATOR in addition to verilator 2010-01-14 19:24:48 -05:00
Wilson Snyder 8203c79f76 /sformat should accept rvalue expressions 2010-01-14 19:07:18 -05:00
Wilson Snyder 43e1b27d16 CDC: 'posedge a or posedge b or edge a' should optimize to 'edge a or posedge b' 2010-01-14 14:17:11 -05:00
Wilson Snyder d1cb3b0d15 Fix duplicate implicit variables under generates, bug201 2010-01-11 12:36:12 -05:00
Wilson Snyder 266b3b8678 Tests: Move old-style test_v's t_arith, etc to test_regress area 2010-01-09 21:19:30 -05:00
Wilson Snyder a2629c4929 Internals: Avoid some extra CRELINES 2010-01-09 15:44:06 -05:00
Wilson Snyder c1fc629c54 Fix lint_off/lint_on pairs on same line as warning 2010-01-09 12:33:01 -05:00
Wilson Snyder 0d12fe43a0 Internals: Move CASEX warning with other case lints; add test 2010-01-09 11:09:14 -05:00
Wilson Snyder 6aec0ce702 --cdc: Report in more typical source to dest order 2010-01-09 09:05:00 -05:00
Wilson Snyder 32c30c34e9 --cdc: Code rearrangement 2010-01-08 21:31:52 -05:00
Wilson Snyder 6b7b2612a9 Fix segfault with -Wno-MODDUP 2010-01-08 14:03:00 -05:00
Wilson Snyder 0b9c6ed178 --cdc: Show duplicated varscopes 2010-01-08 13:29:00 -05:00
Wilson Snyder d903855aa3 Speed up CDC reset on large netlists; userClearVertices too slow 2010-01-08 11:12:16 -05:00
Wilson Snyder 89234bcd42 V3Name: Fix O(n^2) recursion with deep modules 2010-01-08 10:46:12 -05:00
Wilson Snyder 85ba590fa9 Avoid tail recursion, as with -O0 compiler doesn't do it and stack overflows 2010-01-08 10:27:02 -05:00
Wilson Snyder 2950f77dbc Ignore gate delays in UDP cells 2010-01-07 22:44:30 -05:00
Wilson Snyder a94f5ba200 --bbox-unsup now ignores cmos and tran gate primitives 2010-01-07 22:08:48 -05:00
Wilson Snyder 0c4e40102f Make duplicate modules a MODDUP error that can be disabled 2010-01-07 20:25:54 -05:00
Wilson Snyder 27e8126b18 Cdc commentary 2010-01-07 18:51:52 -05:00
Wilson Snyder bf860b21d7 Clock domain crossing checks 2010-01-07 16:41:19 -05:00
Wilson Snyder a03a540156 Internals: Split V3OutFile into separate formatter 2010-01-07 10:50:23 -05:00
Wilson Snyder eb63c8dcb8 Fix multiple declarations on one enum, bug199 2010-01-06 19:04:20 -05:00
Wilson Snyder cdcb94751e Fix with no parenthesis 2010-01-06 14:21:34 -05:00
Wilson Snyder cd5d8cceb8 Fix with no parenthesis 2010-01-06 14:13:11 -05:00
Wilson Snyder 8fbc87be46 Support +notimingchecks 2010-01-06 12:38:58 -05:00
Wilson Snyder 06fba42858 Use vlt as abbreviation to avoid confusion with other simulator 2010-01-06 08:54:56 -05:00
Wilson Snyder 0f8a1e3901 Fix enums in port crossings and function arguments 2010-01-05 21:32:13 -05:00
Wilson Snyder 729dfdfed7 Copyright year update 2010-01-05 21:15:06 -05:00
Wilson Snyder 1b8051dfe5 Leak fix 2009-12-30 07:41:21 -05:00
Wilson Snyder be6454193b Internals: Cleanup V3EmitV to allow filename prefixing 2009-12-28 22:19:03 -05:00
Wilson Snyder f3347be629 Support edge, 1800-2009 2009-12-28 19:49:40 -05:00
Wilson Snyder dbce06500d Support enums 2009-12-27 08:29:55 -05:00
Wilson Snyder 7a81dd3378 Fix tracing with --pins-bv 1, bug195 2009-12-25 10:01:55 -05:00
Wilson Snyder 57dd9c9e01 Merge branch 'master' of ssh://git-verilator-wsnyder/git/verilator 2009-12-24 11:43:43 -05:00
Wilson Snyder ef4e52a60e Pedantic no longer disables __LINE__. 2009-12-24 11:40:56 -05:00
Wilson Snyder e7cbefa316 Support 1800-2009 defines with default arguments. 2009-12-24 11:33:39 -05:00
Wilson Snyder b4f805b4e9 Tristate: Fix missing fileline on some errors 2009-12-21 08:54:39 -05:00
Wilson Snyder 9b0d26aedd Support `undefineall 2009-12-20 22:26:48 -05:00
Wilson Snyder f6758c397d Commentary 2009-12-20 09:39:51 -05:00
Wilson Snyder ef3ed6e338 Support DPI exports 2009-12-20 08:27:00 -05:00
Wilson Snyder 45aa8742d8 Internals: Rename implicit_typeE to match Verilog-Perl 2009-12-17 20:58:14 -05:00
Wilson Snyder ebe8f554c6 Fix dpiSetScope to really set the scope. 2009-12-16 21:28:35 -05:00
Wilson Snyder 45b0e63be2 Tests: Allow TEST_VERBOSE in c code 2009-12-16 21:28:09 -05:00
Wilson Snyder 934dc842e0 Add --bbox-unsup option to black-box unsupported UDP tables. 2009-12-16 11:45:28 -05:00
Wilson Snyder deda877355 Allow --lint-only to ignore UDP tables 2009-12-16 11:21:25 -05:00
Wilson Snyder 2dba8404eb Fix implicit nets when created after used 2009-12-16 11:03:07 -05:00
Wilson Snyder f581b4e92c Commentary 2009-12-15 06:54:29 -05:00
Wilson Snyder 02c74b5bee Document OBJCACHE and OBJCACHE_JOBS 2009-12-13 11:46:29 -05:00
Wilson Snyder df69439b9c Fix verilatedimp compile error on RHEL, bug117 2009-12-11 06:59:50 -05:00
Wilson Snyder eb4a686b14 Internals: Move __Dpi.h writing to EmitCSyms to save a visitor pass 2009-12-08 22:12:59 -05:00
Wilson Snyder 3386466e7a DPI svSetScope is speced to return last scope, not new one 2009-12-08 21:35:15 -05:00
Wilson Snyder 6a2aa7e4f0 Fix creating implicit variables for expressions, bug196. 2009-12-08 18:29:24 -05:00
Wilson Snyder 735871d501 Add Verilated::scopesDump(), for debugging. 2009-12-08 06:41:16 -05:00
Wilson Snyder 097f3590ae Add -sv option to match other simulators 2009-12-07 15:30:37 -05:00
Wilson Snyder 17bf13fcb6 Support DPI context imports 2009-12-05 10:38:49 -05:00
Wilson Snyder 2dc7b7ad78 Tests: Use top. instead of TOP. to match other sims 2009-12-05 09:58:09 -05:00
Wilson Snyder a3c1724d17 DPI: Fix imports from unit level 2009-12-04 07:41:18 -05:00
Wilson Snyder 5a9309de78 DPI import: Allow system calls to call imports 2009-12-04 07:05:44 -05:00
Wilson Snyder a40fae04ce Support direct programming interface (DPI) "import". 2009-12-03 06:55:29 -05:00
Wilson Snyder f8cb6979d7 Add Makefile VM_GLOBAL_FAST, listing objects needed to link executables.
Add additional commentary to makefiles and other output files.
2009-12-02 21:15:56 -05:00
Wilson Snyder fc70ae180e Add descriptive headers to output files 2009-12-02 20:09:13 -05:00
Wilson Snyder 66b5fa821c Tests: Add fix-me test 2009-12-02 20:05:12 -05:00
Wilson Snyder 2f2f416bea Fix auto-indentation of AstCStmts - again 2009-12-02 19:32:41 -05:00
Wilson Snyder 1da07a3b86 Fix auto-indentation of AstCStmts 2009-12-01 21:55:56 -05:00
Wilson Snyder ad0fcb745e Internals: Use common function to resolve task pins 2009-11-30 18:36:31 -05:00
Wilson Snyder 5a502d451d Fix running configure outside of kit, and update README, bug193 2009-11-25 17:20:28 -05:00
Wilson Snyder 955824e634 Fix functions arguments without leading input 2009-11-24 22:16:28 -05:00
Wilson Snyder 3b62f3c9c0 Tests: Cleanup some old -v3 flags to be -vl 2009-11-24 21:08:42 -05:00
Wilson Snyder d2a27a84cf Support chandle 2009-11-24 09:11:25 -05:00
Wilson Snyder c7d8eb126f Support and . 2009-11-23 21:24:55 -05:00
Wilson Snyder d608fd77b9 Fix initialization of 2 state vars to zero 2009-11-23 19:08:25 -05:00
Wilson Snyder af5aa38bc3 Fix `define argument mis-replacing system task of same name, bug191. 2009-11-23 14:26:04 -05:00
Wilson Snyder 2f2f367c0b Internals: AstConst named functions when want true/false size 1 2009-11-22 20:05:33 -05:00
Wilson Snyder d7a2362a76 Parse UDP Tables, and report single unsupported error 2009-11-20 19:53:40 -05:00
Wilson Snyder e479c8a553 Support 'primitive', but not yet 'table'. 2009-11-20 08:41:28 -05:00
Wilson Snyder 62f707f501 Support $test$plusargs and $value$plusargs, but see the docs. 2009-11-19 17:04:21 -05:00
Wilson Snyder 19d62b7a68 Support 'time'. 2009-11-19 10:45:59 -05:00
Wilson Snyder 103bda04d9 Tests: Cleanup MANIFEST.SKIP 2009-11-15 09:18:57 -05:00
Wilson Snyder 8e6846d9da Internals: Remove AstVar methods in preference of going via dtype 2009-11-15 08:52:19 -05:00
Wilson Snyder fd38216eda Commentary: Fix SpTraceVcd include, bug185 2009-11-14 08:43:57 -05:00
Wilson Snyder ae27b8944e Tests: Align verilator & other clocks to start at time 10 2009-11-13 19:15:48 -05:00
Wilson Snyder bb6b825836 Tests: Update invoke_ scripts for more recent environment 2009-11-13 18:18:30 -05:00
Wilson Snyder 3fc55bba8e Fix MinGW compilation, bug184. 2009-11-13 11:08:30 -05:00
Wilson Snyder 92819f5082 Fix multi-dimensional arrayed typedefs, bug183. 2009-11-12 20:50:31 -05:00
Wilson Snyder 736b9074c8 Support for loop i++, ++i, i--, --i, bug175. 2009-11-10 16:40:07 -05:00
Wilson Snyder 376147911f Support optional cell parenthesis, bug179 2009-11-10 16:29:58 -05:00
Wilson Snyder 4281690021 Fix t_case_autoflush* mis-sharing directory 2009-11-10 10:54:51 -05:00
Wilson Snyder 65714165f9 Fix t_case_write* mis-sharing variable 2009-11-10 10:51:26 -05:00
Wilson Snyder 82d917c2c5 Fix Verilator core dump on wide integer divides, bug178. 2009-11-10 10:44:50 -05:00
Wilson Snyder 8487d67f00 Internals: Disable debug message when no warnings 2009-11-09 20:38:23 -05:00
Wilson Snyder 67d1dad77c Support declarations in loop initializers, bug172. 2009-11-09 19:09:27 -05:00
Wilson Snyder 3b39c3391d Support "import". 2009-11-09 19:07:59 -05:00
Wilson Snyder 8a55c6fd9f Internals: Fix missing privates; no functional change 2009-11-09 08:20:28 -05:00
Wilson Snyder 68567e763c Support "package" and $unit.
Add VARHIDDEN warning when signal name hides module name.
2009-11-07 21:05:02 -05:00
Wilson Snyder bc2d3a13f4 Internals: Detect user4 misuse 2009-11-07 18:03:23 -05:00
Wilson Snyder e0bca07e06 Internals: Create AstNodeModule in prep for packages 2009-11-07 06:20:20 -05:00
Wilson Snyder 377f194837 Support typedef 2009-11-06 23:16:06 -05:00
Wilson Snyder de9989d5a2 Remove dead code 2009-11-06 18:09:04 -05:00
Wilson Snyder 50db34457c Add t_dist_untracked files to prevent forgetting adds 2009-11-06 17:52:54 -05:00
Wilson Snyder b1ce6bd5cc Support "var" 2009-11-05 19:57:31 -05:00
Wilson Snyder 81915540de Support "reg x [3][2]". 2009-11-05 19:26:44 -05:00
Wilson Snyder 0d65f08b1d Support "program". 2009-11-05 19:09:45 -05:00
Wilson Snyder ffbd1fd474 Support "reg [1:0][1:0][1:0]", bug176. 2009-11-05 09:57:23 -05:00
Wilson Snyder 700c1f836d Internals: Move array definitions to AstArrayDType instead of under AstVars.
Prep work for more complicated data types.
2009-11-04 22:31:53 -05:00
Wilson Snyder db2c6820ee Comment out __VpadToAlign as GCC is doing it well now itself 2009-11-03 21:55:34 -05:00
Wilson Snyder 3236607be4 Convert README to POD format, and add internals.txt readme 2009-11-03 09:22:47 -05:00
Wilson Snyder 3edbeb8902 Internals: Start cleaning up dtype()-> in AstVar 2009-11-03 06:49:45 -05:00
Wilson Snyder f59467b897 Support void functions.
Fix "int" etc added in wrong keyword section in last commit.
2009-11-02 22:50:31 -05:00
Wilson Snyder 6bc81d3d26 Support byte, shortint, int, longint in variables, parameters and functions.
Internals: function/var sizing and signing now comes via dtypep()
Internals: cleanup code that widths parameters (again)
2009-11-02 22:14:11 -05:00
Wilson Snyder 4c26792c9b Internals: Create data types and attach to AstVars, in prep for typedefs.
Added AstNodeDType and AstBasicDType and associated enums.
2009-11-02 08:06:04 -05:00
Wilson Snyder 9a133ced2d Support 'bit' keyword 2009-10-31 15:12:28 -04:00
Wilson Snyder 18bebaf5c3 Internals: Add parse-time symbol table for eventual typedef detection 2009-10-31 10:26:53 -04:00
Wilson Snyder f7efae93d5 Internals: Clean up the main flex/bison files to have some sanity.
(Hopefully) no functional change.
	. V3Parse.h		External consumer interface to V3ParseImp
	. V3ParseImp		Internals to parser, common to across flex & bison
	... V3ParseGrammar	Wrapper that includes V3ParseBison
	..... V3ParseBison	Bison output
	... V3ParseLex		Wrapper that includes lex output
	..... V3Lexer.yy.cpp	Flex output
2009-10-31 10:08:38 -04:00
Wilson Snyder 7b4d2118ea Internals: Realign flex with Verilog-Perl version 2009-10-30 23:17:56 -04:00
Wilson Snyder 26eb7c9375 Remove version (mod) flag from releases 2009-10-26 20:26:28 -04:00
Wilson Snyder e4d5367ead Version bump 2009-10-26 20:19:23 -04:00
Wilson Snyder 47b5157f01 Support division and modulus of > 64 bit vectors. 2009-10-26 20:12:09 -04:00
Wilson Snyder 39444d83c5 Support little endian bit vectors ("reg [0:2] x;"). 2009-10-25 16:53:55 -04:00
Wilson Snyder 350028553b Fix install missing verilatedsc.h 2009-10-23 19:30:44 -04:00
Wilson Snyder 7392add8e0 Add new tests to support for future commit 2009-10-22 22:25:24 -04:00
Wilson Snyder e14695c96e Fix erroring on strings with backslashed newlines, bug168. 2009-10-22 21:46:49 -04:00
Wilson Snyder b4d3806f10 Fix carriage-returns embedded in display formats
Internals: Store all AstDisplay etc strings in un-backslashed raw format.
2009-10-22 21:29:18 -04:00
Wilson Snyder 996afe7d95 Cleanup handling DOS CRs to match preprocessor
Fix missing line number increment for `pragma
2009-10-22 16:51:34 -04:00
Wilson Snyder 905cadc00e License clarification 2009-10-22 15:46:47 -04:00
Wilson Snyder 6634751303 Verilator --version now uses git describe for tag-relative naming 2009-10-21 09:25:52 -04:00
Wilson Snyder 64b57fa907 Internals: Commentary and new select tests for future merge-in. No functional change. 2009-10-15 21:47:15 -04:00
Wilson Snyder dd4059beb8 Internals: Rework V3Param, V3Width and V3Const to return a AstNode* representing
any replacement edit they made to the passed in node.  Assure all callers use it
and/or comment on non-use.  Hopefully no function changed.
2009-10-14 20:13:04 -04:00
Wilson Snyder fe3b54bc2e Have V3Life unlink at end to prevent proposed new-iteration scheme from breaking. 2009-10-14 08:26:30 -04:00
Wilson Snyder 1b5e1943f5 Part of earlier commit; Fix execute permission 2009-10-12 20:53:21 -04:00
Wilson Snyder b1e6fe7139 Fix core dump with SystemVerilog var declarations under unnamed begins. 2009-10-11 20:50:31 -04:00
Wilson Snyder 92718a819c Fix cell port connection to unsized integer causing false width warning. 2009-10-09 22:55:37 -04:00
Wilson Snyder ceb2f6894f Fix writing to out-of-bounds arrays writing element 0. 2009-10-08 20:42:45 -04:00
Wilson Snyder c42612abac Internal: Reconnect complicated pins in V3Tristate before Unknowns. Prep for next change. 2009-10-07 07:54:30 -04:00
Wilson Snyder 7069d7d802 Internals: Remove AstAssignW::allowImplicit - dead code 2009-10-06 21:58:00 -04:00
Wilson Snyder 9aaa6d5df1 Move V3Unknown to after variable names have been begin'ed; in prep for future change 2009-10-06 21:46:24 -04:00
Wilson Snyder 3eb155cf2a V3Unknown: Don't modify tree if SEL out-of-bounds would be constant. Prep for next change. 2009-10-06 17:19:38 -04:00
Wilson Snyder 7c8d914711 V3Number::setZero can be public. No functional change. 2009-10-05 21:09:26 -04:00
Wilson Snyder 4d1f8bd057 Increase default --unroll-stmts 2009-10-05 07:49:02 -04:00
Wilson Snyder b883ce95b2 Add --gdbbt option 2009-10-04 18:04:37 -04:00
Wilson Snyder 546e7c0c1f Internals: iterateAndNext now requires backp to exist, for forward compatibility 2009-10-04 17:01:35 -04:00
Wilson Snyder 4f2dc0ecff Internals: Route abort() through vlabort(). No functional change 2009-10-04 17:01:28 -04:00
Wilson Snyder 03c5d06107 Visitors that just accept netlists should say so. No functional change 2009-10-01 22:33:11 -04:00
Wilson Snyder 9499047f8e Driver.pl support for iv 2009-10-01 22:32:40 -04:00
Wilson Snyder db5674cb08 Fix VCD files showing internal flattened hierarchy, broke in 3.714. 2009-09-26 09:31:50 -04:00
Wilson Snyder 66d000f4ba Repair new AstConst::Unsigned32 constructor 2009-09-26 06:43:06 -04:00
Wilson Snyder 2c3c990019 Move swap to V3Ast, and tell which AstUser*InUse fails assertions 2009-09-23 23:10:46 -04:00
Wilson Snyder 807aecdb11 Use parallel top level make 2009-09-23 23:10:09 -04:00
Wilson Snyder ea1b705c1c Move test_v submodule into t_case_orig. No functional change 2009-09-23 21:04:12 -04:00
Wilson Snyder cb8b0d3597 No need for V3Signed to recurse into generate if. 2009-09-22 18:58:59 -04:00
Wilson Snyder 7a86514505 Rename opRange->opSel to match AstRange. No functional change. 2009-09-20 09:30:39 -04:00
Wilson Snyder 3a0babb47d Version bump 2009-09-18 22:37:53 -04:00
Wilson Snyder b085b34a69 Commentary 2009-09-18 22:35:46 -04:00
Wilson Snyder abc738b6f1 Fix deep defines causing flex scanner overflows. 2009-09-17 22:23:18 -04:00
Wilson Snyder d37cc5a160 Fix preprocessing commas in deep parameterized macros. 2009-09-17 22:00:17 -04:00
Wilson Snyder 1a0de753e9 Don't require SYSTEMPERL_INCLUDE if SYSTEMPERL/src exists. 2009-09-17 21:31:03 -04:00
Wilson Snyder b798f4fe71 Detect selection index unknown instead of internal erroring 2009-09-16 20:52:52 -04:00
Wilson Snyder 0c0a588b55 Support generate for var++, var--, ++var, --var. 2009-09-16 10:32:14 -04:00
Wilson Snyder faa5ef193b Add --bbox-sys option to blackbox $system calls. 2009-09-16 09:28:09 -04:00
Wilson Snyder 4c7b5005a6 Give fatal instead of coredump 2009-09-15 18:11:56 -04:00
Wilson Snyder 9cf61cef9d Fix --error-limit option being ignored. 2009-09-15 18:11:21 -04:00
Wilson Snyder 28c61b548b Commentary, bug108. 2009-09-14 13:36:15 -04:00
Wilson Snyder 0b24e62d43 Fix $display with uppercase %M. 2009-09-11 19:25:42 -04:00
Wilson Snyder b19dd49fc9 Add test forgot to add earlier 2009-09-07 15:56:20 -04:00
Wilson Snyder 91b1e66933 Fix tracing escaped dotted identifiers. 2009-09-07 15:55:54 -04:00
Wilson Snyder eea2712eac Improved warning when "do" used as identifier. 2009-09-07 15:54:12 -04:00
Wilson Snyder b19a4b6956 Version bump 2009-08-04 15:23:23 -04:00
Wilson Snyder a01c995a53 Fix escaped preprocessor identifiers, bug106. 2009-07-31 12:02:43 -04:00
Wilson Snyder 59b491e3a8 Allow renaming C keywords 2009-07-22 15:21:41 -04:00
Wilson Snyder c44febe85e Remove ; from end of some function definitions. No functional change 2009-07-22 14:38:20 -04:00
Wilson Snyder 15b3c9797b Fix constant functions with and begin/end 2009-07-21 14:31:16 -04:00
Wilson Snyder 584cfa4d4a Tests: Convert t_loop into test_regress format 2009-07-21 10:42:10 -04:00
Wilson Snyder b92f57eacb Support constant function calls for parameters - missed adding tests 2009-07-20 15:08:50 -04:00
Wilson Snyder aeeaaa53d4 Support constant function calls for parameters. 2009-07-17 14:13:11 -04:00
Wilson Snyder a532fce0e4 V3Simulate now knows which node causes non-simulatable errors 2009-07-16 15:30:34 -04:00
Wilson Snyder 510fe8e634 Explicitly size all parameters, even if not used for module cells 2009-07-16 14:49:34 -04:00
Wilson Snyder 556d90a1b4 Remove implicit width 1 var creation. No functional change 2009-07-16 14:06:53 -04:00
Wilson Snyder 4dde1ede0e Support SystemVerilog "logic", bug101. 2009-07-16 09:19:15 -04:00
Wilson Snyder 1c833f8a9a Commentary 2009-07-16 08:59:08 -04:00
Wilson Snyder 6a36bd8514 Add env var test 2009-07-15 10:14:10 -04:00
Wilson Snyder 12cb819adc Split V3Simulate out of V3Table - no functional change 2009-07-14 11:24:21 -04:00
Wilson Snyder 0607edd191 Version bump 2009-07-14 08:42:01 -04:00
Wilson Snyder 96c7abdb39 On WIDTH warnings, show variable name causing error. - Missing files 2009-07-09 21:45:12 -04:00
Wilson Snyder 6835aecdce On WIDTH warnings, show variable name causing error. 2009-07-09 17:39:24 -04:00
Wilson Snyder 8174c1ad02 Patching SystemC is no longer required to trace sc_bvs. 2009-07-07 17:51:00 -04:00
Wilson Snyder 6129452681 Makefile: Rebuild only on git head change, not touching a file 2009-06-30 11:56:00 -04:00
Wilson Snyder be1a3f427e Support zero-width constants in concatenations. 2009-06-30 11:54:07 -04:00
Wilson Snyder 18dc947fa9 Part of last commit 2009-06-30 11:29:58 -04:00
Wilson Snyder 348c43de63 Add verilator --pins-uint8 option to use sc_in<uint8_t/uint16_t>. 2009-06-29 09:21:21 -04:00
Wilson Snyder cd9b15b2a6 Commentary 2009-06-26 06:47:48 -04:00
Wilson Snyder 8b20d777b0 Add verilator -V option, to show verbose version. 2009-06-25 19:53:26 -04:00
Wilson Snyder ec0947ef7e Add BLKLOOPINIT error code, and describe --unroll-count. 2009-06-24 17:24:42 -04:00
Wilson Snyder 02e6005fa9 Version bump 2009-06-23 14:09:38 -04:00
Wilson Snyder a32caac3c1 Fix error on case statement with all duplicate items, bug99. 2009-06-22 18:49:20 -04:00
Wilson Snyder 2aa618ce98 Add 'See the manual' to unsupported+internal errors 2009-06-21 19:37:15 -04:00
Wilson Snyder 96b23f6edd Make old site-specific configuration more generic,
set DIRPROJECT_PERL_BOOT to a script for bin/verilator to call to do setup.
2009-06-21 13:17:12 -04:00
Wilson Snyder 02d162858f Fix compiler errors under Fedora release candidate 11. 2009-06-12 09:56:46 -04:00
Wilson Snyder 82844a5591 Driver: Fix preproc running in parallel random fails 2009-06-12 09:50:27 -04:00
Wilson Snyder 46fb5a852f Test Driver: Detect missing system perl 2009-06-12 09:08:46 -04:00
Wilson Snyder 10a3aa18bc Fix compile warning on gcc 3.3.5 2009-06-12 08:31:11 -04:00
Wilson Snyder 3c395c26be Support decimal constants of arbitrary widths. 2009-06-12 08:27:48 -04:00
Wilson Snyder ea78520220 Fix tristates causing "Assigned pin is neither..." 2009-06-09 15:37:52 -04:00
Wilson Snyder 92fbec2294 Commentary 2009-06-08 16:38:09 -04:00
Wilson Snyder b9be4ae4e8 Fix segfault on unrolling for's with bad inits, bug90. 2009-06-08 15:59:33 -04:00
Wilson Snyder e9a7f60fa7 Version bump 2009-05-19 07:50:56 -04:00
Wilson Snyder 0a02d1f336 Reconsile with Verilog-Perl r77464 2009-05-19 07:49:19 -04:00
Wilson Snyder 663f3592ba `__FILE__ now expands to a string, per draft SystemVerilog 2010(ish). 2009-05-19 07:15:13 -04:00
Wilson Snyder f9484a894f Reconsile with Verilog-Perl 2009-05-11 20:32:52 -04:00
Wilson Snyder 4e522ab7f5 Fix define formal arguments that contain newlines, bug84. 2009-05-11 11:57:43 -04:00
Wilson Snyder 96d150e92d Verilator_includer is no longer installed twice, bug48. 2009-05-08 15:05:12 -04:00
Wilson Snyder 592b2e76a8 Prepatory code for tracing escaped dots 2009-05-08 14:48:33 -04:00
Wilson Snyder a3e463030d Fix escaped identifiers with '.' causing conflicts, bug83. 2009-05-08 13:16:19 -04:00
Wilson Snyder 4569278c53 Reconsile parser with Verilog-Perl version, to enable more SV features 2009-05-07 18:28:05 -04:00
Wilson Snyder 851b022c7a Change lexer to more closely match Verilog-Perl. Should be no functional change 2009-05-05 13:39:25 -04:00
Wilson Snyder 0985f675e3 Update bisonpre to match Verilog-Perl version 2009-05-04 21:54:44 -04:00
Wilson Snyder 7df730cedd Verilator is now licensed under LGPL v3 and/or Artistic v2.0. 2009-05-04 17:07:57 -04:00
Wilson Snyder 314ffd9353 Version bump 2009-05-02 07:38:24 -04:00
Wilson Snyder 2c953dc37f Fix $clog2 calculation error with powers-of-2, bug81. 2009-05-01 22:18:32 -04:00
Wilson Snyder 9b9e4e5a3f Fix "redefining I" error with complex includes. 2009-04-28 07:19:50 -04:00
Wilson Snyder 50f835c701 Fix segfault with error on bad --top-module, bug79. 2009-04-24 10:32:11 -04:00
Wilson Snyder cbb3351d97 Fix GCC 4.3.2 compile warnings. 2009-04-23 09:16:25 -04:00
Wilson Snyder fb81721e7e Add missing files from last bug 2009-04-23 09:13:55 -04:00
Wilson Snyder 2cedef1333 Avoid config_rev making empty file on errors 2009-04-23 09:11:40 -04:00
Wilson Snyder 4a1697a1b5 Fix GCC format warning 2009-04-08 21:47:48 -04:00
Wilson Snyder 86f08a341c Fix error with tasks that have output first, bug78. 2009-04-08 14:33:12 -04:00
Wilson Snyder 3d85cbe6b5 Fix "cloning" error with -y/--top-module, bug76. 2009-04-07 13:23:25 -04:00
Wilson Snyder 6d3dd98e77 Fix "cloning" error with -y/--top-module, bug76.
Caused by missorting top-module cells; so move code from V3LinkLevel into
V3LinkCells.
2009-04-06 22:26:38 -04:00
Wilson Snyder 9b2004d6b7 Commentary 2009-04-03 17:26:34 -04:00
Wilson Snyder eb072da81c Version bump 2009-03-28 10:30:35 -04:00
Wilson Snyder 38669d0a10 Add SYSTEMPERL_INCLUDE envvar to assist RPM builds. 2009-03-28 10:18:53 -04:00
Wilson Snyder 202a8bc3bb Internals: Use common wrapper for setenv 2009-03-28 09:15:13 -04:00
Wilson Snyder 45e8ed6b49 Internals: Cleanup what symbol lookups need to recurse up vs not. 2009-03-24 09:22:58 -04:00
Wilson Snyder 96692e8a5b Report errors when duplicate labels are used, bug72. 2009-03-23 14:57:15 -04:00
Wilson Snyder ecb08b0cf3 Internals: V3Link uses new common func to make symbol table 2009-03-23 13:52:36 -04:00
Wilson Snyder 71bdfd9710 Fix ASSIGN_SI errors with new --pins-bv 1 option 2009-03-13 22:58:55 -04:00
Wilson Snyder 193dcf38f4 Add --pins-bv option to use sc_bv for all ports. 2009-03-13 14:17:30 -04:00
Wilson Snyder 09091781cf Fix the SC_MODULE name() to not include __PVT__, for nicer coverage. 2009-03-12 14:07:38 -04:00
Wilson Snyder 023519c8f6 Version bump 2009-02-26 07:44:00 -05:00
Wilson Snyder d60d0a60c7 Support repeat and forever statements. 2009-02-25 22:06:59 -05:00
Wilson Snyder 8fe0c3dd84 Commentary in parser to match Verilog-Perl 2009-02-25 17:16:51 -05:00
Wilson Snyder 85419f01a9 Fix left associativity for ?: operators. 2009-02-07 20:54:09 -05:00
Wilson Snyder a199f4a849 Update Bison parser to track Verilog-Perl 3.110. No functional change 2009-01-28 15:27:41 -05:00
Wilson Snyder 290795a76b Commentary 2009-01-28 14:28:55 -05:00
Wilson Snyder c2cf2bc0ba Commentary 2009-01-26 18:36:59 -05:00
Wilson Snyder 2224918730 Fix error messages to consistently go to stderr. 2009-01-26 07:57:59 -05:00
Wilson Snyder c4e69daecd Add IEEE grammar comments; sync with Verilator-Perl parser 2009-01-24 21:36:14 -05:00
Wilson Snyder 9162e68d82 Commentary 2009-01-24 21:35:08 -05:00
Wilson Snyder 08f736ae33 bisonpre: Reconsile Verilog-Perl and Verilator bisonpre 2009-01-24 16:44:03 -05:00
Wilson Snyder 81092edab4 Commentary 2009-01-21 16:59:42 -05:00
Wilson Snyder 21b5a4e9e4 Add --debugi-<srcfile> option. 2009-01-21 16:56:50 -05:00
Wilson Snyder 057928b079 Fix VL_RANDom to better randomize bits. 2009-01-21 13:52:51 -05:00
Wilson Snyder 4beaa45199 Clock_enable is past experimental; bug50. 2009-01-20 07:24:57 -05:00
Wilson Snyder 8f88fa45f1 Make grammer names more closely track IEEE. No functional change. 2009-01-15 13:58:43 -05:00
Wilson Snyder 13e8176884 Fix compile issues with GCC 4.3, bug47. 2009-01-09 11:28:50 -05:00
3373 changed files with 258018 additions and 51395 deletions
+111
View File
@@ -0,0 +1,111 @@
---
Language: Cpp
# BasedOnStyle: LLVM
AccessModifierOffset: -4
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlines: DontAlign
AlignOperands: true
AlignTrailingComments: false
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: true
AllowShortCaseLabelsOnASingleLine: true
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: true
AllowShortLoopsOnASingleLine: true
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: false
BinPackArguments: true
BinPackParameters: true
BraceWrapping:
AfterClass: false
AfterControlStatement: false
AfterEnum: false
AfterFunction: false
AfterNamespace: false
AfterObjCDeclaration: false
AfterStruct: false
AfterUnion: false
AfterExternBlock: false
BeforeCatch: false
BeforeElse: false
IndentBraces: false
SplitEmptyFunction: true
SplitEmptyRecord: true
SplitEmptyNamespace: true
BreakBeforeBinaryOperators: All
BreakBeforeBraces: Attach
BreakBeforeInheritanceComma: false
BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
BreakConstructorInitializers: BeforeComma
BreakAfterJavaFieldAnnotations: false
BreakStringLiterals: true
ColumnLimit: 99
CommentPragmas: '^ IWYU pragma:'
CompactNamespaces: false
ConstructorInitializerAllOnOneLineOrOnePerLine: false
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerAlignment: false
DisableFormat: false
ExperimentalAutoDetectBinPacking: false
FixNamespaceComments: true
ForEachMacros:
- foreach
- Q_FOREACH
- BOOST_FOREACH
IncludeBlocks: Preserve
IncludeCategories:
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
Priority: 2
- Regex: '^(<|"(gtest|gmock|isl|json)/)'
Priority: 3
- Regex: '.*'
Priority: 1
IncludeIsMainRegex: '(Test)?$'
IndentCaseLabels: false
IndentPPDirectives: None
IndentWidth: 4
IndentWrappedFunctionNames: false
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: true
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 1
NamespaceIndentation: None
ObjCBlockIndentWidth: 2
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PenaltyBreakAssignment: 2
PenaltyBreakBeforeFirstCallParameter: 19
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 60
PointerAlignment: Left
ReflowComments: true
SortIncludes: false
SortUsingDeclarations: true
SpaceAfterCStyleCast: false
SpaceAfterTemplateKeyword: true
SpaceBeforeAssignmentOperators: true
SpaceBeforeParens: ControlStatements
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 2
SpacesInAngles: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
SpacesInSquareBrackets: false
Standard: Cpp03
TabWidth: 8
UseTab: Never
...
+9
View File
@@ -0,0 +1,9 @@
Checks: 'clang-diagnostic-*,clang-analyzer-*,*,-modernize*,-hicpp*,-android-cloexec-fopen,-cert-dcl50-cpp,-cert-env33-c,-cert-err34-c,-cert-err58-cpp,-clang-analyzer-core.UndefinedBinaryOperatorResult,-clang-analyzer-security*,-cppcoreguidelines-no-malloc,-cppcoreguidelines-owning-memory,-cppcoreguidelines-pro-bounds-array-to-pointer-decay,-cppcoreguidelines-pro-bounds-array-to-pointer-decay,-cppcoreguidelines-pro-bounds-constant-array-index,-cppcoreguidelines-pro-bounds-pointer-arithmetic,-cppcoreguidelines-pro-type-const-cast,-cppcoreguidelines-pro-type-reinterpret-cast,-cppcoreguidelines-pro-type-static-cast-downcast,-cppcoreguidelines-pro-type-union-access,-cppcoreguidelines-pro-type-vararg,-cppcoreguidelines-special-member-functions,-fuchsia-default-arguments,-fuchsia-overloaded-operator,-google-default-arguments,-google-readability-todo,-google-runtime-references,-llvm-header-guard,-llvm-include-order,-misc-string-integer-assignment,-misc-string-literal-with-embedded-nul,-readability-braces-around-statements,-readability-container-size-empty,-readability-delete-null-pointer,-readability-else-after-return,-readability-implicit-bool-conversion,-readability-named-parameter,-readability-static-accessed-through-instance'
WarningsAsErrors: ''
HeaderFilterRegex: ''
FormatStyle: none
CheckOptions:
- key: google-readability-braces-around-statements.ShortStatementLines
value: '2'
- key: google-readability-namespace-comments.SpacesBeforeComments
value: '2'
+6
View File
@@ -0,0 +1,6 @@
---
exclude_paths:
- '.github/**'
- 'ci/build_verilator.sh'
- 'include/vltstd/**'
- 'nodist/fastcov.py'
+4
View File
@@ -0,0 +1,4 @@
*.v linguist-language=SystemVerilog
*.vh linguist-language=SystemVerilog
*.sv linguist-language=SystemVerilog
nodist linguist-detectable=false
+16
View File
@@ -0,0 +1,16 @@
---
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/.github/blob/master/CONTRIBUTING.adoc)
title: ''
labels: new
assignees: ''
---
Thanks for taking the time to report this.
Can you attach an example that shows the issue? (Must be openly licensed, ideally in test_regress format.)
What 'verilator --version' are you using? Did you try it with the git master version?
Would you be willing to try to fix Verilator yourself with assistance?
+16
View File
@@ -0,0 +1,16 @@
---
name: Feature Request
about: Request something should be supported, or a new feature added. (Note our contributor agreement at https://github.com/verilator/verilator/.github/blob/master/CONTRIBUTING.adoc)
title: ''
labels: new
assignees: ''
---
Thanks for taking the time to report this.
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.)
May we assist you in trying to fix this yourself?
+10
View File
@@ -0,0 +1,10 @@
---
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/.github/blob/master/CONTRIBUTING.adoc)
title: ''
labels: new
assignees: ''
---
How may we help - what is your question?
+1
View File
@@ -0,0 +1 @@
We appreciate your contributing to Verilator. If this is your first commit, please add your name to docs/CONTRIBUTORS, and read our contributing guidelines in docs/CONTRIBUTING.adoc.
+199
View File
@@ -0,0 +1,199 @@
["area: assertions"]
color = "ffffe8"
name = "area: assertions"
description = "Issue involves assertions"
["area: configure/compiling"]
color = "ffffe8"
name = "area: configure/compiling"
description = "Issue involves configuring or compilating Verilator itself"
["area: coverage"]
color = "ffffe8"
name = "area: coverage"
description = "Issue involves coverage generation"
["area: data-types"]
color = "ffffe8"
name = "area: data-types"
description = "Issue involves data-types"
["area: documentation"]
color = "ffffe8"
name = "area: documentation"
description = "Issue involves documentation"
["area: elaboration"]
color = "ffffe8"
name = "area: elaboration"
description = "Issue involves elaboration phase"
["area: invoking/options"]
color = "ffffe8"
name = "area: invoking/options"
description = "Issue involves options passed to Verilator"
["area: lint"]
color = "ffffe8"
name = "area: lint"
description = "Issue involves SystemVerilog lint checking"
["area: parser"]
color = "ffffe8"
name = "area: parser"
description = "Issue involves SystemVerilog parsing"
["area: performance"]
color = "ffffe8"
name = "area: performance"
description = "Issue involves performance issues"
["area: portability"]
color = "ffffe8"
name = "area: portability"
description = "Issue involves operating system/compiler portability"
["area: runtime result"]
color = "ffffe8"
name = "area: runtime result"
description = "Issue involves an incorrect runtine result from Verilated model"
["area: scheduling"]
color = "ffffe8"
name = "area: scheduling"
description = "Issue involves scheduling/ordering of events"
["area: tests"]
color = "ffffe8"
name = "area: tests"
description = "Issue involves the testing system"
["area: usability"]
color = "ffffe8"
name = "area: usability"
description = "Issue involves general usability"
["effort: days"]
color = "d0c0b0"
name = "effort: days"
description = "Expect this issue to require roughly days of invested effort to resolve"
["effort: hours"]
color = "f5e6d6"
name = "effort: hours"
description = "Expect this issue to require roughly hours of invested effort to resolve"
["effort: minutes"]
color = "f5e6d6"
name = "effort: minutes"
description = "Expect this issue to require less than an hour of invested effort to resolve"
["effort: weeks"]
color = "d0c0b0"
name = "effort: weeks"
description = "Expect this issue to require weeks or more of invested effort to resolve"
["good first issue"]
color = "7057ff"
name = "good first issue"
description = "Good for newcomers"
["help wanted"]
color = "008672"
name = "help wanted"
description = "Extra attention is needed"
["new"]
color = "ff4400"
name = "new"
description = "New issue, not yet seen by maintainers"
["resolution: abandoned"]
color = "cfd3d7"
name = "resolution: abandoned"
description = "Closed; not enough information or otherwise never finished"
["resolution: answered"]
color = "cfd3d7"
name = "resolution: answered"
description = "Closed; only applies to questions which were answered"
["resolution: duplicate"]
color = "cfd3d7"
name = "resolution: duplicate"
description = "Closed; issue or pull request already exists"
["resolution: external"]
color = "cfd3d7"
name = "resolution: external"
description = "Closed; passed to another tool's bug tracker"
["resolution: fixed"]
color = "cfd3d7"
name = "resolution: fixed"
description = "Closed; fixed"
["resolution: invalid"]
color = "cfd3d7"
name = "resolution: invalid"
description = "Closed; issue or pull request is no longer relevant"
["resolution: no fix needed"]
color = "cfd3d7"
name = "resolution: no fix needed"
description = "Closed; no fix required (not a bug)"
["resolution: wontfix"]
color = "cfd3d7"
name = "resolution: wontfix"
description = "Closed; work won't continue on an issue or pull request"
["status: asked reporter"]
color = "ffffff"
name = "status: asked reporter"
description = "Bug is waiting for reporter to answer a question"
["status: assigned"]
color = "a0f0ff"
name = "status: assigned"
description = "Issue is assigned to someone to work on"
["status: blocked"]
color = "00007f"
name = "status: blocked"
description = "Issue is waiting for another bug, when other bug is fixed, then goes to 'status: assigned'"
["status: discussion"]
color = "d876e3"
name = "status: discussion"
description = "Issue is waiting for discussions to resolve"
["status: ready"]
color = "b6c92a"
name = "status: ready"
description = "Issue is ready for someone to fix; then goes to 'status: assigned'"
["type: bug"]
color = "d73a4a"
name = "type: bug"
description = "Defect"
["type: feature-IEEE"]
color = "cfccff"
name = "type: feature-IEEE"
description = "Request to add new feature, described in IEEE 1800"
["type: feature-non-IEEE"]
color = "cfccff"
name = "type: feature-non-IEEE"
description = "Request to add new feature, outside IEEE 1800"
["type: maintenance"]
color = "cfccff"
name = "type: maintenance"
description = "Internal maintenance task"
["type: q and a"]
color = "84ba34"
name = "type: q and a"
description = "Question and answer about some feature or user question"
+17 -2
View File
@@ -1,4 +1,7 @@
\#*
.#*
*~
*.tidy
*.old
*.gz
*.gz.uu
@@ -6,16 +9,28 @@
*.info
*.log
*.1
.*.swp
*.tmp
*.tex
*.pdf
/Makefile
README
TAGS
autom4te.cache
compile_commands.json
config.cache
config.status
configure
dddrun*
doxygen-doc
gdbrun*
gmon.out
ncverilog.history
internals.txt
verilator.txt
verilator.pdf
verilator_bin*
autom4te.cache
verilator_coverage_bin*
verilator.pc
verilator-config.cmake
verilator-config-version.cmake
**/obj_dir/*
+118
View File
@@ -0,0 +1,118 @@
# DESCRIPTION: Travis-CI config
#
# Copyright 2003-2020 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
version: ~> 1.0
language: cpp
cache:
directories:
- $HOME/.ccache
env:
global:
- VERILATOR_ROOT=$TRAVIS_BUILD_DIR
# The list and order of build stages
stages:
- build # Build Verilator
- test # Run tests
# Dump info about the environment for debugging
before_install:
# To dump the script that Travis itself is executing, add 'cat $0' here
- cd "$TRAVIS_BUILD_DIR" # Skipping the git clone in later stages requires this
- export CCACHE_MAXSIZE=$(ci/travis-ccache-size.bash) # Set here after the 'cd'
- env | sort
- ls -lA .
- ls -lA bin
- g++ -E -dM -c -x c++ /dev/null | sort
- clang++ -E -dM -c -x c++ /dev/null | sort
# Install all dependencies
install:
- ./ci/travis-install.bash
before_script:
# ccache maintenance
- ./ci/travis-ccache-maint.bash
# On Focal, set the SystemC installation location
- |
if [ "$TRAVIS_DIST" = "focal" ]; then
export SYSTEMC_INCLUDE=/usr/include
export SYSTEMC_LIBDIR=/usr/lib/x86_64-linux-gnu
fi
before_cache:
- ccache -s -z
# All jobs run the same script
script: ./ci/travis-script.bash
# Enumerate all the jobs
jobs:
include:
############################################################################
# Jobs in the 'build' stage
############################################################################
# GCC builds
- {stage: build, if: type = cron, os: linux, dist: trusty, compiler: gcc, workspaces: {create: {name: trusty-gcc, paths: .}}}
- {stage: build, if: type = cron, os: linux, dist: xenial, compiler: gcc, workspaces: {create: {name: xenial-gcc, paths: .}}}
- {stage: build, if: type = cron, os: linux, dist: bionic, compiler: gcc, workspaces: {create: {name: bionic-gcc, paths: .}}}
- {stage: build, os: linux, dist: focal, compiler: gcc, workspaces: {create: {name: focal-gcc, paths: .}}}
# Clang builds
- {stage: build, if: type = cron, os: linux, dist: xenial, compiler: clang, workspaces: {create: {name: xenial-clang, paths: .}}}
- {stage: build, os: linux, dist: focal, compiler: clang, workspaces: {create: {name: focal-clang, paths: .}}}
# Coverage build
- {stage: build, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {create: {name: coverage, paths: .}}, env: COVERAGE=1}
############################################################################
# Jobs in the 'test' stage
############################################################################
# GCC tests
- {stage: test, if: type = cron, os: linux, dist: trusty, compiler: gcc, workspaces: {use: trusty-gcc}, git: {clone: false}, env: TESTS=dist-vlt-0}
- {stage: test, if: type = cron, os: linux, dist: trusty, compiler: gcc, workspaces: {use: trusty-gcc}, git: {clone: false}, env: TESTS=dist-vlt-1}
- {stage: test, if: type = cron, os: linux, dist: trusty, compiler: gcc, workspaces: {use: trusty-gcc}, git: {clone: false}, env: TESTS=vltmt-0}
- {stage: test, if: type = cron, os: linux, dist: trusty, compiler: gcc, workspaces: {use: trusty-gcc}, git: {clone: false}, env: TESTS=vltmt-1}
- {stage: test, if: type = cron, os: linux, dist: xenial, compiler: gcc, workspaces: {use: xenial-gcc}, git: {clone: false}, env: TESTS=dist-vlt-0}
- {stage: test, if: type = cron, os: linux, dist: xenial, compiler: gcc, workspaces: {use: xenial-gcc}, git: {clone: false}, env: TESTS=dist-vlt-1}
- {stage: test, if: type = cron, os: linux, dist: xenial, compiler: gcc, workspaces: {use: xenial-gcc}, git: {clone: false}, env: TESTS=vltmt-0}
- {stage: test, if: type = cron, os: linux, dist: xenial, compiler: gcc, workspaces: {use: xenial-gcc}, git: {clone: false}, env: TESTS=vltmt-1}
- {stage: test, if: type = cron, os: linux, dist: bionic, compiler: gcc, workspaces: {use: bionic-gcc}, git: {clone: false}, env: TESTS=dist-vlt-0}
- {stage: test, if: type = cron, os: linux, dist: bionic, compiler: gcc, workspaces: {use: bionic-gcc}, git: {clone: false}, env: TESTS=dist-vlt-1}
- {stage: test, if: type = cron, os: linux, dist: bionic, compiler: gcc, workspaces: {use: bionic-gcc}, git: {clone: false}, env: TESTS=vltmt-0}
- {stage: test, if: type = cron, os: linux, dist: bionic, compiler: gcc, workspaces: {use: bionic-gcc}, git: {clone: false}, env: TESTS=vltmt-1}
- {stage: test, if: type != cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: focal-gcc}, git: {clone: false}, env: TESTS=dist-vlt-0}
- {stage: test, if: type != cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: focal-gcc}, git: {clone: false}, env: TESTS=dist-vlt-1}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: focal-gcc}, git: {clone: false}, env: TESTS=vltmt-0}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: focal-gcc}, git: {clone: false}, env: TESTS=vltmt-1}
# Clang tests
- {stage: test, if: type = cron, os: linux, dist: xenial, compiler: clang, workspaces: {use: xenial-clang}, git: {clone: false}, env: TESTS=dist-vlt-0}
- {stage: test, if: type = cron, os: linux, dist: xenial, compiler: clang, workspaces: {use: xenial-clang}, git: {clone: false}, env: TESTS=dist-vlt-1}
- {stage: test, if: type = cron, os: linux, dist: xenial, compiler: clang, workspaces: {use: xenial-clang}, git: {clone: false}, env: TESTS=vltmt-0}
- {stage: test, if: type = cron, os: linux, dist: xenial, compiler: clang, workspaces: {use: xenial-clang}, git: {clone: false}, env: TESTS=vltmt-1}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: clang, workspaces: {use: focal-clang}, git: {clone: false}, env: TESTS=dist-vlt-0}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: clang, workspaces: {use: focal-clang}, git: {clone: false}, env: TESTS=dist-vlt-1}
- {stage: test, if: type != cron, os: linux, dist: focal, compiler: clang, workspaces: {use: focal-clang}, git: {clone: false}, env: TESTS=vltmt-0}
- {stage: test, if: type != cron, os: linux, dist: focal, compiler: clang, workspaces: {use: focal-clang}, git: {clone: false}, env: TESTS=vltmt-1}
# Coverage tests
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-dist}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-vlt-0}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-vlt-1}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-vlt-2}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-vlt-3}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-vltmt-0}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-vltmt-1}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-vltmt-2}
- {stage: test, if: type = cron, os: linux, dist: focal, compiler: gcc, workspaces: {use: coverage}, git: {clone: false}, env: TESTS=coverage-vltmt-3}
notifications:
email:
if: repo = verilator/verilator
recipients:
- [email protected]
- [email protected]
+197
View File
@@ -0,0 +1,197 @@
Artistic License 2.0
Copyright (c) 2000-2006, The Perl Foundation.
Everyone is permitted to copy and distribute verbatim copies of this
license document, but changing it is not allowed.
Preamble
********
This license establishes the terms under which a given free software
Package may be copied, modified, distributed, and/or redistributed. The
intent is that the Copyright Holder maintains some artistic control over
the development of that Package while still keeping the Package
available as open source and free software.
You are always permitted to make arrangements wholly outside of this
license directly with the Copyright Holder of a given Package. If the
terms of this license do not permit the full use that you propose to
make of the Package, you should contact the Copyright Holder and seek a
different licensing arrangement.
Definitions
***********
"Copyright Holder" means the individual(s) or organization(s) named in
the copyright notice for the entire Package.
"Contributor" means any party that has contributed code or other
material to the Package, in accordance with the Copyright Holder's
procedures.
"You" and "your" means any person who would like to copy, distribute, or
modify the Package.
"Package" means the collection of files distributed by the Copyright
Holder, and derivatives of that collection and/or of those files. A
given Package may consist of either the Standard Version, or a Modified
Version.
"Distribute" means providing a copy of the Package or making it
accessible to anyone else, or in the case of a company or organization,
to others outside of your company or organization.
"Distributor Fee" means any fee that you charge for Distributing this
Package or providing support for this Package to another party. It does
not mean licensing fees.
"Standard Version" refers to the Package if it has not been modified, or
has been modified only in ways explicitly requested by the Copyright
Holder.
"Modified Version" means the Package, if it has been changed, and such
changes were not explicitly requested by the Copyright Holder.
"Original License" means this Artistic License as Distributed with the
Standard Version of the Package, in its current version or as it may be
modified by The Perl Foundation in the future.
"Source" form means the source code, documentation source, and
configuration files for the Package.
"Compiled" form means the compiled bytecode, object code, binary, or any
other form resulting from mechanical transformation or translation of
the Source form.
Permission for Use and Modification Without Distribution
********************************************************
(1) You are permitted to use the Standard Version and create and use
Modified Versions for any purpose without restriction, provided that you
do not Distribute the Modified Version.
Permissions for Redistribution of the Standard Version
******************************************************
(2) You may Distribute verbatim copies of the Source form of the
Standard Version of this Package in any medium without restriction,
either gratis or for a Distributor Fee, provided that you duplicate all
of the original copyright notices and associated disclaimers. At your
discretion, such verbatim copies may or may not include a Compiled form
of the Package.
(3) You may apply any bug fixes, portability changes, and other
modifications made available from the Copyright Holder. The resulting
Package will still be considered the Standard Version, and as such will
be subject to the Original License.
Distribution of Modified Versions of the Package as Source
**********************************************************
(4) You may Distribute your Modified Version as Source (either gratis or
for a Distributor Fee, and with or without a Compiled form of the
Modified Version) provided that you clearly document how it differs from
the Standard Version, including, but not limited to, documenting any
non-standard features, executables, or modules, and provided that you do
at least ONE of the following:
(a) make the Modified Version available to the Copyright Holder of the
Standard Version, under the Original License, so that the Copyright
Holder may include your modifications in the Standard Version.
(b) ensure that installation of your Modified Version does not prevent
the user installing or running the Standard Version. In addition, the
Modified Version must bear a name that is different from the name of the
Standard Version.
(c) allow anyone who receives a copy of the Modified Version to make the
Source form of the Modified Version available to others under
(i) the Original License or
(ii) a license that permits the licensee to freely copy, modify and
redistribute the Modified Version using the same licensing terms that
apply to the copy that the licensee received, and requires that the
Source form of the Modified Version, and of any works derived from it,
be made freely available in that license fees are prohibited but
Distributor Fees are allowed.
Distribution of Compiled Forms of the Standard Version or Modified
******************************************************************
Versions without the Source
***************************
(5) You may Distribute Compiled forms of the Standard Version without
the Source, provided that you include complete instructions on how to
get the Source of the Standard Version. Such instructions must be valid
at the time of your distribution. If these instructions, at any time
while you are carrying out such distribution, become invalid, you must
provide new instructions on demand or cease further distribution. If
you provide valid instructions or cease distribution within thirty days
after you become aware that the instructions are invalid, then you do
not forfeit any of your rights under this license.
(6) You may Distribute a Modified Version in Compiled form without the
Source, provided that you comply with Section 4 with respect to the
Source of the Modified Version.
Aggregating or Linking the Package
**********************************
(7) You may aggregate the Package (either the Standard Version or
Modified Version) with other packages and Distribute the resulting
aggregation provided that you do not charge a licensing fee for the
Package. Distributor Fees are permitted, and licensing fees for other
components in the aggregation are permitted. The terms of this license
apply to the use and Distribution of the Standard or Modified Versions
as included in the aggregation.
(8) You are permitted to link Modified and Standard Versions with other
works, to embed the Package in a larger work of your own, or to build
stand-alone binary or bytecode versions of applications that include the
Package, and Distribute the result without restriction, provided the
result does not expose a direct interface to the Package.
Items That are Not Considered Part of a Modified Version
********************************************************
(9) Works (including, but not limited to, modules and scripts) that
merely extend or make use of the Package, do not, by themselves, cause
the Package to be a Modified Version. In addition, such works are not
considered parts of the Package itself, and are not subject to the terms
of this license.
General Provisions
******************
(10) Any use, modification, and distribution of the Standard or Modified
Versions is governed by this Artistic License. By using, modifying or
distributing the Package, you accept this license. Do not use, modify,
or distribute the Package, if you do not accept this license.
(11) If your Modified Version has been derived from a Modified Version
made by someone other than you, you are nevertheless required to ensure
that your Modified Version complies with the requirements of this
license.
(12) This license does not grant you the right to use any trademark,
service mark, tradename, or logo of the Copyright Holder.
(13) This license includes the non-exclusive, worldwide, free-of-charge
patent license to make, have made, use, offer to sell, sell, import and
otherwise transfer the Package with respect to any patent claims
licensable by the Copyright Holder that are necessarily infringed by the
Package. If you institute patent litigation (including a cross-claim or
counterclaim) against any party alleging that the Package constitutes
direct or contributory patent infringement, then this Artistic License
to you shall terminate on the date that such litigation is filed.
(14) Disclaimer of Warranty: THE PACKAGE IS PROVIDED BY THE COPYRIGHT
HOLDER AND CONTRIBUTORS "AS IS' AND WITHOUT ANY EXPRESS OR IMPLIED
WARRANTIES. THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE, OR NON-INFRINGEMENT ARE DISCLAIMED TO THE EXTENT
PERMITTED BY YOUR LOCAL LAW. UNLESS REQUIRED BY LAW, NO COPYRIGHT
HOLDER OR CONTRIBUTOR WILL BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING IN ANY WAY OUT OF THE USE
OF THE PACKAGE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-339
View File
@@ -1,339 +0,0 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Library General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
Appendix: How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) 19yy <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) 19yy name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General
Public License instead of this License.
+2583 -303
View File
File diff suppressed because it is too large Load Diff
+165
View File
@@ -0,0 +1,165 @@
GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.
+51 -10
View File
@@ -1,28 +1,69 @@
^CVS/
/CVS/
\.clang-format
\.clang-tidy
\.git/
\.git$
\.github/
\.svn/
\.(bak|old)/
\.(bak|old)$
\bMakefile$
\.tar\.
.*\.tgz
.*\.log
\..*\.swp
.*\.tmp
.*\.tidy
.*\.tex
.*\.key
.*\.vcd
/obj_dir/
.*\.1
\.codacy\.yml
\.travis\.yml
/build/
/obj_dbg/
/obj_dir/
/obj_dist/
/obj_iv/
/obj_nc/
/obj_opt/
/INCA_libs/
/obj_vcs/
/obj_vlt/
/obj_vltmt/
INCA_libs/
/cov_work/
/logs/
Makefile
src/Makefile_obj
include/verilated.mk
config.cache
config.status
^Makefile$
README.html
bin/verilator_bin.*
bin/verilator_coverage_bin.*
docs/.*\.html$
docs/Makefile$
docs/clang-format.txt$
docs/doxygen-doc/.*
examples/xml_py/copied/
examples/xml_py/graph.*
src/Makefile$
src/Makefile_obj$
include/verilated.mk$
test_regress/.gdbinit$
codecov.yml
config.cache$
config.status$
verilator\.log
verilator\.tex
verilator-config.cmake$
verilator-config-version.cmake$
verilator.pc$
verilator_bin.*
verilator_coverage_bin.*
.vcsmx_rebuild$
ncverilog.history
autom4te\.cache/
nodist/
ci/
/simv$
/simv.daidir/
/vc_hdrs.h$
/csrc/
obj_dir.*
TAGS
.*~
+348 -157
View File
@@ -3,20 +3,15 @@
#
# This file is part of Verilator.
#
# Author: Wilson Snyder <wsnyder@wsnyder.org>
#
# Code available from: http://www.veripool.org/verilator
# Code available from: https://verilator.org
#
#*****************************************************************************
#
# Copyright 2003-2009 by Wilson Snyder. This program is free software; you can
# redistribute it and/or modify it under the terms of either the GNU
# General Public License or the Perl Artistic License.
#
# Verilator is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# Copyright 2003-2020 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
#
#****************************************************************************/
#
@@ -43,9 +38,6 @@
# reconstructed with this Makefile. This typically includes
# everything deleted by distclean, plus more: C source files
# produced by Bison, tags tables, info files, and so on.
#
# make extraclean
# Still more severe - delete backup and autosave files, too.
#### Start of system configuration section. ####
@@ -53,11 +45,14 @@ srcdir = @srcdir@
VPATH = @srcdir@
HOST = @HOST@
DOXYGEN = doxygen
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
MAKEINFO = makeinfo
TEXI2DVI = texi2dvi
POD2TEXT = pod2text
POD2LATEXFIX = $(srcdir)/src/pod2latexfix
MKINSTALLDIRS = $(SHELL) $(srcdir)/src/mkinstalldirs
PERL = @PERL@
# Destination prefix for RPMs
@@ -70,7 +65,7 @@ exec_prefix = @exec_prefix@
# Directory in which to install scripts.
bindir = @bindir@
# Directory in which to install scripts.
# Directory in which to install manpages.
mandir = @mandir@
# Directory in which to install library files.
@@ -83,249 +78,432 @@ infodir = @infodir@
# Generally ${prefix}/share/verilator
pkgdatadir = @pkgdatadir@
# Directory in which to install pkgconfig file
# Generally ${prefix}/share/pkgconfig
pkgconfigdir = @pkgconfigdir@
# Directory in which to install data across multiple architectures
datarootdir = @datarootdir@
# Compile options
CFG_WITH_CCWARN = @CFG_WITH_CCWARN@
CFG_WITH_DEFENV = @CFG_WITH_DEFENV@
CFG_WITH_LONGTESTS = @CFG_WITH_LONGTESTS@
CFG_WITH_THREADED = @CFG_WITH_THREADED@
PACKAGE_VERSION = @PACKAGE_VERSION@
#### End of system configuration section. ####
######################################################################
.SUFFIXES:
SHELL = /bin/sh
SUBDIRS = src test_verilated test_c test_sc test_sp test_regress test_vcs
SUBDIRS = docs src test_regress \
examples/cmake_hello_c \
examples/cmake_hello_sc \
examples/cmake_tracing_c \
examples/cmake_tracing_sc \
examples/cmake_protect_lib \
examples/make_hello_c \
examples/make_hello_sc \
examples/make_tracing_c \
examples/make_tracing_sc \
examples/make_protect_lib \
examples/xml_py \
INFOS = README verilator.txt verilator.html verilator.1 verilator.pdf
INFOS = verilator.txt verilator.html verilator.pdf
INFOS_OLD = README README.html README.pdf
# Files that can be generated, but should be up to date for a distribution.
DISTDEP = info Makefile
# Files to distribute.
DISTBIN = $(wildcard bin/verilator-*)
DISTFILES_INC = $(INFOS) .gitignore COPYING *.in *.ac \
Changes README TODO \
DISTFILES_INC = $(INFOS) .gitignore \
*.in *.ac \
Artistic \
Changes \
LICENSE \
MANIFEST.SKIP \
bin/* \
install-sh configure mkinstalldirs *.texi \
include/verilated.[chv]* \
include/verilatedos.[chv]* \
README.adoc \
verilator-config.cmake.in \
verilator-config-version.cmake.in \
bin/verilator \
bin/verilator_coverage \
bin/verilator_difftree \
bin/verilator_gantt \
bin/verilator_includer \
bin/verilator_profcfunc \
docs/.gitignore \
docs/CONTRIBUTING.adoc \
docs/CONTRIBUTORS \
docs/Makefile.in \
docs/TODO \
docs/doxygen-mainpage \
docs/doxygen.config \
docs/install.adoc \
docs/internals.adoc \
docs/verilator_logo.png \
docs/xml.adoc \
install-sh configure *.pod \
include/*.[chv]* \
include/*.in \
include/.*ignore \
include/gtkwave/*.[chv]* \
include/vltstd/*.[chv]* \
.*attributes */.*attributes */*/.*attributes \
src/.*ignore src/*.in src/*.cpp src/*.[chly] src/astgen src/bisonpre src/*fix \
src/.*ignore src/*.in src/*.cpp src/*.[chly] \
src/astgen src/bisonpre src/*fix src/cppcheck_filtered \
src/vlcovgen src/mkinstalldirs \
src/.gdbinit \
src/*.pl src/*.pod \
examples/*/.*ignore examples/*/Makefile* \
examples/*/*.[chv]* examples/*/vl_* \
examples/*/CMakeLists.txt \
test_*/.*ignore test_*/Makefile* test_*/*.cpp \
test_*/*.pl test_*/*.v test_*/*.vc test_*/vlint \
test_verilated/vgen*.pl \
test_*/*.pl test_*/*.v test_*/*.vc test_*/*.vh \
test_regress/*.pl \
test_regress/Makefile \
test_regress/Makefile_obj \
test_regress/input.vc \
test_regress/CMakeLists.txt \
test_regress/t/t*/*.sv* \
test_regress/t/t*/*.v* \
test_regress/t/t*/*/*.sv* \
test_regress/t/t*/*/*.v* \
test_regress/t/*.cpp \
test_regress/t/*.h \
test_regress/t/*.dat \
test_regress/t/*.mem \
test_regress/t/*.out \
test_regress/t/*.pl \
test_regress/t/*.pf \
test_regress/t/*.v* \
verilator.* \
INST_PROJ_FILES = \
bin/verilator \
bin/verilator_coverage \
bin/verilator_gantt \
bin/verilator_includer \
bin/verilator_profcfunc \
include/verilated.[chv]* \
include/verilated.mk \
include/verilatedos.[chv]* \
include/*.[chv]* \
include/gtkwave/*.[chv]* \
include/vltstd/*.[chv]* \
INST_PROJ_BIN_FILES = \
verilator_bin \
verilator_bin_dbg \
bin/verilator_bin \
bin/verilator_bin_dbg \
bin/verilator_coverage_bin_dbg \
DISTFILES := $(DISTFILES_INC)
VL_INST_MAN_FILES = verilator.1
EXAMPLES_FIRST = \
examples/make_hello_c \
examples/make_hello_sc \
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
VL_INST_MAN_FILES = verilator.1 verilator_coverage.1 verilator_gantt.1 verilator_profcfunc.1
default: all
all: all_nomsg msg_test
all_nomsg: verilator_exe $(VL_INST_MAN_FILES)
.PHONY:verilator_exe
verilator_exe verilator_bin verilator_bin_dbg:
.PHONY:verilator_bin
.PHONY:verilator_bin_dbg
.PHONY:verilator_coverage_bin_dbg
verilator_exe verilator_bin verilator_bin_dbg verilator_coverage_bin_dbg:
@echo ------------------------------------------------------------
@echo "making verilator in src" ; \
(cd src && $(MAKE) )
@echo "making verilator in src"
$(MAKE) -C src $(OBJCACHE_JOBS)
.PHONY:msg_test
msg_test:
msg_test: all_nomsg
@echo "Build complete!"
@echo
@echo "Type 'make test' to test."
@echo "Now type 'make test' to test."
@echo
.PHONY:test
ifeq ($(VERILATOR_AUTHOR_SITE),1) # Local... Else don't burden users
test: test_vcs test_c test_sc test_sp test_verilated test_regress
.PHONY: test
ifeq ($(CFG_WITH_LONGTESTS),yes) # Local... Else don't burden users
test: smoke-test test_regress
# examples is part of test_regress's test_regress/t/t_a2_examples.pl
# (because that allows it to run in parallel with other test_regress's)
else
test: test_c test_sc test_sp
test: smoke-test examples
endif
@echo "Tests passed!"
@echo
@echo "Type 'make install' to install documentation."
@echo "Now type 'make install' to install."
@echo "Or type 'make' inside an examples subdirectory."
@echo
test_vcs: all_nomsg
@(cd test_vcs && $(MAKE))
test_c: all_nomsg
@(cd test_c && $(MAKE))
test_c_debug: all_nomsg
@(cd test_c && $(MAKE) test_debug)
test_sc: all_nomsg
@(cd test_sc && $(MAKE))
test_sc_debug: all_nomsg
@(cd test_sc && $(MAKE) test_debug)
test_sp: all_nomsg
@(cd test_sp && $(MAKE))
test_sp_debug: all_nomsg
@(cd test_sp && $(MAKE) test_debug)
test_verilated: all_nomsg
@(cd test_verilated && $(MAKE))
smoke-test: all_nomsg
test_regress/t/t_a1_first_cc.pl
test_regress/t/t_a2_first_sc.pl
test_regress: all_nomsg
@(cd test_regress && $(MAKE))
$(MAKE) -C test_regress
examples: all_nomsg
for p in $(EXAMPLES) ; do \
$(MAKE) -C $$p VERILATOR_ROOT=`pwd` || exit 10; \
done
.PHONY: docs
docs: info
info: $(INFOS)
# Use --no-split to avoid creating filenames > 14 chars.
verilator.1: bin/verilator
%.1: ${srcdir}/bin/%
pod2man $< $@
verilator.txt: bin/verilator
pod2text $< $@
verilator.txt: ${srcdir}/bin/verilator
$(POD2TEXT) $< $@
verilator.html: bin/verilator
verilator.html: ${srcdir}/bin/verilator
pod2html $< >$@
verilator.pdf: bin/verilator $(DISTCONFIG)
pod2latex --full --out verilator.tex bin/verilator
cat < verilator.tex \
| sed 's/\\begin{document}/\\usepackage[left=1.7in,right=1.7in,top=1.3in,bottom=1.3in]{geometry}\n\\begin{document}/' \
| sed 's/\\begin{document}/\\usepackage[pdftex,bookmarks=true,bookmarksnumbered=true,hypertexnames=false,breaklinks=true,linkbordercolor={0 0 1}]{hyperref}\n\\begin{document}/' \
| sed 's/\\begin{document}/\\usepackage{fancyhdr} \\pagestyle{fancy}\n\\begin{document}/' \
| sed 's/\\begin{document}/\\setlength{\\parindent}{0pt} \\setlength{\\parskip}{\\baselineskip}\n\\begin{document}/' \
| sed 's/\\begin{document}/\\title{$(DISTTITLE)} \\date{${DISTDATE}} \\author{Wilson Snyder\\\\ http:\/\/www.veripool.org}\n\\begin{document}/' \
| sed 's/\\begin{document}/\\lhead[$(DISTTITLE)]{$(DISTTITLE)}\n\\begin{document}/' \
| sed 's/\\tableofcontents/\\begin{titlepage} \\maketitle \\end{titlepage}\n\\tableofcontents/' \
> verilator2.tex
# PDF needs DIST variables; but having configure.ac as dependency isn't detected
verilator.pdf: ${srcdir}/bin/verilator Makefile $(POD2LATEXFIX)
pod2latex --full --out verilator.tex $<
$(PERL) $(POD2LATEXFIX) "$(DISTTITLE)" "${DISTDATE}" < verilator.tex > verilator2.tex
mv verilator2.tex verilator.tex
pdflatex verilator.tex
pdflatex verilator.tex
-rm -f verilator.toc verilator.aux verilator.idx verilator.out
INSTALL: install.texi
$(MAKEINFO) -I$(srcdir) $(srcdir)/install.texi --output=$@ \
--no-headers --no-validate
README: readme.texi
$(MAKEINFO) -I$(srcdir) $(srcdir)/readme.texi --output=$@ \
--no-headers --no-validate
# See uninstall also
VL_INST_BIN_FILES = verilator verilator_bin verilator_bin_dbg \
verilator_includer verilator_profcfunc
# See uninstall also - don't put wildcards in this variable, it might uninstall other stuff
VL_INST_BIN_FILES = verilator verilator_bin verilator_bin_dbg verilator_coverage_bin_dbg \
verilator_coverage verilator_gantt verilator_includer verilator_profcfunc
# Some scripts go into both the search path and pkgdatadir,
# so they can be found by the user, and under $VERILATOR_ROOT.
installbin:
$(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(bindir)
( cd bin ; $(INSTALL_PROGRAM) verilator $(DESTDIR)$(bindir)/verilator )
( cd bin ; $(INSTALL_PROGRAM) verilator_includer $(DESTDIR)$(bindir)/verilator_includer )
( cd bin ; $(INSTALL_PROGRAM) verilator_profcfunc $(DESTDIR)$(bindir)/verilator_profcfunc )
( $(INSTALL_PROGRAM) verilator_bin $(DESTDIR)$(bindir)/verilator_bin )
( $(INSTALL_PROGRAM) verilator_bin_dbg $(DESTDIR)$(bindir)/verilator_bin_dbg )
$(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(pkgdatadir)/bin
( cd bin ; $(INSTALL_PROGRAM) verilator_includer $(DESTDIR)$(pkgdatadir)/bin/verilator_includer )
installman:
$(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(mandir)/man1
for p in $(VL_INST_MAN_FILES) ; do \
$(INSTALL_PROGRAM) $$p $(DESTDIR)$(mandir)/man1/$$p; \
VL_INST_INC_BLDDIR_FILES = \
include/verilated_config.h \
include/verilated.mk \
# Files under srcdir, instead of build time
VL_INST_INC_SRCDIR_FILES = \
include/*.[chv]* \
include/gtkwave/*.[chv]* \
include/vltstd/*.[chv]* \
VL_INST_DATA_SRCDIR_FILES = \
examples/*/*.[chv]* examples/*/Makefile* \
examples/*/CMakeLists.txt
installbin:
$(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 $(DESTDIR)$(bindir)/verilator_bin )
( cd bin ; $(INSTALL_PROGRAM) verilator_bin_dbg $(DESTDIR)$(bindir)/verilator_bin_dbg )
( cd bin ; $(INSTALL_PROGRAM) verilator_coverage_bin_dbg $(DESTDIR)$(bindir)/verilator_coverage_bin_dbg )
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/bin
( cd ${srcdir}/bin ; $(INSTALL_PROGRAM) verilator_includer $(DESTDIR)$(pkgdatadir)/bin/verilator_includer )
# Man files can either be part of the original kit, or built in current directory
# So important we use $^ so VPATH is searched
installman: $(VL_INST_MAN_FILES)
$(MKINSTALLDIRS) $(DESTDIR)$(mandir)/man1
for p in $^ ; do \
$(INSTALL_DATA) $$p $(DESTDIR)$(mandir)/man1/$$p; \
done
installdata:
$(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(pkgdatadir)/examples
cp -r include $(DESTDIR)$(pkgdatadir)
cp -r test_c $(DESTDIR)$(pkgdatadir)/examples
cp -r test_sc $(DESTDIR)$(pkgdatadir)/examples
cp -r test_sp $(DESTDIR)$(pkgdatadir)/examples
cp -r test_v $(DESTDIR)$(pkgdatadir)/examples
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/include/gtkwave
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/include/vltstd
for p in $(VL_INST_INC_BLDDIR_FILES) ; do \
$(INSTALL_DATA) $$p $(DESTDIR)$(pkgdatadir)/$$p; \
done
cd $(srcdir) \
; for p in $(VL_INST_INC_SRCDIR_FILES) ; do \
$(INSTALL_DATA) $$p $(DESTDIR)$(pkgdatadir)/$$p; \
done
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_hello_c
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_hello_sc
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_tracing_c
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_tracing_sc
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/make_protect_lib
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_hello_c
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_hello_sc
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_c
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_sc
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/cmake_protect_lib
$(MKINSTALLDIRS) $(DESTDIR)$(pkgdatadir)/examples/xml_py
cd $(srcdir) \
; for p in $(VL_INST_DATA_SRCDIR_FILES) ; do \
$(INSTALL_DATA) $$p $(DESTDIR)$(pkgdatadir)/$$p; \
done
$(MKINSTALLDIRS) $(DESTDIR)$(pkgconfigdir)
$(INSTALL_DATA) verilator.pc $(DESTDIR)$(pkgconfigdir)
$(INSTALL_DATA) verilator-config.cmake $(DESTDIR)$(pkgdatadir)
$(INSTALL_DATA) verilator-config-version.cmake $(DESTDIR)$(pkgdatadir)
VL_INST_DATA_FILES = verilator.1
install: all_nomsg installbin installman installdata install-msg
# We don't trust rm -rf, so rmdir instead as it will fail if user put in other files
uninstall:
-cd $(DESTDIR)$(bindir) && rm -f $(VL_INST_BIN_FILES)
-cd $(DESTDIR)$(pkgdatadir)/bin && rm -f $(VL_INST_BIN_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_SRCDIR_FILES)
-cd $(DESTDIR)$(pkgdatadir) && rm -f $(VL_INST_DATA_SRCDIR_FILES)
-rm $(DESTDIR)$(pkgconfigdir)/verilator.pc
-rm $(DESTDIR)$(pkgdatadir)/verilator-config.cmake
-rm $(DESTDIR)$(pkgdatadir)/verilator-config-version.cmake
-rmdir $(DESTDIR)$(pkgdatadir)/bin
-rmdir $(DESTDIR)$(pkgdatadir)/include/gtkwave
-rmdir $(DESTDIR)$(pkgdatadir)/include/vltstd
-rmdir $(DESTDIR)$(pkgdatadir)/include
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_hello_c
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_hello_sc
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_tracing_c
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_tracing_sc
-rmdir $(DESTDIR)$(pkgdatadir)/examples/make_protect_lib
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_hello_c
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_hello_sc
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_c
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_tracing_sc
-rmdir $(DESTDIR)$(pkgdatadir)/examples/cmake_protect_lib
-rmdir $(DESTDIR)$(pkgdatadir)/examples/xml_py
-rmdir $(DESTDIR)$(pkgdatadir)/examples
-rmdir $(DESTDIR)$(pkgdatadir)
-rmdir $(DESTDIR)$(pkgconfigdir)
install: all_nomsg install-all
install-all: installbin installman installdata install-msg
install-here: installman ftp
ifeq ($(VERILATOR_AUTHOR_SITE),1) # Local... Else don't burden users
DIRPROJECT := $(shell project_dir --project)
DISTNAMEREV = $(shell sed -e '/DTVERSION/!d' -e 's/.*verilator_\([^"]*\).*/\1/' -e q ${srcdir}/src/config_rev.h)
VERILATOR_CAD_DIR = $(CAD_DIR)/verilator/$(DISTNAMEREV)/$(DIRPROJECT_ARCH)
INST_PROJ_CVS = cp_if_cvs_diff
install-project: dist
@echo "Install-project to $(DIRPROJECT)"
strip verilator_bin*
$(MAKE) install-project-quick
for p in verilator.1 ; do \
$(INSTALL_PROGRAM) -m 0666 $$p $(DIRPROJECT_PREFIX)/man/man1/$$p; \
install-cadtools: dist
@echo "Install-project to $(CAD_DIR)"
strip bin/verilator_bin*
strip bin/verilator_coverage_bin*
$(MAKE) install-cadtools-quick
$(MKINSTALLDIRS) $(VERILATOR_CAD_DIR)/man/man1
for p in $(VL_INST_MAN_FILES) ; do \
$(INSTALL_DATA) $$p $(VERILATOR_CAD_DIR)/man/man1/$$p; \
done
$(INST_PROJ_CVS) $(DISTNAME).tgz $(DIRPROJECT)/hw/utils/verilator/verilator.tgz
$(INST_PROJ_CVS) $(DISTNAME).tgz $(VERILATOR_CAD_DIR)/verilator.tgz
rm $(DISTNAME).tgz
install-project-quick:
@echo "Install-project-quick (no strip) to $(DIRPROJECT)"
install-cadtools-quick:
ifeq ($(CFG_WITH_DEFENV),yes)
@echo "%Error: Reconfigure with './configure --disable-defenv' to avoid hardcoded paths."
false
endif
@echo "Install-cadtools-quick (no strip) to $(VERILATOR_CAD_DIR)"
$(MKINSTALLDIRS) $(VERILATOR_CAD_DIR)/include/gtkwave
$(MKINSTALLDIRS) $(VERILATOR_CAD_DIR)/include/vltstd
$(MKINSTALLDIRS) $(VERILATOR_CAD_DIR)/bin
for p in $(INST_PROJ_FILES) ; do \
$(INST_PROJ_CVS) $$p $(DIRPROJECT)/hw/utils/verilator/$$p; \
$(INST_PROJ_CVS) $$p $(VERILATOR_CAD_DIR)/$$p; \
done
for p in $(INST_PROJ_BIN_FILES) ; do \
$(INST_PROJ_CVS) $$p $(DIRPROJECT)/hw/utils/verilator/$$p-$(DIRPROJECT_ARCH); \
$(INST_PROJ_CVS) $$p $(VERILATOR_CAD_DIR)/$$p; \
done
# VERILATOR_AUTHOR_SITE
endif
# Use --xml flag to see the cppcheck code to use for suppression
CPPCHECK_CPP = $(wildcard \
$(srcdir)/include/*.cpp \
$(srcdir)/src/*.cpp )
CPPCHECK_H = $(wildcard \
$(srcdir)/include/*.h \
$(srcdir)/src/*.h )
CPPCHECK = src/cppcheck_filtered
CPPCHECK_FLAGS = --enable=all --inline-suppr \
--suppress=unusedScopedObject --suppress=cstyleCast --suppress=useInitializationList \
--suppress=nullPointerRedundantCheck
CPPCHECK_FLAGS += --xml
CPPCHECK_DEP = $(subst .cpp,.cppcheck,$(CPPCHECK_CPP))
CPPCHECK_INC = -I$(srcdir)/include -I$(srcdir)/src/obj_dbg -I$(srcdir)/src
cppcheck: $(CPPCHECK_DEP)
%.cppcheck: %.cpp
$(CPPCHECK) $(CPPCHECK_FLAGS) -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) $<
CLANGTIDY = clang-tidy
CLANGTIDY_FLAGS = -config=''
CLANGTIDY_DEP = $(subst .h,.h.tidy,$(CPPCHECK_H)) \
$(subst .cpp,.cpp.tidy,$(CPPCHECK_CPP))
clangtidy: $(CLANGTIDY_DEP)
%.cpp.tidy: %.cpp
$(CLANGTIDY) $(CLANGTIDY_FLAGS) $< -- -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) | 2>&1 tee $@
%.h.tidy: %.h
$(CLANGTIDY) $(CLANGTIDY_FLAGS) $< -- -DVL_DEBUG=1 -DVL_CPPCHECK=1 $(CPPCHECK_INC) | 2>&1 tee $@
analyzer-src:
-rm -rf src/obj_dbg
scan-build $(MAKE) -k verilator_coverage_bin_dbg verilator_bin_dbg
analyzer-include:
-rm -rf examples/*/obj*
scan-build $(MAKE) -k examples
CLANGFORMAT = clang-format
CLANGFORMAT_FLAGS = -i
clang-format:
@$(CLANGFORMAT) --version | egrep 10.0 > /dev/null \
|| echo "*** You are not using clang-format 10.0, indents may differ from master's ***"
$(CLANGFORMAT) $(CLANGFORMAT_FLAGS) $(CPPCHECK_CPP) $(CPPCHECK_H)
ftp: info
install-msg:
@echo "Installed!"
@echo
@echo "Add to your startup file (for bash or csh, as appropriate):"
@echo " export VERILATOR_ROOT="`pwd`
@echo " setenv VERILATOR_ROOT "`pwd` " ; export VERILATOR_ROOT "
@echo "Installed binaries to $(DESTDIR)$(bindir)/verilator"
@echo "Installed man to $(DESTDIR)$(mandir)/man1"
@echo "Installed examples to $(DESTDIR)$(pkgdatadir)/examples"
@echo
@echo "See 'verilator.txt' for documentation."
@echo "For documentation see 'man verilator' or 'verilator --help'"
@echo "For forums and to report bugs see https://verilator.org"
@echo
uninstall:
-cd $(DESTDIR)$(mandir)/man1 && rm -f $(VL_INST_MAN_FILES)
-cd $(DESTDIR)$(bindir) && rm -f $(VL_INST_BIN_FILES)
-rm -f $(DESTDIR)$(pkgdatadir)
IN_WILD := ${srcdir}/*.in ${srcdir}/*/*.in
# autoheader might not change config_build.h.in, so touch a stamp file.
IN_WILD := ${srcdir}/*.in ${srcdir}/*/*.in ${srcdir}/*/*/*.in \
*.in */*.in */*.in
${srcdir}/config_build.h.in: stamp-h.in
${srcdir}/stamp-h.in: configure.ac $(wildcard $(IN_WILD))
# autoheader might not change config_build.h.in, so touch it
${srcdir}/config_build.h: ${srcdir}/config_build.h.in configure
cd ${srcdir} && autoheader
echo timestamp > ${srcdir}/stamp-h.in
config_build.h: stamp-h
stamp-h: config_build.h.in config.status
./config.status
Makefile: Makefile.in config.status
./config.status
src/Makefile: src/Makefile.in config.status
touch $@
Makefile: Makefile.in config.status $(IN_WILD)
./config.status
src/Makefile: src/Makefile.in Makefile
config.status: configure
./config.status --recheck
configure: configure.ac
ifeq ($(CFG_WITH_CCWARN),yes) # Local... Else don't burden users
autoconf --warnings=all
else
autoconf
endif
maintainer-clean::
@echo "This command is intended for maintainers to use;"
@echo "rebuilding the deleted files requires makeinfo."
rm -f *.info* $(INFOS) faq.html verilator.html configure
@echo "rebuilding the deleted files requires autoconf."
rm -f configure
clean mostlyclean distclean maintainer-clean maintainer-copy::
for dir in $(SUBDIRS); do \
echo making $@ in $$dir ; \
(cd $$dir && $(MAKE) $@) ; \
$(MAKE) -C $$dir $@ ; \
done
clean mostlyclean distclean maintainer-clean::
@@ -334,17 +512,29 @@ clean mostlyclean distclean maintainer-clean::
rm -f *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs *.idx
rm -f *.ev *.evs *.ov *.ovs *.cv *.cvs *.ma *.mas
rm -f *.tex
rm -rf examples/*/obj_dir* examples/*/logs
rm -rf test_*/obj_dir
rm -rf nodist/fuzzer/dictionary
rm -rf nodist/obj_dir
distclean maintainer-clean::
rm -f Makefile config.status config.cache config.log verilator_bin* TAGS
rm -f include/verilated.mk
rm -f *.info* *.1 $(INFOS) $(INFOS_OLD) $(VL_INST_MAN_FILES)
rm -f Makefile config.status config.cache config.log TAGS
rm -f verilator_bin* verilator_coverage_bin*
rm -f bin/verilator_bin* bin/verilator_coverage_bin*
rm -f include/verilated.mk include/verilated_config.h
TAGFILES=${srcdir}/*/*.cpp ${srcdir}/*/*.h ${srcdir}/*/[a-z]*.in \
${srcdir}/[a-z]*.in ${srcdir}/*.texi
TAGFILES=${srcdir}/*/*.cpp ${srcdir}/*/*.h ${srcdir}/*/*.in \
${srcdir}/*.in ${srcdir}/*.pod
TAGS: $(TAGFILES)
etags $(TAGFILES)
.PHONY: doxygen
doxygen:
$(MAKE) -C docs doxygen
######################################################################
# Test targets
@@ -353,17 +543,18 @@ dist-file-list:
@echo $(wildcard $(DISTFILES))
@echo "end-dist-file-list:"; # Scripts look for this
print-cfg-with-threaded:
@echo $(CFG_WITH_THREADED)
######################################################################
# Distributions
DISTCONFIG = src/config_build.h.in
DISTTITLE := $(shell sed -e '/DTVERSION/!d' -e 's/[^0-9]*\([0-9.a-z]*\).*/verilator-\1/' -e 's/v/V/' -e q $(DISTCONFIG))
DISTNAME := $(shell sed -e '/DTVERSION/!d' -e 's/[^0-9]*\([0-9.a-z]*\).*/verilator-\1/' -e q $(DISTCONFIG))
DISTDATEPRE := $(shell sed -e '/DTVERSION/!d' -e 's/.*\([1-2][0-9][0-9][0-9].[0-9]*[0-9].[0-9]*[0-9]\).*/\1/' -e q $(DISTCONFIG))
DISTTITLE := Verilator $(word 1,$(PACKAGE_VERSION))
DISTNAME := verilator-$(word 1,$(PACKAGE_VERSION))
DISTDATEPRE := $(word 2,$(PACKAGE_VERSION))
DISTDATE := $(subst /,-,$(DISTDATEPRE))
DISTTAGNAME := $(subst .,_,$(subst -,_,$(DISTNAME)))
DISTDATE := $(subst /,-,$(DISTDATEPRE))
tag:
svnorcvs tag $(DISTTAGNAME)
+154
View File
@@ -0,0 +1,154 @@
// Github doesn't render images unless absolute URL
:!toc:
ifdef::env-github[]
image:https://img.shields.io/badge/License-LGPL%20v3-blue.svg[license LGPLv3,link=https://www.gnu.org/licenses/lgpl-3.0]
image:https://img.shields.io/badge/License-Artistic%202.0-0298c3.svg[license Artistic-2.0,link=https://opensource.org/licenses/Artistic-2.0]
image:https://api.codacy.com/project/badge/Grade/fa78caa433c84a4ab9049c43e9debc6f[Code Quality,link=https://www.codacy.com/gh/verilator/verilator]
image:https://codecov.io/gh/verilator/verilator/branch/master/graph/badge.svg[Coverage,link=https://codecov.io/gh/verilator/verilator]
image:https://travis-ci.com/verilator/verilator.svg?branch=master[Build Status (Travis CI),link=https://travis-ci.com/verilator/verilator]
endif::[]
ifdef::env-github[]
:link_verilator_contributing: link:docs/CONTRIBUTING.adoc
:link_verilator_install: link:docs/install.adoc
endif::[]
ifndef::env-github[]
:link_verilator_contributing: https://github.com/verilator/verilator/blob/master/docs/CONTRIBUTING.adoc
:link_verilator_install: https://verilator.org/install
endif::[]
:link_verilator_commercial_support: https://verilator.org/verilator_commercial_support
== Welcome to Verilator
[cols="a,a",indent=0,frame="none",grid="rows"]
|===
^.^| *Welcome to Verilator, the fastest Verilog/SystemVerilog simulator.*
+++ <br/> +++ &bullet; Accepts synthesizable Verilog or SystemVerilog
+++ <br/> +++ &bullet; Performs lint code-quality checks
+++ <br/> +++ &bullet; Compiles into multithreaded {cpp}, or SystemC
+++ <br/> +++ &bullet; Creates XML to front-end your own tools
<.^|image:https://www.veripool.org/img/verilator_256_200_min.png[Logo,256,200]
>.^|image:https://www.veripool.org/img/verilator_multithreaded_performance_bg-min.png[,388,178]
^.^| *Fast*
+++ <br/> +++ &bullet; Outperforms many commercial simulators
+++ <br/> +++ &bullet; Single- and multi-threaded output models
^.^| *Widely Used*
+++ <br/> +++ &bullet; Wide industry and academic deployment
+++ <br/> +++ &bullet; Out-of-the-box support from Arm, and RISC-V vendor IP
<.^|image:https://www.veripool.org/img/verilator_usage_400x200-min.png[,400,200]
>.^|image:https://www.veripool.org/img/verilator_community_400x125-min.png[,400,125]
^.^| *Community Driven & Openly Licensed*
+++ <br/> +++ &bullet; Guided by the https://chipsalliance.org/[CHIPS Alliance] and https://www.linuxfoundation.org/[Linux Foundation]
+++ <br/> +++ &bullet; Open, and free as in both speech and beer
+++ <br/> +++ &bullet; More simulation for your verification budget
^.^| *Commercial Support Available*
+++ <br/> +++ &bullet; Commercial support contracts
+++ <br/> +++ &bullet; Design support contracts
+++ <br/> +++ &bullet; Enhancement contracts
<.^|image:https://www.veripool.org/img/verilator_support_400x125-min.png[,400,125]
|===
== What Verilator Does
Verilator is invoked with parameters similar to GCC or Synopsys's VCS. It
"Verilates" the specified Verilog or SystemVerilog code by
reading it, performing lint checks, and optionally inserting assertion
checks and coverage-analysis points. It outputs single- or multi-threaded
.cpp and .h files, the "Verilated" code.
The user writes a little {cpp}/SystemC wrapper file, which instantiates the
"Verilated" model of the user's top level module. These {cpp}/SystemC
files are then compiled by a {cpp} compiler (gcc/clang/MSVC++). The
resulting executable performs the design simulation. Verilator also
supports linking its generated libraries, optionally encrypted, into other
simulators.
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
if you are looking for a behavioral Verilog simulator e.g. for a quick
class project (we recommend http://iverilog.icarus.com[Icarus Verilog] for
this.) However, if you are looking for a path to migrate SystemVerilog to
{cpp} or SystemC, or your team is comfortable writing just a touch of {cpp}
code, Verilator is the tool for you.
== Performance
Verilator does not simply convert Verilog HDL to {cpp} or SystemC. Rather,
Verilator compiles your code into a much faster optimized and optionally
thread-partitioned model, which is in turn wrapped inside a
{cpp}/SystemC 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 thread is about 100 times faster than
interpreted Verilog simulators such as http://iverilog.icarus.com[Icarus
Verilog]. Another 2-10x speedup might be gained from multithreading
(yielding 200-1000x total over interpreted simulators).
Verilator has typically similar or better performance versus the
closed-source Verilog simulators (Carbon Design Systems Carbonator,
Modelsim, Cadence Incisive/NC-Verilog, Synopsys VCS, VTOC, and Pragmatic
CVer/CVC). But, Verilator is open-sourced, so you can spend on computes
rather than licenses. Thus Verilator gives you the best cycles/dollar.
For more information on how Verilator stacks up to some of the other
closed-sourced and open-sourced Verilog simulators, see the
https://www.veripool.org/verilog_sim_benchmarks.html[Verilog Simulator
Benchmarks]. (If you benchmark Verilator, please see the notes in the
https://verilator.org/verilator_doc.pdf[Verilator manual (PDF)], and also
if possible post on the forums the results; there may be additional tweaks
possible.)
== Installation & Documentation
For more information:
* {link_verilator_install}[Verilator installation and package directory
structure]
* https://verilator.org/verilator_doc.html[Verilator manual (HTML)],
or https://verilator.org/verilator_doc.pdf[Verilator manual (PDF)]
* https://github.com/verilator/verilator-announce[Subscribe to verilator announcements]
* https://verilator.org/forum[Verilator forum]
* https://verilator.org/issues[Verilator issues]
== Support
Verilator is a community project, guided by the
https://chipsalliance.org/[CHIPS Alliance] under the
https://www.linuxfoundation.org/[Linux Foundation].
We appreciate and welcome your contributions in whatever form; please see
{link_verilator_contributing}[Contributing to Verilator]. Thanks to our
https://verilator.org/verilator_doc.html#CONTRIBUTORS[Contributors and
Sponsors].
Verilator also supports and encourages commercial support models and
organizations; please see {link_verilator_commercial_support}[Verilator
Commercial Support].
== Related Projects
* http://gtkwave.sourceforge.net/[GTKwave] - Waveform viewer for Verilator
traces.
* http://iverilog.icarus.com[Icarus Verilog] - Icarus is a full featured
interpreted Verilog simulator. If Verilator does not support your needs,
perhaps Icarus may.
== Open License
Verilator is Copyright 2003-2020 by Wilson Snyder. (Report bugs to
https://verilator.org/issues[Verilator Issues].)
Verilator is free software; you can redistribute it and/or modify it under
the terms of either the GNU Lesser General Public License Version 3 or the
Perl Artistic License Version 2.0. See the documentation for more
details.
-153
View File
@@ -1,153 +0,0 @@
// DESCRIPTION: Verilator: List of To Do issues.
//
// Copyright 2004-2009 by Wilson Snyder. This program is free software; you can
// redistribute it and/or modify it under the terms of either the GNU
// General Public License or the Perl Artistic License.
Features:
Finish 3.400 new ordering fixes
Latch optimizations {Need here}
Task I/Os connecting to non-simple variables.
Fix nested casez statements expanding into to huge C++. [JeanPaul Vanitegem]
Fix FileLine memory inefficiency
Fix ordering of each bit separately in a signal (mips)
assign b[3:0] = b[7:4]; assign b[7:4] = in;
Support gate primitives/ cell libraries from xilinx, etc
Assign dont_care value to an 1'bzzz assignment
Function to eval combo logic after /*verilator public*/ functions [gwaters]
Support generated clocks (correctness)
?gcov coverage
Selectable SystemC types based on widths (see notes below)
Compile time
Inline first level trace routines
Coverage
Points should be per-scope like everything else rather then per-module
Expression coverage (see notes)
Constant functions for widths, etc, IE "input [log2(PARAM):0] xx;"
More Verilog 2001 Support
(* *) Attributes (just ignore -- preprocessor?)
Real numbers (NEVER)
Recursive functions (NEVER)
Verilog configuration files (NEVER)
DPI to define C/C++ calls from Verilog
Long-term Features
Assertions
VHDL parser [Philips]
Tristate support
SystemPerl integration
Multithreaded execution
Front end parser integration into Verilog-Perl like Netlist
Testing:
Capture all inputs into global "rerun it" file
Code to make wrapper that sets signals, so can do comparison checks
New random program generator
Better graph viewer with search and zoom
Port and test against opencores.org code
Usability:
Better reporting of unopt problems, including what lines of code
Report more errors (all of them?) before exiting [Eugene Weber]
Internal Code:
Eliminate the AstNUser* passed to all visitors; its only needed in V3Width,
and removing it will speed up and simplify all the other code.
V3Graph should be templated container type, taking in Vertex + Edge types
Performance:
Constant propagation
Extra cleaning AND: 1 & ((VARREF >> 1) | ((&VARREF >> 1) & VARREF))
Extra shift (perhaps due to clean): if (1 & CAST (VARREF >> #))
Gated clock and latch conversion to flops. [JeanPaul Vanitegem]
Could propagate the AND into pos/negedges and let domaining optimize.
Negedge reset
Switch to remove negedges that don't matter
Can't remove async resets from control flops (like in syncronizers)
If all references to array have a constant index, blow up into separate signals-per-index
Multithreaded execution
Bit-multiply for faster bit swapping and a=b[1,3,2] random bit reorderings.
Move _last sets and all other combo logic inside master
if() that triggers on all possible sense items
Rewrite and combine V3Life, V3Subst
If block temp only ever set in one place to constant, propagate it
Used in t_mem for array delayed assignments
Replace variables if set later in same cfunc branch
See for example duplicate sets of _narrow in cycle 90/91 of t_select_plusloop
Same assignment on both if branches
"if (a) { ... b=2; } else { ... b=2;}" -> "b=2; if ..."
Careful though, as b could appear in the statement or multiple times in statement
(Could just require exatly two 'b's in statement)
Simplify XOR/XNOR/AND/OR bit selection trees
Foo = A[1] ^ A[2] ^ A[3] etc are better as ^ ( A & 32'b...1110 )
Combine variables into wider elements
Parallel statements on different bits should become single signal
Variables that are always consumed in "parallel" can be joined
Duplicate assignments in gate optimization
Common to have many separate posedge blocks, each with identical
reset_r <= rst_in
*If signal is used only once (not counting trace), always gate substitute
Don't merge if any combining would form circ logic (out goes back to in)
Multiple assignments each bit can become single assign with concat
Make sure a SEL of a CONCAT can get the single bit back.
Usually blocks/values
Enable only after certain time, so VL_TIME_I(32) > 0x1e gets eliminated out
Better ordering of a<=b, b<=c, put all refs to 'b' next to each other to optimize caching
Allow Split of case statements without a $display/$stop
I-cache packing improvements (what/how?)
Data cache organization (order of vars in class)
First have clocks,
then bools instead of uint32_t's
then based on what sense list they come from, all outputs, then all inputs
finally have any signals part of a "usually" block, or constant.
Rather then tracking widths, have a MSB...LSB of this expression
(or better, a bitmask of bits relevant in this expression)
Track recirculation and convert into clock-enables
Clock enables should become new clocking domains for speed
If floped(a) & flopped(b) and no other a&b, then instead flop(a&b).
Sort by output bitselects so can combine more assignments (see DDP example dx_dm signal)
All of the temp vars that get set, exp pre_ vars and never feedback
(not flops) don't need to be stored in the structs, but instead can
be per-invocation, and even better register-colored-like to reuse
the space. This will greatly reduce the data footprint.
//**********************************************************************
//* Detailed notes on 'todo' features
Selectable SystemC types based on widths (see notes below)
Statements:
verilator sc_type uint32_t {override specific I/O signals}
verilator sc_typedef width 1 bool
verilator sc_typedef width 2-32 uint32_t
verilator sc_typedef width 33-64 uint64_t
verilator sc_typedef width 65+ sc_bv<width> //<< programmable width
Replace `systemc_clock, --pins64
Have accessor function with type overloading to get or set the pin value.
(Get rid of getdatap mess?)
//**********************************************************************
//* Eventual tristate bus Stuff allowed (old verilator)
1) Tristate assignments must be continuous assignments
The RHS of a tristate assignment can be the following
a) a node (tristate or non-tristate)
b) a constant (must be all or no z's)
x'b0, x'bz, x{x'bz}, x{x'b0} -> are allowed
c) a conditional whose possible values are (a) or (b)
2) One can lose that fact that a node is a tristate node. This happens
if a tristate node is assigned to a 'standard' node, or is used on
RHS of a conditional. The following infer tristate signals:
a) inout <SIGNAL>
b) tri <SIGNAL>
c) assigning to 'Z' (maybe through a conditional)
Note: tristate-ness of an output port determined only by
statements in the module (not the instances it calls)
4) Tristate variables can't be multidimensional arrays
5) Only check tristate contention between modules (not within!)
6) Only simple compares with 'Z' are allowed (===)
+3921 -837
View File
File diff suppressed because it is too large Load Diff
+300
View File
@@ -0,0 +1,300 @@
#!/usr/bin/env perl
######################################################################
#
# Copyright 2003-2020 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.
#
######################################################################
require 5.006_001;
use warnings;
use Getopt::Long;
use FindBin qw($RealBin $RealScript);
use IO::File;
use Pod::Usage;
use Cwd qw(abs_path getcwd);
use strict;
use vars qw($Debug @Opt_Verilator_Sw);
#######################################################################
#######################################################################
# main
autoflush STDOUT 1;
autoflush STDERR 1;
$Debug = 0;
# No arguments can't do anything useful. Give help
if ($#ARGV < 0) {
pod2usage(-exitstatus=>2, -verbose=>0);
}
# We sneak a look at the flags so we can do some pre-environment checks
# All flags will hit verilator...
foreach my $sw (@ARGV) {
$sw = "'$sw'" if $sw =~ m![^---a-zA-Z0-9_/\\:.+]!;
push @Opt_Verilator_Sw, $sw;
}
Getopt::Long::config("no_auto_abbrev","pass_through");
if (! GetOptions (
# Major operating modes
"help" => \&usage,
"debug:s" => \&debug,
# "version!" => \&version, # Also passthru'ed
# Additional parameters
"<>" => sub {}, # Ignored
)) {
pod2usage(-exitstatus=>2, -verbose=>0);
}
# Normal, non gdb
run(verilator_coverage_bin()
." ".join(' ',@Opt_Verilator_Sw));
#----------------------------------------------------------------------
sub usage {
pod2usage(-verbose=>2, -exitval=>0, -output=>\*STDOUT);
}
sub debug {
shift;
my $level = shift;
$Debug = $level||3;
}
#######################################################################
#######################################################################
# Builds
sub verilator_coverage_bin {
my $bin = "";
# Use VERILATOR_ROOT if defined, else assume verilator_bin is in the search path
my $basename = ($ENV{VERILATOR_COVERAGE_BIN}
|| "verilator_coverage_bin_dbg");
if (defined($ENV{VERILATOR_ROOT})) {
my $dir = $ENV{VERILATOR_ROOT};
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 {
if (-x "$RealBin/$basename"
|| -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;
}
#######################################################################
#######################################################################
# Utilities
sub run {
# Run command, check errors
my $command = shift;
$! = undef; # Cleanup -x
print "\t$command\n" if $Debug>=3;
system($command);
my $status = $?;
if ($status) {
if ($! =~ /no such file or directory/i) {
warn "%Error: verilator_coverage: Misinstalled, or VERILATOR_ROOT might need to be in environment\n";
}
if ($Debug) { # For easy rerunning
warn "%Error: export VERILATOR_ROOT=".($ENV{VERILATOR_ROOT}||"")."\n";
warn "%Error: $command\n";
}
if ($status & 127) {
if (($status & 127) == 8 || ($status & 127) == 11) { # SIGFPA or SIGSEGV
warn "%Error: Verilator_coverage internal fault, sorry.\n" if !$Debug;
} elsif (($status & 127) == 6) { # SIGABRT
warn "%Error: Verilator_coverage aborted.\n" if !$Debug;
} else {
warn "%Error: Verilator_coverage threw signal $status.\n" if !$Debug;
}
}
if ($status != 256 || $Debug) { # i.e. not normal exit(1)
warn "%Error: Command Failed $command\n";
}
exit $! if $!; # errno
exit $? >> 8 if $? >> 8; # child exit status
exit 255; # last resort
}
}
#######################################################################
#######################################################################
package main;
__END__
=pod
=head1 NAME
verilator_coverage - Verilator coverage analyzer
=head1 SYNOPSIS
verilator_coverage --help
verilator_coverage --version
verilator_coverage --annotate <obj>
verilator_coverage -write merged.dat -read <datafiles>...
verilator_coverage -write-info merged.info -read <datafiles>...
Verilator_coverage processes Verilator coverage reports.
With --anotate, it reads the specified data file and generates annotated
source code with coverage metrics annotated. If multiple coverage points
exist on the same line, additional lines will be inserted to report the
additional points.
Additional Verilog-standard arguments specify the search paths necessary to
find the source code that the coverage analysis was performed on.
To get correct coverage percentages, you may wish to read logs/coverage.dat
into Emacs and do a M-x keep-lines to include only those statistics of
interest.
For Verilog conditions that should never occur, you should add a $stop
statement. This will remove the coverage during the next build.
=head1 ARGUMENTS
=over 4
=item I<filename>
Specify input data file, may be repeated to read multiple inputs. If no
data file is specified, by default coverage.dat is read.
=item --annotate I<output_directory>
Sprcifies the directory name that source files with annotated coverage data
should be written to.
=item --annotate-all
Specifies all files should be shown. By default, only those source files
which have low coverage are written to the output directory.
=item --annotate-min I<count>
Specifies the minimum occurrence count that should be flagged if the
coverage point does not include a specified threshold. Defaults to 10.
=item --help
Displays this message and program version and exits.
=item --rank
Print an experimental report listing the relative importance of each test
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
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
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
all tests are run in the order of highest to lowest rank.
=item --unlink
When using --write to combine coverage data, unlink all input files after
the output has been created.
=item --version
Displays program version and exits.
=item --write I<filename>
Specifies the aggregate coverage results, summed across all the files,
should be written to the given filename in verilator_coverage data format.
This is useful in scripts to combine many sequential runs into one master
coverage file.
=item --write-info I<filename.info>
Specifies the aggregate coverage results, summed across all the files,
should be written to the given filename in C<lcov> .info format.
This may be used to use C<lcov> to aggregate or generate reports.
The info format loses data compared to the Verilator coverage data format;
the info will all forms of coverage converted to line style coverage, and
if there are multiple coverage points on a single line, the minimum
coverage across those points will be used to report coverage of the line.
=back
=head1 VERILOG ARGUMENTS
The following arguments are compatible with GCC, VCS and most Verilog
programs.
=over 4
=item +libext+I<ext>+I<ext>...
Defines the extensions for Verilog files.
=item +define+I<var>+I<value>
=item -DI<var>=I<value>
Defines the given variable.
=item +incdir+I<dir>
=item -II<dir>
Specifies a directory for finding include files.
=item -f I<file>
Specifies a file containing additional command line arguments.
=item -y I<dir>
Specifies a module search directory.
=back
=head1 DISTRIBUTION
The latest version is available from L<https://verilator.org>.
Copyright 2003-2020 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.
SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
=head1 AUTHORS
Wilson Snyder <[email protected]>
=head1 SEE ALSO
C<verilator>, C<lcov>
L<verilator_coverage --help> which is the source for this document.
=cut
######################################################################
+104 -42
View File
@@ -1,19 +1,29 @@
: # -*-Mode: perl;-*- use perl, wherever it is
eval 'exec perl -wS $0 ${1+"$@"}'
if 0;
#!/usr/bin/env perl
# See copyright, etc in below POD section.
######################################################################
require 5.006_001;
use warnings;
use Getopt::Long;
use IO::File;
use Pod::Usage;
use strict;
use vars qw ($Debug);
use vars qw($Debug);
#======================================================================
# Old version 1 dump nodes with no dtypep's
our %Ver1_Non_Dtyped = map {$_ => 1} qw(
ACTIVE ALWAYS ALWAYSPOST ALWAYSPUBLIC ATTROF BEGIN BREAK CASE CASEITEM
CCALL CELL CELLINLINE CFILE CFUNC CHANGEDET CLOCKING COMMENT CONTINUE
COVERDECL COVERINC COVERTOGGLE CRETURN CSTMT DEFPARAM DISABLE DISPLAY DOT
DPIEXPORT FCLOSE FFLUSH FINAL FINISH FOPEN GENCASE GENERATE GENFOR GENIF
IF IMPLICIT INITARRAY INITIAL JUMPGO JUMPLABEL MODULE NETLIST
NOTFOUNDMODULE PACKAGE PACKAGEIMPORT PARSEREF PIN PORT PRAGMA PRIMITIVE
PSLASSERT PSLCOVER PSLDEFCLOCK PULL RANGE READMEM REPEAT RETURN SCCTOR
SCDTOR SCHDR SCIMP SCIMPHDR SCINT SCOPE SELBIT SELEXTRACT SELMINUS
SELPLUS SENGATE SENITEM SENTREE SFORMAT SFORMATF STOP SYSIGNORE SYSTEMT
TASK TASKREF TEXT TOPSCOPE TYPEDEFFWD TYPETABLE UCSTMT UDPTABLE
UDPTABLELINE UNTILSTABLE VASSERT WHILE );
#======================================================================
# main
@@ -24,12 +34,12 @@ my $Opt_B;
my $Opt_Lineno = 1;
autoflush STDOUT 1;
autoflush STDERR 1;
Getopt::Long::config ("no_auto_abbrev");
if (! GetOptions (
"help" => \&usage,
"debug" => \&debug,
"<>" => \&parameter,
"lineno!" => \$Opt_Lineno,
Getopt::Long::config("no_auto_abbrev");
if (! GetOptions(
"help" => \&usage,
"debug" => \&debug,
"<>" => \&parameter,
"lineno!" => \$Opt_Lineno,
)) {
die "%Error: Bad usage, try 'verilator_difftree --help'\n";
}
@@ -41,9 +51,9 @@ defined $Opt_B or die "%Error: No new diff filename\n";
-e $Opt_B or die "%Error: No new diff filename found: $Opt_B\n";
if (-d $Opt_A && -d $Opt_B) {
diff_dir ($Opt_A, $Opt_B);
diff_dir($Opt_A, $Opt_B);
} elsif (-f $Opt_A && -f $Opt_B) {
diff_file ($Opt_A, $Opt_B);
diff_file($Opt_A, $Opt_B);
} else {
die "%Error: Mix of files and dirs\n";
}
@@ -55,49 +65,98 @@ sub diff_dir {
my %files;
foreach my $fn (glob("$a/*.tree")) {
(my $base = $fn) =~ s!.*/!!;
$files{$base}{a} = $fn;
(my $base = $fn) =~ s!.*/!!;
$files{$base}{a} = $fn;
}
foreach my $fn (glob("$b/*.tree")) {
(my $base = $fn) =~ s!.*/!!;
$files{$base}{b} = $fn;
(my $base = $fn) =~ s!.*/!!;
$files{$base}{b} = $fn;
}
my $any;
foreach my $base (sort (keys %files)) {
my $a = $files{$base}{a};
my $b = $files{$base}{b};
next if !$a || !$b;
print "="x70,"\n";
print "= $a <-> $b\n";
diff_file($a,$b);
my $a = $files{$base}{a};
my $b = $files{$base}{b};
next if !$a || !$b;
print "="x70,"\n";
print "= $a <-> $b\n";
diff_file($a,$b);
$any = 1;
}
$any or warn("%Warning: No .tree files found that have similar base names:\n "
.join("\n ", sort keys %files),"\n");
}
sub diff_file {
my $a = shift;
my $b = shift;
# Compare the two tree files
my $tmp_a = "/tmp/$$.a";
my $tmp_b = "/tmp/$$.b";
(my $short_a = $a) =~ s/[^a-zA-Z0-9.]+/_/g;
(my $short_b = $b) =~ s/[^a-zA-Z0-9.]+/_/g;
my $tmp_a = "/tmp/${$}_${short_a}.a";
my $tmp_b = "/tmp/${$}_${short_b}.b";
filter ($a, $tmp_a);
filter ($b, $tmp_b);
system("diff $tmp_a $tmp_b");
my $vera = version_from($a);
my $verb = version_from($b);
my $verCvt = (($vera < 0x3900 && $verb >= 0x3900)
|| ($vera >= 0x3900 && $verb < 0x3900));
filter($a, $tmp_a, $verCvt);
filter($b, $tmp_b, $verCvt);
system("diff -u $tmp_a $tmp_b");
unlink $tmp_a;
unlink $tmp_b;
}
sub version_from {
my $fn = shift;
# Return dump format
my $f1 = IO::File->new ($fn) or die "%Error: $! $fn,";
while (defined (my $line=$f1->getline())) {
last if $. > 10;
return hex $1 if $line =~ /\(format (0x[0-9.]+)\)/;
}
return 1.0;
}
sub filter {
my $fn1 = shift;
my $fn2 = shift;
my $verCvt = shift;
# Remove hex numbers before diffing
my $f1 = IO::File->new ($fn1) or die "%Error: $! $fn1,";
my $f2 = IO::File->new ($fn2,"w") or die "%Error: $! $fn2,";
while (defined (my $line=$f1->getline())) {
next if $line =~ / This=/;
$line =~ s/0x[a-f0-9]+/0x/g;
$line =~ s/<e[0-9]+\#?>/<e>/g;
$line =~ s/{\d+}/{}/g if !$Opt_Lineno;
print $f2 $line;
same_line:
next if $line =~ / This=/;
$line =~ s/0x[a-f0-9]+/0x/g;
$line =~ s/<e[0-9]+\#?>/<e>/g;
$line =~ s/{[a-z]*\d+}/{}/g if !$Opt_Lineno;
if ($verCvt) {
next if $line =~ /^ NETLIST/;
$line =~ s!\@dt=0x\(G?/?([^)]+)\)!$1!g; # NEW: @dt -> OLD: non @dt format
# # Below Ver1_Non_Dtyped may replace above further
if ($line =~ /: ([A-Z]+) /) {
my $type = $1;
next if $type =~ 'DTYPE';
if ($type eq 'TYPETABLE' || $type eq 'RANGE') {
$line =~ /^(\s+\S+:) /; my $prefix = $1;
while (defined ($line=$f1->getline())) {
next if $line =~ /^\s+[a-z]/; # Table body
next if $line =~ /^${prefix}[0-9]:/;
goto same_line;
}
next;
}
if ($Ver1_Non_Dtyped{$type}) {
$line =~ s! w[0-9]+!!g;
}
}
$line =~ s!\@dt=0$!NoW!g; # NEW: dt=null -> common format
$line =~ s!\@dt=0 !NoW !g; # NEW: dt=null -> common format
$line =~ s! s?w0$! NoW!g; # OLD: no width -> common format
$line =~ s! s?w0 ! NoW !g; # OLD: no width -> common format
}
print $f2 $line;
}
$f1->close;
$f2->close;
@@ -106,8 +165,8 @@ sub filter {
#----------------------------------------------------------------------
sub usage {
pod2usage(-verbose=>2, -exitval => 2);
exit (1);
pod2usage(-verbose=>2, -exitval=>0, -output=>\*STDOUT);
exit(1); # Unreachable
}
sub debug {
@@ -117,11 +176,11 @@ sub debug {
sub parameter {
my $param = shift;
if (!defined $Opt_A) {
$Opt_A = $param;
$Opt_A = $param;
} elsif (!defined $Opt_B) {
$Opt_B = $param;
$Opt_B = $param;
} else {
die "%Error: Unknown parameter: $param\n";
die "%Error: Unknown parameter: $param\n";
}
}
@@ -172,11 +231,14 @@ Do not show differences in line numbering.
=head1 DISTRIBUTION
The latest version is available from L<http://www.veripool.org/verilator>.
The latest version is available from L<https://verilator.org>.
Copyright 2005-2009 by Wilson Snyder. This package is free software; you
Copyright 2005-2020 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 or the Perl Artistic License.
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
=head1 AUTHORS
@@ -190,5 +252,5 @@ C<verilator>
######################################################################
### Local Variables:
### compile-command: "$V4/bin/verilator_difftree $V4/test_c/obj_dir/V*_03_*.tree $V4N/test_c/obj_dir/V*_03_*.tree"
### compile-command: "$V4/bin/verilator_difftree {$V4D,$V4}/test_regress/obj_dir/t_EXAMPLE/V*_03_*.tree"
### End:
+561
View File
@@ -0,0 +1,561 @@
#!/usr/bin/env perl
# See copyright, etc in below POD section.
######################################################################
use warnings;
use strict;
use Getopt::Long;
use IO::File;
use Pod::Usage;
use vars qw($Debug);
$Debug = 0;
my $Opt_File;
my $Opt_Time_Per_Char = 0; # rdtsc ticks per char in gantt chart, 0=auto
my $opt_vcd = "profile_threads.vcd";
our %Threads;
our %Mtasks;
our %Global;
autoflush STDOUT 1;
autoflush STDERR 1;
Getopt::Long::config("no_auto_abbrev");
if (! GetOptions(
"help" => \&usage,
"scale=i" => \$Opt_Time_Per_Char,
"debug" => sub { $Debug = 1; },
"vcd=s" => \$opt_vcd,
"no-vcd!" => sub { $opt_vcd = undef; },
"<>" => \&parameter,
)) {
die "%Error: Bad usage, try 'verilator_gantt --help'\n";
}
$Opt_File = "profile_threads.dat" if !defined $Opt_File;
process($Opt_File);
write_vcd($opt_vcd) if defined $opt_vcd;
exit(0);
#######################################################################
sub usage {
pod2usage(-verbose=>2, -exitval=>0, -output=>\*STDOUT);
exit(1); # Unreachable
}
sub parameter {
my $param = shift;
if (!defined $Opt_File) {
$Opt_File = $param;
} else {
die "%Error: Unknown parameter: $param\n";
}
}
#######################################################################
sub process {
my $filename = shift;
read_data($filename);
report();
}
#######################################################################
sub read_data {
my $filename = shift;
%Global = (rdtsc_cycle_time => 0);
my $fh = IO::File->new ($filename) or die "%Error: $! $filename,";
while (my $line = $fh->getline) {
if ($line =~ m/VLPROF mtask\s(\d+)\sstart\s(\d+)\send\s(\d+)\selapsed\s(\d+)\spredict_time\s(\d+)\scpu\s(\d+)\son thread (\d+)/) {
my $mtask = $1;
my $start = $2;
my $end = $3;
my $elapsed_time = $4;
my $predict_time = $5;
my $cpu = $6;
my $thread = $7;
$Threads{$thread}{$start}{mtask} = $mtask;
$Threads{$thread}{$start}{end} = $end;
$Threads{$thread}{$start}{cpu} = $cpu;
if (!exists $Mtasks{$mtask}{elapsed}) {
$Mtasks{$mtask}{elapsed} = 0;
}
$Mtasks{$mtask}{elapsed} += $elapsed_time;
$Mtasks{$mtask}{predict} = $predict_time;
$Mtasks{$mtask}{end} = max($Mtasks{$mtask}{end}, $end);
}
elsif ($line =~ /^VLPROFTHREAD/) {}
elsif ($line =~ m/VLPROF arg\s+(\S+)\+([0-9.])\s*$/
|| $line =~ m/VLPROF arg\s+(\S+)\s+([0-9.])\s*$/) {
$Global{args}{$1} = $2;
}
elsif ($line =~ m/VLPROF stat\s+(\S+)\s+([0-9.]+)/) {
$Global{stats}{$1} = $2;
}
elsif ($line =~ /^#/) {}
elsif ($Debug) {
chomp $line;
print "Unk: $line\n";
}
# TODO -- this is parsing text printed by a client.
# Really, verilator proper should generate this
# if it's useful...
if ($line =~ m/rdtsc time = (\d+) ticks/) {
$Global{rdtsc_cycle_time} = $1;
}
}
}
sub report {
print "Verilator Gantt report\n";
print "\nArgument settings:\n";
foreach my $arg (sort keys %{$Global{args}}) {
my $plus = ($arg =~ /^\+/) ? "+" : " ";
printf " %s%s%d\n", $arg, $plus, $Global{args}{$arg};
}
my $nthreads = scalar keys %Threads;
$Global{cpus} = {};
foreach my $thread (keys %Threads) {
# Make potentially multiple characters per column
foreach my $start (keys %{$Threads{$thread}}) {
my $cpu = $Threads{$thread}{$start}{cpu};
my $elapsed = $Threads{$thread}{$start}{end} - $start;
$Global{cpus}{$cpu}{cpu_time} += $elapsed;
}
}
my $mt_mtask_time = 0;
my $long_mtask_time = 0;
my $last_end = 0;
foreach my $mtask (keys %Mtasks) {
$mt_mtask_time += $Mtasks{$mtask}{elapsed};
$last_end = max($last_end, $Mtasks{$mtask}{end});
$long_mtask_time = max($long_mtask_time, $Mtasks{$mtask}{elapsed});
}
$Global{last_end} = $last_end;
report_graph();
# If we know cycle time in the same (rdtsc) units,
# this will give us an actual utilization number,
# (how effectively we keep the cores busy.)
#
# It also gives us a number we can compare against
# serial mode, to estimate the overhead of data sharing,
# which will show up in the total elapsed time. (Overhead
# of synchronization and scheduling should not.)
print "\nAnalysis:\n";
printf " Total threads = %d\n", $nthreads;
printf " Total mtasks = %d\n", scalar(keys %Mtasks);
printf " Total cpus used = %d\n", scalar(keys %{$Global{cpus}});
printf " Total yields = %d\n", $Global{stats}{yields};
printf " Total eval time = %d rdtsc ticks\n", $Global{last_end};
printf " Longest mtask time = %d rdtsc ticks\n", $long_mtask_time;
printf " All-thread mtask time = %d rdtsc ticks\n", $mt_mtask_time;
my $long_efficiency = $long_mtask_time/($Global{last_end});
printf " Longest-thread efficiency = %0.1f%%\n", $long_efficiency*100;
my $mt_efficiency = $mt_mtask_time/($Global{last_end}*$nthreads);
printf " All-thread efficiency = %0.1f%%\n", $mt_efficiency*100;
printf " All-thread speedup = %0.1f\n", $mt_efficiency*$nthreads;
if ($Global{rdtsc_cycle_time} > 0) {
my $ut = $mt_mtask_time / $Global{rdtsc_cycle_time};
print "tot_mtask_cpu=$mt_mtask_time cyc=$Global{rdtsc_cycle_time} ut=$ut\n";
}
my @p2e_ratios;
my $min_p2e = 1000000;
my $min_mtask;
my $max_p2e = -1000000;
my $max_mtask;
foreach my $mtask (sort keys %Mtasks) {
if ($Mtasks{$mtask}{elapsed} > 0) {
if ($Mtasks{$mtask}{predict} == 0) {
$Mtasks{$mtask}{predict} = 1; # don't log(0) below
}
my $p2e_ratio = log( $Mtasks{$mtask}{predict} / $Mtasks{$mtask}{elapsed} );
#print "log(p2e $mtask) = $p2e_ratio (predict $Mtasks{$mtask}{predict}, elapsed $Mtasks{$mtask}{elapsed})\n";
push @p2e_ratios, $p2e_ratio;
if ($p2e_ratio > $max_p2e) {
$max_p2e = $p2e_ratio;
$max_mtask = $mtask;
}
if ($p2e_ratio < $min_p2e) {
$min_p2e = $p2e_ratio;
$min_mtask = $mtask;
}
}
}
print "\nStatistics:\n";
print " min log(p2e) = $min_p2e from mtask $min_mtask (predict $Mtasks{$min_mtask}{predict}, elapsed $Mtasks{$min_mtask}{elapsed})\n";
print " max log(p2e) = $max_p2e from mtask $max_mtask (predict $Mtasks{$max_mtask}{predict}, elapsed $Mtasks{$max_mtask}{elapsed})\n";
my $stddev = stddev(\@p2e_ratios);
my $mean = mean(\@p2e_ratios);
print " mean = " . ($mean) . "\n";
print " stddev = " . ($stddev) . "\n";
print " e ^ stddev = " . exp($stddev). "\n";
print "\n";
}
sub report_graph {
my $time_per = $Opt_Time_Per_Char;
if ($time_per == 0) {
$time_per = ($Global{last_end} / 40); # Start with 40 columns
while ($time_per > 10) {
my ($graph, $conflicts) = _make_graph($time_per);
last if !$conflicts;
$time_per = int($time_per/2);
}
# One more step so we can fit more labels
$time_per = int($time_per/2);
}
my ($graph, $conflicts) = _make_graph($time_per);
print "\nThread gantt graph:\n";
print " Legend: One character width = $time_per rdtsc ticks\n";
print " Legend: '&' = multiple mtasks in this period (character width)\n";
my $scale = " <-".$Global{last_end}." rdtsc total";
for (my $col = length($scale); # -2 for '->' below
$col < ($Global{last_end}/$time_per); ++$col) {
$scale .= "-";
}
print " $scale->\n";
foreach my $thread (sort keys %{$graph}) {
print " t: ";
_print_graph_line($graph->{$thread}, '');
}
}
sub _make_graph {
my $time_per = shift;
my $graph = {}; # {thread}{column}{char=>'x' or chars=>#}
my $conflicts = 0;
foreach my $thread (keys %Threads) {
# Make potentially multiple characters per column
foreach my $start (sort {$a <=> $b} keys %{$Threads{$thread}}) {
my $end = $Threads{$thread}{$start}{end};
my $mtask = $Threads{$thread}{$start}{mtask};
my $cpu = $Threads{$thread}{$start}{cpu};
my $startcol = _time_col($time_per, $start);
my $endcol = _time_col($time_per, $end);
my $label = "[";
$label .= "$cpu"; # Maybe make optional in future
my $width = $endcol - $startcol + 1;
while (length($label) < ($width-1)) { # -1 for ']'
$label .= "-";
}
$label .= "]";
$graph->{$thread}[$startcol]{char} .= $label;
}
if ($Debug) {
print "# Multicol: "; _print_graph_line($graph->{$thread}, '|');
}
# Expand line to one char per column
for (my $col = 0; $col <= $#{$graph->{$thread}}; ++$col) {
if (my $chars = $graph->{$thread}[$col]{char}) {
my $ok = 1;
for (my $coladd = 1; $coladd<length($chars); ++$coladd) {
if ($graph->{$thread}[$col + $coladd]{char}) {
$ok = 0; last;
}
}
if (!$ok) {
if ($chars =~ /\[.*\[/) { # Two begins or more
$conflicts++;
$graph->{$thread}[$col]{char} = "&";
} else {
$graph->{$thread}[$col]{char} = "[";
}
for (my $coladd = 1; $coladd<length($chars); ++$coladd) {
if ($graph->{$thread}[$col + $coladd]{char}) {
last;
} else {
$graph->{$thread}[$col + $coladd]{char} = 'x';
}
}
} else {
my $coladd = 0;
foreach my $char (split //, $chars) {
$graph->{$thread}[$col+$coladd]{char} = $char;
++$coladd;
}
}
}
}
if ($Debug) {
print "# Singlcol: "; _print_graph_line($graph->{$thread}, '|');
}
}
print "# Conflicts $conflicts\n" if $Debug;
return ($graph, $conflicts);
}
sub _print_graph_line {
my $graph_thread = shift;
my $sep = shift;
for (my $col = 0; $col <= $#{$graph_thread}; ++$col) {
my $c = $graph_thread->[$col]{char}; $c=' ' if !defined $c;
print $c, $sep;
}
print "\n";
}
sub _time_col {
my $time_per = shift;
my $time = shift;
return int($time/$time_per);
}
#######################################################################
sub write_vcd {
my $filename = shift;
print "Writing $filename\n";
my $fh = IO::File->new(">$filename") or die "%Error: $! $filename,";
my $vcd = {values => {}, # {<time>}{<code>} = value
sigs => {}, # {<module>}{<sig}} = code
code => 0,
};
my %parallelism;
foreach my $thread (keys %Threads) {
my $mcode = ($vcd->{sigs}{threads}{"thread${thread}_mtask"} ||= $vcd->{code}++);
foreach my $start (sort {$a <=> $b} keys %{$Threads{$thread}}) {
my $end = $Threads{$thread}{$start}{end};
my $mtask = $Threads{$thread}{$start}{mtask};
my $cpu = $Threads{$thread}{$start}{cpu};
$vcd->{values}{$start}{$mcode} = $mtask;
$vcd->{values}{$end}{$mcode} = undef;
$parallelism{$start}++;
$parallelism{$end}--;
my $ccode = $vcd->{sigs}{cpus}{"cpu${cpu}_thread"} ||= $vcd->{code}++;
$vcd->{values}{$start}{$ccode} = $thread;
$vcd->{values}{$end}{$ccode} = undef;
my $mcode = $vcd->{sigs}{mtasks}{"mtask${mtask}_cpu"} ||= $vcd->{code}++;
$vcd->{values}{$start}{$mcode} = $cpu;
$vcd->{values}{$end}{$mcode} = undef;
}
}
{
my $pcode = ($vcd->{sigs}{Stats}{"parallelism"} ||= $vcd->{code}++);
my $value = 0;
foreach my $time (sort {$a<=>$b} keys %parallelism) {
$value += $parallelism{$time};
$vcd->{values}{$time}{$pcode} = $value;
}
}
$fh->print('$version Generated by verilator_gantt $end'."\n");
$fh->print('$timescale 1ns $end'."\n");
$fh->print("\n");
my %all_codes;
$fh->print(' $scope module gantt $end'."\n");
foreach my $module (sort keys %{$vcd->{sigs}}) {
$fh->printf(' $scope module %s $end'."\n", $module);
foreach my $sig (sort keys %{$vcd->{sigs}{$module}}) {
my $code = $vcd->{sigs}{$module}{$sig};
$fh->printf(' $var wire 32 v%x %s [31:0] $end'."\n",
$code, $sig);
$all_codes{$code} = 1;
}
$fh->print(' $upscope $end'."\n");
}
$fh->print(' $upscope $end'."\n");
$fh->print('$enddefinitions $end'."\n");
$fh->print("\n");
my $first = 1;
foreach my $time (sort {$a <=> $b} keys %{$vcd->{values}}) {
if ($first) {
$first = 0;
# Start with Z for any signals without time zero data
foreach my $code (keys %all_codes) {
if (!defined $vcd->{values}{$time}{$code}) {
$vcd->{values}{$time}{$code} = undef;
}
}
}
$fh->printf("#%d\n", $time);
foreach my $code (sort keys %{$vcd->{values}{$time}}) {
my $value = $vcd->{values}{$time}{$code};
if (defined $value) {
$fh->printf("b%b v%x\n", $value, $code);
} else {
$fh->printf("bz v%x\n", $code);
}
}
}
}
#######################################################################
# Similar to Statistics::Basic functions, but avoid a package dependency
sub max {
my $n = $_[0]; shift;
while (defined $_[0]) {
$n = $_[0] if !defined $n || $_[0] > $n;
shift;
}
return $n;
}
sub mean {
my $arrayref = shift;
my $n = 0;
my $sum = 0;
foreach my $v (@$arrayref) {
$sum += $v;
$n++;
}
return undef if !$n;
return $sum/$n;
}
sub stddev {
my $arrayref = shift;
my $n = 0;
my $sum = 0;
my $sumsq = 0;
foreach my $v (@$arrayref) {
$sum += $v;
$sumsq += $v**2;
$n++;
}
return undef if !$n;
return sqrt(($sumsq/$n) - ($sum/$n)**2);
}
#######################################################################
__END__
=pod
=head1 NAME
verilator_gantt - Create Gantt chart of multi-threaded execution
=head1 SYNOPSIS
Creates a visual representation to help analyze Verilator multithreaded
simulation performance, by showing when each macro-task starts and ends,
and showing when each thread is busy or idle.
The generated Gantt chart has time on the X-axis. Times shown are to the
scale printed, i.e. a certain about of time for each character width. The
Y-axis shows threads, each thread's execution is shown on one line. That
line shows "[" at the position in time when it executes.
Following the "[" is the cpu number the task executed on, followed by zero
or more "-" to make the width of the characters match the scaled execution
time, followed by a "]". If the scale is too small, the cpu number and
mtask number will not be printed. If the scale is very small, a "&"
indicates multiple mtasks started at that time position.
Also creates a value change dump (VCD) format dump file which may be viewed
in a waveform viewer (e.g. C<GTKWave>). See below.
=head1 USAGE
Build with --prof-threads.
Run a sim with +verilator+prof+threads+window 2.
This will create profile_threads.dat.
Then run:
verilator_gantt profile_threads.dat
The report will be printed on standard output, this also generates
profile_threads.vcd
View profile_threads.vcd in a waveform viewer.
=head1 VCD SIGNALS
In waveforms there are the following signals. Most signals the "decimal"
format will remove the leading zeros and make the traces easier to read.
parallelism: The number of mtasks active at this time, for best performance
this will match the thread count. You may want to use an "analog step"
format to view this signal.
cpu#_thread: For the given CPU number, the thread number executing.
mtask#_cpu; For the given mtask id, the CPU it is executing on.
thread#_mtask: For the given thread number, the mtask id executing.
=head1 ARGUMENTS
=over 4
=item I<filename>
The filename to read data from, defaults to "profile_threads.dat".
=item --help
Displays this message and program version and exits.
=item --scale I<n>
On the X-axis of the generated Gantt chart, each character represents this
many time units. (On x86, time units are rdtsc ticks.) Defaults to 0,
which will automatically compute a reasonable scale where no two mtasks
need to fit into same character width's worth of scaled time.
=item --no-vcd
=item --vcd I<filename>
Set output filename for vcd dump, or disable. Default is
verilator_gantt.vcd.
=back
=head1 DISTRIBUTION
The latest version is available from L<https://verilator.org>.
Copyright 2018-2020 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
=head1 AUTHORS
Wilson Snyder <[email protected]>
=head1 SEE ALSO
C<verilator>
=cut
######################################################################
### Local Variables:
### compile-command: "$V4/bin/verilator_gantt $V4/test_regress/obj_vltmt/t_gantt/vlt_sim.log"
### End:
+12 -7
View File
@@ -1,15 +1,20 @@
: # -*-Mode: perl;-*- use perl, wherever it is
eval 'exec perl -wS $0 ${1+"$@"}'
if 0;
#!/usr/bin/env perl
# DESCRIPTION: Print include statements for each ARGV
#
# Copyright 2003-2009 by Wilson Snyder. This program is free software; you can
# redistribute it and/or modify it under the terms of either the GNU
# General Public License or the Perl Artistic License.
# Copyright 2003-2020 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.005;
use warnings;
print "// DESCR"."IPTION: Generated by verilator_includer via makefile\n";
foreach my $param (@ARGV) {
print "#include \"$param\"\n"
if ($param =~ /^-D([^=]+)=(.*)/) {
print "#define $1 $2\n"
} else {
print "#include \"$param\"\n"
}
}
+110 -87
View File
@@ -1,6 +1,4 @@
: # -*-Mode: perl;-*- use perl, wherever it is
eval 'exec perl -wS $0 ${1+"$@"}'
if 0;
#!/usr/bin/env perl
# See copyright, etc in below POD section.
######################################################################
@@ -11,7 +9,7 @@ use IO::File;
use Pod::Usage;
eval { use Data::Dumper; $Data::Dumper::Indent = 1; }; # Debug, ok if missing
use strict;
use vars qw ($Debug);
use vars qw($Debug);
#======================================================================
@@ -23,12 +21,12 @@ $Debug = 0;
my $Opt_File;
autoflush STDOUT 1;
autoflush STDERR 1;
Getopt::Long::config ("no_auto_abbrev");
if (! GetOptions (
"help" => \&usage,
"debug" => \&debug,
"<>" => \&parameter,
)) {
Getopt::Long::config("no_auto_abbrev");
if (! GetOptions(
"help" => \&usage,
"debug" => \&debug,
"<>" => \&parameter,
)) {
die "%Error: Bad usage, try 'verilator_profcfunc --help'\n";
}
@@ -39,8 +37,8 @@ profcfunc($Opt_File);
#----------------------------------------------------------------------
sub usage {
pod2usage(-verbose=>2, -exitval => 2);
exit (1);
pod2usage(-verbose=>2, -exitval=>0, -output=>\*STDOUT);
exit(1); # Unreachable
}
sub debug {
@@ -50,9 +48,9 @@ sub debug {
sub parameter {
my $param = shift;
if (!defined $Opt_File) {
$Opt_File = $param;
$Opt_File = $param;
} else {
die "%Error: Unknown parameter: $param\n";
die "%Error: Unknown parameter: $param\n";
}
}
@@ -66,13 +64,21 @@ sub profcfunc {
my %funcs;
while (defined (my $line=$fh->getline())) {
# %time cumesec selfsec calls {stuff} name
if ($line =~ /^\s*([0-9.]+)\s+[0-9.]+\s+([0-9.]+)\s+([0-9.]+)\s+[^a-zA-Z_]*([a-zA-Z_].*)$/) {
my $pct=$1; my $sec=$2; my $calls=$3; my $func=$4;
$funcs{$func}{pct} += $pct;
$funcs{$func}{sec} += $sec;
$funcs{$func}{calls} += $calls;
}
# %time cumesec selfsec calls {stuff} name
if ($line =~ /^\s*([0-9.]+)\s+[0-9.]+\s+([0-9.]+)\s+([0-9.]+)\s+[^a-zA-Z_]*([a-zA-Z_].*)$/) {
my $pct=$1; my $sec=$2; my $calls=$3; my $func=$4;
$funcs{$func}{pct} += $pct;
$funcs{$func}{sec} += $sec;
$funcs{$func}{calls} += $calls;
}
# Older gprofs have no call column for single-call functions
# %time cumesec selfsec {stuff} name
elsif ($line =~ /^\s*([0-9.]+)\s+[0-9.]+\s+([0-9.]+)\s+[^a-zA-Z_]*([a-zA-Z_].*)$/) {
my $pct=$1; my $sec=$2; my $calls=1; my $func=$3;
$funcs{$func}{pct} += $pct;
$funcs{$func}{sec} += $sec;
$funcs{$func}{calls} += $calls;
}
}
$fh->close;
@@ -80,10 +86,10 @@ sub profcfunc {
my %pointer_mods;
my %verilated_mods;
foreach my $func (keys %funcs) {
if ($func =~ /(.*)::_eval\(([a-zA-Z_0-9]+__Syms).*\)$/) {
$verilated_mods{$1} = qr/^$1/;
$pointer_mods{$2} = $1;
}
if ($func =~ /(.*)::_eval\(([a-zA-Z_0-9]+__Syms).*\)$/) {
$verilated_mods{$1} = qr/^$1/;
$pointer_mods{$2} = $1;
}
}
#print Dumper(\%pointer_mods, \%verilated_mods);
@@ -91,67 +97,81 @@ sub profcfunc {
my %vfuncs;
my %groups;
foreach my $func (keys %funcs) {
my $pct = $funcs{$func}{pct};
my $vfunc = $func;
my $design;
my $pct = $funcs{$func}{pct};
my $vfunc = $func;
my $design;
if ($func =~ /\(([a-zA-Z_0-9]+__Syms)/) {
$design = $pointer_mods{$1};
}
if ($func =~ /\(([a-zA-Z_0-9]+__Syms)/) {
$design = $pointer_mods{$1};
}
foreach my $vde (keys %verilated_mods) {
last if $design;
if ($func =~ /$verilated_mods{$vde}/) {
$design=$vde;
last;
}
}
foreach my $vde (keys %verilated_mods) {
last if $design;
if ($func =~ /$verilated_mods{$vde}/) {
$design=$vde;
last;
}
}
if ($vfunc =~ /__PROF__([a-zA-Z_0-9]+)__l?([0-9]+)\(/) {
$vfunc = sprintf("VBlock %s:%d", $1, $2);
$groups{type}{"Verilog Blocks under $design"} += $pct;
$groups{design}{$design} += $pct;
$groups{module}{$1} += $pct;
} else {
if ($design) {
$vfunc = sprintf("VCommon %s", $func);
$groups{type}{"Common code under $design"} += $pct;
$groups{design}{$design} += $pct;
$groups{module}{$design." common code"} += $pct;
} else {
$vfunc = sprintf("C++ %s", $func);
$groups{type}{'C++'} += $pct;
$groups{design}{'C++'} += $pct;
$groups{module}{'C++'} += $pct;
}
}
$vfuncs{$vfunc} = $funcs{$func};
if ($vfunc =~ /__PROF__([a-zA-Z_0-9]+)__l?([0-9]+)\(/) {
$vfunc = sprintf("VBlock %s:%d", $1, $2);
$groups{type}{"Verilog Blocks under $design"} += $pct;
$groups{design}{$design} += $pct;
$groups{module}{$1} += $pct;
} else {
if ($design) {
$vfunc = sprintf("VCommon %s", $func);
$groups{type}{"Common code under $design"} += $pct;
$groups{design}{$design} += $pct;
$groups{module}{$design." common code"} += $pct;
} elsif ($func =~ /^VL_[A-Z0-9_]+/
|| $func =~ /^_?vl_[a-zA-Z0-9_]+/
|| $func =~ /^verilated/i) {
$vfunc = sprintf("VLib %s", $func);
$groups{type}{'VLib'} += $pct;
$groups{design}{'VLib'} += $pct;
$groups{module}{'VLib'} += $pct;
} elsif ($func =~ /^_mcount_private/) {
$vfunc = sprintf("Prof %s", $func);
$groups{type}{'Prof'} += $pct;
$groups{design}{'Prof'} += $pct;
$groups{module}{'Prof'} += $pct;
} else {
$vfunc = sprintf("C++ %s", $func);
$groups{type}{'C++'} += $pct;
$groups{design}{'C++'} += $pct;
$groups{module}{'C++'} += $pct;
}
}
$vfuncs{$vfunc} = $funcs{$func};
}
foreach my $type qw(type design module) {
my $missing = 100;
foreach (sort (keys %{$groups{$type}})) {
$missing -= $groups{$type}{$_};
}
if ($missing) {
$groups{$type}{"\377Unaccounted for/rounding error"} = $missing;
}
foreach my $type (qw(type design module)) {
my $missing = 100;
foreach (sort (keys %{$groups{$type}})) {
$missing -= $groups{$type}{$_};
}
if ($missing) {
$groups{$type}{"\377Unaccounted for/rounding error"} = $missing;
}
print("Overall summary by $type:\n");
printf(" %-6s %s\n","% time",$type);
foreach my $what (sort (keys %{$groups{$type}})) {
(my $pwhat = $what) =~ s/^\377//; # Just used to establish sort order
printf(" %6.2f %s\n", $groups{$type}{$what}, $pwhat);
}
print("\n");
print("Overall summary by $type:\n");
printf(" %-6s %s\n","% time",$type);
foreach my $what (sort (keys %{$groups{$type}})) {
(my $pwhat = $what) =~ s/^\377//; # Just used to establish sort order
printf(" %6.2f %s\n", $groups{$type}{$what}, $pwhat);
}
print("\n");
}
print("Verilog code profile:\n");
print(" These are split into three categories:\n");
print(" C++: Time in non-Verilated C++ code\n");
print(" Prof: Time in profile overhead\n");
print(" VBlock: Time attributable to a block in a Verilog file and line\n");
print(" VCommon: Time in a Verilated module, due to all parts of the design\n");
print(" VLib: Time in Verilated common libraries, called by the Verilated code\n");
print("\n");
print(" % cumulative self \n");
@@ -159,14 +179,14 @@ sub profcfunc {
my $cume = 0;
foreach my $func (sort {$vfuncs{$b}{sec} <=> $vfuncs{$a}{sec}
|| $a cmp $b}
(keys %vfuncs)) {
$cume += $vfuncs{$func}{sec};
printf +("%6.2f %9.2f %8.2f %8d %s\n",
$vfuncs{$func}{pct},
$cume, $vfuncs{$func}{sec},
$vfuncs{$func}{calls},
$func);
|| $a cmp $b}
(keys %vfuncs)) {
$cume += $vfuncs{$func}{sec};
printf +("%6.2f %9.2f %8.2f %8d %s\n",
$vfuncs{$func}{pct},
$cume, $vfuncs{$func}{sec},
$vfuncs{$func}{calls},
$func);
}
}
@@ -177,11 +197,11 @@ __END__
=head1 NAME
verilator_profcfunc - Read gprof report created with --profile-cfuncs
verilator_profcfunc - Read gprof report created with --prof-cfuncs
=head1 SYNOPSIS
verilator --profile-cfuncs ....
verilator --prof-cfuncs ....
gcc --ggdb -pg ....
{run executable}
gprof
@@ -190,8 +210,8 @@ verilator_profcfunc - Read gprof report created with --profile-cfuncs
=head1 DESCRIPTION
Verilator_profcfunc reads a profile report created by gprof. The names of
the functions are then transformed, assuming the user used verilator's
--profile-cfuncs, and a report printed showing the percentage of time, etc,
the functions are then transformed, assuming the user used Verilator's
--prof-cfuncs, and a report printed showing the percentage of time, etc,
in each Verilog block.
=head1 ARGUMENTS
@@ -206,11 +226,14 @@ Displays this message and program version and exits.
=head1 DISTRIBUTION
The latest version is available from L<http://www.veripool.org/>.
The latest version is available from L<https://verilator.org>.
Copyright 2007-2009 by Wilson Snyder. This package is free software; you
Copyright 2007-2020 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 or the Perl Artistic License.
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
=head1 AUTHORS
+56
View File
@@ -0,0 +1,56 @@
# DESCRIPTION: Dockerfile for env to build and fully test Verilator
#
# Copyright 2020 by Stefan Wallentowitz. 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
FROM ubuntu:20.04
RUN apt-get update \
&& DEBIAN_FRONTEND=noninteractive \
apt-get install --no-install-recommends -y \
autoconf \
bc \
bison \
build-essential \
ca-certificates \
ccache \
clang \
cmake \
flex \
gdb \
git \
gtkwave \
libfl2 \
libfl-dev \
libgoogle-perftools-dev \
libsystemc \
libsystemc-dev \
numactl \
perl \
python3 \
wget \
zlibc \
zlib1g \
zlib1g-dev \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /tmp
RUN cpan install -fi Unix::Processors Parallel::Forker Bit::Vector
RUN git clone https://github.com/veripool/vcddiff.git && \
make -C vcddiff && \
cp -p vcddiff/vcddiff /usr/local/bin/vcddiff && \
rm -rf vcddiff
COPY build.sh /tmp/build.sh
ENV VERILATOR_AUTHOR_SITE=1
WORKDIR /work
ENTRYPOINT [ "/tmp/build.sh" ]
+49
View File
@@ -0,0 +1,49 @@
= Verilator Docker Build Environment
This Verilator Build container is set up to compile and test a Verilator
build. It uses the following parameters:
* Source repository (default: https://github.com/verilator/verilator)
* Source revision (default: master)
* Compiler (GCC 9.3.0, clang 10.0.0, default: 9.3.0)
The container is published as `verilator/verilator-buildenv` on
https://hub.docker.com/repository/docker/verilator/verilator-buildenv[docker hub].
To run the basic build using the current Verilator master:
docker run -ti verilator/verilator-buildenv
To also run tests:
docker run -ti verilator/verilator-buildenv test
To change the compiler:
docker run -ti -e CC=clang-10 -e CXX=clang++-10 verilator/verilator-buildenv test
The tests that involve gdb are not working due to security restrictions.
To run those too:
....
docker run -ti -e CC=clang-10 -e CXX=clang++-10 --cap-add=SYS_PTRACE --security-opt seccomp=unconfined verilator/verilator-buildenv test
....
Rather then building using a remote git repository you may prefer to use a
working copy on the local filesystem. Mount the local working copy path as
a volume and use that in place of git. When doing this be careful to have
all changes committed to the local git area. To build the current HEAD from
top of a repository:
....
docker run -ti -v ${PWD}:/tmp/repo -e REPO=/tmp/repo -e REV=`git rev-parse --short HEAD` --cap-add=SYS_PTRACE --security-opt seccomp=unconfined verilator/verilator-buildenv test
....
== Rebuilding
To rebuild the Verilator-buildenv docker image, run:
docker build .
This will also build SystemC under all supported compiler variants to
reduce the SystemC testing time.
+25
View File
@@ -0,0 +1,25 @@
#!/bin/bash -e
# DESCRIPTION: Build Verilator (inside container)
#
# Copyright 2020 by Stefan Wallentowitz. 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
: "${REPO:=https://github.com/verilator/verilator}"
: "${REV:=master}"
: "${CC:=gcc}"
: "${CXX:=g++}"
SRCS=$PWD/verilator
git clone "$REPO" "$SRCS"
cd "$SRCS"
git checkout "$REV"
autoconf
./configure --enable-longtests
make -j $(nproc)
if [ "${1:-''}" == "test" ]; then
make test
fi
+51
View File
@@ -0,0 +1,51 @@
# DESCRIPTION: Dockerfile for image to run Verilator inside
#
# Copyright 2020 by Stefan Wallentowitz. 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
FROM ubuntu:20.04
RUN apt-get update \
&& DEBIAN_FRONTEND=noninteractive \
&& apt-get install --no-install-recommends -y \
autoconf \
bc \
bison \
build-essential \
ca-certificates \
ccache \
flex \
git \
libfl-dev \
libgoogle-perftools-dev \
perl \
python3 \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
ARG REPO=https://github.com/verilator/verilator
ARG SOURCE_COMMIT=master
WORKDIR /tmp
# Add an exception for the linter, we want to cd here in one layer
# to reduce the number of layers (and thereby size).
# hadolint ignore=DL3003
RUN git clone "${REPO}" verilator && \
cd verilator && \
git checkout "${SOURCE_COMMIT}" && \
autoconf && \
./configure && \
make -j "$(nproc)" && \
make install && \
cd .. && \
rm -r verilator
COPY verilator-wrap.sh /usr/local/bin/verilator-wrap.sh
WORKDIR /work
ENTRYPOINT [ "/usr/local/bin/verilator-wrap.sh" ]
+59
View File
@@ -0,0 +1,59 @@
= Verilator Executable Docker Container
The Verilator Executable Docker Container allows you to run Verilator
easily as a docker image, e.g.:
docker run -ti verilator/verilator:latest --version
This will install the container, run the latest Verilator and print
Verilator's version.
Containers are automatically built for all released versions, so you may
easily compare results across versions, e.g.:
docker run -ti verilator/verilator:4.030 --version
Verilator needs to read and write files on the local system. To simplify
this process, use the `verilator-docker` convenience script. This script
takes the version number, and all remaining arguments are passed through to
Verilator. e.g.:
./verilator-docker 4.030 --version
or
./verilator-docker 4.030 --cc test.v
If you prefer not to use `verilator-docker` you must give the container
access to your files as a volume with appropriate user rights. For example
to Verilate test.v:
....
docker run -ti -v ${PWD}:/work --user $(id -u):$(id -g) verilator/verilator:latest --cc test.v
....
This method can only access files below the current directory. An
alternative is setup the volume `-workdir`.
You can also work in the container by setting the entrypoint
(don't forget to mount a volume if you want your work persistent):
docker run -ti --entrypoint /bin/bash verilator/verilator:latest
You can also use the container to build Verilator at a specific
commit:
docker build --build-arg SOURCE_COMMIT=<commit> .
== Internals
The Dockerfile builds Verilator and removes the tree when completed to
reduce the image size. The entrypoint is set as a wrapper script
(`verilator-wrap.sh`). That script 1. calls Verilator, and 2. copies the
Verilated runtime files to the `obj_dir` or the `-Mdir` 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 patches the Verilated
Makefile accordingly.
There is also a hook defined that is run by docker hub via automated
builds.
+10
View File
@@ -0,0 +1,10 @@
#!/bin/bash
# DESCRIPTION: Docker hub hook to pass SOURCE_COMMIT
#
# Copyright 2020 by Stefan Wallentowitz. 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
docker build --build-arg SOURCE_COMMIT=${SOURCE_COMMIT} -f $DOCKERFILE_PATH -t $IMAGE_NAME .
+13
View File
@@ -0,0 +1,13 @@
#!/bin/bash
# DESCRIPTION: Docker hub hook to tag the latest release (stable)
#
# Copyright 2020 by Stefan Wallentowitz. 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
if [ "$SOURCE_BRANCH"="stable" ]; then
docker tag $IMAGE_NAME $DOCKER_REPO:latest
docker push $DOCKER_REPO:latest
fi
+11
View File
@@ -0,0 +1,11 @@
#!/bin/bash
# DESCRIPTION: Wrap a verilator call to run a docker container
#
# Copyright 2020 by Stefan Wallentowitz. 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
docker pull verilator/verilator:$1 >/dev/null
docker run -ti -v ${PWD}:/work --user $(id -u):$(id -g) verilator/verilator:$1 "${@:2}"
+31
View File
@@ -0,0 +1,31 @@
#!/bin/bash
# DESCRIPTION: Wrap a Verilator call and copy vlt includes
# (inside docker container)
#
# Copyright 2020 by Stefan Wallentowitz. 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
perl /usr/local/bin/verilator "$@"
status=$?
if [ $status -ne 0 ]; then
exit $status
fi
# Check if user set an obj_dir
obj_dir=$(echo " $@" | grep -oP '\s--Mdir\s*\K\S+')
if [ "$obj_dir" == "" ]; then
obj_dir="obj_dir"
fi
# If the run was successful: Copy required files to allow build without this container
if [ -e ${obj_dir} ]; then
# Copy files required for the build
mkdir -p ${obj_dir}/vlt
cp -r /usr/local/share/verilator/bin ${obj_dir}/vlt
cp -r /usr/local/share/verilator/include ${obj_dir}/vlt
# Point Makefile to that folder
perl -i -pe 's/VERILATOR_ROOT = \/usr\/local\/share\/verilator/VERILATOR_ROOT = vlt/g' ${obj_dir}/*.mk
fi
+29
View File
@@ -0,0 +1,29 @@
#!/usr/bin/env bash
# DESCRIPTION: Verilator: Travis CI ccache maintenance
#
# Copyright 2020 by Geza Lore. 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
################################################################################
# This script is run in 'before_script', once ccache has been set up.
################################################################################
set -e
set -x
# Show version
ccache --version
# Flush ccache if requested in commit message
COMMIT="${TRAVIS_PULL_REQUEST_SHA:-$TRAVIS_COMMIT}"
if git log --format=%B -n 1 "$COMMIT" | grep -q -i '\[travis\s\+ccache\s\+clear\]'; then
echo "Flushing ccache due to commit message"
ccache -C
fi
# Dump stats, then zero stats
ccache -s -z
+37
View File
@@ -0,0 +1,37 @@
#!/usr/bin/env bash
# DESCRIPTION: Verilator: Travis CI ccache sizer
#
# Copyright 2020 by Geza Lore. 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
################################################################################
# This script computes the size of the ccache to be used for a job. We want the
# ccache to be just big enough to be able to hold a whole build so a re-build
# of the same does not miss in the cache due to capacity, but we don't want the
# ccache too big as pulling it down from the network takes time, and it is
# unlikely objects from much earlier builds would be useful.
################################################################################
fatal() {
echo "ERROR: $(basename "$0"): $1" >&2; exit 1;
}
if [ "$TRAVIS_BUILD_STAGE_NAME" = "build" ]; then
if [ "$COVERAGE" == 1 ]; then
echo "1024M"
else
echo "768M"
fi
elif [ "$TRAVIS_BUILD_STAGE_NAME" = "test" ]; then
if [[ $TESTS == coverage-* ]]; then
echo "1536M"
else
echo "256M"
fi
else
fatal "Unknown build stage: '$TRAVIS_BUILD_STAGE_NAME'"
fi
+72
View File
@@ -0,0 +1,72 @@
#!/usr/bin/env bash
# DESCRIPTION: Verilator: Travis CI dependency install script
#
# Copyright 2020 by Geza Lore. 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
################################################################################
# This script runs in the 'install' phase of all jobs, in all stages. We try to
# minimize the time spent in this by selectively installing only the components
# required by the particular build stage.
################################################################################
# Note that Travis runs "apt-get update" when "apt-get install" is used in the
# .travis.yml file directly, but since we invoke it via this script, we need to
# run it manually where requried, otherwise some packages cannot be found.
set -e
set -x
fatal() {
echo "ERROR: $(basename "$0"): $1" >&2; exit 1;
}
install-vcddiff() {
TMP_DIR="$(mktemp -d)"
git clone https://github.com/veripool/vcddiff "$TMP_DIR"
git -C "${TMP_DIR}" checkout 5112f88b7ba8818dce9dfb72619e64a1fc19542c
make -C "${TMP_DIR}"
sudo cp "${TMP_DIR}/vcddiff" /usr/local/bin
}
if [ "$TRAVIS_BUILD_STAGE_NAME" = "build" ]; then
##############################################################################
# Dependencies of jobs in the 'build' stage, i.e.: packages required to
# build Verilator
if [ "$TRAVIS_OS_NAME" = "linux" ]; then
time sudo apt-get update
sudo apt-get install libfl-dev
sudo apt-get install libgoogle-perftools-dev
if [ "$COVERAGE" = 1 ]; then
yes yes | sudo cpan -fi Unix::Processors Parallel::Forker
fi
else
fatal "Unknown os: '$TRAVIS_OS_NAME'"
fi
elif [ "$TRAVIS_BUILD_STAGE_NAME" = "test" ]; then
##############################################################################
# Dependencies of jobs in the 'test' stage, i.e.: packages required to
# run the tests
if [ "$TRAVIS_OS_NAME" = "linux" ]; then
sudo apt-get update
sudo apt-get install gdb gtkwave lcov
if [ "$TRAVIS_DIST" = "focal" ]; then
sudo apt-get install libsystemc-dev
fi
yes yes | sudo cpan -fi Unix::Processors Parallel::Forker
# Not listing Bit::Vector as slow to install, and only skips one test
install-vcddiff
else
fatal "Unknown os: '$TRAVIS_OS_NAME'"
fi
else
##############################################################################
# Unknown build stage
fatal "Unknown build stage: '$TRAVIS_BUILD_STAGE_NAME'"
fi
+101
View File
@@ -0,0 +1,101 @@
#!/usr/bin/env bash
# DESCRIPTION: Verilator: Travis CI main job script
#
# Copyright 2020 by Geza Lore. 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
################################################################################
# This is the main script executed in the 'script' phase by all jobs. We use a
# single script to keep the .travis.yml spec simple. We pass job parameters via
# environment variables using 'env' keys. Having different 'env' keys in jobs
# ensures they use different Travis build caches.
################################################################################
set -e
set -x
fatal() {
echo "ERROR: $(basename "$0"): $1" >&2; exit 1;
}
if [ "$TRAVIS_BUILD_STAGE_NAME" = "build" ]; then
##############################################################################
# Build verilator
if [ "$TRAVIS_OS_NAME" = "linux" ]; then
if [ "$COVERAGE" != 1 ]; then
autoconf
./configure --enable-longtests --enable-ccwarn
make -j $(nproc)
else
nodist/code_coverage --stages 1-2
fi
else
fatal "Unknown os: '$TRAVIS_OS_NAME'"
fi
elif [ "$TRAVIS_BUILD_STAGE_NAME" = "test" ]; then
##############################################################################
# Run tests
if [ "$TRAVIS_OS_NAME" = "linux" ]; then
# Run the specified test
case $TESTS in
dist-vlt-0)
make -C test_regress SCENARIOS="--dist --vlt" DRIVER_HASHSET=--hashset=0/2
;;
dist-vlt-1)
make -C test_regress SCENARIOS="--dist --vlt" DRIVER_HASHSET=--hashset=1/2
;;
vltmt-0)
make -C test_regress SCENARIOS=--vltmt DRIVER_HASHSET=--hashset=0/2
;;
vltmt-1)
make -C test_regress SCENARIOS=--vltmt DRIVER_HASHSET=--hashset=1/2
;;
coverage-dist)
nodist/code_coverage --stages 3- --scenarios=--dist
;;
coverage-vlt-0)
nodist/code_coverage --stages 3- --scenarios=--vlt --hashset=0/4
;;
coverage-vlt-1)
nodist/code_coverage --stages 3- --scenarios=--vlt --hashset=1/4
;;
coverage-vlt-2)
nodist/code_coverage --stages 3- --scenarios=--vlt --hashset=2/4
;;
coverage-vlt-3)
nodist/code_coverage --stages 3- --scenarios=--vlt --hashset=3/4
;;
coverage-vltmt-0)
nodist/code_coverage --stages 3- --scenarios=--vltmt --hashset=0/4
;;
coverage-vltmt-1)
nodist/code_coverage --stages 3- --scenarios=--vltmt --hashset=1/4
;;
coverage-vltmt-2)
nodist/code_coverage --stages 3- --scenarios=--vltmt --hashset=2/4
;;
coverage-vltmt-3)
nodist/code_coverage --stages 3- --scenarios=--vltmt --hashset=3/4
;;
*)
fatal "Unknown test: $TESTS"
;;
esac
# Upload coverage data to codecov.io
if [[ $TESTS == coverage-* ]]; then
bash <(curl -s https://codecov.io/bash) -f nodist/obj_dir/coverage/app_total.info
fi
else
fatal "Unknown os: '$TRAVIS_OS_NAME'"
fi
else
##############################################################################
# Unknown build stage
fatal "Unknown build stage: '$TRAVIS_BUILD_STAGE_NAME'"
fi
+38
View File
@@ -0,0 +1,38 @@
# DESCRIPTION: codecov.io config
#
# Copyright 2020-2020 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
####################
# Validate:
# curl --data-binary @codecov.yml https://codecov.io/validate
codecov:
require_ci_to_pass: no
coverage:
precision: 2
round: down
range: "70...100"
ignore:
- "ci"
- "docs"
- "examples"
- "include/gtkwave"
- "include/vltstd"
- "test_regress"
parsers:
gcov:
branch_detection:
conditional: yes
loop: yes
method: no
macro: no
comment:
layout: "reach,diff,flags,tree"
behavior: default
require_changes: yes
+430 -35
View File
@@ -1,35 +1,153 @@
dnl DESCRIPTION: Process this file with autoconf to produce a configure script.
dnl Copyright 2003-2009 by Wilson Snyder. This program is free software; you can
dnl redistribute it and/or modify it under the terms of either the GNU
dnl General Public License or the Perl Artistic License.
# DESCRIPTION: Process this file with autoconf to produce a configure script.
#
# Copyright 2003-2020 by Wilson Snyder. Verilator is free software; you
# can redistribute it and/or modify it under the terms of either the GNU Lesser
# General Public License Version 3 or the Perl Artistic License Version 2.0.
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
#AC_INIT([Verilator],[#.### YYYY-MM-DD])
#AC_INIT([Verilator],[#.### devel])
AC_INIT([Verilator],[4.036 2020-06-06],
[https://verilator.org],
[verilator],[https://verilator.org])
# When releasing, also update header of Changes file
# and commit using "devel release" or "Version bump" message
AC_INIT(src/Verilator.cpp)
AC_CONFIG_HEADER(src/config_build.h)
AC_CONFIG_FILES(Makefile docs/Makefile src/Makefile src/Makefile_obj include/verilated.mk include/verilated_config.h verilator.pc verilator-config.cmake verilator-config-version.cmake)
dnl Special Substitutions
AC_ARG_ENABLE(defenv,
[AS_HELP_STRING([--disable-defenv], [disable hardcoded default environment variables])],
CFG_WITH_DEFENV=$enableval,
CFG_WITH_DEFENV=yes)
# Version
AC_MSG_RESULT([configuring for $PACKAGE_STRING])
PACKAGE_VERSION_NUMBER=`AS_ECHO("$PACKAGE_VERSION") | sed 's/ .*//g'`
AC_SUBST(PACKAGE_VERSION_NUMBER)
# Ignore automake flags passed by Ubuntu builds
AC_ARG_ENABLE([dependency-tracking],
[AS_HELP_STRING([--disable-dependency-tracking], [ignored])])
AC_ARG_ENABLE([maintainer-mode],
[AS_HELP_STRING([--enable-maintainer-mode], [ignored])])
AC_ARG_ENABLE([silent-rules],
[AS_HELP_STRING([--disable-silent-rules], [ignored])])
# Flag to enable linking specific libraries statically
AC_MSG_CHECKING(whether to perform partial static linking of Verilator binary)
AC_ARG_ENABLE([partial-static],
[AS_HELP_STRING([--disable-partial-static],
[By default, for Verilation peformance, Verilator
is linked against some of its dependencies
statically. Use this to link the Verilator binary
fully dynamically.])],
[case "${enableval}" in
yes) CFG_ENABLE_PARTIAL_STATIC=yes ;;
no) CFG_ENABLE_PARTIAL_STATIC=no ;;
*) AC_MSG_ERROR([bad value '${enableval}' for --disable-partial-static]) ;;
esac],
CFG_ENABLE_PARTIAL_STATIC=yes)
AC_MSG_RESULT($CFG_ENABLE_PARTIAL_STATIC)
# Flag to enable linking Verilator with tcmalloc if available
AC_MSG_CHECKING(whether to use tcmalloc)
AC_ARG_ENABLE([tcmalloc],
[AS_HELP_STRING([--enable-tcmalloc],
[Use libtcmalloc_minimal for faster dynamic memory
management in Verilator binary@<:@default=check@:>@])],
[case "${enableval}" in
yes) CFG_WITH_TCMALLOC=yes ;;
no) CFG_WITH_TCMALLOC=no ;;
*) AC_MSG_ERROR([bad value '${enableval}' for --enable-tcmalloc]) ;;
esac],
[CFG_WITH_TCMALLOC=check;])
AC_MSG_RESULT($CFG_WITH_TCMALLOC)
# Special Substitutions - CFG_WITH_DEFENV
AC_MSG_CHECKING(whether to use hardcoded paths)
AC_ARG_ENABLE([defenv],
[AS_HELP_STRING([--disable-defenv],
[disable using some hardcoded data paths extracted
from some default environment variables (the default
is to use hardcoded paths) in Verilator binary])],
[case "${enableval}" in
yes) CFG_WITH_DEFENV=yes ;;
no) CFG_WITH_DEFENV=no ;;
*) AC_MSG_ERROR([bad value ${enableval} for --disable-defenv]) ;;
esac],
CFG_WITH_DEFENV=yes)
AC_SUBST(CFG_WITH_DEFENV)
AC_MSG_RESULT($CFG_WITH_DEFENV)
dnl Compiler flags
CXX=g++
CFLAGS=-I${includedir}
CPPFLAGS=-I${includedir}
CXXFLAGS=-I${includedir}
LDFLAGS=-L${libdir}
# Special Substitutions - CFG_WITH_CCWARN
AC_MSG_CHECKING(whether to show and stop on compilation warnings)
AC_ARG_ENABLE([ccwarn],
[AS_HELP_STRING([--enable-ccwarn],
[enable showing and stopping on compilation warnings
in Verilator binrary and Verilated makefiles])],
[case "${enableval}" in
yes) CFG_WITH_CCWARN=yes ;;
no) CFG_WITH_CCWARN=no ;;
*) AC_MSG_ERROR([bad value ${enableval} for --enable-ccwarn]) ;;
esac],
[case "x${VERILATOR_AUTHOR_SITE}" in
x) CFG_WITH_CCWARN=no ;;
*) CFG_WITH_CCWARN=yes ;;
esac]
)
AC_SUBST(CFG_WITH_CCWARN)
AC_MSG_RESULT($CFG_WITH_CCWARN)
dnl Checks for programs.
# Special Substitutions - CFG_WITH_LONGTESTS
AC_MSG_CHECKING(whether to run long tests)
AC_ARG_ENABLE([longtests],
[AS_HELP_STRING([--enable-longtests],
[enable running long developer tests])],
[case "${enableval}" in
yes) CFG_WITH_LONGTESTS=yes ;;
no) CFG_WITH_LONGTESTS=no ;;
*) AC_MSG_ERROR([bad value ${enableval} for --enable-longtests]) ;;
esac],
[case "x${VERILATOR_AUTHOR_SITE}" in
x) CFG_WITH_LONGTESTS=no ;;
*) CFG_WITH_LONGTESTS=yes ;;
esac]
)
AC_SUBST(CFG_WITH_LONGTESTS)
AC_MSG_RESULT($CFG_WITH_LONGTESTS)
# CFG_WITH_PREC11
AC_MSG_CHECKING(whether allow pre-C++11)
AC_ARG_ENABLE([prec11],
[AS_HELP_STRING([--enable-prec11],
[enable pre-C++11 compilers for Verilator binary
and Verilated makefiles])],
[case "${enableval}" in
yes) CFG_WITH_PREC11=yes ;;
no) CFG_WITH_PREC11=no ;;
*) AC_MSG_ERROR([bad value ${enableval} for --enable-prec11]) ;;
esac],
[CFG_WITH_PREC11=no;]
)
AC_SUBST(CFG_WITH_PREC11)
AC_MSG_RESULT($CFG_WITH_PREC11)
# Compiler flags
CFLAGS+=" -I${includedir}"
CPPFLAGS+=" -I${includedir}"
CXXFLAGS+=" -I${includedir}"
LDFLAGS+=" -L${libdir}"
# Checks for programs.
AC_PROG_CC
AC_PROG_CXX
AC_PROG_INSTALL
AC_LANG_PUSH(C++)
cxx_version=$($CXX --version | head -1)
AC_MSG_RESULT([compiler is $CXX --version = $cxx_version])
AC_MSG_CHECKING([that C++ compiler can compile simple program])
AC_TRY_RUN([int main() { return 0; }],
AC_MSG_RESULT(yes),
AC_MSG_RESULT(no);AC_MSG_ERROR([a working C++ compiler is required]))
AC_RUN_IFELSE(
[AC_LANG_SOURCE([int main() { return 0; }])],
AC_MSG_RESULT(yes),
AC_MSG_RESULT(no);AC_MSG_ERROR([a working C++ compiler is required]),
AC_MSG_RESULT(yes))
AC_PATH_PROG(PERL,perl)
if test "x$PERL" = "x" ; then
@@ -44,33 +162,310 @@ if test "x$YACC" = "x" ; then
AC_MSG_ERROR([Cannot find "bison" in your PATH, please install it])
fi
dnl Checks for libraries.
AC_CHECK_PROG(OBJCACHE,ccache,ccache)
if test "x$OBJCACHE" != "x" ; then
objcache_version=$($OBJCACHE --version | head -1)
AC_MSG_RESULT([objcache is $OBJCACHE --version = $objcache_version])
fi
dnl Checks for header files.
AC_HEADER_STDC
AC_HEADER_SYS_WAIT
AC_CHECK_HEADERS(fcntl.h unistd.h inttypes.h sys/file.h sys/time.h sys/un.h math.h stdint.h mingw/stdint.h)
# Checks for libraries.
dnl Checks for typedefs, structures
# Checks for typedefs, structures
AC_CHECK_TYPE(size_t,unsigned int)
AC_CHECK_TYPE(uint_t,unsigned int)
AC_CHECK_TYPE(ulong_t,unsigned long)
AC_TYPE_SIZE_T
AC_STRUCT_TM
dnl Checks for compiler characteristics.
# Checks for compiler characteristics.
AC_C_INLINE
dnl Checks for library functions.
AC_LINK_IFELSE(
[AC_LANG_PROGRAM([#include <new>], [[int* a=new int; delete a; ]])],
[], [AC_MSG_ERROR([$CXX does not seem to successfully compile a simple C++ program])])
dnl Checks for system services
AC_DEFUN([_MY_CXX_CHECK_FLAG],
[# _MY_CXX_CHECK_FLAG(flag) -- Check if compiler supports specific options
# Set $_my_result appropriately
ACO_SAVE_CXXFLAGS="$CXXFLAGS"
# -Werror needed otherwise unknown -Wno-div-by-zero won't report problems
# new/delete is needed to find -faligned-new link problem on Darwin
CXXFLAGS="$CXXFLAGS $1 -Werror"
AC_MSG_CHECKING([whether $CXX accepts $1])
AC_LINK_IFELSE(
[AC_LANG_PROGRAM([#include <new>], [[int* a=new int; delete a; ]])],
[_my_result=yes
if test -s conftest.err; then
if grep -e "$1" conftest.err >/dev/null; then
_my_result=no
fi
fi],
[_my_result=no])
# GCC is annoying, trying to be helpful, it postpones unknown -Wno-
# options if there's no error We want to see them regardless, so try
# forcing an error and see if we get a gcc warning
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM([[an_error "intentional-error-for-test.h"
]],[])],
[], # Ignore ok exit
[if test -s conftest.err; then
if grep -e "$1" conftest.err >/dev/null; then
_my_result=no
fi
fi])
AC_MSG_RESULT($_my_result)
CXXFLAGS="$ACO_SAVE_CXXFLAGS"
])
dnl Other install directories
AC_DEFUN([_MY_CXX_CHECK_SET],
[# _MY_CXX_CHECK_SET(variable,flag) -- Check if compiler supports specific options
# If it does, set variable to flag, only if not previously set
if test "$$1" = ""; then
_MY_CXX_CHECK_FLAG($2)
if test "$_my_result" = "yes" ; then
$1="$2"
fi
fi
])
AC_DEFUN([_MY_CXX_CHECK_OPT],
[# _MY_CXX_CHECK_OPT(flag) -- Check if compiler supports specific options
# If it does, append flag to variable
_MY_CXX_CHECK_FLAG($2)
if test "$_my_result" = "yes" ; then
$1="$$1 $2"
fi
])
AC_DEFUN([_MY_LDLIBS_CHECK_FLAG],
[# _MY_LDLIBS_CHECK_FLAG(flag) -- Check if linker supports specific options
# Set $_my_result appropriately
ACO_SAVE_LIBS="$LIBS"
LIBS="$LIBS $1"
AC_MSG_CHECKING([whether $CXX linker accepts $1])
AC_LINK_IFELSE(
[AC_LANG_PROGRAM([[]])],
[_my_result=yes
if test -s conftest.err; then
if grep -e "$1" conftest.err >/dev/null; then
_my_result=no
fi
fi],
[_my_result=no])
AC_MSG_RESULT($_my_result)
LIBS="$ACO_SAVE_LIBS"
])
AC_DEFUN([_MY_LDLIBS_CHECK_IFELSE],
[# _MY_LDLIBS_CHECK_IFELSE(flag,action-if-supported,action-if-not-supported)
# Check if linker supports specific flag, if it does do action-if-supported
# otherwise do action-if-not-supported
_MY_LDLIBS_CHECK_FLAG($1)
if test "$_my_result" = "yes" ; then
true
$2
else
true
$3
fi
])
AC_DEFUN([_MY_LDLIBS_CHECK_OPT],
[# _MY_LDLIBS_CHECK_OPT(variable, flag) -- Check if linker supports specific
# options. If it does, append flag to variable.
_MY_LDLIBS_CHECK_IFELSE($2, $1="$$1 $2")
])
# Flag to select newest language standard supported
# Macros work such that first option that passes is the one we take
# gnu++17 code is clean, but SystemC in 2018 doesn't link with it (bug1339)
# gnu++14 is the newest that Verilator supports
# std++03 is the oldest that Verilator supports
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++17)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++14)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++11)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++03)
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++17)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++14)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++11)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++03)
AC_SUBST(CFG_CXXFLAGS_STD_NEWEST)
# And likewise oldest standard (same list above, backwards)
# This is used for internal testing
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_OLDEST,-std=c++03)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_OLDEST,-std=c++11)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_OLDEST,-std=c++14)
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_OLDEST,-std=std++17)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_OLDEST,-std=gnu++03)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_OLDEST,-std=gnu++11)
_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_OLDEST,-std=gnu++14)
#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_OLDEST,-std=gnu++17)
AC_SUBST(CFG_CXXFLAGS_STD_OLDEST)
# Flags for compiling Verilator internals including parser, and Verilated files
# These turn on extra warnings and are only used with 'configure --enable-ccwarn'
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_WEXTRA,-Wextra)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_WEXTRA,-Wfloat-conversion)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_WEXTRA,-Wlogical-op)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_WEXTRA,-Wthread-safety)
AC_SUBST(CFG_CXXFLAGS_WEXTRA)
# Flags for compiling Verilator internals including parser always
_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,-Wno-unused-parameter)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-Wno-shadow)
AC_SUBST(CFG_CXXFLAGS_SRC)
# Flags for compiling Verilator parser always (in addition to above CFG_CXXFLAGS_SRC)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_PARSER,-Wno-char-subscripts)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_PARSER,-Wno-null-conversion)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_PARSER,-Wno-parentheses-equality)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_PARSER,-Wno-unused)
AC_SUBST(CFG_CXXFLAGS_PARSER)
# Flags for Verilated makefile
# For example, -Wno-div-by-zero isn't in 4.1.2
# Random code often does / 0. Unfortunately VL_DIV_I(0,0) will warn
# without this flag, even though there's a conditional to prevent the divide.
# We still don't add no-div-by-zero as it throws message to stdout, though doesn't die.
#_MY_CXX_CHECK_OPT(-Wno-div-by-zero)
# For some reason -faligned-new does not work under Travis w/ clang but the
# configure test doesn't catch this either
AS_IF([test "x$TRAVIS_COMPILER" != xclang], [_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_NO_UNUSED,-faligned-new)])
CFG_CXX_FLAGS_CMAKE="-faligned-new"
m4_foreach([cflag],[
[-fbracket-depth=4096],
[-fcf-protection=none],
[-mno-cet],
[-Qunused-arguments],
[-Wno-bool-operation],
[-Wno-tautological-bitwise-compare],
[-Wno-parentheses-equality],
[-Wno-sign-compare],
[-Wno-uninitialized],
[-Wno-unused-but-set-variable],
[-Wno-unused-parameter],
[-Wno-unused-variable],
[-Wno-shadow]],[
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_NO_UNUSED,cflag)
# CMake will test what flags work itself, so pass all flags through to it
CFG_CXX_FLAGS_CMAKE="$CFG_CXX_FLAGS_CMAKE cflag"
])
AC_SUBST(CFG_CXXFLAGS_NO_UNUSED)
AC_SUBST(CFG_CXX_FLAGS_CMAKE)
# Find multithread linker flags
m4_foreach([ldflag], [
[-mt],
[-pthread],
[-lpthread],
[-latomic]],[
_MY_LDLIBS_CHECK_OPT(CFG_LDLIBS_THREADS,ldflag)
# CMake will test what flags work itself, so pass all flags through to it
CFG_LDFLAGS_THREADS_CMAKE="$CFG_LDFLAGS_THREADS_CMAKE ldflag"
])
AC_SUBST(CFG_LDLIBS_THREADS)
AC_SUBST(CFG_LDFLAGS_THREADS_CMAKE)
# When linking partially statically
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-libstdc++)
_MY_LDLIBS_CHECK_OPT(CFG_LDFLAGS_SRC, -Xlinker -gc-sections)
LTCMALLOC=-l:libtcmalloc_minimal.a
else
LTCMALLOC=-ltcmalloc_minimal
fi
AC_SUBST(CFG_LDFLAGS_SRC)
# 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
# pthreads is harmless otherwise.
CFG_LIBS="$LIBS $CFG_LIBS"
_MY_LDLIBS_CHECK_OPT(CFG_LIBS, -lpthread)
# Check libraries for MingW
_MY_LDLIBS_CHECK_OPT(CFG_LIBS, -lbcrypt)
_MY_LDLIBS_CHECK_OPT(CFG_LIBS, -lpsapi)
# Check if tcmalloc is available based on --enable-tcmalloc
_MY_LDLIBS_CHECK_IFELSE(
$LTCMALLOC,
[if test "$CFG_WITH_TCMALLOC" != "no"; then
CFG_LIBS="$LTCMALLOC $CFG_LIBS";
# If using tcmalloc, add some extra options to make the compiler not assume
# it is using it's own versions of the standard library functions
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-fno-builtin-malloc)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-fno-builtin-calloc)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-fno-builtin-realloc)
_MY_CXX_CHECK_OPT(CFG_CXXFLAGS_SRC,-fno-builtin-free)
fi],
[if test "$CFG_WITH_TCMALLOC" = "yes"; then
AC_MSG_ERROR([--enable-tcmalloc was given but test for ${LTCMALLOC} failed])
fi])
AC_SUBST(CFG_LIBS)
# Set CFG_WITH_THREADED if can support threading
AC_MSG_CHECKING(whether $CXX supports Verilated threads)
ACO_SAVE_CXXFLAGS="$CXXFLAGS"
CXXFLAGS="$CXXFLAGS $CFG_CXXFLAGS_STD_NEWEST $CFG_CXXFLAGS_NO_UNUSED"
AC_LINK_IFELSE(
[AC_LANG_PROGRAM([#include <thread>], [[ ]])],
[_my_result=yes
if test -s conftest.err; then
if grep -e "$1" conftest.err >/dev/null; then
_my_result=no
fi
fi],
[_my_result=no])
CFG_WITH_THREADED=$_my_result
AC_SUBST(CFG_WITH_THREADED)
AC_MSG_RESULT($CFG_WITH_THREADED)
CXXFLAGS="$ACO_SAVE_CXXFLAGS"
# Check compiler flag
if test "$CFG_WITH_THREADED" = "no" ; then
if test "$CFG_WITH_PREC11" = "no" ; then
AC_MSG_NOTICE([[]])
AC_MSG_ERROR([[the $CXX compiler appears to not support C++11.
Verilator plans to require a C++11 or newer compiler in a future release,
unless sufficient people report problems. Therefore, if you do not have a
C++11 compiler, please post a message to
https://www.veripool.org/boards/3/topics/2580-Verilator-Requiring-C-11-compiler
indicating your OS and when you think C++11 might be ok, and then rerun
configure with the --enable-prec11 argument. Thanks.]])
fi
fi
# Checks for library functions.
AC_CHECK_MEMBER([struct stat.st_mtim.tv_nsec],
[AC_DEFINE([HAVE_STAT_NSEC],[1],[Defined if struct stat has st_mtim.tv_nsec])],
[], [#include <sys/stat.h>])
# HAVE_SYSTEMC
# - If found the default search path has it, so support is always enabled.
# - If not found or not system-wide, user can set SYSTEMC_INCLUDE.
# AC_CHECK_HEADERS seems to not locate on Travis-CI but include does work.
AC_MSG_CHECKING([whether SystemC is found (in system path)])
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM([[#include <systemc.h>
]],[])],
[_my_result=yes
AC_DEFINE([HAVE_SYSTEMC_H],[1],[Defined if have systemc.h])],
[_my_result=no])
AC_MSG_RESULT($_my_result)
AC_SUBST(HAVE_SYSTEMC_H)
# Checks for system services
# Other install directories
pkgdatadir=${datadir}/verilator
AC_SUBST(pkgdatadir)
pkgconfigdir=${datadir}/pkgconfig
AC_SUBST(pkgconfigdir)
AC_OUTPUT(Makefile src/Makefile src/Makefile_obj include/verilated.mk)
AC_OUTPUT
AC_MSG_RESULT([])
AC_MSG_RESULT([Now type 'make'])
AC_MSG_RESULT([Now type 'make' (or sometimes 'gmake') to build Verilator.])
AC_MSG_RESULT([])
+4
View File
@@ -0,0 +1,4 @@
*.1
*.html
*.pdf
Makefile
+82
View File
@@ -0,0 +1,82 @@
= How to contribute to Verilator
Thanks for using Verilator! We welcome your contributions in whatever form.
This contributing document contains some suggestions that may make
contributions flow more efficiently.
==== Did you find a bug?
* Please **Ensure the bug was not already reported** by searching
https://verilator.org/issues[Verilator Issues].
* If you're unable to find an open issue addressing the problem,
https://verilator.org/issues/new[open a new Verilator issue].
** Be sure to include a **code sample** or an **executable test case**
demonstrating the bug and expected behavior that is not occurring.
** The ideal example works against other simulators, and is in the
test_regress/t test format, as described in
link:internals.adoc[docs/internals].
==== Did you write a patch that fixes a bug?
* Please https://verilator.org/issues/new[Open a new issue].
* You may attach a patch to the issue, or (preferred) may request a GitHub
pull request.
** Verilator uses Travis CI to provide continuous integration. You may
want to setup Travis CI on your GitHub branch to ensure your changes
keep the tests passing. See link:internals.adoc[docs/internals].
* Your source-code contributions must be certified as open source, under
the https://developercertificate.org/[Developer Certificate of
Origin]. On your first contribution, you must either:
** Have your patch include the addition of your name to
link:CONTRIBUTORS[docs/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
https://github.com/wking/signed-off-by/blob/master/Documentation/SubmittingPatches[Signed-of-By
convention].
** Email, or post in an issue a statement that you certify your
contributions.
** In any of these cases your name will be added to
link:CONTRIBUTORS[docs/CONTRIBUTORS] and you are agreeing all future
contributions are also certified.
** We occasionally accept contributions where people do not want their name
published. Please email us; you must still privately certify your
contribution.
* Your test contributions are generally considered released into the
Creative Commons Public Domain (CC0), unless you request otherwise or put
a GNU/Artistic license on your file.
* Most important is we get your patch. If you'd like to clean up
indentation and related issues ahead of our feedback, that is
appreciated; please see the coding conventions in
link:internals.adoc[docs/internals].
==== Do you have questions?
* Please see FAQ section and rest of the
https://verilator.org/verilator_doc.html[Verilator manual],
or https://verilator.org/verilator_doc.pdf[Verilator manual (PDF)].
* Ask any question in the
https://verilator.org/forum[Verilator forum].
==== Code of Conduct
* Our contributors and participants pledge to make participation in our
project and our community a positive experience for everyone. We follow
the https://www.contributor-covenant.org/version/1/4/code-of-conduct.html[Contributor
Covenant version 1.4].
Thanks!
+66
View File
@@ -0,0 +1,66 @@
The contributors listed below have certified their Verilator contributions
under the Developer Certificate of Origin (https://developercertificate.org/).
Please see the Verilator manual for 200+ additional contributors. Thanks to all.
Ahmed El-Mahmoudy
Alex Chadwick
Chris Randall
Dan Petrisko
David Horton
David Stanford
Driss Hafdi
Eric Rippey
Garrett Smith
Geza Lore
Gianfranco Costamagna
Glen Gibb
Howard Su
Huang Rui
Iztok Jeras
James Hanlon
James Hutchinson
Jamey Hicks
Jan Van Winkel
Jeremy Bennett
John Coiner
John Demme
Julien Margetts
Kanad Kanhere
Kevin Kiningham
Kuba Ober
Ludwig Rogiers
Lukasz Dalek
Maarten De Braekeleer
Maciej Sobkowski
Marco Widmer
Matthew Ballance
Michael Killough
Mike Popoloski
Nathan Kohagen
Nathan Myers
Patrick Stewart
Peter Horvath
Peter Monsson
Philipp Wagner
Pieter Kapsenberg
Qingyao Sun
Richard Myers
Sean Cross
Sebastien Van Cauwenberghe
Sergi Granell
Stefan Wallentowitz
Stephen Henry
Tim Snyder
Tobias Rosenkranz
Tobias Wölfel
Todd Strader
Tomasz Gorochowik
Tymoteusz Blazejczyk
Vassilis Papaefstathiou
Veripool API Bot
Wilson Snyder
Yossi Nivin
Yuri Victorovich
Yutetsu TAKATSUKASA
Yves Mathieu
+50
View File
@@ -0,0 +1,50 @@
#*****************************************************************************
# DESCRIPTION: Verilator documentation: Makefile pre-configure version
#
# This file is part of Verilator.
#
# Code available from: https://verilator.org
#
#*****************************************************************************
#
# Copyright 2003-2020 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
#
#****************************************************************************/
#
# This file is intended only to be called from the top-level Verilator Makefile.
#### Start of system configuration section. ####
ASCIIDOCTOR = asciidoctor
DOXYGEN = doxygen
#### End of system configuration section. ####
######################################################################
.SUFFIXES:
default:
@echo "error: make not supported here, run 'make docs' from Verilator top-level"
%.html: %.adoc
$(ASCIIDOCTOR) $< -n -o $@
clean mostlyclean distclean maintainer-clean::
rm -f $(SCRIPTS) *.tmp
rm -f *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.log
rm -f *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs *.idx
rm -f *.ev *.evs *.ov *.ovs *.cv *.cvs *.ma *.mas
rm -f *.tex
distclean maintainer-clean::
rm -f *.info* *.1 *.html *.pdf $(INFOS)
rm -f Makefile
.PHONY: doxygen
doxygen:
$(DOXYGEN) doxygen.config
+113
View File
@@ -0,0 +1,113 @@
// DESCRIPTION: Verilator: List of To Do issues.
//
// Copyright 2004-2020 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
* Language support:
** Fix ordering of each bit separately in a signal (mips)
assign b[3:0] = b[7:4]; assign b[7:4] = in;
** Support UDP gate primitives/ cell libraries
(have code for combos - problem is sequential udps)
** Function to eval combo logic after /*verilator public*/ functions [gwaters]
** Support generated clocks (correctness)
** Recursive functions
** Verilog configuration files
** Expression coverage (see notes)
** Better tristate support
** UVM
* Long-term Features
** Assertions
** Tristate support
* Testing:
** Code to make wrapper that sets signals, so can do comparison checks
** New random program generator
** Better graph viewer with search and zoom
* Usability:
** Detect and pre-remove most UNOPTFLATs
** Better reporting of unopt problems, including what lines of code
** Report more errors (all of them?) before exiting [Eugene Weber]
** Auto-create scons config files
** Print version/etc message at runtime. (4.000?)
Include number of lines of code, percent comments, code complexity measurement
<-80chars------------------------------------------------------------------->
Verilator 3.600 - The fast free open-sourced simulator. Copyright 2001-2013.
Verilated #### modules, #### instances, ##### sigs,
#### non-comment lines, ##### ops, ### KB model size
* Lint:
** CDCRSTLOGIC should allow filtering with paths
"waive CDCRSTLOGIC --from a.b.sig --to a.c.sig --via OR"
* Internal Code:
** A Visitor class that understands how to traverse data types
** V3Graph should be templated container type, taking in Vertex + Edge types
** Instead of string, have an VEncodedString/VIdString which contains __DOT__ish
things, to reduce bugs. Also add _20 trailing space to \ encoded names.
* Runtime:
** New evalulation loop ~/src/verilator/notes/event_loop.txt (4.000?)
** Remove all private internal functions from top level wrapper header, move
to new level
** Completely standalone simulation
main() records arguments for $test$plusvars
instantiates top,
does tracing (support $dump?)
calls top->simulateForever()
exits
* Performance:
** Latch optimizations
** Constant propagation
Extra cleaning AND: 1 & ((VARREF >> 1) | ((&VARREF >> 1) & VARREF))
Extra shift (perhaps due to clean): if (1 & CAST (VARREF >> #))
** Gated clock and latch conversion to flops. [JeanPaul Vanitegem]
Could propagate the AND into pos/negedges and let domaining optimize.
** Negedge reset
Switch to remove negedges that don't matter
Can't remove async resets from control flops (like in syncronizers)
** If all references to array have a constant index, blow up into separate signals-per-index
** Bit-multiply for faster bit swapping and a=b[1,3,2] random bit reorderings.
** Move _last sets and all other combo logic inside master
if() that triggers on all possible sense items
** Rewrite and combine V3Life, V3Subst
If block temp only ever set in one place to constant, propagate it
Used in t_mem for array delayed assignments
Replace variables if set later in same cfunc branch
See for example duplicate sets of _narrow in cycle 90/91 of t_select_plusloop
** Same assignment on both if branches
"if (a) { ... b=2; } else { ... b=2;}" -> "b=2; if ..."
Careful though, as b could appear in the statement or multiple times in statement
(Could just require exatly two 'b's in statement)
** Simplify XOR/XNOR/AND/OR bit selection trees
Foo = A[1] ^ A[2] ^ A[3] etc are better as ^ ( A & 32'b...1110 )
** Combine variables into wider elements
Parallel statements on different bits should become single signal
Variables that are always consumed in "parallel" can be joined
** Duplicate assignments in gate optimization
Common to have many separate posedge blocks, each with identical
reset_r <= rst_in
** If signal is used only once (not counting trace), always gate substitute
Don't merge if any combining would form circ logic (out goes back to in)
** Multiple assignments each bit can become single assign with concat
Make sure a SEL of a CONCAT can get the single bit back.
** Usually blocks/values
Enable only after certain time, so VL_TIME_I(32) > 0x1e gets eliminated out
** Better ordering of a<=b, b<=c, put all refs to 'b' next to each other to optimize caching
** I-cache packing improvements (what/how?)
** Data cache organization (order of vars in class)
First have clocks,
then bools instead of uint32_t's
then based on what sense list they come from, all outputs, then all inputs
finally have any signals part of a "usually" block, or constant.
** Rather then tracking widths, have a MSB...LSB of this expression
(or better, a bitmask of bits relevant in this expression)
** Track recirculation and convert into clock-enables
** Clock enables should become new clocking domains for speed
** If floped(a) & flopped(b) and no other a&b, then instead flop(a&b).
** Sort by output bitselects so can combine more assignments (see DDP example dx_dm signal)
+6
View File
@@ -0,0 +1,6 @@
/*! \mainpage Verilator Doxygen Documentation
*
* \section intro_sec Introduction
*
* This is a full doxygen analysis of the Verilator source tree.
*/
+1765
View File
File diff suppressed because it is too large Load Diff
+305
View File
@@ -0,0 +1,305 @@
= Verilator Installation
:toc: right
// Github doesn't render unless absolute URL
image::https://www.veripool.org/img/verilator_256_200_min.png[Logo,256,200,role="right"]
== Introduction
This discusses how to install Verilator. For more general information
please see https://verilator.org[verilator.org].
== Quick-start
=== Install From a Package Manager
Using a distribution's package manager is the easiest way to get
started. (Note packages are unlikely to have the most recent version, so
Git, below, maybe a better alternative.) To install as a package:
apt-get install verilator
If this works, skip down to <<Running Verilator>>.
=== Docker
Verilator is available in pre-built Docker containers. See
https://github.com/verilator/verilator/blob/master/ci/docker/run/README.adoc
=== Git
Installing Verilator with Git provides the most flexibility.
For additional options and details see the additional sections below. In
brief:
// Also update README
....
# Prerequisites:
#sudo apt-get install git make autoconf g++ flex bison
#sudo apt-get install libfl2 # Ubuntu only (ignore if gives error)
#sudo apt-get install libfl-dev # Ubuntu only (ignore if gives error)
git clone https://git.veripool.org/git/verilator # Only first time
## Note the URL above is not a page you can see with a browser, it's for git only
# Every time you need to build:
unsetenv VERILATOR_ROOT # For csh; ignore error if on bash
unset VERILATOR_ROOT # For bash
cd verilator
git pull # Make sure git repository is up-to-date
git tag # See what versions exist
#git checkout master # Use development branch (e.g. recent bug fixes)
#git checkout stable # Use most recent stable release
#git checkout v{version} # Switch to specified release version
autoconf # Create ./configure script
./configure
make
sudo make install
# Now see "man verilator" or online verilator.pdf's for the example tutorials
....
If this works, skip down to <<Running Verilator>>.
== Detailed Build Instructions
This section describes details of the build process, and assumes you are
building from Git or a tarball. For using a pre-built binary for your
Linux distribution, see instead <<Install From a Package Manager>>.
=== OS Requirements
Verilator is developed and has primary testing on Ubuntu. Versions have
also built on Redhat Linux, Apple OS-X, HPUX and Solaris. It should run
with minor porting on any GNU/Linux-ish platform. Verilator also works on
Windows under Cygwin, and Windows under MinGW (gcc -mno-cygwin). Verilated
output (not Verilator itself) compiles under all the options above, plus
MSVC++.
=== Install Prerequisites
To build or run Verilator you need these standard packages:
sudo apt-get install perl python3 make
sudo apt-get install g++ # Alternatively, clang
sudo apt-get install libgz # Non-Ubuntu (ignore if gives error)
sudo apt-get install libfl2 libfl-dev zlibc zlib1g zlib1g-dev # Ubuntu only (ignore if gives error)
To build or run the following are optional but should be installed for
good performance:
sudo apt-get install ccache # If present at build, needed for run
sudo apt-get install libgoogle-perftools-dev numactl
To build Verilator you will need to install these packages; these do not
need to be present to run Verilator:
sudo apt-get install git autoconf flex bison
Those developing Verilator itself may also want these (see internals.adoc):
sudo apt-get install gdb asciidoctor graphviz cmake clang clang-format gprof lcov
cpan install Pod::Perldoc
cpan install Unix::Processors
cpan install Parallel::Forker
cpan install Bit::Vector
==== Install SystemC
If you will be using SystemC (vs straight C++ output), download
https://www.accellera.org/downloads/standards/systemc[SystemC].
Follow their installation instructions. You will need to set `SYSTEMC_INCLUDE`
to point to the include directory with `systemc.h` in it, and `SYSTEMC_LIBDIR`
to points to the directory with `libsystemc.a` in it. (Older installations
may set `SYSTEMC` and `SYSTEMC_ARCH` instead.)
==== Install GTKWave
To make use of Verilator FST tracing you will want
http://gtkwave.sourceforge.net/[GTKwave] installed, however this is not
required at Verilator build time.
=== Obtain Sources
You may use Git or a tarball for the sources. Git is the supported option.
(If using a historical build that uses a tarball, tarballs are obtained
from https://www.veripool.org/projects/verilator/wiki/Download[Verilator
Downloads]; we presume you know how to use it, and is not described here.)
Get the sources from the repository: (You need do this only once, ever.)
git clone https://git.veripool.org/git/verilator # Only first time
## Note the URL above is not a page you can see with a browser, it's for git only
Enter the checkout and determine what version/branch to use:
cd verilator
git pull # Make sure we're up-to-date
git tag # See what versions exist
#git checkout master # Use development branch (e.g. recent bug fix)
#git checkout stable # Use most recent release
#git checkout v{version} # Switch to specified release version
=== Auto Configure
Create the configuration script:
autoconf # Create ./configure script
=== Eventual Installation Options
Before configuring the build, you have to decide how you're going to
eventually install the kit. Verilator will be compiling the current value
of `VERILATOR_ROOT`, `SYSTEMC_INCLUDE`, and `SYSTEMC_LIBDIR` as defaults
into the executable, so they must be correct before configuring.
These are the options:
==== 1. Run-in-Place from VERILATOR_ROOT
Our personal favorite is to always run Verilator in-place from its Git
directory. This allows the easiest experimentation and upgrading, and
allows many versions of Verilator to co-exist on a system.
export VERILATOR_ROOT=`pwd` # if your shell is bash
setenv VERILATOR_ROOT `pwd` # if your shell is csh
./configure
# Running will use files from $VERILATOR_ROOT, so no install needed
Note after installing (below steps), a calling program or shell must set
the environment variable `VERILATOR_ROOT` to point to this Git directory,
then execute `$VERILATOR_ROOT/bin/verilator`, which will find the path to
all needed files.
==== 2. Install into a CAD Disk
You may eventually be installing onto a project/company-wide "CAD" tools
disk that may support multiple versions of every tool. Target the build to
a destination directory name that includes the Verilator version name:
unset VERILATOR_ROOT # if your shell is bash
unsetenv VERILATOR_ROOT # if your shell is csh
# For the tarball, use the version number instead of git describe
./configure --prefix /CAD_DISK/verilator/`git describe | sed "s/verilator_//"`
Note after installing (below steps), if you use
http://modules.sourceforge.net/[modulecmd], you'll want a module file like
the following:
.modulecmd's verilator/version file
----
set install_root /CAD_DISK/verilator/{version-number-used-above}
unsetenv VERILATOR_ROOT
prepend-path PATH $install_root/bin
prepend-path MANPATH $install_root/man
prepend-path PKG_CONFIG_PATH $install_root/share/pkgconfig
----
==== 3. Install into a Specific Path
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 `$PATH`.
==== 4. Install System Globally
The final option is to eventually install Verilator globally, using the
normal system paths:
unset VERILATOR_ROOT # if your shell is bash
unsetenv VERILATOR_ROOT # if your shell is csh
./configure
Then after installing (below) the binary directories should already be in
your `$PATH`.
=== Configure
The command to configure the package was described in the previous step.
Developers should configure to have more complete developer tests.
Additional packages may be required for these tests.
export VERILATOR_AUTHOR_SITE=1 # Put in your .bashrc
./configure --enable-longtests ...above options...
=== Compile
Compile Verilator:
make -j
=== Test
Check the compilation by running self-tests:
make test
=== Install
If you used any but the <<1. Run-in-Place from VERILATOR_ROOT>> scheme,
install to the OS-standard place:
make install
== Running Verilator
To run Verilator, see the example sections in the
https://verilator.org/verilator_doc.html[Verilator manual (HTML)],
or https://verilator.org/verilator_doc.pdf[Verilator manual (PDF)].
Also see the `examples/` directory that is part of the kit, and is installed
(in a OS-specific place, often in e.g. `/usr/local/share/verilator/examples`).
cd examples/make_hello_c
make
Note if you did a `make install` above you should not have `VERILATOR_ROOT`
set in your environment; it is built into the executable.
== Announcements
To get notified of new releases, go to
https://github.com/verilator/verilator-announce[Verilator announcement
repository] and follow the instructions there.
== Directory Structure
Some relevant files and directories in this package are as follows:
Changes => Version history
README.adoc => This document
bin/verilator => Compiler wrapper invoked to Verilate code
docs/ => Additional documentation
examples/make_hello_c => Example GNU-make simple Verilog->C++ conversion
examples/make_hello_sc => Example GNU-make simple Verilog->SystemC conversion
examples/make_tracing_c => Example GNU-make Verilog->C++ with tracing
examples/make_tracing_sc => Example GNU-make Verilog->SystemC with tracing
examples/make_protect_lib => Example using --protect-lib
examples/cmake_hello_c => Example building make_hello_c with CMake
examples/cmake_hello_sc => Example building make_hello_sc with CMake
examples/cmake_tracing_c => Example building make_tracing_c with CMake
examples/cmake_tracing_sc => Example building make_tracing_sc with CMake
examples/cmake_protect_lib => Example building make_protect_lib with CMake
include/ => Files that should be in your -I compiler path
include/verilated*.cpp => Global routines to link into your simulator
include/verilated*.h => Global headers
include/verilated.mk => Common Makefile
src/ => Translator source code
test_regress => Internal tests
For files created after a design is Verilated, see the
https://verilator.org/verilator_doc.html[Verilator manual (HTML)],
or https://verilator.org/verilator_doc.pdf[Verilator manual (PDF)].
== License
Copyright 2008-2020 by Wilson Snyder. Verilator is free software; you can
redistribute it and/or modify it under the terms of either the GNU Lesser
General Public License Version 3 or the Perl Artistic License Version 2.0.
// SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
+1026
View File
File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 9.9 KiB

+72
View File
@@ -0,0 +1,72 @@
= Verilator XML Output
:toc: right
// Github doesn't render unless absolute URL
image::https://www.veripool.org/img/verilator_256_200_min.png[Logo,256,200,role="right"]
== Introduction
This document describes Verilator's XML output. For more general information
please see https://verilator.org[verilator.org].
== General
Verilator's XML output is enabled with the `--xml-only` flag. It contains
limited information about the elaborated design including files, modules,
instance hierarchy, logic and data types. There is no formal schema since part
of the structure of the XML document matches the compiled code which would
require the schema to describe legal SystemVerilog structure. The intended
usage is to enable other downstream tools to take advantage of Verilator's
parser.
== Structure
The XML document consists of 4 sections within the top level `verilator_xml`
element:
`<files>`...`</files>`::
This section contains a list of all design files read, including the
built-in constructs and the command line as their own entries. Each
`<file>` has an attribute `id` which is a short ASCII string unique to that
file. Other elements' `loc` attributes use this id to refer to a particular
file.
`<module_files>`...`</module_files>`::
All files containing Verilog module definitions are listed in this section.
This element's contents is a subset of the `<files>` element's contents.
`<cells>`...`</cells>`::
The cells section of the XML document contains the design instance
hierarchy. Each instance is represented with the `<cell>` element 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 column
number and last column number of the identifier where the module was
instanced, separated by commas.
* `name`: The instance name.
* `submodname`: The module name uniquified with particular parameter values (if any).
* `hier`: The full hierarchy path.
`<netlist>`...`</netlist>`::
The netlist section contains a number of `<module>`...`</module>` elements,
each describing the contents of that module, and a single `<typetable>`...
`</typetable>` element which lists all used types used within the
modules. Each type has a numeric `id` attribute that is referred to by
elements in the `<module>` elements using the `dtype_id` attribute.
== Distribution
Copyright 2020-2020 by Wilson Snyder. Verilator is free software; you can
redistribute it and/or modify it under the terms of either the GNU Lesser
General Public License Version 3 or the Perl Artistic License Version 2.0.
// SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
+1
View File
@@ -0,0 +1 @@
build*
+36
View File
@@ -0,0 +1,36 @@
######################################################################
#
# DESCRIPTION: Verilator CMake Example: Small CMakeLists.txt
#
# This is an example cmake script to build a verilog to systemc project
# using cmake and verilator.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# This example builds the tracing_c example using CMake
# To use it, run the following:
# cd /path/to/verilator/examples/cmake_c
# rm -rf build && mkdir build && cd build
# cmake ..
# cmake --build .
cmake_minimum_required(VERSION 3.8)
project(cmake_hello_c)
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
if (NOT verilator_FOUND)
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
endif()
# Create a new executable target that will contain all your sources
add_executable(example ../make_hello_c/sim_main.cpp)
# Add the Verilated circuit to the target
verilate(example
INCLUDE_DIRS "../make_hello_c"
SOURCES ../make_hello_c/top.v)
+78
View File
@@ -0,0 +1,78 @@
######################################################################
#
# DESCRIPTION: Verilator CMake example usage
#
# This file shows usage of the CMake script.
# This makefile is here for testing the examples and should
# generally not be added to a CMake project.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
######################################################################
# Set up variables
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR_COVERAGE = verilator_coverage
else
export VERILATOR_ROOT
VERILATOR_COVERAGE = $(VERILATOR_ROOT)/bin/verilator_coverage
endif
######################################################################
# Check if CMake is installed and of correct version
ifeq ($(shell which cmake),)
TARGET := nocmake
else
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -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)
ifeq ($(CMAKE_GT_3_8),true)
TARGET := run
else
TARGET := oldcmake
endif
endif
default: $(TARGET)
run:
@echo
@echo "-- Verilator CMake hello world example"
@echo
@echo "-- VERILATE ----------------"
mkdir -p build && cd build && cmake ..
@echo
@echo "-- BUILD -------------------"
cmake --build build
@echo
@echo "-- RUN ---------------------"
build/example
@echo
@echo "-- DONE --------------------"
@echo
clean mostlyclean distclean maintainer-clean:
@rm -rf build logs
nocmake:
@echo
@echo "%Skip: CMake has not been found"
@echo
oldcmake:
@echo
@echo "%Skip: CMake version is too old (need at least 3.8)"
@echo
+1
View File
@@ -0,0 +1 @@
build*
+45
View File
@@ -0,0 +1,45 @@
######################################################################
#
# DESCRIPTION: Verilator CMake Example: Small CMakeLists.txt with SystemC
#
# This is an example cmake script to build a verilog to SystemC project
# using CMake and Verilator.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# This example builds the tracing_sc example using CMake
# To use it, run the following:
# cd /path/to/verilator/examples/cmake_sc
# rm -rf build && mkdir build && cd build
# cmake ..
# cmake --build .
cmake_minimum_required(VERSION 3.8)
project(cmake_hello_sc)
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
if (NOT verilator_FOUND)
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
endif()
# SystemC dependencies
set(THREADS_PREFER_PTHREAD_FLAG ON)
find_package(Threads REQUIRED)
# Find SystemC using SystemC's CMake integration
find_package(SystemCLanguage QUIET)
# Create a new executable target that will contain all your sources
add_executable(example ../make_hello_sc/sc_main.cpp)
# Add the Verilated circuit to the target
verilate(example SYSTEMC
INCLUDE_DIRS "../make_hello_sc"
SOURCES ../make_hello_sc/top.v)
verilator_link_systemc(example)
+128
View File
@@ -0,0 +1,128 @@
######################################################################
#
# DESCRIPTION: Verilator CMake example usage
#
# This file shows usage of the CMake script.
# This makefile is here for testing the examples and should
# generally not be added to a CMake project.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
######################################################################
# Set up variables
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR_COVERAGE = verilator_coverage
else
export VERILATOR_ROOT
VERILATOR_COVERAGE = $(VERILATOR_ROOT)/bin/verilator_coverage
endif
######################################################################
# Check if CMake is installed and of correct version
ifeq ($(shell which cmake),)
TARGET := nocmake
else
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -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)
ifneq ($(CMAKE_GT_3_8),true)
TARGET := oldcmake
else
# Test existence of SYSTEMC_INCLUDE and SYSTEMC_LIBDIR environment variabless
ifneq (,$(SYSTEMC_INCLUDE))
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
# This will print a CMake error about processing arguments that can (currently) be ignored.
ifneq (SYSTEMC_SET, true)
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)))
SYSTEMC_SET := true
endif
endif
ifeq ($(SYSTEMC_SET), true)
TARGET := run
else
TARGET := nosc
endif
endif
endif
default: $(TARGET)
run:
@echo
@echo "-- Verilator CMake SystemC hello-world simple example"
@echo
@echo "-- VERILATE ----------------"
mkdir -p build && cd build && cmake ..
@echo
@echo "-- BUILD -------------------"
cmake --build build
@echo
@echo "-- RUN ---------------------"
@mkdir -p logs
build/example
@echo "-- DONE --------------------"
@echo "Note: Once this example is understood, see examples/cmake_tracing_sc."
@echo "Note: Also see the EXAMPLE section in the verilator manpage/document."
clean mostlyclean distclean maintainer-clean:
@rm -rf build logs
nocmake:
@echo
@echo "%Skip: CMake has not been found"
@echo
oldcmake:
@echo
@echo "%Skip: CMake version is too old (need at least 3.8)"
@echo
nosc:
@echo
@echo "%Skip: CMake could not find SystemC."
@echo "% Make sure that either:"
@echo "% - The environment variables SYSTEMC_INCLUDE and SYSTEMC_LIBDIR are exported."
@echo "% - Or, the environment variable SYSTEMC_ROOT is exported."
@echo "% - Or, The environment variable SYSTEMC is exported."
@echo "% - Or, if the SystemC installation provides CMake support,"
@echo "% that its installation prefix is in CMAKE_PREFIX_PATH."
@echo "% Also that the C++ standard of the SystemC library is the same as this example."
@echo "% Please see the Verilator documentation's CMake section for more information."
@echo
+1
View File
@@ -0,0 +1 @@
build*
+59
View File
@@ -0,0 +1,59 @@
######################################################################
#
# DESCRIPTION: Verilator CMake Example: Small CMakeLists.txt
#
# This is an example cmake script to build a verilog to systemc project
# using cmake and verilator.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# This example builds the tracing_c example using CMake
# To use it, run the following:
# cd /path/to/verilator/examples/cmake_c
# rm -rf build && mkdir build && cd build
# cmake ..
# cmake --build .
cmake_minimum_required(VERSION 3.8)
project(cmake_protect_lib)
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
if (NOT verilator_FOUND)
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
endif()
# Create the main executable target
add_executable(example ../make_protect_lib/sim_main.cpp)
# Create a secret library
add_library(verilated_secret STATIC) # or SHARED for a shared library
target_link_libraries(example PRIVATE verilated_secret)
# To create both libraries on CMake >= 3.12 replace the above 2 lines with the following:
# add_library(verilated_secret OBJECT)
# set_property(TARGET verilated_secret PROPERTY POSITION_INDEPENDENT_CODE 1)
# add_library(verilated_secret_static STATIC $<TARGET_OBJECTS:verilated_secret>)
# set_target_properties(verilated_secret_static PROPERTIES OUTPUT_NAME verilated_secret)
# add_library(verilated_secret_shared SHARED $<TARGET_OBJECTS:verilated_secret>)
# set_target_properties(verilated_secret_shared PROPERTIES OUTPUT_NAME verilated_secret)
# target_link_libraries(example PRIVATE verilated_secret_static)
# Setup random seed
verilator_generate_key(KEY_INIT)
set(PROTECT_KEY ${KEY_INIT} CACHE STRING "Random seed for protection")
# Add the Verilated modules to the targets
verilate(verilated_secret
VERILATOR_ARGS --protect-lib verilated_secret
--protect-key ${PROTECT_KEY}
DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/verilated_secret
SOURCES ../make_protect_lib/secret_impl.v)
# Include location of verilated_secret.sv wrapper
verilate(example
VERILATOR_ARGS "-I${CMAKE_CURRENT_BINARY_DIR}/verilated_secret"
SOURCES ../make_protect_lib/top.v)
+78
View File
@@ -0,0 +1,78 @@
######################################################################
#
# DESCRIPTION: Verilator CMake example usage
#
# This file shows usage of the CMake script.
# This makefile is here for testing the examples and should
# generally not be added to a CMake project.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
######################################################################
# Set up variables
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR_COVERAGE = verilator_coverage
else
export VERILATOR_ROOT
VERILATOR_COVERAGE = $(VERILATOR_ROOT)/bin/verilator_coverage
endif
######################################################################
# Check if CMake is installed and of correct version
ifeq ($(shell which cmake),)
TARGET := nocmake
else
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -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)
ifeq ($(CMAKE_GT_3_8),true)
TARGET := run
else
TARGET := oldcmake
endif
endif
default: $(TARGET)
run:
@echo
@echo "-- Verilator CMake protect_lib example"
@echo
@echo "-- VERILATE ----------------"
mkdir -p build && cd build && cmake ..
@echo
@echo "-- BUILD -------------------"
cmake --build build
@echo
@echo "-- RUN ---------------------"
build/example
@echo
@echo "-- DONE --------------------"
@echo
clean mostlyclean distclean maintainer-clean:
@rm -rf build logs
nocmake:
@echo
@echo "%Skip: CMake has not been found"
@echo
oldcmake:
@echo
@echo "%Skip: CMake version is too old (need at least 3.8)"
@echo
+2
View File
@@ -0,0 +1,2 @@
build*
logs
+37
View File
@@ -0,0 +1,37 @@
######################################################################
#
# DESCRIPTION: Verilator CMake Example: Small CMakeLists.txt with tracing
#
# This is an example cmake script to build a verilog to systemc project
# using cmake and verilator.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# This example builds the make_tracing_c example using CMake
# To use it, run the following:
# cd /path/to/verilator/examples/cmake_tracing_c
# rm -rf build && mkdir build && cd build
# cmake ..
# cmake --build .
cmake_minimum_required(VERSION 3.8)
project(cmake_tracing_c)
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
if (NOT verilator_FOUND)
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
endif()
# Create a new executable target that will contain all your sources
add_executable(example ../make_tracing_c/sim_main.cpp)
# Add the Verilated circuit to the target
verilate(example COVERAGE TRACE
INCLUDE_DIRS "../make_tracing_c"
VERILATOR_ARGS -f ../make_tracing_c/input.vc -Os -x-assign 0
SOURCES ../make_tracing_c/top.v)
+84
View File
@@ -0,0 +1,84 @@
######################################################################
#
# DESCRIPTION: Verilator CMake example usage
#
# This file shows usage of the CMake script.
# This makefile is here for testing the examples and should
# generally not be added to a CMake project.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
######################################################################
# Set up variables
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR_COVERAGE = verilator_coverage
else
export VERILATOR_ROOT
VERILATOR_COVERAGE = $(VERILATOR_ROOT)/bin/verilator_coverage
endif
######################################################################
# Check if CMake is installed and of correct version
ifeq ($(shell which cmake),)
TARGET := nocmake
else
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -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)
ifeq ($(CMAKE_GT_3_8),true)
TARGET := run
else
TARGET := oldcmake
endif
endif
default: $(TARGET)
run:
@echo
@echo "-- Verilator CMake tracing example"
@echo
@echo "-- VERILATE ----------------"
mkdir -p build && cd build && cmake ..
@echo
@echo "-- BUILD -------------------"
cmake --build build
@echo
@echo "-- RUN ---------------------"
@mkdir -p logs
build/example +trace
@echo
@echo "-- COVERAGE ----------------"
$(VERILATOR_COVERAGE) --annotate logs/annotated logs/coverage.dat
@echo
@echo "-- DONE --------------------"
@echo "To see waveforms, open vlt_dump.vcd in a waveform viewer"
@echo
clean mostlyclean distclean maintainer-clean:
@rm -rf build logs
nocmake:
@echo
@echo "%Skip: CMake has not been found"
@echo
oldcmake:
@echo
@echo "%Skip: CMake version is too old (need at least 3.8)"
@echo
@@ -1,8 +1,7 @@
*.old
*.dmp
*.log
*.csrc
*.vcd
obj_*
logs
project
build*
+46
View File
@@ -0,0 +1,46 @@
######################################################################
#
# DESCRIPTION: Verilator CMake Example: Small CMakeLists.txt with SystemC tracing
#
# This is an example cmake script to build a verilog to SystemC project
# using CMake and Verilator.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# This example builds the tracing_sc example using CMake
# To use it, run the following:
# cd /path/to/verilator/examples/cmake_tracing_sc
# rm -rf build && mkdir build && cd build
# cmake ..
# cmake --build .
cmake_minimum_required(VERSION 3.8)
project(cmake_tracing_sc_example)
find_package(verilator HINTS $ENV{VERILATOR_ROOT} ${VERILATOR_ROOT})
if (NOT verilator_FOUND)
message(FATAL_ERROR "Verilator was not found. Either install it, or set the VERILATOR_ROOT environment variable")
endif()
# SystemC dependencies
set(THREADS_PREFER_PTHREAD_FLAG ON)
find_package(Threads REQUIRED)
# Find SystemC using SystemC's CMake integration
find_package(SystemCLanguage QUIET)
# Create a new executable target that will contain all your sources
add_executable(example ../make_tracing_sc/sc_main.cpp)
# Add the Verilated circuit to the target
verilate(example SYSTEMC COVERAGE TRACE
INCLUDE_DIRS "../make_tracing_sc"
VERILATOR_ARGS -f ../make_tracing_sc/input.vc -Os -x-assign 0
SOURCES ../make_tracing_sc/top.v)
verilator_link_systemc(example)
+133
View File
@@ -0,0 +1,133 @@
######################################################################
#
# DESCRIPTION: Verilator CMake example usage
#
# This file shows usage of the CMake script.
# This makefile is here for testing the examples and should
# generally not be added to a CMake project.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
######################################################################
# Set up variables
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR_COVERAGE = verilator_coverage
else
export VERILATOR_ROOT
VERILATOR_COVERAGE = $(VERILATOR_ROOT)/bin/verilator_coverage
endif
######################################################################
# Check if CMake is installed and of correct version
ifeq ($(shell which cmake),)
TARGET := nocmake
else
CMAKE_VERSION := $(shell cmake --version | grep -Po '(\d[\.\d]+)')
CMAKE_MAJOR := $(shell echo $(CMAKE_VERSION) | cut -f1 -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)
ifneq ($(CMAKE_GT_3_8),true)
TARGET := oldcmake
else
# Test existence of SYSTEMC_INCLUDE and SYSTEMC_LIBDIR environment variabless
ifneq (,$(SYSTEMC_INCLUDE))
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
# This will print a CMake error about processing arguments that can (currently) be ignored.
ifneq (SYSTEMC_SET, true)
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)))
SYSTEMC_SET := true
endif
endif
ifeq ($(SYSTEMC_SET), true)
TARGET := run
else
TARGET := nosc
endif
endif
endif
default: $(TARGET)
run:
@echo
@echo "-- Verilator CMake SystemC tracing example"
@echo
@echo "-- VERILATE ----------------"
mkdir -p build && cd build && cmake ..
@echo
@echo "-- BUILD -------------------"
cmake --build build
@echo
@echo "-- RUN ---------------------"
@mkdir -p logs
build/example +trace
@echo
@echo "-- COVERAGE ----------------"
$(VERILATOR_COVERAGE) --annotate logs/annotated logs/coverage.dat
@echo
@echo "-- DONE --------------------"
@echo "To see waveforms, open vlt_dump.vcd in a waveform viewer"
@echo
clean mostlyclean distclean maintainer-clean:
@rm -rf build logs
nocmake:
@echo
@echo "%Skip: CMake has not been found"
@echo
oldcmake:
@echo
@echo "%Skip: CMake version is too old (need at least 3.8)"
@echo
nosc:
@echo
@echo "%Skip: CMake could not find SystemC."
@echo "% Make sure that either:"
@echo "% - The environment variables SYSTEMC_INCLUDE and SYSTEMC_LIBDIR are exported."
@echo "% - Or, the environment variable SYSTEMC_ROOT is exported."
@echo "% - Or, The environment variable SYSTEMC is exported."
@echo "% - Or, if the SystemC installation provides CMake support,"
@echo "% that its installation prefix is in CMAKE_PREFIX_PATH."
@echo "% Also that the C++ standard of the SystemC library is the same as this example."
@echo "% Please see the Verilator documentation's CMake section for more information."
@echo
@@ -3,4 +3,4 @@
*.csrc
*.vcd
obj_*
project
logs
+49
View File
@@ -0,0 +1,49 @@
######################################################################
#
# DESCRIPTION: Verilator Example: Small Makefile
#
# This calls the object directory makefile. That allows the objects to
# be placed in the "current directory" which simplifies the Makefile.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# Check for sanity to avoid later confusion
ifneq ($(words $(CURDIR)),1)
$(error Unsupported: GNU Make cannot build in directories containing spaces, build elsewhere: '$(CURDIR)')
endif
######################################################################
# This is intended to be a minimal example. Before copying this to start a
# real project, it is better to start with a more complete example,
# e.g. examples/make_tracing_c.
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR = verilator
else
export VERILATOR_ROOT
VERILATOR = $(VERILATOR_ROOT)/bin/verilator
endif
default:
@echo "-- Verilator hello-world simple example"
@echo "-- VERILATE & BUILD --------"
$(VERILATOR) -cc --exe --build -j top.v sim_main.cpp
@echo "-- RUN ---------------------"
obj_dir/Vtop
@echo "-- DONE --------------------"
@echo "Note: Once this example is understood, see examples/make_tracing_c."
@echo "Note: Also see the EXAMPLE section in the verilator manpage/document."
######################################################################
maintainer-copy::
clean mostlyclean distclean maintainer-clean::
-rm -rf obj_dir *.log *.dmp *.vpd core
+42
View File
@@ -0,0 +1,42 @@
// DESCRIPTION: Verilator: Verilog example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2017 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
//======================================================================
// Include common routines
#include <verilated.h>
// Include model header, generated from Verilating "top.v"
#include "Vtop.h"
int main(int argc, char** argv, char** env) {
// See a similar example walkthrough in the verilator manpage.
// This is intended to be a minimal example. Before copying this to start a
// real project, it is better to start with a more complete example,
// e.g. examples/c_tracing.
// Prevent unused variable warnings
if (false && argc && argv && env) {}
// Construct the Verilated model, from Vtop.h generated from Verilating "top.v"
Vtop* top = new Vtop;
// Simulate until $finish
while (!Verilated::gotFinish()) {
// Evaluate model
top->eval();
}
// Final model cleanup
top->final();
// Destroy model
delete top;
// Fin
exit(0);
}
+13
View File
@@ -0,0 +1,13 @@
// DESCRIPTION: Verilator: Verilog example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2017 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
// See also the EXAMPLE section in the verilator manpage/document.
module top;
initial begin
$display("Hello World!");
$finish;
end
endmodule
@@ -1,8 +1,6 @@
*.old
*.dmp
*.log
*.csrc
*.vcd
obj_*
logs
project
+64
View File
@@ -0,0 +1,64 @@
######################################################################
#
# DESCRIPTION: Verilator Example: Small Makefile
#
# This calls the object directory makefile. That allows the objects to
# be placed in the "current directory" which simplifies the Makefile.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# Check for sanity to avoid later confusion
ifneq ($(words $(CURDIR)),1)
$(error Unsupported: GNU Make cannot build in directories containing spaces, build elsewhere: '$(CURDIR)')
endif
######################################################################
# This is intended to be a minimal example. Before copying this to start a
# real project, it is better to start with a more complete example,
# e.g. examples/make_tracing_sc.
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR = verilator
else
export VERILATOR_ROOT
VERILATOR = $(VERILATOR_ROOT)/bin/verilator
endif
# Check if SC exists via a verilator call (empty if not)
SYSTEMC_EXISTS := $(shell $(VERILATOR) --getenv SYSTEMC_INCLUDE)
ifneq ($(SYSTEMC_EXISTS),)
default: run
else
default: nosc
endif
run:
@echo "-- Verilator hello-world simple example"
@echo "-- VERILATE & COMPILE ------"
$(VERILATOR) -sc --exe --build -j top.v sc_main.cpp
@echo "-- RUN ---------------------"
obj_dir/Vtop
@echo "-- DONE --------------------"
@echo "Note: Once this example is understood, see examples/make_tracing_sc."
@echo "Note: Also see the EXAMPLE section in the verilator manpage/document."
######################################################################
nosc:
@echo
@echo "%Skip: SYSTEMC_INCLUDE not in environment"
@echo "(If you have SystemC see the README, and rebuild Verilator)"
@echo
maintainer-copy::
clean mostlyclean distclean maintainer-clean::
-rm -rf obj_dir *.log *.dmp *.vpd core
+52
View File
@@ -0,0 +1,52 @@
// -*- SystemC -*-
// DESCRIPTION: Verilator Example: Top level main for invoking SystemC model
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2017 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
//======================================================================
// SystemC global header
#include <systemc.h>
// Include common routines
#include <verilated.h>
// Include model header, generated from Verilating "top.v"
#include "Vtop.h"
int sc_main(int argc, char* argv[]) {
// See a similar example walkthrough in the verilator manpage.
// This is intended to be a minimal example. Before copying this to start a
// real project, it is better to start with a more complete example,
// e.g. examples/c_tracing.
// Prevent unused variable warnings
if (false && argc && argv) {}
// Construct the Verilated model, from Vtop.h generated from Verilating "top.v"
Vtop* top = new Vtop("top");
// Initialize SC model
#if (SYSTEMC_VERSION >= 20070314)
sc_start(1, SC_NS);
#else
sc_start(1);
#endif
// Simulate until $finish
while (!Verilated::gotFinish()) {
#if (SYSTEMC_VERSION >= 20070314)
sc_start(1, SC_NS);
#else
sc_start(1);
#endif
}
// Final model cleanup
top->final();
// Fin
return 0;
}
+13
View File
@@ -0,0 +1,13 @@
// DESCRIPTION: Verilator: Verilog example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2017 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
// See also the EXAMPLE section in the verilator manpage/document.
module top;
initial begin
$display("Hello World!");
$finish;
end
endmodule
+2
View File
@@ -0,0 +1,2 @@
obj_*
logs
+96
View File
@@ -0,0 +1,96 @@
######################################################################
#
# DESCRIPTION: Verilator Example: --protect-lib Makefile
#
# This calls the object directory makefiles. That allows the objects to
# be placed in the "current directory" which simplifies the Makefile.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# Check for sanity to avoid later confusion
ifneq ($(words $(CURDIR)),1)
$(error Unsupported: GNU Make cannot build in directories containing spaces, build elsewhere: '$(CURDIR)')
endif
######################################################################
# Set up variables
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR = verilator
else
export VERILATOR_ROOT
VERILATOR = $(VERILATOR_ROOT)/bin/verilator
endif
VERILATOR_FLAGS =
# Generate C++
VERILATOR_FLAGS += -cc
# Optimize
VERILATOR_FLAGS += -Os -x-assign 0
# Warn abount lint issues; may not want this on less solid designs
VERILATOR_FLAGS += -Wall
# Make waveforms
TOP_VERILATOR_FLAGS = $(VERILATOR_FLAGS) --trace
######################################################################
default: run
run:
@echo
@echo "-- Verilator --protect-lib example -_--------------------------"
@echo
@echo "-- VERILATE secret module -------------------------------------"
@echo " --protect-lib will produce both a static and shared library"
@echo " In this example the static library is used, but some"
@echo " simulators may require the shared library."
@echo "---------------------------------------------------------------"
$(VERILATOR) $(VERILATOR_FLAGS) --protect-lib verilated_secret -Mdir obj_dir_secret/ secret_impl.v
@echo
@echo "-- COMPILE protected library ----------------------------------"
@echo " This builds verilated_secret.sv, libverilated_secret.a and"
@echo " libverilated_secret.so which can be distributed apart from"
@echo " the source"
@echo "---------------------------------------------------------------"
$(MAKE) -j 4 -C obj_dir_secret -f Vsecret_impl.mk
@echo
@echo "-- VERILATE top module ----------------------------------------"
@echo " Use the SystemVerilog wrapper (verilated_secret.sv) and the"
@echo " library (libverilated_secret.a) generated from the previous"
@echo " step"
@echo "---------------------------------------------------------------"
$(VERILATOR) $(TOP_VERILATOR_FLAGS) --exe -LDFLAGS '-L../obj_dir_secret -lverilated_secret -static' top.v obj_dir_secret/verilated_secret.sv sim_main.cpp
@echo
@echo "-- COMPILE entire design --------------------------------------"
$(MAKE) -j 4 -C obj_dir -f Vtop.mk
@echo
@echo "-- RUN --------------------------------------------------------"
@mkdir -p logs
obj_dir/Vtop +trace
@echo
@echo "-- DONE -------------------------------------------------------"
@echo "To see waveforms, open logs/vlt_dump.vcd in a waveform viewer"
@echo
######################################################################
# Other targets
show-config:
$(VERILATOR) -V
maintainer-copy::
clean mostlyclean distclean maintainer-clean::
-rm -rf obj_dir* logs *.log core
+30
View File
@@ -0,0 +1,30 @@
// DESCRIPTION: Verilator: --protect-lib example secret module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2019 by Todd Strader.
// SPDX-License-Identifier: CC0-1.0
// This module will be used as libsecret.a or libsecret.so without
// exposing the source.
module secret_impl
(
input [31:0] a,
input [31:0] b,
output logic [31:0] x,
input clk);
logic [31:0] accum_q = 0;
logic [31:0] secret_value = 9;
initial $display("%m: initialized");
always @(posedge clk) begin
accum_q <= accum_q + a;
if (accum_q > 10)
x <= b;
else
x <= a + b + secret_value;
end
endmodule
+75
View File
@@ -0,0 +1,75 @@
// DESCRIPTION: Verilator: --protect-lib example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2019 by Todd Strader.
// SPDX-License-Identifier: CC0-1.0
//======================================================================
// See examples/tracing_c for notes on tracing
// Include common routines
#include <verilated.h>
#include "Vtop.h"
#if VM_TRACE
# include <verilated_vcd_c.h>
#endif
vluint64_t main_time = 0;
double sc_time_stamp() { return main_time; }
int main(int argc, char** argv, char** env) {
if (false && argc && argv && env) {}
Verilated::debug(0);
Verilated::randReset(2);
Verilated::commandArgs(argc, argv);
// Construct the Verilated model, including the secret module
Vtop* top = new Vtop;
#if VM_TRACE
// When tracing, the contents of the secret module will not be seen
VerilatedVcdC* tfp = NULL;
const char* flag = Verilated::commandArgsPlusMatch("trace");
if (flag && 0 == strcmp(flag, "+trace")) {
Verilated::traceEverOn(true);
VL_PRINTF("Enabling waves into logs/vlt_dump.vcd...\n");
tfp = new VerilatedVcdC;
top->trace(tfp, 99);
Verilated::mkdir("logs");
tfp->open("logs/vlt_dump.vcd");
}
#endif
top->clk = 0;
// Simulate until $finish
while (!Verilated::gotFinish()) {
main_time++;
top->clk = ~top->clk & 0x1;
top->eval();
#if VM_TRACE
if (tfp) tfp->dump(main_time);
#endif
}
// Final model cleanup
top->final();
// Close trace if opened
#if VM_TRACE
if (tfp) {
tfp->close();
tfp = NULL;
}
#endif
// Destroy model
delete top;
top = NULL;
// Fin
exit(0);
}
+35
View File
@@ -0,0 +1,35 @@
// DESCRIPTION: Verilator: --protect-lib example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2019 by Todd Strader.
// SPDX-License-Identifier: CC0-1.0
// See also the EXAMPLE section in the verilator manpage/document.
module top (input clk);
integer cyc = 0;
logic [31:0] a = 0;
logic [31:0] b = 0;
logic [31:0] x;
verilated_secret secret (.a, .b, .x, .clk);
always @(posedge clk) begin
$display("[%0t] cyc=%0d a=%0d b=%0d x=%0d", $time, cyc, a, b, x);
cyc <= cyc + 1;
if (cyc == 0) begin
a <= 5;
b <= 7;
end else if (cyc == 1) begin
a <= 6;
b <= 2;
end else if (cyc == 2) begin
a <= 1;
b <= 9;
end else if (cyc > 3) begin
$display("Done");
$finish;
end
end
endmodule
+6
View File
@@ -0,0 +1,6 @@
*.dmp
*.log
*.csrc
*.vcd
obj_*
logs
+102
View File
@@ -0,0 +1,102 @@
######################################################################
#
# DESCRIPTION: Verilator Example: Small Makefile
#
# This calls the object directory makefile. That allows the objects to
# be placed in the "current directory" which simplifies the Makefile.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# Check for sanity to avoid later confusion
ifneq ($(words $(CURDIR)),1)
$(error Unsupported: GNU Make cannot build in directories containing spaces, build elsewhere: '$(CURDIR)')
endif
######################################################################
# Set up variables
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR = verilator
VERILATOR_COVERAGE = verilator_coverage
else
export VERILATOR_ROOT
VERILATOR = $(VERILATOR_ROOT)/bin/verilator
VERILATOR_COVERAGE = $(VERILATOR_ROOT)/bin/verilator_coverage
endif
VERILATOR_FLAGS =
# Generate C++ in executable form
VERILATOR_FLAGS += -cc --exe
# Generate makefile dependencies (not shown as complicates the Makefile)
#VERILATOR_FLAGS += -MMD
# Optimize
VERILATOR_FLAGS += -Os -x-assign 0
# Warn abount lint issues; may not want this on less solid designs
VERILATOR_FLAGS += -Wall
# Make waveforms
VERILATOR_FLAGS += --trace
# Check SystemVerilog assertions
VERILATOR_FLAGS += --assert
# Generate coverage analysis
VERILATOR_FLAGS += --coverage
# Run Verilator in debug mode
#VERILATOR_FLAGS += --debug
# Add this trace to get a backtrace in gdb
#VERILATOR_FLAGS += --gdbbt
# Input files for Verilator
VERILATOR_INPUT = -f input.vc top.v sim_main.cpp
######################################################################
default: run
run:
@echo
@echo "-- Verilator tracing example"
@echo
@echo "-- VERILATE ----------------"
$(VERILATOR) $(VERILATOR_FLAGS) $(VERILATOR_INPUT)
@echo
@echo "-- BUILD -------------------"
# To compile, we can either
# 1. Pass --build to Verilator by editing VERILATOR_FLAGS above.
# 2. Or, run the make rules Verilator does:
# $(MAKE) -j -C obj_dir -f Vtop.mk
# 3. Or, call a submakefile where we can override the rules ourselves:
$(MAKE) -j -C obj_dir -f ../Makefile_obj
@echo
@echo "-- RUN ---------------------"
@rm -rf logs
@mkdir -p logs
obj_dir/Vtop +trace
@echo
@echo "-- COVERAGE ----------------"
@rm -rf logs/annotated
$(VERILATOR_COVERAGE) --annotate logs/annotated logs/coverage.dat
@echo
@echo "-- DONE --------------------"
@echo "To see waveforms, open vlt_dump.vcd in a waveform viewer"
@echo
######################################################################
# Other targets
show-config:
$(VERILATOR) -V
maintainer-copy::
clean mostlyclean distclean maintainer-clean::
-rm -rf obj_dir logs *.log *.dmp *.vpd coverage.dat core
+57
View File
@@ -0,0 +1,57 @@
# -*- Makefile -*-
#######################################################################
#
# DESCRIPTION: Verilator Example: Makefile for inside object directory
#
# This is executed in the object directory, and called by ../Makefile
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
#######################################################################
default: Vtop
# Include the rules made by Verilator
include Vtop.mk
# Use OBJCACHE (ccache) if using gmake and its installed
COMPILE.cc = $(OBJCACHE) $(CXX) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c
#######################################################################
# Compile flags
# Override some default compile flags
CPPFLAGS += -MMD -MP
CPPFLAGS += -DVL_DEBUG=1
# Turn on some more flags (when configured appropriately)
# For testing inside Verilator, "configure --enable-ccwarn" will do this
# automatically; otherwise you may want this unconditionally enabled
ifeq ($(CFG_WITH_CCWARN),yes) # Local... Else don't burden users
USER_CPPFLAGS_WALL += -W -Werror -Wall
endif
# See the benchmarking section of bin/verilator.
# Support class optimizations. This includes the tracing and symbol table.
# SystemC takes minutes to optimize, thus it is off by default.
OPT_SLOW =
# Fast path optimizations. Most time is spent in these classes.
OPT_FAST = -Os -fstrict-aliasing
#OPT_FAST = -O
#OPT_FAST =
#######################################################################
# Linking final exe -- presumes have a sim_main.cpp
# Special compile rule
sim_main.o: sim_main.cpp $(VM_PREFIX).h
######################################################################
######################################################################
# Automatically understand dependencies
DEPS := $(wildcard *.d)
ifneq ($(DEPS),)
include $(DEPS)
endif
+2
View File
@@ -0,0 +1,2 @@
// This file typically lists flags required by a large project, e.g. include directories
+librescan +libext+.v+.sv+.vh+.svh -y .
+106
View File
@@ -0,0 +1,106 @@
// DESCRIPTION: Verilator: Verilog example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2017 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
//======================================================================
// Include common routines
#include <verilated.h>
// Include model header, generated from Verilating "top.v"
#include "Vtop.h"
// Current simulation time (64-bit unsigned)
vluint64_t main_time = 0;
// Called by $time in Verilog
double sc_time_stamp() {
return main_time; // Note does conversion to real, to match SystemC
}
int main(int argc, char** argv, char** env) {
// This is a more complicated example, please also see the simpler examples/make_hello_c.
// Prevent unused variable warnings
if (false && argc && argv && env) {}
// Set debug level, 0 is off, 9 is highest presently used
// May be overridden by commandArgs
Verilated::debug(0);
// Randomization reset policy
// May be overridden by commandArgs
Verilated::randReset(2);
// Verilator must compute traced signals
Verilated::traceEverOn(true);
// Pass arguments so Verilated code can see them, e.g. $value$plusargs
// This needs to be called before you create any model
Verilated::commandArgs(argc, argv);
// Create logs/ directory in case we have traces to put under it
Verilated::mkdir("logs");
// Construct the Verilated model, from Vtop.h generated from Verilating "top.v"
Vtop* top = new Vtop; // Or use a const unique_ptr, or the VL_UNIQUE_PTR wrapper
// Set some inputs
top->reset_l = !0;
top->clk = 0;
top->in_small = 1;
top->in_quad = 0x1234;
top->in_wide[0] = 0x11111111;
top->in_wide[1] = 0x22222222;
top->in_wide[2] = 0x3;
// Simulate until $finish
while (!Verilated::gotFinish()) {
main_time++; // Time passes...
// Toggle a fast (time/2 period) clock
top->clk = !top->clk;
// Toggle control signals on an edge that doesn't correspond
// to where the controls are sampled; in this example we do
// this only on a negedge of clk, because we know
// reset is not sampled there.
if (!top->clk) {
if (main_time > 1 && main_time < 10) {
top->reset_l = !1; // Assert reset
} else {
top->reset_l = !0; // Deassert reset
}
// Assign some other inputs
top->in_quad += 0x12;
}
// Evaluate model
// (If you have multiple models being simulated in the same
// timestep then instead of eval(), call eval_step() on each, then
// eval_end_step() on each.)
top->eval();
// Read outputs
VL_PRINTF("[%" VL_PRI64 "d] clk=%x rstl=%x iquad=%" VL_PRI64 "x"
" -> oquad=%" VL_PRI64 "x owide=%x_%08x_%08x\n",
main_time, top->clk, top->reset_l, top->in_quad, top->out_quad, top->out_wide[2],
top->out_wide[1], top->out_wide[0]);
}
// Final model cleanup
top->final();
// Coverage analysis (since test passed)
#if VM_COVERAGE
Verilated::mkdir("logs");
VerilatedCov::write("logs/coverage.dat");
#endif
// Destroy model
delete top;
top = NULL;
// Fin
exit(0);
}
+42
View File
@@ -0,0 +1,42 @@
// DESCRIPTION: Verilator: Verilog Test module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2003 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
// ======================================================================
module sub
(
input clk,
input reset_l
);
// Example counter/flop
reg [31:0] count_c;
always_ff @ (posedge clk) begin
if (!reset_l) begin
/*AUTORESET*/
// Beginning of autoreset for uninitialized flops
count_c <= 32'h0;
// End of automatics
end
else begin
count_c <= count_c + 1;
if (count_c >= 3) begin
// This write is a magic value the Makefile uses to make sure the
// test completes successfully.
$write("*-* All Finished *-*\n");
$finish;
end
end
end
// An example assertion
always_ff @ (posedge clk) begin
AssertionExample: assert (!reset_l || count_c<100);
end
// And example coverage analysis
cover property (@(posedge clk) count_c==3);
endmodule
+46
View File
@@ -0,0 +1,46 @@
// DESCRIPTION: Verilator: Verilog example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2003 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
// ======================================================================
// This is intended to be a complex example of several features, please also
// see the simpler examples/make_hello_c.
module top
(
// Declare some signals so we can see how I/O works
input clk,
input reset_l,
output wire [1:0] out_small,
output wire [39:0] out_quad,
output wire [69:0] out_wide,
input [1:0] in_small,
input [39:0] in_quad,
input [69:0] in_wide
);
// Connect up the outputs, using some trivial logic
assign out_small = ~reset_l ? '0 : (in_small + 2'b1);
assign out_quad = ~reset_l ? '0 : (in_quad + 40'b1);
assign out_wide = ~reset_l ? '0 : (in_wide + 70'b1);
// And an example sub module. The submodule will print stuff.
sub sub (/*AUTOINST*/
// Inputs
.clk (clk),
.reset_l (reset_l));
// Print some stuff as an example
initial begin
if ($test$plusargs("trace") != 0) begin
$display("[%0t] Tracing to logs/vlt_dump.vcd...\n", $time);
$dumpfile("logs/vlt_dump.vcd");
$dumpvars();
end
$display("[%0t] Model running...\n", $time);
end
endmodule
+6
View File
@@ -0,0 +1,6 @@
*.dmp
*.log
*.csrc
*.vcd
obj_*
logs
+116
View File
@@ -0,0 +1,116 @@
######################################################################
#
# DESCRIPTION: Verilator Example: Small Makefile
#
# This calls the object directory makefile. That allows the objects to
# be placed in the "current directory" which simplifies the Makefile.
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# Check for sanity to avoid later confusion
ifneq ($(words $(CURDIR)),1)
$(error Unsupported: GNU Make cannot build in directories containing spaces, build elsewhere: '$(CURDIR)')
endif
######################################################################
# Set up variables
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR = verilator
VERILATOR_COVERAGE = verilator_coverage
else
export VERILATOR_ROOT
VERILATOR = $(VERILATOR_ROOT)/bin/verilator
VERILATOR_COVERAGE = $(VERILATOR_ROOT)/bin/verilator_coverage
endif
VERILATOR_FLAGS =
# Generate SystemC in executable form
VERILATOR_FLAGS += -sc --exe
# Generate makefile dependencies (not shown as complicates the Makefile)
#VERILATOR_FLAGS += -MMD
# Optimize
VERILATOR_FLAGS += -Os -x-assign 0
# Warn abount lint issues; may not want this on less solid designs
VERILATOR_FLAGS += -Wall
# Make waveforms
VERILATOR_FLAGS += --trace
# Check SystemVerilog assertions
VERILATOR_FLAGS += --assert
# Generate coverage analysis
VERILATOR_FLAGS += --coverage
# Run Verilator in debug mode
#VERILATOR_FLAGS += --debug
# Add this trace to get a backtrace in gdb
#VERILATOR_FLAGS += --gdbbt
# Input files for Verilator
VERILATOR_INPUT = -f input.vc top.v sc_main.cpp
# Check if SC exists via a verilator call (empty if not)
SYSTEMC_EXISTS := $(shell $(VERILATOR) --getenv SYSTEMC_INCLUDE)
######################################################################
ifneq ($(SYSTEMC_EXISTS),)
default: run
else
default: nosc
endif
run:
@echo
@echo "-- Verilator tracing example"
@echo
@echo "-- VERILATE ----------------"
$(VERILATOR) $(VERILATOR_FLAGS) $(VERILATOR_INPUT)
@echo
@echo "-- COMPILE -----------------"
# To compile, we can either
# 1. Pass --build to Verilator by editing VERILATOR_FLAGS above.
# 2. Or, run the make rules Verilator does:
# $(MAKE) -j -C obj_dir -f Vtop.mk
# 3. Or, call a submakefile where we can override the rules ourselves:
$(MAKE) -j -C obj_dir -f ../Makefile_obj
@echo
@echo "-- RUN ---------------------"
@rm -rf logs
@mkdir -p logs
obj_dir/Vtop +trace
@echo
@echo "-- COVERAGE ----------------"
@rm -rf logs/annotated
$(VERILATOR_COVERAGE) --annotate logs/annotated logs/coverage.dat
@echo
@echo "-- DONE --------------------"
@echo "To see waveforms, open vlt_dump.vcd in a waveform viewer"
@echo
######################################################################
# Other targets
nosc:
@echo
@echo "%Skip: SYSTEMC_INCLUDE not in environment"
@echo "(If you have SystemC see the README, and rebuild Verilator)"
@echo
show-config:
$(VERILATOR) -V
maintainer-copy::
clean mostlyclean distclean maintainer-clean::
-rm -rf obj_dir logs *.log *.dmp *.vpd coverage.dat core
+65
View File
@@ -0,0 +1,65 @@
# -*- Makefile -*-
#######################################################################
#
# DESCRIPTION: Verilator Example: Makefile for inside object directory
#
# This is executed in the object directory, and called by ../Makefile
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
#######################################################################
default: Vtop
# Include the rules made by Verilator
include Vtop.mk
# Use OBJCACHE (ccache) if using gmake and its installed
COMPILE.cc = $(OBJCACHE) $(CXX) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c
#######################################################################
# Compile flags
# Override some default compile flags
CPPFLAGS += -MMD -MP
CPPFLAGS += -DVL_DEBUG=1
# SystemC isn't too clean
CPPFLAGS += -Wno-deprecated
# Turn on some more flags (when configured appropriately)
# For testing inside Verilator, "configure --enable-ccwarn" will do this
# automatically; otherwise you may want this unconditionally enabled
ifeq ($(CFG_WITH_CCWARN),yes) # Local... Else don't burden users
USER_CPPFLAGS_WALL += -W -Werror -Wall
endif
# If you build your own rules from scratch, note you need to include
# SystemC as follows (Vtop.mk file includes verilated.mk with these
# already).
# CPPFLAGS += $(SYSTEMC_CXX_FLAGS) $(addprefix -I, $(SYSTEMC_INCLUDE))
# LDFLAGS += $(SYSTEMC_CXX_FLAGS) $(addprefix -L, $(SYSTEMC_LIBDIR))
# See the benchmarking section of bin/verilator.
# Support class optimizations. This includes the tracing and symbol table.
# SystemC takes minutes to optimize, thus it is off by default.
OPT_SLOW =
# Fast path optimizations. Most time is spent in these classes.
OPT_FAST = -Os -fstrict-aliasing
#OPT_FAST = -O
#OPT_FAST =
#######################################################################
# Linking final exe -- presumes have a sim_main.cpp
# Special compile rule
sim_main.o: sim_main.cpp $(VM_PREFIX).h
######################################################################
######################################################################
# Automatically understand dependencies
DEPS := $(wildcard *.d)
ifneq ($(DEPS),)
include $(DEPS)
endif
+2
View File
@@ -0,0 +1,2 @@
// This file typically lists flags required by a large project, e.g. include directories
+librescan +libext+.v+.sv+.vh+.svh -y .
+158
View File
@@ -0,0 +1,158 @@
// -*- SystemC -*-
// DESCRIPTION: Verilator Example: Top level main for invoking SystemC model
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2017 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
//======================================================================
// SystemC global header
#include <systemc.h>
// Include common routines
#include <verilated.h>
#if VM_TRACE
#include <verilated_vcd_sc.h>
#endif
#include <sys/stat.h> // mkdir
// Include model header, generated from Verilating "top.v"
#include "Vtop.h"
int sc_main(int argc, char* argv[]) {
// This is a more complicated example, please also see the simpler examples/make_hello_c.
// Prevent unused variable warnings
if (false && argc && argv) {}
// Set debug level, 0 is off, 9 is highest presently used
// May be overridden by commandArgs
Verilated::debug(0);
// Randomization reset policy
// May be overridden by commandArgs
Verilated::randReset(2);
// Pass arguments so Verilated code can see them, e.g. $value$plusargs
// This needs to be called before you create any model
Verilated::commandArgs(argc, argv);
// Create logs/ directory in case we have traces to put under it
Verilated::mkdir("logs");
// General logfile
ios::sync_with_stdio();
// Defaults time
#if (SYSTEMC_VERSION > 20011000)
#else
sc_time dut(1.0, sc_ns);
sc_set_default_time_unit(dut);
#endif
// Define clocks
#if (SYSTEMC_VERSION >= 20070314)
sc_clock clk("clk", 10, SC_NS, 0.5, 3, SC_NS, true);
sc_clock fastclk("fastclk", 2, SC_NS, 0.5, 2, SC_NS, true);
#else
sc_clock clk("clk", 10, 0.5, 3, true);
sc_clock fastclk("fastclk", 2, 0.5, 2, true);
#endif
// Define interconnect
sc_signal<bool> reset_l;
sc_signal<vluint32_t> in_small;
sc_signal<vluint64_t> in_quad;
sc_signal<sc_bv<70> > in_wide;
sc_signal<vluint32_t> out_small;
sc_signal<vluint64_t> out_quad;
sc_signal<sc_bv<70> > out_wide;
// Construct the Verilated model, from inside Vtop.h
Vtop* top = new Vtop("top");
// Attach signals to the model
top->clk(clk);
top->fastclk(fastclk);
top->reset_l(reset_l);
top->in_small(in_small);
top->in_quad(in_quad);
top->in_wide(in_wide);
top->out_small(out_small);
top->out_quad(out_quad);
top->out_wide(out_wide);
#if VM_TRACE
// Before any evaluation, need to know to calculate those signals only used for tracing
Verilated::traceEverOn(true);
#endif
// You must do one evaluation before enabling waves, in order to allow
// SystemC to interconnect everything for testing.
#if (SYSTEMC_VERSION >= 20070314)
sc_start(1, SC_NS);
#else
sc_start(1);
#endif
#if VM_TRACE
// If verilator was invoked with --trace argument,
// and if at run time passed the +trace argument, turn on tracing
VerilatedVcdSc* tfp = NULL;
const char* flag = Verilated::commandArgsPlusMatch("trace");
if (flag && 0 == strcmp(flag, "+trace")) {
cout << "Enabling waves into logs/vlt_dump.vcd...\n";
tfp = new VerilatedVcdSc;
top->trace(tfp, 99); // Trace 99 levels of hierarchy
Verilated::mkdir("logs");
tfp->open("logs/vlt_dump.vcd");
}
#endif
// Simulate until $finish
while (!Verilated::gotFinish()) {
#if VM_TRACE
// Flush the wave files each cycle so we can immediately see the output
// Don't do this in "real" programs, do it in an abort() handler instead
if (tfp) tfp->flush();
#endif
// Apply inputs
if (sc_time_stamp() > sc_time(1, SC_NS) && sc_time_stamp() < sc_time(10, SC_NS)) {
reset_l = !1; // Assert reset
} else {
reset_l = !0; // Deassert reset
}
// Simulate 1ns
#if (SYSTEMC_VERSION >= 20070314)
sc_start(1, SC_NS);
#else
sc_start(1);
#endif
}
// Final model cleanup
top->final();
// Close trace if opened
#if VM_TRACE
if (tfp) {
tfp->close();
tfp = NULL;
}
#endif
// Coverage analysis (since test passed)
#if VM_COVERAGE
Verilated::mkdir("logs");
VerilatedCov::write("logs/coverage.dat");
#endif
// Destroy model
delete top;
top = NULL;
// Fin
return 0;
}
+59
View File
@@ -0,0 +1,59 @@
// DESCRIPTION: Verilator: Verilog Test module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2003 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
// ======================================================================
module sub
(
input clk,
input fastclk,
input reset_l
);
// Example counter/flop
reg [31:0] count_f;
always_ff @ (posedge fastclk) begin
if (!reset_l) begin
/*AUTORESET*/
// Beginning of autoreset for uninitialized flops
count_f <= 32'h0;
// End of automatics
end
else begin
count_f <= count_f + 1;
end
end
// Another example flop
reg [31:0] count_c;
always_ff @ (posedge clk) begin
if (!reset_l) begin
/*AUTORESET*/
// Beginning of autoreset for uninitialized flops
count_c <= 32'h0;
// End of automatics
end
else begin
count_c <= count_c + 1;
if (count_c >= 3) begin
$display("[%0t] fastclk is %0d times faster than clk\n",
$time, count_f/count_c);
// This write is a magic value the Makefile uses to make sure the
// test completes successfully.
$write("*-* All Finished *-*\n");
$finish;
end
end
end
// An example assertion
always_ff @ (posedge clk) begin
AssertionExample: assert(!reset_l || count_c<100);
end
// And example coverage analysis
cover property (@(posedge clk) count_c==3);
endmodule
+43
View File
@@ -0,0 +1,43 @@
// DESCRIPTION: Verilator: Verilog example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2003 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
// ======================================================================
// This is intended to be a complex example of several features, please also
// see the simpler examples/make_hello_c.
module top
(
// Declare some signals so we can see how I/O works
input clk,
input fastclk,
input reset_l,
output wire [1:0] out_small,
output wire [39:0] out_quad,
output wire [69:0] out_wide,
input [1:0] in_small,
input [39:0] in_quad,
input [69:0] in_wide
);
// Connect up the outputs, using some trivial logic
assign out_small = ~reset_l ? '0 : (in_small + 2'b1);
assign out_quad = ~reset_l ? '0 : (in_quad + 40'b1);
assign out_wide = ~reset_l ? '0 : (in_wide + 70'b1);
// And an example sub module. The submodule will print stuff.
sub sub (/*AUTOINST*/
// Inputs
.clk (clk),
.fastclk (fastclk),
.reset_l (reset_l));
// Print some stuff as an example
initial begin
$display("[%0t] Model running...\n", $time);
end
endmodule
+6
View File
@@ -0,0 +1,6 @@
obj_*
copied
*.csv
*.dot
*.dmp
*.pdf
+61
View File
@@ -0,0 +1,61 @@
######################################################################
#
# DESCRIPTION: Verilator Example: XML tests
#
# This file ONLY is placed under the Creative Commons Public Domain, for
# any use, without warranty, 2020 by Wilson Snyder.
# SPDX-License-Identifier: CC0-1.0
#
######################################################################
# This makefile is not intended to be useful as an example itself,
# it is just to run the small example scripts in this directory.
# If $VERILATOR_ROOT isn't in the environment, we assume it is part of a
# package install, and verilator is in your path. Otherwise find the
# binary relative to $VERILATOR_ROOT (such as when inside the git sources).
ifeq ($(VERILATOR_ROOT),)
VERILATOR = verilator
else
export VERILATOR_ROOT
VERILATOR = $(VERILATOR_ROOT)/bin/verilator
endif
DOT = dot
PYTHON = python3
PYTHON_VERSION := $(shell ${PYTHON} --version 2>&1)
PYTHON_VERSION_FULL := $(wordlist 2,4,$(subst ., ,${PYTHON_VERSION}))
PYTHON_VERSION_MAJOR := $(word 1,${PYTHON_VERSION_FULL})
PYTHON_VERSION_MINOR := $(word 2,${PYTHON_VERSION_FULL})
PYTHON_GE_3_5 := $(shell [ ${PYTHON_VERSION_MAJOR} -eq 3 -a ${PYTHON_VERSION_MINOR} -ge 5 ] && echo true)
ifeq (${PYTHON_GE_3_5},true)
default: test
else
default: python_message
endif
python_message:
@echo "Found Python version ${PYTHON_VERSION}, but require >= 3.5"
test: \
test-vl_file_copy \
test-vl_hier_graph \
test-vl_file_copy:
@echo "-- vl_file_copy example"
$(PYTHON) vl_file_copy -odir copied top.v
@cmp copied/top.v top.v
@cmp copied/sub.v sub.v
test-vl_hier_graph:
@echo "-- vl_hier_graph example"
$(PYTHON) vl_hier_graph -o graph.dot top.v
@echo "Manually run: " $(DOT) -Tpdf -o graph.pdf graph.dot
######################################################################
maintainer-copy::
clean mostlyclean distclean maintainer-clean::
-rm -rf obj_dir *.log *.csv *.dmp *.dot *.vpd *.pdf core copied
+18
View File
@@ -0,0 +1,18 @@
// DESCRIPTION: Verilator: Verilog Test module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2019 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
// ======================================================================
module sub
#(parameter type TYPE_t = logic)
(
input TYPE_t in,
output TYPE_t out
);
// Some simple logic
always_comb out = ~ in;
endmodule
+33
View File
@@ -0,0 +1,33 @@
// DESCRIPTION: Verilator: Verilog example module
//
// This file ONLY is placed under the Creative Commons Public Domain, for
// any use, without warranty, 2019 by Wilson Snyder.
// SPDX-License-Identifier: CC0-1.0
// ======================================================================
module top
(
input clk,
input fastclk,
input reset_l,
output wire [1:0] out_small,
output wire [39:0] out_quad,
output wire [69:0] out_wide,
input [1:0] in_small,
input [39:0] in_quad,
input [69:0] in_wide
);
sub #(.TYPE_t(logic [1:0])) sub_small
(.in(in_small),
.out(out_small));
sub #(.TYPE_t(logic [39:0])) sub_quad
(.in(in_quad),
.out(out_quad));
sub #(.TYPE_t(logic [69:0])) sub_wide
(.in(in_wide),
.out(out_wide));
endmodule
+114
View File
@@ -0,0 +1,114 @@
#!/usr/bin/env python3
# -*- Python -*- See copyright, etc below
######################################################################
import argparse
import os
import re
import subprocess
import sys
import tempfile
import xml.etree.ElementTree as ET
from shutil import copy2
from pprint import pprint,pformat
#######################################################################
class VlFileCopy:
def __init__(self,
verilator_args, # presently all verilator options are passed-thru
# ideally this script would check against options mentioned in help
debug=0,
output_dir='copied'): # directory name we output file uses
self.debug = debug
xml_temp = tempfile.NamedTemporaryFile()
args = ['--xml-output', xml_temp.name,
'--bbox-sys', # Parse some stuff can't translate
'--bbox-unsup',
'--prefix vlxml'] # So we know name of .xml output
args += verilator_args
self.run_verilator(args)
self.tree = ET.parse(xml_temp.name)
os.makedirs(output_dir, 0o777, True)
# Find and copy the files
root = self.tree.getroot()
xfiles = root.find('files')
for xfile in xfiles.findall('file'):
filename = xfile.get('filename')
if not re.match('^<', filename): # e.g. <built-in>
if self.debug:
print("\tcp %s %s" % (filename, output_dir))
copy2(filename, output_dir)
def run_verilator(self, args):
"""Run Verilator command, check errors"""
if os.getenv("VERILATOR_ROOT"):
command = os.getenv("VERILATOR_ROOT") + "/bin/verilator"
else:
command = "verilator"
command += ' ' + ' '.join(args)
if self.debug:
print("\t%s " % command)
status = subprocess.call(command, shell=True)
if status != 0:
raise Exception("Command failed running Verilator with '"+command+"', stopped")
#######################################################################
if __name__=='__main__':
parser = argparse.ArgumentParser(
allow_abbrev=False,
formatter_class=argparse.RawTextHelpFormatter,
description=
"""Example of using Verilator XML output to copy a list of files to an
output directory (-odir, defaults to 'copied'), e.g. to easily create a
tarball of the design to pass to others.
Example usage:
vl_file_copy -f input.vc top.v -odir mycopy
# This will make at least mycopy/top.v
""",
epilog=
"""All other arguments are pass-thru to Verilator: e.g.:
+define+<var>=<value> Set preprocessor define
-F <file> Parse options from a file, relatively
-f <file> Parse options from a file
-G<name>=<value> Overwrite toplevel parameter
+incdir+<dir> Directory to search for includes
+libext+<ext>+[ext]... Extensions for finding modules
-v <filename> Verilog library
-y <dir> Directory to search for modules
This file ONLY is placed under the Creative Commons Public Domain, for
any use, without warranty, 2019 by Wilson Snyder.
SPDX-License-Identifier: CC0-1.0
"""
)
parser.add_argument('-debug', '--debug',
action='store_const', const=9,
help='enable debug')
parser.add_argument('-odir', '--odir',
action='store', metavar='directory', required=True,
help='target output directory')
(args, rem) = parser.parse_known_args()
print("NOTE: vl_file_copy is only an example starting point for writing your own tool.")
# That is:
# 1. We will accept basic patches
# 2. We are not expecting to make this globally useful. (e.g. we don't cleanup obj_dir)
# 3. "make install" will not install this.
# 4. This has not had production-worthy validation.
fc = VlFileCopy(output_dir = args.odir,
debug = args.debug,
verilator_args = rem)
######################################################################
### Local Variables:
### compile-command: "./vl_file_copy -h ; VERILATOR_ROOT=$V4 ./vl_file_copy +define+thru top.v"
### End:
+138
View File
@@ -0,0 +1,138 @@
#!/usr/bin/env python3
# -*- Python -*- See copyright, etc below
######################################################################
import argparse
import os
import re
import subprocess
import sys
import tempfile
import xml.etree.ElementTree as ET
from shutil import copy2
from pprint import pprint,pformat
#######################################################################
class VlHierGraph:
def __init__(self,
verilator_args, # presently all verilator options are passed-thru
# ideally this script would check against options mentioned in help
debug=0,
output_filename='graph.dot'): # output filename
self.debug = debug
self.next_vertex_number = 0
self.name_to_number = {}
xml_temp = tempfile.NamedTemporaryFile()
args = ['--xml-output', xml_temp.name,
'--bbox-sys', # Parse some stuff can't translate
'--bbox-unsup',
'--prefix vlxml'] # So we know name of .xml output
args += verilator_args
self.run_verilator(args)
self.tree = ET.parse(xml_temp.name)
with open(output_filename, "w") as fh:
# For more serious purposes, use the python graphviz package instead
fh.write("digraph {\n")
fh.write(" dpi=300;\n")
fh.write(" order=LR;\n")
fh.write(" node [fontsize=8 shape=\"box\" margin=0.01 width=0 height=0]")
fh.write(" edge [fontsize=6]")
# Find cells
root = self.tree.getroot()
netlist = root.find('netlist')
for module in netlist.findall('module'):
# origNames are before parameterization, name if after
mod_name = module.get('name')
mod_number = self.name_to_vertex_number(mod_name)
fh.write(" n%d [label=\"%s\""
% (mod_number, mod_name))
if module.get('topModule'):
fh.write(" color=\"red\" rank=1")
fh.write("];\n")
for instance in module.findall('instance'):
inst_name = instance.get('name')
def_name = instance.get('defName')
def_number = self.name_to_vertex_number(def_name)
fh.write(" n%d->n%d [label=\"%s\"];\n"
% (mod_number, def_number, inst_name));
fh.write("}\n")
def name_to_vertex_number(self, name):
if not name in self.name_to_number:
self.next_vertex_number += 1
self.name_to_number[name] = self.next_vertex_number
return self.name_to_number[name]
def run_verilator(self, args):
"""Run Verilator command, check errors"""
if os.getenv("VERILATOR_ROOT"):
command = os.getenv("VERILATOR_ROOT") + "/bin/verilator"
else:
command = "verilator"
command += ' ' + ' '.join(args)
if self.debug:
print("\t%s " % command)
status = subprocess.call(command, shell=True)
if status != 0:
raise Exception("Command failed running Verilator with '"+command+"', stopped")
#######################################################################
if __name__=='__main__':
parser = argparse.ArgumentParser(
allow_abbrev=False,
formatter_class=argparse.RawTextHelpFormatter,
description=
"""Example of using Verilator XML output to create a .dot file showing the
design module hierarchy.
Example usage:
vl_hier_graph -f input.vc top.v -o graph.dot
dot -Tpdf -o graph.pdf graph.dot
""",
epilog=
"""All other arguments are pass-thru to Verilator: e.g.:
+define+<var>=<value> Set preprocessor define
-F <file> Parse options from a file, relatively
-f <file> Parse options from a file
-G<name>=<value> Overwrite toplevel parameter
+incdir+<dir> Directory to search for includes
+libext+<ext>+[ext]... Extensions for finding modules
-v <filename> Verilog library
-y <dir> Directory to search for modules
This file ONLY is placed under the Creative Commons Public Domain, for
any use, without warranty, 2019 by Wilson Snyder.
SPDX-License-Identifier: CC0-1.0
"""
)
parser.add_argument('-debug', '--debug',
action='store_const', const=9,
help='enable debug')
parser.add_argument('-o', '--o',
action='store', metavar='filename', required=True,
help='output filename')
(args, rem) = parser.parse_known_args()
print("NOTE: vl_hier_graph is only an example starting point for writing your own tool.")
# That is:
# 1. We will accept basic patches
# 2. We are not expecting to make this globally useful. (e.g. we don't cleanup obj_dir)
# 3. "make install" will not install this.
# 4. This has not had production-worthy validation.
fc = VlHierGraph(output_filename = args.o,
debug = args.debug,
verilator_args = rem)
######################################################################
### Local Variables:
### compile-command: "./vl_hier_graph -h ; VERILATOR_ROOT=$V4 ./vl_hier_graph +define+thru top.v"
### End:
+1
View File
@@ -1 +1,2 @@
verilated.mk
verilated_config.h

Some files were not shown because too many files have changed in this diff Show More