mirror of
https://github.com/verilator/verilator.git
synced 2026-10-06 10:03:44 +02:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c5f0ed9c99 | ||
|
|
2ce30e78a1 | ||
|
|
3b554f4c5b | ||
|
|
cf40fd356f | ||
|
|
8848469bf9 | ||
|
|
4100417f83 | ||
|
|
bd6d743f9c | ||
|
|
857ac24ba7 | ||
|
|
5672b99203 | ||
|
|
3d8de3194c | ||
|
|
8b91a9f898 | ||
|
|
038ee69a96 | ||
|
|
8986d1f16f | ||
|
|
86c8e7b3e6 | ||
|
|
9026118a7c | ||
|
|
58fc922737 | ||
|
|
3b5c791332 | ||
|
|
6e16bc1b7b | ||
|
|
1aba0f6379 | ||
|
|
11cfa3c072 | ||
|
|
59141b1678 | ||
|
|
2083c071ce | ||
|
|
3ad5872d30 | ||
|
|
ea6bb21cdc | ||
|
|
3d4fe0364a |
@@ -3,17 +3,43 @@ Revision history for Verilator
|
|||||||
The contributors that suggested a given feature are shown in []. [by ...]
|
The contributors that suggested a given feature are shown in []. [by ...]
|
||||||
indicates the contributor was also the author of the fix; Thanks!
|
indicates the contributor was also the author of the fix; Thanks!
|
||||||
|
|
||||||
* Verilator 3.62**
|
* Verilator 3.62***
|
||||||
|
|
||||||
**** Fix link error when using --exe with --trace. [Eugene Weber]
|
*** Fixed configure and compiling under Solaris. [Bob Farrell]
|
||||||
|
|
||||||
**** Public functions now allow > 64 bit arguments.
|
*** When dotted signal lookup fails, help the user by showing known scopes.
|
||||||
|
|
||||||
**** Don't core dump on errors when not under --debug. [Allan Cochrane]
|
**** Fix dotted references inside generated cells. [David Hewson]
|
||||||
|
|
||||||
|
**** Fix missed split optimization points underneath other re-split blocks.
|
||||||
|
|
||||||
|
* Verilator 3.623 12/05/2006
|
||||||
|
|
||||||
|
*** Add --output-split-cfuncs for accelerating GCC compile. [Eugene Weber]
|
||||||
|
|
||||||
|
**** Fix $signed mis-extending when input has a WIDTH violation. [Eugene Weber]
|
||||||
|
|
||||||
|
**** Add M32 make variable to support -m32 compiles. [Eugene Weber]
|
||||||
|
|
||||||
|
* Verilator 3.622 10/17/2006 Stable
|
||||||
|
|
||||||
|
**** Fix --skip-identical without --debug, broken in 3.621. [Andy Meier]
|
||||||
|
|
||||||
|
* Verilator 3.621 10/11/2006 Beta
|
||||||
|
|
||||||
|
** Add /*verilator no_inline_task*/ to prevent over-expansion. [Eugene Weber]
|
||||||
|
|
||||||
|
*** Public functions now allow > 64 bit arguments.
|
||||||
|
|
||||||
**** Remove .vpp intermediate files when not under --debug.
|
**** Remove .vpp intermediate files when not under --debug.
|
||||||
|
|
||||||
* Verilator 3.620 10/04/2006
|
**** Fix link error when using --exe with --trace. [Eugene Weber]
|
||||||
|
|
||||||
|
**** Fix mis-optimization of wide concats with constants.
|
||||||
|
|
||||||
|
**** Fix core dump on printing error when not under --debug. [Allan Cochrane]
|
||||||
|
|
||||||
|
* Verilator 3.620 10/04/2006 Stable
|
||||||
|
|
||||||
*** Support simple inout task ports. [Eugene Weber]
|
*** Support simple inout task ports. [Eugene Weber]
|
||||||
|
|
||||||
@@ -436,7 +462,7 @@ indicates the contributor was also the author of the fix; Thanks!
|
|||||||
**** Added NC Verilog as alternative to VCS for reference tests.
|
**** Added NC Verilog as alternative to VCS for reference tests.
|
||||||
|
|
||||||
**** Support implicit wire declarations on input-only signals.
|
**** Support implicit wire declarations on input-only signals.
|
||||||
(Dangerous, as leads to wires without drivers, but allowed by spec.)
|
(Dangerous, as leads to wires without drivers, but allowed by spec.)
|
||||||
|
|
||||||
**** Fixed compile warnings on Suse 9.1
|
**** Fixed compile warnings on Suse 9.1
|
||||||
|
|
||||||
|
|||||||
+7
-8
@@ -78,7 +78,6 @@ datadir = @datadir@
|
|||||||
infodir = @infodir@
|
infodir = @infodir@
|
||||||
|
|
||||||
# Directory in which to install package specific files
|
# Directory in which to install package specific files
|
||||||
# Note this gets coded into v3c/config.h also
|
|
||||||
pkgdatadir = @pkgdatadir@
|
pkgdatadir = @pkgdatadir@
|
||||||
|
|
||||||
#### End of system configuration section. ####
|
#### End of system configuration section. ####
|
||||||
@@ -265,16 +264,16 @@ uninstall:
|
|||||||
-cd $(mandir)/man1 && rm -f $(VL_INST_MAN_FILES)
|
-cd $(mandir)/man1 && rm -f $(VL_INST_MAN_FILES)
|
||||||
-cd $(bindir) && rm -f $(VL_INST_BIN_FILES)
|
-cd $(bindir) && rm -f $(VL_INST_BIN_FILES)
|
||||||
|
|
||||||
# autoheader might not change config.h.in, so touch a stamp file.
|
# autoheader might not change config_build.h.in, so touch a stamp file.
|
||||||
IN_WILD := ${srcdir}/*.in ${srcdir}/*/*.in ${srcdir}/*/*/*.in \
|
IN_WILD := ${srcdir}/*.in ${srcdir}/*/*.in ${srcdir}/*/*/*.in \
|
||||||
*.in */*.in */*.in
|
*.in */*.in */*.in
|
||||||
|
|
||||||
${srcdir}/config.h.in: stamp-h.in
|
${srcdir}/config_build.h.in: stamp-h.in
|
||||||
${srcdir}/stamp-h.in: configure.in $(wildcard $(IN_WILD))
|
${srcdir}/stamp-h.in: configure.ac $(wildcard $(IN_WILD))
|
||||||
cd ${srcdir} && autoheader
|
cd ${srcdir} && autoheader
|
||||||
echo timestamp > ${srcdir}/stamp-h.in
|
echo timestamp > ${srcdir}/stamp-h.in
|
||||||
config.h: stamp-h
|
config_build.h: stamp-h
|
||||||
stamp-h: config.h.in config.status
|
stamp-h: config_build.h.in config.status
|
||||||
./config.status
|
./config.status
|
||||||
Makefile: Makefile.in config.status
|
Makefile: Makefile.in config.status
|
||||||
./config.status
|
./config.status
|
||||||
@@ -282,7 +281,7 @@ src/Makefile: src/Makefile.in config.status
|
|||||||
./config.status
|
./config.status
|
||||||
config.status: configure
|
config.status: configure
|
||||||
./config.status --recheck
|
./config.status --recheck
|
||||||
configure: configure.in
|
configure: configure.ac
|
||||||
autoconf
|
autoconf
|
||||||
|
|
||||||
maintainer-clean::
|
maintainer-clean::
|
||||||
@@ -317,7 +316,7 @@ TAGS: $(TAGFILES)
|
|||||||
######################################################################
|
######################################################################
|
||||||
# Distributions
|
# Distributions
|
||||||
|
|
||||||
DISTCONFIG = src/config.h.in
|
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))
|
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))
|
DISTNAME := $(shell sed -e '/DTVERSION/!d' -e 's/[^0-9]*\([0-9.a-z]*\).*/verilator-\1/' -e q $(DISTCONFIG))
|
||||||
|
|||||||
+119
-19
@@ -377,9 +377,18 @@ C++ file exceeds the specified number of operations, a new file will be
|
|||||||
created. In addition, any slow routines will be placed into __Slow files.
|
created. In addition, any slow routines will be placed into __Slow files.
|
||||||
This accelerates compilation by as optimization can be disabled on the slow
|
This accelerates compilation by as optimization can be disabled on the slow
|
||||||
routines, and the remaining files can be compiled on parallel machines.
|
routines, and the remaining files can be compiled on parallel machines.
|
||||||
|
Using --output-split should have only a trivial impact on performance.
|
||||||
With GCC 3.3 on a 2GHz Opteron, --output-split 20000 will result in
|
With GCC 3.3 on a 2GHz Opteron, --output-split 20000 will result in
|
||||||
splitting into approximately one-minute-compile chunks.
|
splitting into approximately one-minute-compile chunks.
|
||||||
|
|
||||||
|
=item --output-split-cfuncs I<statements>
|
||||||
|
|
||||||
|
Enables splitting functions in the output .cpp/.sp files into multiple
|
||||||
|
functions. When a generated function exceeds the specified number of
|
||||||
|
operations, a new function will be created. With --output-split, this will
|
||||||
|
enable GCC to compile faster, at a small loss in performance that increases
|
||||||
|
with smaller statement values.
|
||||||
|
|
||||||
=item --pins64
|
=item --pins64
|
||||||
|
|
||||||
Specifies SystemC outputs of 33-64 bits wide should use uint64_t instead of
|
Specifies SystemC outputs of 33-64 bits wide should use uint64_t instead of
|
||||||
@@ -407,7 +416,7 @@ compatibility.
|
|||||||
|
|
||||||
=item --psl
|
=item --psl
|
||||||
|
|
||||||
Enable PSL parsing. Without this switch, psl meta-comments are ignored.
|
Enable PSL parsing. Without this switch, PSL meta-comments are ignored.
|
||||||
See the --assert flag to enable all assertions, and --coverage-user to
|
See the --assert flag to enable all assertions, and --coverage-user to
|
||||||
enable functional coverage.
|
enable functional coverage.
|
||||||
|
|
||||||
@@ -609,7 +618,7 @@ Then we convert the SystemPerl output to SystemC.
|
|||||||
$SYSTEMPERL/sp_preproc --preproc *.sp
|
$SYSTEMPERL/sp_preproc --preproc *.sp
|
||||||
|
|
||||||
(You can also skip the above sp_preproc by getting pure SystemC from
|
(You can also skip the above sp_preproc by getting pure SystemC from
|
||||||
verilator by replacing the verilator --sp flag in the previous step with
|
Verilator by replacing the verilator --sp flag in the previous step with
|
||||||
-sc.)
|
-sc.)
|
||||||
|
|
||||||
We then can compile it
|
We then can compile it
|
||||||
@@ -846,6 +855,30 @@ Lower modules are not pure SystemC code. This is a feature, as using the
|
|||||||
SystemC pin interconnect scheme everywhere would reduce performance by an
|
SystemC pin interconnect scheme everywhere would reduce performance by an
|
||||||
order of magnitude.
|
order of magnitude.
|
||||||
|
|
||||||
|
=head1 CROSS COMPILATION
|
||||||
|
|
||||||
|
Verilator supports cross-compling Verilated code. This is generally used
|
||||||
|
to run Verilator on a Linux system and produce C++ code that is then compiled
|
||||||
|
on Windows.
|
||||||
|
|
||||||
|
Cross compilation involves up to three different OSes. The build system is
|
||||||
|
where you configured and compiled Verilator, the host system where you run
|
||||||
|
Verilator, and the target system where you compile the Verilated code and
|
||||||
|
run the simulation.
|
||||||
|
|
||||||
|
Currently, Verilator requires the build and host system type to be the
|
||||||
|
same, though the target system type may be different. To support this,
|
||||||
|
./configure and make Verilator on the build system. Then, run Verilator on
|
||||||
|
the host system. Finally, the output of Verilator may be compiled on the
|
||||||
|
different target system.
|
||||||
|
|
||||||
|
To support this, none of the files that Verilator produces will reference
|
||||||
|
any configure generated build-system specific files, such as config.h
|
||||||
|
(which is renamed in Verilator to config_build.h to reduce confusion.) The
|
||||||
|
disadvantage of this approach is that include/verilatedos.h must
|
||||||
|
self-detect the requirements of the target system, rather then using
|
||||||
|
configure.
|
||||||
|
|
||||||
=head1 VERILOG 2001 SUPPORT
|
=head1 VERILOG 2001 SUPPORT
|
||||||
|
|
||||||
Verilator supports the more common Verilog 2001 language features. This
|
Verilator supports the more common Verilog 2001 language features. This
|
||||||
@@ -938,7 +971,7 @@ call C++ functions from your Verilog code.
|
|||||||
String arguments will be put directly into the output C++ code. Expression
|
String arguments will be put directly into the output C++ code. Expression
|
||||||
arguments will have the code to evaluate the expression inserted. Thus to
|
arguments will have the code to evaluate the expression inserted. Thus to
|
||||||
call a C++ function, $c("func(",a,")") will result in 'func(a)' in the
|
call a C++ function, $c("func(",a,")") will result in 'func(a)' in the
|
||||||
output C++ code. For input arguments, rather then hardcoding variable
|
output C++ code. For input arguments, rather then hard-coding variable
|
||||||
names in the string $c("func(a)"), instead pass the variable as an
|
names in the string $c("func(a)"), instead pass the variable as an
|
||||||
expression $c("func(",a,")"). This will allow the call to work inside
|
expression $c("func(",a,")"). This will allow the call to work inside
|
||||||
Verilog functions where the variable is flattened out, and also enable
|
Verilog functions where the variable is flattened out, and also enable
|
||||||
@@ -1056,6 +1089,14 @@ Disable the specified warning message for any warnings following the comment.
|
|||||||
|
|
||||||
Re-enable the specified warning message for any warnings following the comment.
|
Re-enable the specified warning message for any warnings following the comment.
|
||||||
|
|
||||||
|
=item /*verilator no_inline_task*/
|
||||||
|
|
||||||
|
Used in a function or task variable definition section to specify the
|
||||||
|
function or task should not be inlined into where it is used. This may
|
||||||
|
reduce the size of the final executable when a task is used a very large
|
||||||
|
number of times. For this flag to work, the task and tasks below it must
|
||||||
|
be pure; they cannot reference any variables outside the task itself.
|
||||||
|
|
||||||
=item /*verilator sc_clock*/
|
=item /*verilator sc_clock*/
|
||||||
|
|
||||||
Used after a input declaration to indicate the signal should be declared in
|
Used after a input declaration to indicate the signal should be declared in
|
||||||
@@ -1271,7 +1312,7 @@ appropriate width.
|
|||||||
$display and friends must have a constant format string as the first
|
$display and friends must have a constant format string as the first
|
||||||
argument (as with C's printf), you cannot simply list variables standalone.
|
argument (as with C's printf), you cannot simply list variables standalone.
|
||||||
|
|
||||||
=head1 ERRORS
|
=head1 ERRORS AND WARNINGS
|
||||||
|
|
||||||
Warnings may be disabled in two ways. First, when the warning is
|
Warnings may be disabled in two ways. First, when the warning is
|
||||||
printed it will include a warning code. Simply surround the offending
|
printed it will include a warning code. Simply surround the offending
|
||||||
@@ -1281,13 +1322,13 @@ line with a warn_off/warn_on pair:
|
|||||||
if (`DEF_THAT_IS_EQ_ZERO <= 3) $stop;
|
if (`DEF_THAT_IS_EQ_ZERO <= 3) $stop;
|
||||||
// verilator lint_on UNSIGNED
|
// verilator lint_on UNSIGNED
|
||||||
|
|
||||||
They may also be globally disabled by invoking Verilator with the
|
Warnings may also be globally disabled by invoking Verilator with the
|
||||||
C<-Wno-I<warning>> switch. This should be avoided, as it removes
|
C<-Wno-I<warning>> switch. This should be avoided, as it removes all
|
||||||
all checking across the designs, and prevents other users from
|
checking across the designs, and prevents other users from compiling your
|
||||||
compiling your code without knowing the magic set of disables needed
|
code without knowing the magic set of disables needed to successfully
|
||||||
to successfully compile your design.
|
compile your design.
|
||||||
|
|
||||||
Warnings:
|
List of all warnings:
|
||||||
|
|
||||||
=over 4
|
=over 4
|
||||||
|
|
||||||
@@ -1344,12 +1385,41 @@ signal before it is implicitly declared by a cell, and can lead to dangling
|
|||||||
nets. A better option is the /*AUTOWIRE*/ feature of Verilog-Mode for
|
nets. A better option is the /*AUTOWIRE*/ feature of Verilog-Mode for
|
||||||
Emacs, available from L<http://www.veripool.com/>
|
Emacs, available from L<http://www.veripool.com/>
|
||||||
|
|
||||||
|
=item IMPURE
|
||||||
|
|
||||||
|
Warns that a task or function that has been marked with /*verilator
|
||||||
|
no_inline_task*/ references variables that are not local to the task.
|
||||||
|
Verilator cannot schedule these variables correctly.
|
||||||
|
|
||||||
=item MULTIDRIVEN
|
=item MULTIDRIVEN
|
||||||
|
|
||||||
Warns that the specified signal comes from multiple always blocks. This is
|
Warns that the specified signal comes from multiple always blocks. This is
|
||||||
often unsupported by synthesis tools, and is considered bad style. It will
|
often unsupported by synthesis tools, and is considered bad style. It will
|
||||||
also cause longer runtimes due to reduced optimizations.
|
also cause longer runtimes due to reduced optimizations.
|
||||||
|
|
||||||
|
=item TASKNSVAR
|
||||||
|
|
||||||
|
Error when a call to a task or function has a output from that task tied to
|
||||||
|
a non-simple signal. Instead connect the task output to a temporary signal
|
||||||
|
of the appropriate width, and use that signal to set the appropriate
|
||||||
|
expression as the next statement. For example:
|
||||||
|
|
||||||
|
task foo; output sig; ... endtask
|
||||||
|
always @* begin
|
||||||
|
foo(bus_we_select_from[2]); // Will get TASKNSVAR error
|
||||||
|
end
|
||||||
|
|
||||||
|
Change this to:
|
||||||
|
|
||||||
|
reg foo_temp_out;
|
||||||
|
always @* begin
|
||||||
|
foo(foo_temp_out);
|
||||||
|
bus_we_select_from[2] = foo_temp_out;
|
||||||
|
end
|
||||||
|
|
||||||
|
Verilator doesn't do this conversion for you, as some more complicated
|
||||||
|
cases would result in simulator mismatches.
|
||||||
|
|
||||||
=item UNDRIVEN
|
=item UNDRIVEN
|
||||||
|
|
||||||
Warns that the specified signal is never sourced.
|
Warns that the specified signal is never sourced.
|
||||||
@@ -1375,11 +1445,11 @@ may be only one particular usage of a multiply instantiated block. The
|
|||||||
construct should be cleaned up to improve runtime; two times better
|
construct should be cleaned up to improve runtime; two times better
|
||||||
performance may be possible by fixing these warnings.
|
performance may be possible by fixing these warnings.
|
||||||
|
|
||||||
Unlike UNOPT this occurs after netlist flattening, and indicates a more
|
Unlike the UNOPT warning, this occurs after netlist flattening, and
|
||||||
basic problem, as the less obvious case described under UNOPT does not
|
indicates a more basic problem, as the less obvious case described under
|
||||||
apply.
|
UNOPT does not apply.
|
||||||
|
|
||||||
Often this is caused by logic that isn't truly circular as viewed by
|
Often UNOPTFLAT is caused by logic that isn't truly circular as viewed by
|
||||||
synthesis which analyzes interconnection per-bit, but is circular to
|
synthesis which analyzes interconnection per-bit, but is circular to
|
||||||
simulation which analyzes per-bus:
|
simulation which analyzes per-bus:
|
||||||
|
|
||||||
@@ -1387,12 +1457,31 @@ simulation which analyzes per-bus:
|
|||||||
|
|
||||||
This statement needs to be evaluated multiple times, as a change in
|
This statement needs to be evaluated multiple times, as a change in
|
||||||
"shift_in" requires "x" to be computed 3 times before it becomes stable.
|
"shift_in" requires "x" to be computed 3 times before it becomes stable.
|
||||||
|
This is because a change in "x" requires "x" itself to change value, which
|
||||||
|
causes the warning.
|
||||||
|
|
||||||
For significantly better performance, split this into 2 separate signals:
|
For significantly better performance, split this into 2 separate signals:
|
||||||
|
|
||||||
wire [2:1] x_21 = x[1:0];
|
wire [2:0] xout = {x[1:0],shift_in};
|
||||||
wire [0:0] x_0 = shift_in;
|
|
||||||
|
|
||||||
This warning may also be due to clock enables. To fix these, use the
|
and change all receiving logic to instead receive "xout". Alternatively,
|
||||||
|
change it to
|
||||||
|
|
||||||
|
wire [2:0] x = {xin[1:0],shift_in};
|
||||||
|
|
||||||
|
and change all driving logic to instead drive "xin".
|
||||||
|
|
||||||
|
With this change this assignment needs to be evaluated only once. These
|
||||||
|
sort of changes may also speed up your traditional event driven simulator,
|
||||||
|
as it will result in fewer events per cycle.
|
||||||
|
|
||||||
|
The most complicated UNOPTFLAT path we've seen was due to low bits of a bus
|
||||||
|
being generated from an always statement that consumed high bits of the
|
||||||
|
same bus processed by another series of always blocks. The fix is the
|
||||||
|
same; split it into two separate signals generated from each block.
|
||||||
|
|
||||||
|
The UNOPTFLAT warning may also be due to clock enables, identified from the
|
||||||
|
reported path going through a clock gating cell. To fix these, use the
|
||||||
clock_enable meta comment described above.
|
clock_enable meta comment described above.
|
||||||
|
|
||||||
=item UNSIGNED
|
=item UNSIGNED
|
||||||
@@ -1450,8 +1539,8 @@ that is not yet supported in Verilator. See the Limitations chapter.
|
|||||||
=item Verilated model didn't converge
|
=item Verilated model didn't converge
|
||||||
|
|
||||||
Verilator sometimes has to evaluate combinatorial logic multiple times,
|
Verilator sometimes has to evaluate combinatorial logic multiple times,
|
||||||
usually around code where a UNOPT warning was issued, but disabled. For
|
usually around code where a UNOPTFLAT warning was issued, but disabled.
|
||||||
example:
|
For example:
|
||||||
|
|
||||||
always @ (a) b=~a;
|
always @ (a) b=~a;
|
||||||
always @ (b) a=b
|
always @ (b) a=b
|
||||||
@@ -1546,6 +1635,11 @@ controlled by --assert are disabled.
|
|||||||
In C++ (non SystemC) code you need to define this function so that the
|
In C++ (non SystemC) code you need to define this function so that the
|
||||||
simulator knows the current time. See the "CONNECTING TO C++" examples.
|
simulator knows the current time. See the "CONNECTING TO C++" examples.
|
||||||
|
|
||||||
|
=item Why do I get "undefined reference to `VL_RAND_RESET_I' or `Verilated::...'"?
|
||||||
|
|
||||||
|
You need to link your compiled Verilated code against the verilated.cpp
|
||||||
|
file found in the include directory of the Verilator kit.
|
||||||
|
|
||||||
=item Is the PLI supported?
|
=item Is the PLI supported?
|
||||||
|
|
||||||
No.
|
No.
|
||||||
@@ -1556,6 +1650,12 @@ complex, since Verilator emits standard C++ code, you can simply write your
|
|||||||
own C++ routines that can access and modify signal values without needing
|
own C++ routines that can access and modify signal values without needing
|
||||||
any PLI interface code, and call it with $c("{any_c++_statement}").
|
any PLI interface code, and call it with $c("{any_c++_statement}").
|
||||||
|
|
||||||
|
=item How do I make a Verilog module that contain a C++ object?
|
||||||
|
|
||||||
|
You need to add the object to the structure that Verilator creates, then
|
||||||
|
use $c to call a method inside your object. The
|
||||||
|
test_regress/t/t_extend_class files show an example of how to do this.
|
||||||
|
|
||||||
=item How do I get faster build times?
|
=item How do I get faster build times?
|
||||||
|
|
||||||
Between GCC 3.0 to 3.3, each compiled progressively slower, thus if you can
|
Between GCC 3.0 to 3.3, each compiled progressively slower, thus if you can
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ dnl General Public License or the Perl Artistic License.
|
|||||||
|
|
||||||
AC_REVISION($Revision$)dnl
|
AC_REVISION($Revision$)dnl
|
||||||
AC_INIT(src/Verilator.cpp)
|
AC_INIT(src/Verilator.cpp)
|
||||||
AC_CONFIG_HEADER(src/config.h)
|
AC_CONFIG_HEADER(src/config_build.h)
|
||||||
|
|
||||||
dnl Special Substitutions
|
dnl Special Substitutions
|
||||||
|
|
||||||
@@ -24,7 +24,7 @@ dnl Checks for libraries.
|
|||||||
dnl Checks for header files.
|
dnl Checks for header files.
|
||||||
AC_HEADER_STDC
|
AC_HEADER_STDC
|
||||||
AC_HEADER_SYS_WAIT
|
AC_HEADER_SYS_WAIT
|
||||||
AC_CHECK_HEADERS(fcntl.h unistd.h sys/file.h sys/time.h sys/un.h math.h stdint.h mingw/stdint.h)
|
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)
|
||||||
|
|
||||||
dnl Checks for typedefs, structures
|
dnl Checks for typedefs, structures
|
||||||
AC_CHECK_TYPE(size_t,unsigned int)
|
AC_CHECK_TYPE(size_t,unsigned int)
|
||||||
@@ -1328,6 +1328,38 @@ static inline WDataOutP VL_CONST_W_16X(int obits, WDataOutP o,
|
|||||||
o[0]=d0; o[1]=d1; o[2]=d2; o[3]=d3; o[4]=d4; o[5]=d5; o[6]=d6; o[7]=d7;
|
o[0]=d0; o[1]=d1; o[2]=d2; o[3]=d3; o[4]=d4; o[5]=d5; o[6]=d6; o[7]=d7;
|
||||||
o[8]=d8; o[9]=d9; o[10]=d10; o[11]=d11; o[12]=d12; o[13]=d13; o[14]=d14; o[15]=d15;
|
o[8]=d8; o[9]=d9; o[10]=d10; o[11]=d11; o[12]=d12; o[13]=d13; o[14]=d14; o[15]=d15;
|
||||||
_END(obits,16); }
|
_END(obits,16); }
|
||||||
|
static inline WDataOutP VL_CONST_W_17X(int obits, WDataOutP o,
|
||||||
|
I d16,
|
||||||
|
I d15,I d14,I d13,I d12,I d11,I d10,I d9,I d8,
|
||||||
|
I d7,I d6,I d5,I d4,I d3,I d2,I d1,I d0) {
|
||||||
|
o[0]=d0; o[1]=d1; o[2]=d2; o[3]=d3; o[4]=d4; o[5]=d5; o[6]=d6; o[7]=d7;
|
||||||
|
o[8]=d8; o[9]=d9; o[10]=d10; o[11]=d11; o[12]=d12; o[13]=d13; o[14]=d14; o[15]=d15;
|
||||||
|
o[16]=d16;
|
||||||
|
_END(obits,17); }
|
||||||
|
static inline WDataOutP VL_CONST_W_18X(int obits, WDataOutP o,
|
||||||
|
I d17,I d16,
|
||||||
|
I d15,I d14,I d13,I d12,I d11,I d10,I d9,I d8,
|
||||||
|
I d7,I d6,I d5,I d4,I d3,I d2,I d1,I d0) {
|
||||||
|
o[0]=d0; o[1]=d1; o[2]=d2; o[3]=d3; o[4]=d4; o[5]=d5; o[6]=d6; o[7]=d7;
|
||||||
|
o[8]=d8; o[9]=d9; o[10]=d10; o[11]=d11; o[12]=d12; o[13]=d13; o[14]=d14; o[15]=d15;
|
||||||
|
o[16]=d16; o[17]=d17;
|
||||||
|
_END(obits,18); }
|
||||||
|
static inline WDataOutP VL_CONST_W_19X(int obits, WDataOutP o,
|
||||||
|
I d18,I d17,I d16,
|
||||||
|
I d15,I d14,I d13,I d12,I d11,I d10,I d9,I d8,
|
||||||
|
I d7,I d6,I d5,I d4,I d3,I d2,I d1,I d0) {
|
||||||
|
o[0]=d0; o[1]=d1; o[2]=d2; o[3]=d3; o[4]=d4; o[5]=d5; o[6]=d6; o[7]=d7;
|
||||||
|
o[8]=d8; o[9]=d9; o[10]=d10; o[11]=d11; o[12]=d12; o[13]=d13; o[14]=d14; o[15]=d15;
|
||||||
|
o[16]=d16; o[17]=d17; o[18]=d18;
|
||||||
|
_END(obits,19); }
|
||||||
|
static inline WDataOutP VL_CONST_W_20X(int obits, WDataOutP o,
|
||||||
|
I d19,I d18,I d17,I d16,
|
||||||
|
I d15,I d14,I d13,I d12,I d11,I d10,I d9,I d8,
|
||||||
|
I d7,I d6,I d5,I d4,I d3,I d2,I d1,I d0) {
|
||||||
|
o[0]=d0; o[1]=d1; o[2]=d2; o[3]=d3; o[4]=d4; o[5]=d5; o[6]=d6; o[7]=d7;
|
||||||
|
o[8]=d8; o[9]=d9; o[10]=d10; o[11]=d11; o[12]=d12; o[13]=d13; o[14]=d14; o[15]=d15;
|
||||||
|
o[16]=d16; o[17]=d17; o[18]=d18; o[19]=d19;
|
||||||
|
_END(obits,20); }
|
||||||
static inline WDataOutP VL_CONST_W_24X(int obits, WDataOutP o,
|
static inline WDataOutP VL_CONST_W_24X(int obits, WDataOutP o,
|
||||||
I d23,I d22,I d21,I d20,I d19,I d18,I d17,I d16,
|
I d23,I d22,I d21,I d20,I d19,I d18,I d17,I d16,
|
||||||
I d15,I d14,I d13,I d12,I d11,I d10,I d9,I d8,
|
I d15,I d14,I d13,I d12,I d11,I d10,I d9,I d8,
|
||||||
|
|||||||
@@ -48,6 +48,9 @@ VPATH += $(VERILATOR_ROOT)/include
|
|||||||
#OPT = -ggdb -DPRINTINITSTR
|
#OPT = -ggdb -DPRINTINITSTR
|
||||||
CPPFLAGS += $(OPT)
|
CPPFLAGS += $(OPT)
|
||||||
|
|
||||||
|
CPPFLAGS += $(M32)
|
||||||
|
LDFLAGS += $(M32)
|
||||||
|
|
||||||
# See the benchmarking section of bin/verilator.
|
# See the benchmarking section of bin/verilator.
|
||||||
# Support class optimizations. This includes the tracing and symbol table.
|
# Support class optimizations. This includes the tracing and symbol table.
|
||||||
# SystemC takes minutes to optimize, thus it is off by default.
|
# SystemC takes minutes to optimize, thus it is off by default.
|
||||||
|
|||||||
@@ -15,9 +15,11 @@
|
|||||||
/// \file
|
/// \file
|
||||||
/// \brief Verilator: Common include for OS portability (verilated & verilator)
|
/// \brief Verilator: Common include for OS portability (verilated & verilator)
|
||||||
///
|
///
|
||||||
/// This header is used by both verilated code, and the verilator
|
/// This header is used by both the Verilator source code (run on the
|
||||||
/// program itself Code needed by only one goes into verilated.h or
|
/// build and host system), and the Verilated output (run on the target
|
||||||
/// config.h.in respectively.
|
/// system). Code needed by only the host system goes into
|
||||||
|
/// config_build.h.in, code needed by Verilated code only goes into
|
||||||
|
/// verilated.h, and code needed by both goes here (verilatedos.h).
|
||||||
///
|
///
|
||||||
/// Code available from: http://www.veripool.com/verilator
|
/// Code available from: http://www.veripool.com/verilator
|
||||||
///
|
///
|
||||||
|
|||||||
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
*.old
|
*.old
|
||||||
config.h
|
config_build.h
|
||||||
Makefile
|
Makefile
|
||||||
Makefile_obj
|
Makefile_obj
|
||||||
.objcache*
|
.objcache*
|
||||||
|
|||||||
+1
-1
@@ -87,4 +87,4 @@ clean mostlyclean distclean maintainer-clean::
|
|||||||
-rm -f .objcache*
|
-rm -f .objcache*
|
||||||
|
|
||||||
distclean maintainer-clean::
|
distclean maintainer-clean::
|
||||||
-rm -f Makefile Makefile_obj
|
-rm -f Makefile Makefile_obj config_build.h
|
||||||
|
|||||||
+3
-4
@@ -28,6 +28,8 @@ CC = @CC@
|
|||||||
CXX = @CXX@
|
CXX = @CXX@
|
||||||
LINK = @CXX@
|
LINK = @CXX@
|
||||||
|
|
||||||
|
LDFLAGS += @LDFLAGS@
|
||||||
|
|
||||||
#### End of system configuration section. ####
|
#### End of system configuration section. ####
|
||||||
|
|
||||||
VPATH += . $(srcdir)
|
VPATH += . $(srcdir)
|
||||||
@@ -36,14 +38,12 @@ TGT = ../../verilator_bin
|
|||||||
#################
|
#################
|
||||||
ifeq ($(VL_DEBUG),)
|
ifeq ($(VL_DEBUG),)
|
||||||
# Optimize
|
# Optimize
|
||||||
LDFLAGS =
|
|
||||||
COPT = -O
|
COPT = -O
|
||||||
else
|
else
|
||||||
# Debug
|
# Debug
|
||||||
LDFLAGS =
|
|
||||||
COPT = -ggdb -DVL_DEBUG
|
COPT = -ggdb -DVL_DEBUG
|
||||||
# Debug & Profile:
|
# Debug & Profile:
|
||||||
#LDFLAGS = -pg -g
|
#LDFLAGS += -pg -g
|
||||||
#COPT = -ggdb -pg -g
|
#COPT = -ggdb -pg -g
|
||||||
endif
|
endif
|
||||||
#################
|
#################
|
||||||
@@ -89,7 +89,6 @@ clean mostlyclean distclean maintainer-clean::
|
|||||||
-rm -f obj_* .objcache*
|
-rm -f obj_* .objcache*
|
||||||
|
|
||||||
distclean maintainer-clean:: clean
|
distclean maintainer-clean:: clean
|
||||||
rm -f Makefile config.h
|
|
||||||
|
|
||||||
maintainer-clean::
|
maintainer-clean::
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -31,7 +31,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3ACTIVE_H_
|
#ifndef _V3ACTIVE_H_
|
||||||
#define _V3ACTIVE_H_ 1
|
#define _V3ACTIVE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -28,7 +28,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3ACTIVETOP_H_
|
#ifndef _V3ACTIVETOP_H_
|
||||||
#define _V3ACTIVETOP_H_ 1
|
#define _V3ACTIVETOP_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3ASSERT_H_
|
#ifndef _V3ASSERT_H_
|
||||||
#define _V3ASSERT_H_ 1
|
#define _V3ASSERT_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -22,7 +22,8 @@
|
|||||||
// Attach clocks to each assertion
|
// Attach clocks to each assertion
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3ASSERTPRE_H_
|
#ifndef _V3ASSERTPRE_H_
|
||||||
#define _V3ASSERTPRE_H_ 1
|
#define _V3ASSERTPRE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
@@ -98,6 +98,12 @@ string AstNode::prettyName(const string& namein) {
|
|||||||
while ((pos=pretty.find("__DOT__")) != string::npos) {
|
while ((pos=pretty.find("__DOT__")) != string::npos) {
|
||||||
pretty.replace(pos, 7, ".");
|
pretty.replace(pos, 7, ".");
|
||||||
}
|
}
|
||||||
|
while ((pos=pretty.find("__BRA__")) != string::npos) {
|
||||||
|
pretty.replace(pos, 7, "[");
|
||||||
|
}
|
||||||
|
while ((pos=pretty.find("__KET__")) != string::npos) {
|
||||||
|
pretty.replace(pos, 7, "]");
|
||||||
|
}
|
||||||
while ((pos=pretty.find("__PVT__")) != string::npos) {
|
while ((pos=pretty.find("__PVT__")) != string::npos) {
|
||||||
pretty.replace(pos, 7, "");
|
pretty.replace(pos, 7, "");
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3AST_H_
|
#ifndef _V3AST_H_
|
||||||
#define _V3AST_H_ 1
|
#define _V3AST_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Number.h"
|
#include "V3Number.h"
|
||||||
#include <vector>
|
#include <vector>
|
||||||
@@ -57,6 +58,7 @@ public:
|
|||||||
COVERAGE_BLOCK_OFF,
|
COVERAGE_BLOCK_OFF,
|
||||||
INLINE_MODULE,
|
INLINE_MODULE,
|
||||||
NO_INLINE_MODULE,
|
NO_INLINE_MODULE,
|
||||||
|
NO_INLINE_TASK,
|
||||||
PUBLIC_MODULE,
|
PUBLIC_MODULE,
|
||||||
PUBLIC_TASK
|
PUBLIC_TASK
|
||||||
};
|
};
|
||||||
|
|||||||
+5
-1
@@ -19,6 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
@@ -349,7 +351,8 @@ void AstVar::dump(ostream& str) {
|
|||||||
if (isSigPublic()) str<<" [P]";
|
if (isSigPublic()) str<<" [P]";
|
||||||
if (attrClockEn()) str<<" [aCLKEN]";
|
if (attrClockEn()) str<<" [aCLKEN]";
|
||||||
if (attrFileDescr()) str<<" [aFD]";
|
if (attrFileDescr()) str<<" [aFD]";
|
||||||
if (isFuncLocal() || isFuncReturn()) str<<" [FUNC]";
|
if (isFuncReturn()) str<<" [FUNCRTN]";
|
||||||
|
else if (isFuncLocal()) str<<" [FUNC]";
|
||||||
str<<" "<<varType();
|
str<<" "<<varType();
|
||||||
}
|
}
|
||||||
void AstSenTree::dump(ostream& str) {
|
void AstSenTree::dump(ostream& str) {
|
||||||
@@ -375,6 +378,7 @@ void AstNodeFTaskRef::dump(ostream& str) {
|
|||||||
}
|
}
|
||||||
void AstNodeFTask::dump(ostream& str) {
|
void AstNodeFTask::dump(ostream& str) {
|
||||||
this->AstNode::dump(str);
|
this->AstNode::dump(str);
|
||||||
|
if (taskPublic()) str<<" [PUBLIC]";
|
||||||
}
|
}
|
||||||
void AstCoverDecl::dump(ostream& str) {
|
void AstCoverDecl::dump(ostream& str) {
|
||||||
this->AstNode::dump(str);
|
this->AstNode::dump(str);
|
||||||
|
|||||||
+2
-1
@@ -27,7 +27,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3BEGIN_H_
|
#ifndef _V3BEGIN_H_
|
||||||
#define _V3BEGIN_H_ 1
|
#define _V3BEGIN_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -25,7 +25,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3BRANCH_H_
|
#ifndef _V3BRANCH_H_
|
||||||
#define _V3BRANCH_H_ 1
|
#define _V3BRANCH_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -26,7 +26,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3BROKEN_H_
|
#ifndef _V3BROKEN_H_
|
||||||
#define _V3BROKEN_H_ 1
|
#define _V3BROKEN_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -38,7 +38,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3CASE_H_
|
#ifndef _V3CASE_H_
|
||||||
#define _V3CASE_H_ 1
|
#define _V3CASE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -42,7 +42,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3CAST_H_
|
#ifndef _V3CAST_H_
|
||||||
#define _V3CAST_H_ 1
|
#define _V3CAST_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -31,7 +31,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3CHANGED_H_
|
#ifndef _V3CHANGED_H_
|
||||||
#define _V3CHANGED_H_ 1
|
#define _V3CHANGED_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+6
-1
@@ -28,7 +28,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@@ -239,6 +240,10 @@ private:
|
|||||||
nodep->iterateChildren(*this);
|
nodep->iterateChildren(*this);
|
||||||
insureCleanAndNext (nodep->bodysp());
|
insureCleanAndNext (nodep->bodysp());
|
||||||
}
|
}
|
||||||
|
virtual void visit(AstCCall* nodep, AstNUser*) {
|
||||||
|
nodep->iterateChildren(*this);
|
||||||
|
insureCleanAndNext (nodep->argsp());
|
||||||
|
}
|
||||||
|
|
||||||
//--------------------
|
//--------------------
|
||||||
// Default: Just iterate
|
// Default: Just iterate
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3CLEAN_H_
|
#ifndef _V3CLEAN_H_
|
||||||
#define _V3CLEAN_H_ 1
|
#define _V3CLEAN_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+3
-3
@@ -32,7 +32,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@@ -364,8 +365,7 @@ private:
|
|||||||
// Move statements to if
|
// Move statements to if
|
||||||
m_lastIfp->addIfsp(stmtsp);
|
m_lastIfp->addIfsp(stmtsp);
|
||||||
} else if (nodep->hasSettle()) {
|
} else if (nodep->hasSettle()) {
|
||||||
// Settlement
|
// Don't need to: clearLastSen();, as we're adding it to different cfunc
|
||||||
clearLastSen();
|
|
||||||
// Move statements to function
|
// Move statements to function
|
||||||
addToSettleLoop(stmtsp);
|
addToSettleLoop(stmtsp);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3CLOCK_H_
|
#ifndef _V3CLOCK_H_
|
||||||
#define _V3CLOCK_H_ 1
|
#define _V3CLOCK_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -35,7 +35,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3COMBINE_H_
|
#ifndef _V3COMBINE_H_
|
||||||
#define _V3COMBINE_H_ 1
|
#define _V3COMBINE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -25,7 +25,8 @@
|
|||||||
// If operands are constant, replace this node with constant.
|
// If operands are constant, replace this node with constant.
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3CONST_H_
|
#ifndef _V3CONST_H_
|
||||||
#define _V3CONST_H_ 1
|
#define _V3CONST_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -29,7 +29,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3COVERAGE_H_
|
#ifndef _V3COVERAGE_H_
|
||||||
#define _V3COVERAGE_H_ 1
|
#define _V3COVERAGE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -24,7 +24,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3DEAD_H_
|
#ifndef _V3DEAD_H_
|
||||||
#define _V3DEAD_H_ 1
|
#define _V3DEAD_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -52,7 +52,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3DELAYED_H_
|
#ifndef _V3DELAYED_H_
|
||||||
#define _V3DELAYED_H_ 1
|
#define _V3DELAYED_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -28,7 +28,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3DEPTH_H_
|
#ifndef _V3DEPTH_H_
|
||||||
#define _V3DEPTH_H_ 1
|
#define _V3DEPTH_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -27,7 +27,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3DESCOPE_H_
|
#ifndef _V3DESCOPE_H_
|
||||||
#define _V3DESCOPE_H_ 1
|
#define _V3DESCOPE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+16
-17
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@@ -96,22 +97,20 @@ public:
|
|||||||
string cFuncArgs(AstCFunc* nodep) {
|
string cFuncArgs(AstCFunc* nodep) {
|
||||||
// Return argument list for given C function
|
// Return argument list for given C function
|
||||||
string args = nodep->argTypes();
|
string args = nodep->argTypes();
|
||||||
if (args=="") {
|
// Might be a user function with argument list.
|
||||||
// Might be a user function with argument list.
|
for (AstNode* stmtp = nodep->argsp(); stmtp; stmtp=stmtp->nextp()) {
|
||||||
for (AstNode* stmtp = nodep->argsp(); stmtp; stmtp=stmtp->nextp()) {
|
if (AstVar* portp = stmtp->castVar()) {
|
||||||
if (AstVar* portp = stmtp->castVar()) {
|
if (portp->isIO() && !portp->isFuncReturn()) {
|
||||||
if (portp->isIO() && !portp->isFuncReturn()) {
|
if (args != "") args+= ", ";
|
||||||
if (args != "") args+= ", ";
|
if (portp->isWide()) {
|
||||||
if (portp->isWide()) {
|
if (portp->isInOnly()) args += "const ";
|
||||||
if (portp->isInOnly()) args += "const ";
|
args += portp->cType();
|
||||||
args += portp->cType();
|
args += " (& "+portp->name();
|
||||||
args += " (& "+portp->name();
|
args += ")["+cvtToStr(portp->widthWords())+"]";
|
||||||
args += ")["+cvtToStr(portp->widthWords())+"]";
|
} else {
|
||||||
} else {
|
args += portp->cType();
|
||||||
args += portp->cType();
|
if (portp->isOutput()) args += "&";
|
||||||
if (portp->isOutput()) args += "&";
|
args += " "+portp->name();
|
||||||
args += " "+portp->name();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3EMITC_H_
|
#ifndef _V3EMITC_H_
|
||||||
#define _V3EMITC_H_ 1
|
#define _V3EMITC_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+3
-2
@@ -22,7 +22,8 @@
|
|||||||
#ifndef _V3EMITCBASE_H_
|
#ifndef _V3EMITCBASE_H_
|
||||||
#define _V3EMITCBASE_H_ 1
|
#define _V3EMITCBASE_H_ 1
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@@ -109,7 +110,7 @@ public:
|
|||||||
bool optSystemPerl() { return v3Global.opt.systemPerl(); }
|
bool optSystemPerl() { return v3Global.opt.systemPerl(); }
|
||||||
static string symClassName() { return v3Global.opt.prefix()+"__Syms"; }
|
static string symClassName() { return v3Global.opt.prefix()+"__Syms"; }
|
||||||
static string symClassVar() { return symClassName()+"* __restrict vlSymsp"; }
|
static string symClassVar() { return symClassName()+"* __restrict vlSymsp"; }
|
||||||
static string symTopAssign() { return v3Global.opt.prefix()+"* __restrict vlTOPp = vlSymsp->TOPp;"; }
|
static string symTopAssign() { return v3Global.opt.prefix()+"* __restrict vlTOPp VL_ATTR_UNUSED = vlSymsp->TOPp;"; }
|
||||||
static string modClassName(AstModule* modp) { // Return name of current module being processed
|
static string modClassName(AstModule* modp) { // Return name of current module being processed
|
||||||
if (modp->isTop()) {
|
if (modp->isTop()) {
|
||||||
return v3Global.opt.prefix();
|
return v3Global.opt.prefix();
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3EMITMK_H_
|
#ifndef _V3EMITMK_H_
|
||||||
#define _V3EMITMK_H_ 1
|
#define _V3EMITMK_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3EMITV_H_
|
#ifndef _V3EMITV_H_
|
||||||
#define _V3EMITV_H_ 1
|
#define _V3EMITV_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+5
-5
@@ -92,7 +92,7 @@ void FileLine::lineDirective(const char* textp) {
|
|||||||
|
|
||||||
bool FileLine::warnOff(const string& msg, bool flag) {
|
bool FileLine::warnOff(const string& msg, bool flag) {
|
||||||
V3ErrorCode code (msg.c_str());
|
V3ErrorCode code (msg.c_str());
|
||||||
if (code == V3ErrorCode::ERROR) {
|
if (code < V3ErrorCode::FIRST_WARN) {
|
||||||
return false;
|
return false;
|
||||||
} else {
|
} else {
|
||||||
warnOff(code, flag);
|
warnOff(code, flag);
|
||||||
@@ -168,9 +168,8 @@ void FileLine::v3errorEnd(ostringstream& str) {
|
|||||||
void V3Error::init() {
|
void V3Error::init() {
|
||||||
for (int i=0; i<V3ErrorCode::MAX; i++) {
|
for (int i=0; i<V3ErrorCode::MAX; i++) {
|
||||||
s_describedEachWarn[i] = false;
|
s_describedEachWarn[i] = false;
|
||||||
s_pretendError[i] = false;
|
s_pretendError[i] = V3ErrorCode(i).pretendError();
|
||||||
}
|
}
|
||||||
pretendError(V3ErrorCode::BLKANDNBLK, true);
|
|
||||||
|
|
||||||
if (string(V3ErrorCode(V3ErrorCode::MAX).ascii()) != " MAX") {
|
if (string(V3ErrorCode(V3ErrorCode::MAX).ascii()) != " MAX") {
|
||||||
v3fatalSrc("Enum table in V3ErrorCode::ascii() is munged");
|
v3fatalSrc("Enum table in V3ErrorCode::ascii() is munged");
|
||||||
@@ -204,8 +203,9 @@ void V3Error::abortIfErrors() {
|
|||||||
string V3Error::msgPrefix(V3ErrorCode code) {
|
string V3Error::msgPrefix(V3ErrorCode code) {
|
||||||
if (code==V3ErrorCode::SUPPRESS) return "-arning-suppressed: ";
|
if (code==V3ErrorCode::SUPPRESS) return "-arning-suppressed: ";
|
||||||
else if (code==V3ErrorCode::FATAL) return "%Error: ";
|
else if (code==V3ErrorCode::FATAL) return "%Error: ";
|
||||||
else if (code==V3ErrorCode::ERROR
|
else if (code==V3ErrorCode::ERROR) return "%Error: ";
|
||||||
|| s_pretendError[code]) return "%Error: ";
|
else if (code<V3ErrorCode::FIRST_WARN
|
||||||
|
|| s_pretendError[code]) return "%Error-"+(string)code.ascii()+": ";
|
||||||
else return "%Warning-"+(string)code.ascii()+": ";
|
else return "%Warning-"+(string)code.ascii()+": ";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+12
-3
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3ERROR_H_
|
#ifndef _V3ERROR_H_
|
||||||
#define _V3ERROR_H_ 1
|
#define _V3ERROR_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
@@ -34,9 +35,12 @@ public:
|
|||||||
enum en {
|
enum en {
|
||||||
SUPPRESS, // Warning suppressed by user
|
SUPPRESS, // Warning suppressed by user
|
||||||
FATAL, // Kill the program
|
FATAL, // Kill the program
|
||||||
ERROR, // Error out, can't suppress
|
ERROR, // General error out, can't suppress
|
||||||
|
// Error codes:
|
||||||
|
TASKNSVAR, // Error: Task I/O not simple
|
||||||
// Warning codes:
|
// Warning codes:
|
||||||
FIRST_WARN, // Just a code so the program knows where to start warnings
|
FIRST_WARN, // Just a code so the program knows where to start warnings
|
||||||
|
//
|
||||||
BLKANDNBLK, // Blocked and non-blocking assignments to same variable
|
BLKANDNBLK, // Blocked and non-blocking assignments to same variable
|
||||||
CASEINCOMPLETE, // Case statement has missing values
|
CASEINCOMPLETE, // Case statement has missing values
|
||||||
CASEOVERLAP, // Case statements overlap
|
CASEOVERLAP, // Case statements overlap
|
||||||
@@ -45,6 +49,7 @@ public:
|
|||||||
COMBDLY, // Combinatorial delayed assignment
|
COMBDLY, // Combinatorial delayed assignment
|
||||||
GENCLK, // Generated Clock
|
GENCLK, // Generated Clock
|
||||||
IMPLICIT, // Implicit wire
|
IMPLICIT, // Implicit wire
|
||||||
|
IMPURE, // Impure function not being inlined
|
||||||
MULTIDRIVEN, // Driven from multiple blocks
|
MULTIDRIVEN, // Driven from multiple blocks
|
||||||
UNDRIVEN, // No drivers
|
UNDRIVEN, // No drivers
|
||||||
UNOPT, // Unoptimizable block
|
UNOPT, // Unoptimizable block
|
||||||
@@ -66,10 +71,11 @@ public:
|
|||||||
const char* names[] = {
|
const char* names[] = {
|
||||||
// Leading spaces indicate it can't be disabled.
|
// Leading spaces indicate it can't be disabled.
|
||||||
" SUPPRESS", " FATAL", " ERROR",
|
" SUPPRESS", " FATAL", " ERROR",
|
||||||
|
"TASKNSVAR",
|
||||||
" FIRST_WARN",
|
" FIRST_WARN",
|
||||||
"BLKANDNBLK",
|
"BLKANDNBLK",
|
||||||
"CASEINCOMPLETE", "CASEOVERLAP", "CASEX", "CMPCONST",
|
"CASEINCOMPLETE", "CASEOVERLAP", "CASEX", "CMPCONST",
|
||||||
"COMBDLY", "GENCLK", "IMPLICIT",
|
"COMBDLY", "GENCLK", "IMPLICIT", "IMPURE",
|
||||||
"MULTIDRIVEN",
|
"MULTIDRIVEN",
|
||||||
"UNDRIVEN", "UNOPT", "UNOPTFLAT", "UNSIGNED", "UNUSED",
|
"UNDRIVEN", "UNOPT", "UNOPTFLAT", "UNSIGNED", "UNUSED",
|
||||||
"VARHIDDEN", "WIDTH",
|
"VARHIDDEN", "WIDTH",
|
||||||
@@ -79,6 +85,9 @@ public:
|
|||||||
};
|
};
|
||||||
// Warnings that warn about nasty side effects
|
// Warnings that warn about nasty side effects
|
||||||
bool dangerous() const { return ( m_e==COMBDLY );};
|
bool dangerous() const { return ( m_e==COMBDLY );};
|
||||||
|
// Warnings we'll present to the user as errors
|
||||||
|
// Later -Werror- options may make more of these.
|
||||||
|
bool pretendError() const { return ( m_e==BLKANDNBLK || m_e==IMPURE); };
|
||||||
};
|
};
|
||||||
inline bool operator== (V3ErrorCode lhs, V3ErrorCode rhs) { return (lhs.m_e == rhs.m_e); }
|
inline bool operator== (V3ErrorCode lhs, V3ErrorCode rhs) { return (lhs.m_e == rhs.m_e); }
|
||||||
inline bool operator== (V3ErrorCode lhs, V3ErrorCode::en rhs) { return (lhs.m_e == rhs); }
|
inline bool operator== (V3ErrorCode lhs, V3ErrorCode::en rhs) { return (lhs.m_e == rhs); }
|
||||||
|
|||||||
+5
-1
@@ -30,7 +30,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@@ -660,6 +661,9 @@ private:
|
|||||||
// Lhs or Rhs may be word, long, or quad.
|
// Lhs or Rhs may be word, long, or quad.
|
||||||
// newAstWordSelClone nicely abstracts the difference.
|
// newAstWordSelClone nicely abstracts the difference.
|
||||||
int rhsshift = rhsp->rhsp()->widthMin();
|
int rhsshift = rhsp->rhsp()->widthMin();
|
||||||
|
// Sometimes doing the words backwards is preferrable.
|
||||||
|
// When we have x={x,foo} backwards is better, when x={foo,x} forward is better
|
||||||
|
// However V3Subst tends to rip this up, so not worth optimizing now.
|
||||||
for (int w=0; w<rhsp->widthWords(); w++) {
|
for (int w=0; w<rhsp->widthWords(); w++) {
|
||||||
addWordAssign(nodep, w,
|
addWordAssign(nodep, w,
|
||||||
new AstOr (rhsp->fileline(),
|
new AstOr (rhsp->fileline(),
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3EXPAND_H_
|
#ifndef _V3EXPAND_H_
|
||||||
#define _V3EXPAND_H_ 1
|
#define _V3EXPAND_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+5
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3FILE_H_
|
#ifndef _V3FILE_H_
|
||||||
#define _V3FILE_H_ 1
|
#define _V3FILE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stack>
|
#include <stack>
|
||||||
@@ -42,6 +43,9 @@ public:
|
|||||||
}
|
}
|
||||||
static ofstream* new_ofstream(const string& filename, bool append=false) {
|
static ofstream* new_ofstream(const string& filename, bool append=false) {
|
||||||
addTgtDepend(filename);
|
addTgtDepend(filename);
|
||||||
|
return new_ofstream_nodepend (filename, append);
|
||||||
|
}
|
||||||
|
static ofstream* new_ofstream_nodepend(const string& filename, bool append=false) {
|
||||||
if (append) {
|
if (append) {
|
||||||
return new ofstream(filename.c_str(), ios::app);
|
return new ofstream(filename.c_str(), ios::app);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
+2
-1
@@ -26,7 +26,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3GATE_H_
|
#ifndef _V3GATE_H_
|
||||||
#define _V3GATE_H_ 1
|
#define _V3GATE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -24,7 +24,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3GENCLK_H_
|
#ifndef _V3GENCLK_H_
|
||||||
#define _V3GENCLK_H_ 1
|
#define _V3GENCLK_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -22,7 +22,8 @@
|
|||||||
#ifndef _V3GLOBAL_H_
|
#ifndef _V3GLOBAL_H_
|
||||||
#define _V3GLOBAL_H_ 1
|
#define _V3GLOBAL_H_ 1
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3GRAPH_H_
|
#ifndef _V3GRAPH_H_
|
||||||
#define _V3GRAPH_H_ 1
|
#define _V3GRAPH_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3List.h"
|
#include "V3List.h"
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3GRAPHALG_H_
|
#ifndef _V3GRAPHALG_H_
|
||||||
#define _V3GRAPHALG_H_ 1
|
#define _V3GRAPHALG_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
|
|
||||||
#include "V3Global.h"
|
#include "V3Global.h"
|
||||||
#include "V3Graph.h"
|
#include "V3Graph.h"
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3GRAPHDFA_H_
|
#ifndef _V3GRAPHDFA_H_
|
||||||
#define _V3GRAPHDFA_H_ 1
|
#define _V3GRAPHDFA_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "V3Global.h"
|
#include "V3Global.h"
|
||||||
|
|||||||
+2
-1
@@ -19,7 +19,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -26,7 +26,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3HASHED_H_
|
#ifndef _V3HASHED_H_
|
||||||
#define _V3HASHED_H_ 1
|
#define _V3HASHED_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -29,7 +29,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3INLINE_H_
|
#ifndef _V3INLINE_H_
|
||||||
#define _V3INLINE_H_ 1
|
#define _V3INLINE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+3
-2
@@ -26,7 +26,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@@ -200,7 +201,7 @@ private:
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Save some time
|
// Save some time
|
||||||
virtual void visit(AstNodeStmt*, AstNUser*) {}
|
virtual void visit(AstNodeMath*, AstNUser*) {}
|
||||||
//--------------------
|
//--------------------
|
||||||
// Default: Just iterate
|
// Default: Just iterate
|
||||||
virtual void visit(AstNode* nodep, AstNUser*) {
|
virtual void visit(AstNode* nodep, AstNUser*) {
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3INST_H_
|
#ifndef _V3INST_H_
|
||||||
#define _V3INST_H_ 1
|
#define _V3INST_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LANGUAGEWORDS_H_
|
#ifndef _V3LANGUAGEWORDS_H_
|
||||||
#define _V3LANGUAGEWORDS_H_ 1
|
#define _V3LANGUAGEWORDS_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
//============================================================================
|
//============================================================================
|
||||||
|
|||||||
+5
-2
@@ -28,7 +28,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@@ -374,7 +375,9 @@ private:
|
|||||||
//UINFO(4," CCALL "<<nodep<<endl);
|
//UINFO(4," CCALL "<<nodep<<endl);
|
||||||
nodep->iterateChildren(*this);
|
nodep->iterateChildren(*this);
|
||||||
// Enter the function and trace it
|
// Enter the function and trace it
|
||||||
nodep->funcp()->accept(*this);
|
if (!nodep->funcp()->entryPoint()) { // else is non-inline or public function we optimize separately
|
||||||
|
nodep->funcp()->accept(*this);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
virtual void visit(AstUCFunc* nodep, AstNUser*) {
|
virtual void visit(AstUCFunc* nodep, AstNUser*) {
|
||||||
m_sideEffect = true; // If appears on assign RHS, don't ever delete the assignment
|
m_sideEffect = true; // If appears on assign RHS, don't ever delete the assignment
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LIFE_H_
|
#ifndef _V3LIFE_H_
|
||||||
#define _V3LIFE_H_ 1
|
#define _V3LIFE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -29,7 +29,8 @@
|
|||||||
//
|
//
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LIFEPOST_H_
|
#ifndef _V3LIFEPOST_H_
|
||||||
#define _V3LIFEPOST_H_ 1
|
#define _V3LIFEPOST_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -26,7 +26,8 @@
|
|||||||
// Link to var they reference
|
// Link to var they reference
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LINK_H_
|
#ifndef _V3LINK_H_
|
||||||
#define _V3LINK_H_ 1
|
#define _V3LINK_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -25,7 +25,8 @@
|
|||||||
// Link to module that instantiates it
|
// Link to module that instantiates it
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LINKCELLS_H_
|
#ifndef _V3LINKCELLS_H_
|
||||||
#define _V3LINKCELLS_H_ 1
|
#define _V3LINKCELLS_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+89
-15
@@ -29,7 +29,8 @@
|
|||||||
// Find appropriate named cell and link to var they reference
|
// Find appropriate named cell and link to var they reference
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@@ -81,6 +82,26 @@ public:
|
|||||||
}
|
}
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
void errorScopes(AstNode* nodep) {
|
||||||
|
if (!this) { // Silence if we messed it up and aren't debugging
|
||||||
|
if (debug()) nodep->v3fatalSrc("Void pointer; perhaps used null vxp instead of okVxp?");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
string scopes;
|
||||||
|
for (NameVtxMap::iterator it = m_nameToVtxMap.begin(); it!=m_nameToVtxMap.end(); ++it) {
|
||||||
|
if (scopes != "") scopes += ", ";
|
||||||
|
scopes += AstNode::prettyName(it->second->cellName());
|
||||||
|
}
|
||||||
|
cerr<<V3Error::msgPrefix()<<" Known scopes under '"<<cellName()<<"': "
|
||||||
|
<<scopes<<endl;
|
||||||
|
}
|
||||||
|
if (debug()) {
|
||||||
|
for (NameVtxMap::iterator it = m_nameToVtxMap.begin(); it!=m_nameToVtxMap.end(); ++it) {
|
||||||
|
UINFO(1,"\t\t KnownScope: "<<it->second->name()<<endl);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
class LinkDotCellVertex : public LinkDotBaseVertex {
|
class LinkDotCellVertex : public LinkDotBaseVertex {
|
||||||
@@ -125,6 +146,27 @@ public:
|
|||||||
virtual string dotColor() const { return "yellow"; }
|
virtual string dotColor() const { return "yellow"; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
class LinkDotBeginVertex : public LinkDotBaseVertex {
|
||||||
|
// A fake point in the hierarchy, corresponding to a begin block
|
||||||
|
// After we remove begins these will go away
|
||||||
|
// Note we use the symbol table of the parent, as we want to find variables there
|
||||||
|
// However, cells walk the graph, so cells will appear under the begin itself
|
||||||
|
AstBegin* m_nodep; // Relevant node
|
||||||
|
LinkDotCellVertex* m_symVxp; // Above cell so we can find real symbol table
|
||||||
|
// // (Could walk graph to find it, but that's much slower.)
|
||||||
|
public:
|
||||||
|
LinkDotBeginVertex(V3Graph* graphp, AstBegin* nodep, LinkDotCellVertex* symVxp)
|
||||||
|
: LinkDotBaseVertex(graphp, nodep->name()+"__DOT__")
|
||||||
|
, m_nodep(nodep), m_symVxp(symVxp) {}
|
||||||
|
virtual ~LinkDotBeginVertex() {}
|
||||||
|
// Search up through tree to find the real symbol table.
|
||||||
|
virtual V3SymTable& syms() { return m_symVxp->syms(); }
|
||||||
|
virtual string modName() const { return m_nodep->name(); }
|
||||||
|
virtual string cellName() const { return m_nodep->name(); }
|
||||||
|
virtual string name() const { return (string)("BEG C:")+cellName(); }
|
||||||
|
virtual string dotColor() const { return "blue"; }
|
||||||
|
};
|
||||||
|
|
||||||
//######################################################################
|
//######################################################################
|
||||||
// LinkDot state, as a visitor of each AstNode
|
// LinkDot state, as a visitor of each AstNode
|
||||||
|
|
||||||
@@ -194,6 +236,14 @@ public:
|
|||||||
}
|
}
|
||||||
return vxp;
|
return vxp;
|
||||||
}
|
}
|
||||||
|
LinkDotBeginVertex* insertBegin(LinkDotBaseVertex* abovep, LinkDotCellVertex* cellVxp,
|
||||||
|
AstBegin* nodep) {
|
||||||
|
UINFO(9," INSERTbeg "<<nodep<<endl);
|
||||||
|
LinkDotBeginVertex* vxp = new LinkDotBeginVertex(&m_graph, nodep, cellVxp);
|
||||||
|
new V3GraphEdge(&m_graph, abovep, vxp, 1, false);
|
||||||
|
abovep->insertSubcellName(nodep->name(), vxp);
|
||||||
|
return vxp;
|
||||||
|
}
|
||||||
void insertSym(LinkDotCellVertex* abovep, const string& name, AstNode* nodep) {
|
void insertSym(LinkDotCellVertex* abovep, const string& name, AstNode* nodep) {
|
||||||
UINFO(9," INSERTsym "<<name<<" "<<nodep<<endl);
|
UINFO(9," INSERTsym "<<name<<" "<<nodep<<endl);
|
||||||
abovep->syms().insert(name, nodep);
|
abovep->syms().insert(name, nodep);
|
||||||
@@ -225,12 +275,14 @@ private:
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
public:
|
public:
|
||||||
LinkDotBaseVertex* findDotted(LinkDotBaseVertex* cellVxp, const string& dotname, string& baddot) {
|
LinkDotBaseVertex* findDotted(LinkDotBaseVertex* cellVxp, const string& dotname,
|
||||||
|
string& baddot, LinkDotBaseVertex*& okVxp) {
|
||||||
// Given a dotted hiearchy name, return where in scope it is
|
// Given a dotted hiearchy name, return where in scope it is
|
||||||
// Note when dotname=="" we just fall through and return cellVxp
|
// Note when dotname=="" we just fall through and return cellVxp
|
||||||
UINFO(8," dottedFind "<<dotname<<endl);
|
UINFO(8," dottedFind "<<dotname<<endl);
|
||||||
bool firstId = true;
|
bool firstId = true;
|
||||||
string leftname = dotname;
|
string leftname = dotname;
|
||||||
|
okVxp = cellVxp; // So can list bad scopes
|
||||||
while (leftname != "") { // foreach dotted part of xref name
|
while (leftname != "") { // foreach dotted part of xref name
|
||||||
string::size_type pos;
|
string::size_type pos;
|
||||||
string ident;
|
string ident;
|
||||||
@@ -242,6 +294,7 @@ public:
|
|||||||
leftname = "";
|
leftname = "";
|
||||||
}
|
}
|
||||||
baddot = ident; // So user can see where they botched it
|
baddot = ident; // So user can see where they botched it
|
||||||
|
okVxp = cellVxp;
|
||||||
string altIdent = "";
|
string altIdent = "";
|
||||||
if (m_forPrearray) {
|
if (m_forPrearray) {
|
||||||
// Cell foo__[array] before we've expanded arrays is just foo.
|
// Cell foo__[array] before we've expanded arrays is just foo.
|
||||||
@@ -353,29 +406,36 @@ private:
|
|||||||
}
|
}
|
||||||
virtual void visit(AstCell* nodep, AstNUser*) {
|
virtual void visit(AstCell* nodep, AstNUser*) {
|
||||||
UINFO(5," CELL under "<<m_scope<<" is "<<nodep<<endl);
|
UINFO(5," CELL under "<<m_scope<<" is "<<nodep<<endl);
|
||||||
|
// Process XREFs inside pins
|
||||||
|
nodep->iterateChildren(*this);
|
||||||
// Recurse in, preserving state
|
// Recurse in, preserving state
|
||||||
string oldscope = m_scope;
|
string oldscope = m_scope;
|
||||||
|
AstBegin* oldbeginp = m_beginp;
|
||||||
LinkDotCellVertex* oldVxp = m_cellVxp;
|
LinkDotCellVertex* oldVxp = m_cellVxp;
|
||||||
|
LinkDotBaseVertex* oldInlineVxp = m_inlineVxp;
|
||||||
// Where do we add it?
|
// Where do we add it?
|
||||||
LinkDotBaseVertex* aboveVxp = m_cellVxp;
|
LinkDotBaseVertex* aboveVxp = m_inlineVxp;
|
||||||
string origname = nodep->prettyName();
|
string origname = nodep->prettyName();
|
||||||
string::size_type pos;
|
string::size_type pos;
|
||||||
if ((pos = origname.rfind(".")) != string::npos) {
|
if ((pos = origname.rfind(".")) != string::npos) {
|
||||||
// Flattened, find what CellInline it should live under
|
// Flattened, find what CellInline it should live under
|
||||||
string scope = origname.substr(0,pos);
|
string scope = origname.substr(0,pos);
|
||||||
string baddot;
|
string baddot;
|
||||||
aboveVxp = m_statep->findDotted(aboveVxp, scope, baddot);
|
LinkDotBaseVertex* okVxp;
|
||||||
|
aboveVxp = m_statep->findDotted(aboveVxp, scope, baddot, okVxp);
|
||||||
if (!aboveVxp) nodep->v3fatalSrc("Can't find cell insertion point at '"<<baddot<<"' in: "<<nodep->prettyName());
|
if (!aboveVxp) nodep->v3fatalSrc("Can't find cell insertion point at '"<<baddot<<"' in: "<<nodep->prettyName());
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
m_scope = m_scope+"."+nodep->name();
|
m_scope = m_scope+"."+nodep->name();
|
||||||
m_cellVxp = m_statep->insertCell(aboveVxp, m_cellVxp, nodep, m_scope);
|
m_cellVxp = m_statep->insertCell(aboveVxp, m_cellVxp, nodep, m_scope);
|
||||||
m_inlineVxp = m_cellVxp;
|
m_inlineVxp = m_cellVxp;
|
||||||
|
m_beginp = NULL;
|
||||||
if (nodep->modp()) nodep->modp()->accept(*this);
|
if (nodep->modp()) nodep->modp()->accept(*this);
|
||||||
}
|
}
|
||||||
m_scope = oldscope;
|
m_scope = oldscope;
|
||||||
|
m_beginp = oldbeginp;
|
||||||
m_cellVxp = oldVxp;
|
m_cellVxp = oldVxp;
|
||||||
m_inlineVxp = m_cellVxp;
|
m_inlineVxp = oldInlineVxp;
|
||||||
}
|
}
|
||||||
virtual void visit(AstCellInline* nodep, AstNUser*) {
|
virtual void visit(AstCellInline* nodep, AstNUser*) {
|
||||||
UINFO(5," CELLINLINE under "<<m_scope<<" is "<<nodep<<endl);
|
UINFO(5," CELLINLINE under "<<m_scope<<" is "<<nodep<<endl);
|
||||||
@@ -387,7 +447,8 @@ private:
|
|||||||
string dotted = dottedname.substr(0, pos);
|
string dotted = dottedname.substr(0, pos);
|
||||||
string ident = dottedname.substr(pos+strlen("__DOT__"));
|
string ident = dottedname.substr(pos+strlen("__DOT__"));
|
||||||
string baddot;
|
string baddot;
|
||||||
aboveVxp = m_statep->findDotted(aboveVxp, dotted, baddot);
|
LinkDotBaseVertex* okVxp;
|
||||||
|
aboveVxp = m_statep->findDotted(aboveVxp, dotted, baddot, okVxp);
|
||||||
if (!aboveVxp) nodep->v3fatalSrc("Can't find cellinline insertion point at '"<<baddot<<"' in: "<<nodep->prettyName());
|
if (!aboveVxp) nodep->v3fatalSrc("Can't find cellinline insertion point at '"<<baddot<<"' in: "<<nodep->prettyName());
|
||||||
m_statep->insertInline(aboveVxp, m_cellVxp, nodep, ident);
|
m_statep->insertInline(aboveVxp, m_cellVxp, nodep, ident);
|
||||||
} else { // No __DOT__, just directly underneath
|
} else { // No __DOT__, just directly underneath
|
||||||
@@ -396,10 +457,16 @@ private:
|
|||||||
}
|
}
|
||||||
virtual void visit(AstBegin* nodep, AstNUser*) {
|
virtual void visit(AstBegin* nodep, AstNUser*) {
|
||||||
UINFO(5," "<<nodep<<endl);
|
UINFO(5," "<<nodep<<endl);
|
||||||
// We don't pickup variables, but do need to find cells
|
|
||||||
AstBegin* oldbegin = m_beginp;
|
AstBegin* oldbegin = m_beginp;
|
||||||
m_beginp = nodep;
|
LinkDotBaseVertex* oldVxp = m_inlineVxp;
|
||||||
nodep->iterateChildren(*this);
|
{
|
||||||
|
m_beginp = nodep;
|
||||||
|
// Ignore begin names
|
||||||
|
m_inlineVxp = m_statep->insertBegin(m_inlineVxp, m_cellVxp, nodep);
|
||||||
|
// We don't pickup variables, but do need to find cells
|
||||||
|
nodep->iterateChildren(*this);
|
||||||
|
}
|
||||||
|
m_inlineVxp = oldVxp;
|
||||||
m_beginp = oldbegin;
|
m_beginp = oldbegin;
|
||||||
}
|
}
|
||||||
virtual void visit(AstVar* nodep, AstNUser*) {
|
virtual void visit(AstVar* nodep, AstNUser*) {
|
||||||
@@ -407,6 +474,8 @@ private:
|
|||||||
&& !m_beginp // For now, we don't support xrefs into begin blocks
|
&& !m_beginp // For now, we don't support xrefs into begin blocks
|
||||||
&& !nodep->isFuncLocal()) {
|
&& !nodep->isFuncLocal()) {
|
||||||
m_statep->insertSym(m_cellVxp, nodep->name(), nodep);
|
m_statep->insertSym(m_cellVxp, nodep->name(), nodep);
|
||||||
|
} else {
|
||||||
|
UINFO(9," Not allowing dot refs to: "<<nodep<<endl);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
virtual void visit(AstNodeFTask* nodep, AstNUser*) {
|
virtual void visit(AstNodeFTask* nodep, AstNUser*) {
|
||||||
@@ -418,7 +487,7 @@ private:
|
|||||||
}
|
}
|
||||||
|
|
||||||
// For speed, don't recurse things that can't have cells
|
// For speed, don't recurse things that can't have cells
|
||||||
virtual void visit(AstNodeStmt*, AstNUser*) {}
|
// Note we allow AstNodeStmt's as generates may be under them
|
||||||
virtual void visit(AstNodeMath*, AstNUser*) {}
|
virtual void visit(AstNodeMath*, AstNUser*) {}
|
||||||
virtual void visit(AstNode* nodep, AstNUser*) {
|
virtual void visit(AstNode* nodep, AstNUser*) {
|
||||||
// Default: Just iterate
|
// Default: Just iterate
|
||||||
@@ -479,9 +548,9 @@ private:
|
|||||||
nodep->iterateChildren(*this);
|
nodep->iterateChildren(*this);
|
||||||
}
|
}
|
||||||
// For speed, don't recurse things that can't have scope
|
// For speed, don't recurse things that can't have scope
|
||||||
|
// Note we allow AstNodeStmt's as generates may be under them
|
||||||
virtual void visit(AstCell*, AstNUser*) {}
|
virtual void visit(AstCell*, AstNUser*) {}
|
||||||
virtual void visit(AstVar*, AstNUser*) {}
|
virtual void visit(AstVar*, AstNUser*) {}
|
||||||
virtual void visit(AstNodeStmt*, AstNUser*) {}
|
|
||||||
virtual void visit(AstNodeMath*, AstNUser*) {}
|
virtual void visit(AstNodeMath*, AstNUser*) {}
|
||||||
virtual void visit(AstNode* nodep, AstNUser*) {
|
virtual void visit(AstNode* nodep, AstNUser*) {
|
||||||
// Default: Just iterate
|
// Default: Just iterate
|
||||||
@@ -544,13 +613,14 @@ private:
|
|||||||
nodep->varp(NULL); // Module that is not in hiearchy. We'll be dead code eliminating it later.
|
nodep->varp(NULL); // Module that is not in hiearchy. We'll be dead code eliminating it later.
|
||||||
} else {
|
} else {
|
||||||
string baddot;
|
string baddot;
|
||||||
|
LinkDotBaseVertex* okVxp;
|
||||||
LinkDotBaseVertex* dotVxp = m_cellVxp; // Start search at current scope
|
LinkDotBaseVertex* dotVxp = m_cellVxp; // Start search at current scope
|
||||||
if (nodep->inlinedDots()!="") { // Correct for current scope
|
if (nodep->inlinedDots()!="") { // Correct for current scope
|
||||||
string inl = AstNode::prettyName(nodep->inlinedDots());
|
string inl = AstNode::prettyName(nodep->inlinedDots());
|
||||||
dotVxp = m_statep->findDotted(dotVxp, inl, baddot);
|
dotVxp = m_statep->findDotted(dotVxp, inl, baddot, okVxp);
|
||||||
if (!dotVxp) nodep->v3fatalSrc("Couldn't resolve inlined scope '"<<baddot<<"' in: "<<nodep->inlinedDots());
|
if (!dotVxp) nodep->v3fatalSrc("Couldn't resolve inlined scope '"<<baddot<<"' in: "<<nodep->inlinedDots());
|
||||||
}
|
}
|
||||||
dotVxp = m_statep->findDotted(dotVxp, nodep->dotted(), baddot); // Maybe NULL
|
dotVxp = m_statep->findDotted(dotVxp, nodep->dotted(), baddot, okVxp); // Maybe NULL
|
||||||
if (!m_statep->forScopeCreation()) {
|
if (!m_statep->forScopeCreation()) {
|
||||||
AstVar* varp = (m_statep->findSym(dotVxp, nodep->name(), baddot)
|
AstVar* varp = (m_statep->findSym(dotVxp, nodep->name(), baddot)
|
||||||
->castVar()); // maybe NULL
|
->castVar()); // maybe NULL
|
||||||
@@ -558,6 +628,7 @@ private:
|
|||||||
UINFO(7," Resolved "<<nodep<<endl); // Also prints varp
|
UINFO(7," Resolved "<<nodep<<endl); // Also prints varp
|
||||||
if (!nodep->varp()) {
|
if (!nodep->varp()) {
|
||||||
nodep->v3error("Can't find definition of '"<<baddot<<"' in dotted signal: "<<nodep->dotted()+"."+nodep->prettyName());
|
nodep->v3error("Can't find definition of '"<<baddot<<"' in dotted signal: "<<nodep->dotted()+"."+nodep->prettyName());
|
||||||
|
okVxp->errorScopes(nodep);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
string baddot;
|
string baddot;
|
||||||
@@ -565,6 +636,7 @@ private:
|
|||||||
->castVarScope()); // maybe NULL
|
->castVarScope()); // maybe NULL
|
||||||
if (!vscp) {
|
if (!vscp) {
|
||||||
nodep->v3error("Can't find varpin scope of '"<<baddot<<"' in dotted signal: "<<nodep->dotted()+"."+nodep->prettyName());
|
nodep->v3error("Can't find varpin scope of '"<<baddot<<"' in dotted signal: "<<nodep->dotted()+"."+nodep->prettyName());
|
||||||
|
okVxp->errorScopes(nodep);
|
||||||
} else {
|
} else {
|
||||||
while (vscp->user2p()) { // If V3Inline aliased it, pick up the new signal
|
while (vscp->user2p()) { // If V3Inline aliased it, pick up the new signal
|
||||||
UINFO(7," Resolved pre-alias "<<vscp<<endl); // Also prints taskp
|
UINFO(7," Resolved pre-alias "<<vscp<<endl); // Also prints taskp
|
||||||
@@ -588,14 +660,15 @@ private:
|
|||||||
nodep->taskp(NULL); // Module that is not in hiearchy. We'll be dead code eliminating it later.
|
nodep->taskp(NULL); // Module that is not in hiearchy. We'll be dead code eliminating it later.
|
||||||
} else {
|
} else {
|
||||||
string baddot;
|
string baddot;
|
||||||
|
LinkDotBaseVertex* okVxp;
|
||||||
LinkDotBaseVertex* dotVxp = m_cellVxp; // Start search at current scope
|
LinkDotBaseVertex* dotVxp = m_cellVxp; // Start search at current scope
|
||||||
if (nodep->inlinedDots()!="") { // Correct for current scope
|
if (nodep->inlinedDots()!="") { // Correct for current scope
|
||||||
string inl = AstNode::prettyName(nodep->inlinedDots());
|
string inl = AstNode::prettyName(nodep->inlinedDots());
|
||||||
UINFO(8,"\t\tInlined "<<inl<<endl);
|
UINFO(8,"\t\tInlined "<<inl<<endl);
|
||||||
dotVxp = m_statep->findDotted(dotVxp, inl, baddot);
|
dotVxp = m_statep->findDotted(dotVxp, inl, baddot, okVxp);
|
||||||
if (!dotVxp) nodep->v3fatalSrc("Couldn't resolve inlined scope '"<<baddot<<"' in: "<<nodep->inlinedDots());
|
if (!dotVxp) nodep->v3fatalSrc("Couldn't resolve inlined scope '"<<baddot<<"' in: "<<nodep->inlinedDots());
|
||||||
}
|
}
|
||||||
dotVxp = m_statep->findDotted(dotVxp, nodep->dotted(), baddot); // Maybe NULL
|
dotVxp = m_statep->findDotted(dotVxp, nodep->dotted(), baddot, okVxp); // Maybe NULL
|
||||||
|
|
||||||
AstNodeFTask* taskp = (m_statep->findSym(dotVxp, nodep->name(), baddot)
|
AstNodeFTask* taskp = (m_statep->findSym(dotVxp, nodep->name(), baddot)
|
||||||
->castNodeFTask()); // maybe NULL
|
->castNodeFTask()); // maybe NULL
|
||||||
@@ -603,6 +676,7 @@ private:
|
|||||||
UINFO(7," Resolved "<<nodep<<endl); // Also prints taskp
|
UINFO(7," Resolved "<<nodep<<endl); // Also prints taskp
|
||||||
if (!nodep->taskp()) {
|
if (!nodep->taskp()) {
|
||||||
nodep->v3error("Can't find definition of '"<<baddot<<"' in dotted task/function: "<<nodep->dotted()+"."+nodep->prettyName());
|
nodep->v3error("Can't find definition of '"<<baddot<<"' in dotted task/function: "<<nodep->dotted()+"."+nodep->prettyName());
|
||||||
|
okVxp->errorScopes(nodep);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
nodep->iterateChildren(*this);
|
nodep->iterateChildren(*this);
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LINKDOT_H_
|
#ifndef _V3LINKDOT_H_
|
||||||
#define _V3LINKDOT_H_ 1
|
#define _V3LINKDOT_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -24,7 +24,8 @@
|
|||||||
// Create new MODULE TOP with connections to below signals
|
// Create new MODULE TOP with connections to below signals
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LINKLEVEL_H_
|
#ifndef _V3LINKLEVEL_H_
|
||||||
#define _V3LINKLEVEL_H_ 1
|
#define _V3LINKLEVEL_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
@@ -28,7 +28,8 @@
|
|||||||
// Convert normal var to FILE* type
|
// Convert normal var to FILE* type
|
||||||
//*************************************************************************
|
//*************************************************************************
|
||||||
|
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LINKRESOLVE_H_
|
#ifndef _V3LINKRESOLVE_H_
|
||||||
#define _V3LINKRESOLVE_H_ 1
|
#define _V3LINKRESOLVE_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include "V3Error.h"
|
#include "V3Error.h"
|
||||||
#include "V3Ast.h"
|
#include "V3Ast.h"
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -21,7 +21,8 @@
|
|||||||
|
|
||||||
#ifndef _V3LIST_H_
|
#ifndef _V3LIST_H_
|
||||||
#define _V3LIST_H_ 1
|
#define _V3LIST_H_ 1
|
||||||
#include "config.h"
|
#include "config_build.h"
|
||||||
|
#include "verilatedos.h"
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
//============================================================================
|
//============================================================================
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user