Wilson Snyder
28718f964a
Fix tracing replicated hierarchical models ( #5027 ) ( #5029 )
2024-03-30 16:00:52 -04:00
Wilson Snyder
1d486e3a59
Rename statsPrintSummary()
2024-03-30 13:19:47 -04:00
Wilson Snyder
e390d6779d
Internals: Rename threadsInModel()
2024-03-30 11:13:14 -04:00
Wilson Snyder
0114cb67ca
Fix $readmem with missing newline ( #5019 ).
2024-03-27 18:42:20 -04:00
Wilson Snyder
ea8f86dd30
Internals: Prefer '(void)' to avoid unused var. No functional change.
2024-03-27 18:07:14 -04:00
Wilson Snyder
0ff77fc352
Internals: Remove extra single-line {}. No functional change.
2024-03-27 17:57:49 -04:00
Wilson Snyder
4df9e2e0e5
Add printing summary reports ( #4909 ) ( #5018 )
2024-03-25 07:03:17 -04:00
Wilson Snyder
71d76c993c
Fix MSVC++ warnings. No functional change.
2024-03-24 10:19:26 -04:00
Wilson Snyder
38ad328956
Remove duplicate stop ignored messages
2024-03-22 19:35:42 -04:00
Wilson Snyder
ba47da6587
Internals: Move vl_timescaled_double to verilated_funcs.h. No functional change intended
2024-03-10 22:34:32 -04:00
Wilson Snyder
7694a7bf41
Fix suggestion of ulimit -s ( #4956 )
2024-03-10 11:20:25 -04:00
Wilson Snyder
11bfe7a7bb
cppcheck fixes. No functional change.
2024-03-07 19:20:00 -05:00
Wilson Snyder
3786f59e03
Change to IEEE 1800-2023 warning mentions
2024-03-02 10:15:19 -05:00
Wilson Snyder
e320b0b581
Internals: Favor const_iterators. No functional change intended.
2024-02-25 17:12:13 -05:00
Wilson Snyder
22687a6901
Internals: Use C++14 quoted literal std::string
2024-01-28 21:00:20 -05:00
Wilson Snyder
ce174743bb
Fix some MSVC warnings
2024-01-28 14:47:14 -05:00
Wilson Snyder
a84be1844f
MSVC fix, part of fix of null ( #4862 ).
2024-01-28 11:05:38 -05:00
Wilson Snyder
9ccef4180f
Fix $fwrite of null ( #4862 ).
2024-01-28 09:05:50 -05:00
Wilson Snyder
1a92502788
Add --main support for dumping coverage, and +verilator+coverage+file runtime option.
2024-01-20 12:28:49 -05:00
Wilson Snyder
89cfa0737f
Internals: Fix cppcheck warnings
2024-01-17 19:48:07 -05:00
Tim Hutt
5073f208af
Internals: Use more standard syntax for avoiding unused variable warnings ( #4826 )
2024-01-13 15:34:59 -05:00
Wilson Snyder
68e4eeb53e
Add predicted stack overflow warning ( #4799 ).
2024-01-06 16:16:14 -05:00
Wilson Snyder
0ca90257a5
Add predicted stack overflow warning ( #4799 ).
2024-01-06 16:14:58 -05:00
Wilson Snyder
e76f29e5ba
Copyright year update
2024-01-01 03:19:59 -05:00
Wilson Snyder
ca3b5fbe99
Add verilated asserts that VL_MULS_MAX_WORDS does not overflow ( #4781 ). No functional change intended.
2023-12-30 15:31:58 -05:00
Wilson Snyder
9de6612cde
Avoid shift by 32 even if later masked, to avoid sanitizer warning ( #4781 ). No functional change intended.
2023-12-30 14:46:57 -05:00
Wilson Snyder
1a43afe6f7
Fix $finish twice to no longer exit ( #4757 ).
2023-12-24 11:02:52 -05:00
Wilson Snyder
a022b672a0
Fix 0**0 with wide numbers ( #4721 ).
2023-11-26 17:11:22 -05:00
Wilson Snyder
4a10c9ef6f
Internals: Rename. No functional change.
2023-11-11 20:47:10 -05:00
Geza Lore
dc346b7ffa
Remove deprecated options ( #4663 )
2023-11-04 17:28:36 +00:00
Geza Lore
a09506a0ad
Trivial simplification of V3EmitCModel
...
Still some remains of the --threads 0 mode. Remove unnecessary complexity
from V3EmitCModel. (Also don't pretend there is an MTask in single
threaded mode, when there really isn't.)
2023-10-21 20:41:46 +01:00
Wilson Snyder
a773a52559
Cleanup some IEEE references
2023-10-19 19:26:36 -04:00
Wilson Snyder
36932d31c4
Fix C++11 missing C++14's std::make_unique.
2023-09-01 18:07:15 -04:00
Wilson Snyder
ed25aaaad9
Internals: Fix g++ std11 warning. No functional change.
2023-09-01 17:59:30 -04:00
Yinan Xu
b4b74d72f0
Add prepareClone and atClone APIs for Verilated models ( #3503 ) ( #4444 )
...
This API is used if the user copies the process using `fork`
and similar OS-level mechanisms. The `at_clone` member function
ensures that all model-allocated resources are re-allocated, such
that the copied child process/model can simulate correctly.
A typical allocated resource is the thread pool, which every model
has its own pool.
2023-08-30 07:02:55 -04:00
Ryszard Rozak
b517fb5ee3
Support some stream operations on queues ( #4292 )
2023-06-13 22:46:42 -04:00
Mariusz Glebocki
949be301de
Internals: Fix unbalanced V3LockGuard locking ( #4193 )
2023-05-13 10:32:33 -04:00
Wilson Snyder
e6f5a0495f
Fix $fscanf of decimals overflowing variables ( #4174 ).
2023-05-07 08:25:10 -04:00
Wilson Snyder
c6052830e1
Fix C++17 requirement on previous commit.
2023-05-06 20:23:35 -04:00
Wilson Snyder
a3640c1767
Support get_randstate/set_randstate class method function.
2023-05-06 19:09:19 -04:00
Kamil Rakoczy
65a484e00b
Internal: Update clang_check_annotations conditions ( #4134 )
2023-04-20 07:02:31 -04:00
Wilson Snyder
fff0eb5d88
Internals: Use standard 'result' name for return variable. No functional change.
2023-04-08 22:11:28 -04:00
Wilson Snyder
69121633cf
Support class srandom and class random stability.
2023-04-01 10:50:27 -04:00
Wilson Snyder
9b869edd90
Internals: Fix cppcheck warnings. No functional change.
2023-03-18 19:28:48 -04:00
Kamil Rakoczy
0130c2bceb
Internals: update clang attributes check report conditions ( #3997 )
2023-03-02 18:37:07 -05:00
Wilson Snyder
b1a95f642f
Support cast to numbers from strings.
2023-02-28 23:34:33 -05:00
Wilson Snyder
eb5aad94f1
Support to packed array
2023-02-05 10:18:03 -05:00
Wilson Snyder
6908e471e7
Revert: e3558d9e: Support vpiDefName ( #3906 ) ( #3931 )
2023-02-03 21:26:21 -05:00
Andrew Nolte
e3558d9e1b
Support vpiDefName ( #3906 ) ( #3931 )
2023-02-03 19:14:41 -05:00
Wilson Snyder
7855a78a0f
Support %p of union with real
2023-01-28 21:41:50 -05:00
Sören Tempel
78fe77db0f
Fix compatibility with musl libc / Alpine Linux ( #3845 )
2023-01-05 15:50:25 -05:00
Wilson Snyder
b24d7c83d3
Copyright year update
2023-01-01 10:18:39 -05:00
Wilson Snyder
3ccb2e0f2d
Fix initiation of function variables ( #3815 ).
2022-12-23 10:51:52 -05:00
Wilson Snyder
d64971ba35
Fix some MSVC warnings.
2022-12-22 12:19:09 -05:00
Kamil Rakoczy
4f7df4a915
Internals: Mark more VL_MT_SAFE functions ( #3816 ).
2022-12-16 10:14:02 -05:00
Wilson Snyder
073af8e1f2
Fix to zero possibly uninitialized bits in replications ( #3815 )
2022-12-15 22:00:21 -05:00
Wilson Snyder
2eafd82696
Internals: Mark more VL_MT_SAFE functions ( #3748 ). No functional change
2022-12-15 21:32:34 -05:00
Kamil Rakoczy
925fb921a2
Fix missing VL_REQUIRES in definition ( #3804 )
2022-12-14 21:16:16 -05:00
Wilson Snyder
61d6546400
Internals: Mark more VL_MT_SAFE functions. No functional change
2022-12-11 23:03:27 -05:00
Larry Doolittle
f27cf4c804
Commentary: Fix spelling in C++ comments ( #3797 ) ( #3798 )
2022-12-02 18:46:38 -05:00
Wilson Snyder
468a33b61c
Move SystemC requirement out of .cpp files ( #3507 )
2022-11-29 22:44:37 -05:00
Wilson Snyder
8ff607f679
Deprecate verilated_fst_sc.cpp and verilated_vcd_sc.cpp ( #3507 )
2022-11-29 22:17:50 -05:00
Wilson Snyder
6143892619
Internals: Add some VL_UNLIKELY. No functional change.
2022-11-29 20:36:56 -05:00
Wilson Snyder
4452a9b10f
Internals: Fix some VL_MT metacomments.
2022-11-28 07:08:34 -05:00
Wilson Snyder
f4be3d5d2b
Fix empty string literals converting to string types ( #3774 ).
2022-11-27 13:28:57 -05:00
Wilson Snyder
833780fac1
Internal: cppcheck fixes. No functional change intended.
2022-11-27 05:52:40 -05:00
Wilson Snyder
66d85b3381
Internals: Fix cppcheck warnings. No functional change intended.
2022-11-21 21:40:49 -05:00
github action
cd8528e83b
Apply 'make format'
2022-11-18 00:14:05 +00:00
Wilson Snyder
e8a1e4745c
Support $stacktrace
2022-11-17 19:12:54 -05:00
Wilson Snyder
8c6d1e53ca
Internals: Fix some 'p' names, and make new base class for VlDeleter. No functional change intended.
2022-11-13 17:40:50 -05:00
Wilson Snyder
218dd4322b
Fix C++11 warnings
2022-11-12 16:03:13 -05:00
Kamil Rakoczy
d6126c4b32
Remove --no-threads; require --threads 1 for single threaded ( #3703 ).
2022-11-05 08:47:34 -04:00
Geza Lore
65e08f4dbf
Make all expressions derive from AstNodeExpr ( #3721 ).
...
Apart from the representational changes below, this patch renames
AstNodeMath to AstNodeExpr, and AstCMath to AstCExpr.
Now every expression (i.e.: those AstNodes that represent a [possibly
void] value, with value being interpreted in a very general sense) has
AstNodeExpr as a super class. This necessitates the introduction of an
AstStmtExpr, which represents an expression in statement position, e.g :
'foo();' would be represented as AstStmtExpr(AstCCall(foo)). In exchange
we can get rid of isStatement() in AstNodeStmt, which now really always
represent a statement
Peak memory consumption and verilation speed are not measurably changed.
Partial step towards #3420
2022-11-03 16:02:16 +00:00
Kamil Rakoczy
ed93a111c2
Fix deadlock in ``timeprecision`` when using systemC ( #3707 )
2022-10-26 04:50:28 -07:00
Wilson Snyder
e7068369fe
Fix $display of fixed-width numbers ( #3565 ).
2022-10-18 21:10:35 -04:00
Wilson Snyder
6f9c585452
Spelling ( #3664 )
2022-10-09 14:18:14 -04:00
Wilson Snyder
4367e03e46
Internals: Make VL_UNREACHABLE similar to std::unreachable()
2022-10-02 16:35:45 -04:00
Krzysztof Bieganski
9c2ead90d5
Add custom memory management for verilated classes ( #3595 )
...
This change introduces a custom reference-counting pointer class that
allows creating such pointers from 'this'. This lets us keep the
receiver object around even if all references to it outside of a class
method no longer exist. Useful for coroutine methods, which may outlive
all external references to the object.
The deletion of objects is deferred until the next time slot. This is to
make clearing the triggered flag on named events in classes safe
(otherwise freed memory could be accessed).
2022-09-28 18:54:18 -04:00
Geza Lore
38a8d7fb2e
Remove redundant 'inline' keywords from definitions
...
Also add checks to t/t_dist_cppstyle
2022-09-16 15:52:25 +01:00
Geza Lore
96a4b3e5a5
Update clang-format config and apply
...
- Regroup and sort #include directives (like we used to, but automatic)
- Set AlwaysBreakTemplateDeclarations to true
2022-08-05 12:00:24 +01:00
Wilson Snyder
a2d26b45bb
Internals: Fix some clang-tidy issues. No functional change intended.
2022-07-30 11:54:28 -04:00
Geza Lore
38e5b6c1ad
Replace __gcov_flush with __gcov_dump
...
__gcov_flush was a private function and was removed from later GCC
versions (at least from 11.2.0, possibly earlier). Replace with the
documented public __gcov_dump.
2022-07-30 16:02:03 +01:00
Wilson Snyder
b9d7819faa
Internals: Fix some cppcheck issues. Some dump functions fixed.
2022-07-30 10:01:39 -04:00
Gustav Svensk
eeef5ab4de
Fix sformat string incorrectly cleared ( #3515 ) ( #3519 ).
2022-07-25 17:36:34 +02:00
Geza Lore
30e3edb81d
Remove deprecated and unused timescale override defines
...
These have been 'deprecated' for 2 years and are otherwise unused except
for using a temporary placeholder value, which I have inlined with the
default value.
Also remove the now VL_TIME_STR_CONVERT utility function (and
corresponding unit tests), which have no references in any project on
GitHub.
2022-07-20 14:06:09 +01:00
Geza Lore
1d400dd98c
Configure tracing at run-time, instead of compile time ( #3504 )
...
All remaining use of conditional compilation in the tracing
implementation of the run-time library are replaced with the use of
VerilatedModel::traceConfig, and is now done at run-time.
2022-07-20 11:27:10 +01:00
Geza Lore
b61d819fcb
Move contextp() under VerilatedModel
2022-07-12 16:06:08 +01:00
Geza Lore
f4038e3674
Move thread pool and execution profiler into the context. ( #3477 )
...
Fixes #3454
2022-07-12 11:41:15 +01:00
Arkadiusz Kozdra
8377514127
Add support for $test$plusargs(expr) ( #3489 )
2022-07-11 06:21:35 -04:00
Wilson Snyder
5aa12e9b51
Add assert when VerilatedContext is mis-deleted ( #3121 ).
2022-05-15 10:51:03 -04:00
Wilson Snyder
33105f017c
Commentary
2022-03-30 20:17:59 -04:00
Wilson Snyder
e02f97854c
Deprecate 'vluint64_t' and similar types ( #3255 ).
2022-03-27 15:27:40 -04:00
Geza Lore
b1b5b5dfe2
Improve run-time profiling
...
The --prof-threads option has been split into two independent options:
1. --prof-exec, for collecting verilator_gantt and other execution
related profiling data, and
2. --prof-pgo, for collecting data needed for PGO
The implementation of execution profiling is extricated from
VlThreadPool and is now a separate class VlExecutionProfiler. This means
--prof-exec can now be used for single-threaded models (though it does
not measure a lot of things just yet). For consistency VerilatedProfiler
is renamed VlPgoProfiler. Both VlExecutionProfiler and VlPgoProfiler are
in verilated_profiler.{h/cpp}, but can be used completely independently.
Also re-worked the execution profile format so it now only emits events
without holding onto any temporaries. This is in preparation for some
future optimizations that would be hindered by the introduction of function
locals via AstText.
Also removed the Barrier event. Clearing the profile buffers is not
notably more expensive as the profiling records are trivially
destructible.
2022-03-27 15:57:30 +02:00
Geza Lore
c7440b250f
Validate integer run-time arguments
2022-03-26 22:58:47 +00:00
Wilson Snyder
ef87d057fc
Fix $fscanf etc to return -1 on EOF ( #3113 ).
2022-03-07 17:43:33 -05:00
Wilson Snyder
e52a4ac74f
Fix $readmem file not found to be warning not error ( #3310 ).
2022-02-19 10:04:12 -05:00
Wilson Snyder
d679d50eca
Fix $random not updating seed ( #3238 ). [Julie Schwartz]
2022-01-01 16:43:06 -05:00
Wilson Snyder
4cd56b1fb9
Use C++11 standard types for MacOS portability ( #3254 ) ( #3257 ).
2022-01-01 16:04:20 -05:00
Wilson Snyder
ca42be982c
Copyright year update.
2022-01-01 08:26:40 -05:00
Wilson Snyder
7526151670
Fix bad ending address on $readmem ( #3205 ).
2021-12-21 19:55:04 -05:00