mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-07 09:55:20 +00:00
Another block of spelling fixes
Smaller this time
This commit is contained in:
parent
022f570563
commit
6c00704a5e
10
CHANGELOG
10
CHANGELOG
|
@ -82,7 +82,7 @@ Yosys 0.3.0 .. Yosys 0.4
|
||||||
* Changes for simple synthesis flows
|
* Changes for simple synthesis flows
|
||||||
- There is now a "synth" command with a recommended default script
|
- There is now a "synth" command with a recommended default script
|
||||||
- Many improvements in synthesis of arithmetic functions to gates
|
- Many improvements in synthesis of arithmetic functions to gates
|
||||||
- Multiplieres and adders with many operands are using carry-save adder trees
|
- Multipliers and adders with many operands are using carry-save adder trees
|
||||||
- Remaining adders are now implemented using Brent-Kung carry look-ahead adders
|
- Remaining adders are now implemented using Brent-Kung carry look-ahead adders
|
||||||
- Various new high-level optimizations on RTL netlist
|
- Various new high-level optimizations on RTL netlist
|
||||||
- Various improvements in FSM optimization
|
- Various improvements in FSM optimization
|
||||||
|
@ -98,7 +98,7 @@ Yosys 0.3.0 .. Yosys 0.4
|
||||||
- Added macros for code coverage counters
|
- Added macros for code coverage counters
|
||||||
- Added some Makefile magic for pretty make logs
|
- Added some Makefile magic for pretty make logs
|
||||||
- Added "kernel/yosys.h" with all the core definitions
|
- Added "kernel/yosys.h" with all the core definitions
|
||||||
- Chanded a lot of code from FILE* to c++ streams
|
- Changed a lot of code from FILE* to c++ streams
|
||||||
- Added RTLIL::Monitor API and "trace" command
|
- Added RTLIL::Monitor API and "trace" command
|
||||||
- Added "Yosys" C++ namespace
|
- Added "Yosys" C++ namespace
|
||||||
|
|
||||||
|
@ -167,7 +167,7 @@ Yosys 0.2.0 .. Yosys 0.3.0
|
||||||
- Added "sat -dump_cnf" feature
|
- Added "sat -dump_cnf" feature
|
||||||
- Added "sat -initsteps <N>" feature
|
- Added "sat -initsteps <N>" feature
|
||||||
- Added "freduce -stop <N>" feature
|
- Added "freduce -stop <N>" feature
|
||||||
- Added "fredure -dump <prefix>" feature
|
- Added "freduce -dump <prefix>" feature
|
||||||
|
|
||||||
* Integration with ABC:
|
* Integration with ABC:
|
||||||
- Updated ABC rev to 7600ffb9340c
|
- Updated ABC rev to 7600ffb9340c
|
||||||
|
@ -254,13 +254,13 @@ Yosys 0.1.0 .. Yosys 0.2.0
|
||||||
- Added "expose" command
|
- Added "expose" command
|
||||||
- Added support for @<sel_name> to sat and eval signal expressions
|
- Added support for @<sel_name> to sat and eval signal expressions
|
||||||
|
|
||||||
* Changes in the 'make test' framework and auxilary test tools:
|
* Changes in the 'make test' framework and auxiliary test tools:
|
||||||
- Added autotest.sh -p and -f options
|
- Added autotest.sh -p and -f options
|
||||||
- Replaced autotest.sh ISIM support with XSIM support
|
- Replaced autotest.sh ISIM support with XSIM support
|
||||||
- Added test cases for SAT framework
|
- Added test cases for SAT framework
|
||||||
|
|
||||||
* Added "abbreviated IDs":
|
* Added "abbreviated IDs":
|
||||||
- Now $<something>$foo can be abbriviated as $foo.
|
- Now $<something>$foo can be abbreviated as $foo.
|
||||||
- Usually this last part is a unique id (from RTLIL::autoidx)
|
- Usually this last part is a unique id (from RTLIL::autoidx)
|
||||||
- This abbreviated IDs are now also used in "show" output
|
- This abbreviated IDs are now also used in "show" output
|
||||||
|
|
||||||
|
|
|
@ -228,11 +228,11 @@ Formatting of code
|
||||||
on its own line for larger blocks, especially blocks that contains
|
on its own line for larger blocks, especially blocks that contains
|
||||||
blank lines.
|
blank lines.
|
||||||
|
|
||||||
- Otherwise stick to the Linux Kernel Coding Stlye:
|
- Otherwise stick to the Linux Kernel Coding Style:
|
||||||
https://www.kernel.org/doc/Documentation/CodingStyle
|
https://www.kernel.org/doc/Documentation/CodingStyle
|
||||||
|
|
||||||
|
|
||||||
C++ Langugage
|
C++ Language
|
||||||
-------------
|
-------------
|
||||||
|
|
||||||
Yosys is written in C++11. At the moment only constructs supported by
|
Yosys is written in C++11. At the moment only constructs supported by
|
||||||
|
@ -262,7 +262,7 @@ Creating the Visual Studio Template Project
|
||||||
[ ] Add to source control
|
[ ] Add to source control
|
||||||
|
|
||||||
[X] Console applications
|
[X] Console applications
|
||||||
[X] Empty Projcect
|
[X] Empty Project
|
||||||
[ ] SDL checks
|
[ ] SDL checks
|
||||||
|
|
||||||
2. Open YosysVS Project Properties
|
2. Open YosysVS Project Properties
|
||||||
|
@ -303,7 +303,7 @@ Things to do after finalizing the cell interface:
|
||||||
|
|
||||||
- Add support to kernel/satgen.h for the new cell type
|
- Add support to kernel/satgen.h for the new cell type
|
||||||
- Add to manual/CHAPTER_CellLib.tex (or just add a fixme to the bottom)
|
- Add to manual/CHAPTER_CellLib.tex (or just add a fixme to the bottom)
|
||||||
- Maybe add support to the verilog backend for dumping such cells as expression
|
- Maybe add support to the Verilog backend for dumping such cells as expression
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
20
README
20
README
|
@ -84,7 +84,7 @@ To build Yosys simply type 'make' in this directory.
|
||||||
$ sudo make install
|
$ sudo make install
|
||||||
|
|
||||||
Note that this also downloads, builds and installs ABC (using yosys-abc
|
Note that this also downloads, builds and installs ABC (using yosys-abc
|
||||||
as executeable name).
|
as executable name).
|
||||||
|
|
||||||
Yosys can be used with the interactive command shell, with
|
Yosys can be used with the interactive command shell, with
|
||||||
synthesis scripts or with command line arguments. Let's perform
|
synthesis scripts or with command line arguments. Let's perform
|
||||||
|
@ -98,7 +98,7 @@ commands and "help <command>" to print details on the specified command:
|
||||||
|
|
||||||
yosys> help help
|
yosys> help help
|
||||||
|
|
||||||
reading the design using the verilog frontend:
|
reading the design using the Verilog frontend:
|
||||||
|
|
||||||
yosys> read_verilog tests/simple/fiedler-cooley.v
|
yosys> read_verilog tests/simple/fiedler-cooley.v
|
||||||
|
|
||||||
|
@ -127,7 +127,7 @@ translating netlist to gate logic and perform some simple optimizations:
|
||||||
|
|
||||||
yosys> techmap; opt
|
yosys> techmap; opt
|
||||||
|
|
||||||
write design netlist to a new verilog file:
|
write design netlist to a new Verilog file:
|
||||||
|
|
||||||
yosys> write_verilog synth.v
|
yosys> write_verilog synth.v
|
||||||
|
|
||||||
|
@ -223,7 +223,7 @@ The following Verilog-2005 features are not supported by
|
||||||
yosys and there are currently no plans to add support
|
yosys and there are currently no plans to add support
|
||||||
for them:
|
for them:
|
||||||
|
|
||||||
- Non-sythesizable language features as defined in
|
- Non-synthesizable language features as defined in
|
||||||
IEC 62142(E):2005 / IEEE Std. 1364.1(E):2002
|
IEC 62142(E):2005 / IEEE Std. 1364.1(E):2002
|
||||||
|
|
||||||
- The "tri", "triand", "trior", "wand" and "wor" net types
|
- The "tri", "triand", "trior", "wand" and "wor" net types
|
||||||
|
@ -271,7 +271,7 @@ Verilog Attributes and non-standard features
|
||||||
storage element. The register itself will always have all bits set
|
storage element. The register itself will always have all bits set
|
||||||
to 'x' (undefined). The variable may only be used as blocking assigned
|
to 'x' (undefined). The variable may only be used as blocking assigned
|
||||||
temporary variable within an always block. This is mostly used internally
|
temporary variable within an always block. This is mostly used internally
|
||||||
by yosys to synthesize verilog functions and access arrays.
|
by yosys to synthesize Verilog functions and access arrays.
|
||||||
|
|
||||||
- The "onehot" attribute on wires mark them as onehot state register. This
|
- The "onehot" attribute on wires mark them as onehot state register. This
|
||||||
is used for example for memory port sharing and set by the fsm_map pass.
|
is used for example for memory port sharing and set by the fsm_map pass.
|
||||||
|
@ -279,7 +279,7 @@ Verilog Attributes and non-standard features
|
||||||
- The "blackbox" attribute on modules is used to mark empty stub modules
|
- The "blackbox" attribute on modules is used to mark empty stub modules
|
||||||
that have the same ports as the real thing but do not contain information
|
that have the same ports as the real thing but do not contain information
|
||||||
on the internal configuration. This modules are only used by the synthesis
|
on the internal configuration. This modules are only used by the synthesis
|
||||||
passes to identify input and output ports of cells. The verilog backend
|
passes to identify input and output ports of cells. The Verilog backend
|
||||||
also does not output blackbox modules on default.
|
also does not output blackbox modules on default.
|
||||||
|
|
||||||
- The "keep" attribute on cells and wires is used to mark objects that should
|
- The "keep" attribute on cells and wires is used to mark objects that should
|
||||||
|
@ -315,16 +315,16 @@ Verilog Attributes and non-standard features
|
||||||
to simply declare a module port as 'input' or 'output' in the module
|
to simply declare a module port as 'input' or 'output' in the module
|
||||||
body.
|
body.
|
||||||
|
|
||||||
- When defining a macro with `define, all text between tripple double quotes
|
- When defining a macro with `define, all text between triple double quotes
|
||||||
is interpreted as macro body, even if it contains unescaped newlines. The
|
is interpreted as macro body, even if it contains unescaped newlines. The
|
||||||
tripple double quotes are removed from the macro body. For example:
|
tipple double quotes are removed from the macro body. For example:
|
||||||
|
|
||||||
`define MY_MACRO(a, b) """
|
`define MY_MACRO(a, b) """
|
||||||
assign a = 23;
|
assign a = 23;
|
||||||
assign b = 42;
|
assign b = 42;
|
||||||
"""
|
"""
|
||||||
|
|
||||||
- The attribute "via_celltype" can be used to implement a verilog task or
|
- The attribute "via_celltype" can be used to implement a Verilog task or
|
||||||
function by instantiating the specified cell type. The value is the name
|
function by instantiating the specified cell type. The value is the name
|
||||||
of the cell type to use. For functions the name of the output port can
|
of the cell type to use. For functions the name of the output port can
|
||||||
be specified by appending it to the cell type separated by a whitespace.
|
be specified by appending it to the cell type separated by a whitespace.
|
||||||
|
@ -364,7 +364,7 @@ Verilog Attributes and non-standard features
|
||||||
$ yosys -p 'plugin -a foo -i /lib/libm.so; read_verilog dpitest.v'
|
$ yosys -p 'plugin -a foo -i /lib/libm.so; read_verilog dpitest.v'
|
||||||
|
|
||||||
- Sized constants (the syntax <size>'s?[bodh]<value>) support constant
|
- Sized constants (the syntax <size>'s?[bodh]<value>) support constant
|
||||||
expressions as <size>. If the expresion is not a simple identifier, it
|
expressions as <size>. If the expression is not a simple identifier, it
|
||||||
must be put in parentheses. Examples: WIDTH'd42, (4+2)'b101010
|
must be put in parentheses. Examples: WIDTH'd42, (4+2)'b101010
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
#
|
#
|
||||||
# Script to writing btor from verilog design
|
# Script to write BTOR from Verilog design
|
||||||
#
|
#
|
||||||
|
|
||||||
if [ "$#" -ne 3 ]; then
|
if [ "$#" -ne 3 ]; then
|
||||||
|
|
|
@ -329,7 +329,7 @@ struct JsonBackend : public Backend {
|
||||||
log("connected to a constant driver are denoted as string \"0\" or \"1\" instead of\n");
|
log("connected to a constant driver are denoted as string \"0\" or \"1\" instead of\n");
|
||||||
log("a number.\n");
|
log("a number.\n");
|
||||||
log("\n");
|
log("\n");
|
||||||
log("For example the following verilog code:\n");
|
log("For example the following Verilog code:\n");
|
||||||
log("\n");
|
log("\n");
|
||||||
log(" module test(input x, y);\n");
|
log(" module test(input x, y);\n");
|
||||||
log(" (* keep *) foo #(.P(42), .Q(1337))\n");
|
log(" (* keep *) foo #(.P(42), .Q(1337))\n");
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
*
|
*
|
||||||
* ---
|
* ---
|
||||||
*
|
*
|
||||||
* A simple and straightforward verilog backend.
|
* A simple and straightforward Verilog backend.
|
||||||
*
|
*
|
||||||
* Note that RTLIL processes can't always be mapped easily to a Verilog
|
* Note that RTLIL processes can't always be mapped easily to a Verilog
|
||||||
* process. Therefore this frontend should only be used to export a
|
* process. Therefore this frontend should only be used to export a
|
||||||
|
@ -966,7 +966,7 @@ bool dump_cell_expr(std::ostream &f, std::string indent, RTLIL::Cell *cell)
|
||||||
n += wen_width;
|
n += wen_width;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Output verilog that looks something like this:
|
// Output Verilog that looks something like this:
|
||||||
// reg [..] _3_;
|
// reg [..] _3_;
|
||||||
// always @(posedge CLK2) begin
|
// always @(posedge CLK2) begin
|
||||||
// _3_ <= memory[D1ADDR];
|
// _3_ <= memory[D1ADDR];
|
||||||
|
|
|
@ -329,7 +329,7 @@ static std::string id2vl(std::string txt)
|
||||||
return txt;
|
return txt;
|
||||||
}
|
}
|
||||||
|
|
||||||
// dump AST node as verilog pseudo-code
|
// dump AST node as Verilog pseudo-code
|
||||||
void AstNode::dumpVlog(FILE *f, std::string indent)
|
void AstNode::dumpVlog(FILE *f, std::string indent)
|
||||||
{
|
{
|
||||||
bool first = true;
|
bool first = true;
|
||||||
|
@ -894,7 +894,7 @@ static AstModule* process_module(AstNode *ast, bool defer)
|
||||||
AstNode *ast_before_simplify = ast->clone();
|
AstNode *ast_before_simplify = ast->clone();
|
||||||
|
|
||||||
if (flag_dump_ast1) {
|
if (flag_dump_ast1) {
|
||||||
log("Dumping verilog AST before simplification:\n");
|
log("Dumping Verilog AST before simplification:\n");
|
||||||
ast->dumpAst(NULL, " ");
|
ast->dumpAst(NULL, " ");
|
||||||
log("--- END OF AST DUMP ---\n");
|
log("--- END OF AST DUMP ---\n");
|
||||||
}
|
}
|
||||||
|
@ -904,13 +904,13 @@ static AstModule* process_module(AstNode *ast, bool defer)
|
||||||
while (ast->simplify(!flag_noopt, false, false, 0, -1, false, false)) { }
|
while (ast->simplify(!flag_noopt, false, false, 0, -1, false, false)) { }
|
||||||
|
|
||||||
if (flag_dump_ast2) {
|
if (flag_dump_ast2) {
|
||||||
log("Dumping verilog AST after simplification:\n");
|
log("Dumping Verilog AST after simplification:\n");
|
||||||
ast->dumpAst(NULL, " ");
|
ast->dumpAst(NULL, " ");
|
||||||
log("--- END OF AST DUMP ---\n");
|
log("--- END OF AST DUMP ---\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (flag_dump_vlog) {
|
if (flag_dump_vlog) {
|
||||||
log("Dumping verilog AST (as requested by dump_vlog option):\n");
|
log("Dumping Verilog AST (as requested by dump_vlog option):\n");
|
||||||
ast->dumpVlog(NULL, " ");
|
ast->dumpVlog(NULL, " ");
|
||||||
log("--- END OF AST DUMP ---\n");
|
log("--- END OF AST DUMP ---\n");
|
||||||
}
|
}
|
||||||
|
|
|
@ -136,7 +136,7 @@ static void my_strtobin(std::vector<RTLIL::State> &data, const char *str, int le
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// convert the verilog code for a constant to an AST node
|
// convert the Verilog code for a constant to an AST node
|
||||||
AstNode *VERILOG_FRONTEND::const2ast(std::string code, char case_type, bool warn_z)
|
AstNode *VERILOG_FRONTEND::const2ast(std::string code, char case_type, bool warn_z)
|
||||||
{
|
{
|
||||||
if (warn_z) {
|
if (warn_z) {
|
||||||
|
|
|
@ -281,7 +281,7 @@ supply1 { return TOK_SUPPLY1; }
|
||||||
static bool printed_warning = false;
|
static bool printed_warning = false;
|
||||||
if (!printed_warning) {
|
if (!printed_warning) {
|
||||||
log_warning("Found one of those horrible `(synopsys|synthesis) full_case' comments.\n"
|
log_warning("Found one of those horrible `(synopsys|synthesis) full_case' comments.\n"
|
||||||
"Yosys does support them but it is recommended to use verilog `full_case' attributes instead!\n");
|
"Yosys does support them but it is recommended to use Verilog `full_case' attributes instead!\n");
|
||||||
printed_warning = true;
|
printed_warning = true;
|
||||||
}
|
}
|
||||||
return TOK_SYNOPSYS_FULL_CASE;
|
return TOK_SYNOPSYS_FULL_CASE;
|
||||||
|
@ -290,7 +290,7 @@ supply1 { return TOK_SUPPLY1; }
|
||||||
static bool printed_warning = false;
|
static bool printed_warning = false;
|
||||||
if (!printed_warning) {
|
if (!printed_warning) {
|
||||||
log_warning("Found one of those horrible `(synopsys|synthesis) parallel_case' comments.\n"
|
log_warning("Found one of those horrible `(synopsys|synthesis) parallel_case' comments.\n"
|
||||||
"Yosys does support them but it is recommended to use verilog `parallel_case' attributes instead!\n");
|
"Yosys does support them but it is recommended to use Verilog `parallel_case' attributes instead!\n");
|
||||||
printed_warning = true;
|
printed_warning = true;
|
||||||
}
|
}
|
||||||
return TOK_SYNOPSYS_PARALLEL_CASE;
|
return TOK_SYNOPSYS_PARALLEL_CASE;
|
||||||
|
|
|
@ -503,7 +503,7 @@ Commands for executing scripts or entering interactive mode:
|
||||||
Commands for reading and elaborating the design:
|
Commands for reading and elaborating the design:
|
||||||
\begin{lstlisting}[xleftmargin=1cm, basicstyle=\ttfamily\fontsize{8pt}{10pt}\selectfont, language=ys]
|
\begin{lstlisting}[xleftmargin=1cm, basicstyle=\ttfamily\fontsize{8pt}{10pt}\selectfont, language=ys]
|
||||||
read_ilang # read modules from ilang file
|
read_ilang # read modules from ilang file
|
||||||
read_verilog # read modules from verilog file
|
read_verilog # read modules from Verilog file
|
||||||
hierarchy # check, expand and clean up design hierarchy
|
hierarchy # check, expand and clean up design hierarchy
|
||||||
\end{lstlisting}
|
\end{lstlisting}
|
||||||
|
|
||||||
|
@ -536,7 +536,7 @@ Commands for writing the results:
|
||||||
write_edif # write design to EDIF netlist file
|
write_edif # write design to EDIF netlist file
|
||||||
write_ilang # write design to ilang file
|
write_ilang # write design to ilang file
|
||||||
write_spice # write design to SPICE netlist file
|
write_spice # write design to SPICE netlist file
|
||||||
write_verilog # write design to verilog file
|
write_verilog # write design to Verilog file
|
||||||
\end{lstlisting}
|
\end{lstlisting}
|
||||||
|
|
||||||
\bigskip
|
\bigskip
|
||||||
|
@ -761,7 +761,7 @@ Because of the framework characteristics of Yosys, an increasing number of featu
|
||||||
become available in one tool. Yosys not only can be used for circuit synthesis but
|
become available in one tool. Yosys not only can be used for circuit synthesis but
|
||||||
also for formal equivalence checking, SAT solving, and for circuit analysis, to
|
also for formal equivalence checking, SAT solving, and for circuit analysis, to
|
||||||
name just a few other application domains. With proprietary software one needs to
|
name just a few other application domains. With proprietary software one needs to
|
||||||
learn a new tool for each of this applications.
|
learn a new tool for each of these applications.
|
||||||
\end{itemize}
|
\end{itemize}
|
||||||
\end{frame}
|
\end{frame}
|
||||||
|
|
||||||
|
|
|
@ -762,7 +762,7 @@ This pass flattens the design by replacing cells by their implementation. This
|
||||||
pass is very similar to the 'techmap' pass. The only difference is that this
|
pass is very similar to the 'techmap' pass. The only difference is that this
|
||||||
pass is using the current design as mapping library.
|
pass is using the current design as mapping library.
|
||||||
|
|
||||||
Cells and/or modules with the 'keep_hiearchy' attribute set will not be
|
Cells and/or modules with the 'keep_hierarchy' attribute set will not be
|
||||||
flattened by this command.
|
flattened by this command.
|
||||||
\end{lstlisting}
|
\end{lstlisting}
|
||||||
|
|
||||||
|
@ -3360,7 +3360,7 @@ values referenced above are vectors of this integers. Signal bits that are
|
||||||
connected to a constant driver are denoted as string "0" or "1" instead of
|
connected to a constant driver are denoted as string "0" or "1" instead of
|
||||||
a number.
|
a number.
|
||||||
|
|
||||||
For example the following verilog code:
|
For example the following Verilog code:
|
||||||
|
|
||||||
module test(input x, y);
|
module test(input x, y);
|
||||||
(* keep *) foo #(.P(42), .Q(1337))
|
(* keep *) foo #(.P(42), .Q(1337))
|
||||||
|
|
|
@ -1321,7 +1321,7 @@ struct SelectPass : public Pass {
|
||||||
log_cmd_error("No selection to check.\n");
|
log_cmd_error("No selection to check.\n");
|
||||||
work_stack.back().optimize(design);
|
work_stack.back().optimize(design);
|
||||||
if (!work_stack.back().empty())
|
if (!work_stack.back().empty())
|
||||||
log_error("Assertation failed: selection is not empty:%s\n", sel_str.c_str());
|
log_error("Assertion failed: selection is not empty:%s\n", sel_str.c_str());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1331,7 +1331,7 @@ struct SelectPass : public Pass {
|
||||||
log_cmd_error("No selection to check.\n");
|
log_cmd_error("No selection to check.\n");
|
||||||
work_stack.back().optimize(design);
|
work_stack.back().optimize(design);
|
||||||
if (work_stack.back().empty())
|
if (work_stack.back().empty())
|
||||||
log_error("Assertation failed: selection is empty:%s\n", sel_str.c_str());
|
log_error("Assertion failed: selection is empty:%s\n", sel_str.c_str());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1358,7 +1358,7 @@ struct SelectPass : public Pass {
|
||||||
total_count++;
|
total_count++;
|
||||||
}
|
}
|
||||||
if (assert_count != total_count)
|
if (assert_count != total_count)
|
||||||
log_error("Assertation failed: selection contains %d elements instead of the asserted %d:%s\n",
|
log_error("Assertion failed: selection contains %d elements instead of the asserted %d:%s\n",
|
||||||
total_count, assert_count, sel_str.c_str());
|
total_count, assert_count, sel_str.c_str());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1102,7 +1102,7 @@ struct FlattenPass : public Pass {
|
||||||
log("pass is very similar to the 'techmap' pass. The only difference is that this\n");
|
log("pass is very similar to the 'techmap' pass. The only difference is that this\n");
|
||||||
log("pass is using the current design as mapping library.\n");
|
log("pass is using the current design as mapping library.\n");
|
||||||
log("\n");
|
log("\n");
|
||||||
log("Cells and/or modules with the 'keep_hiearchy' attribute set will not be\n");
|
log("Cells and/or modules with the 'keep_hierarchy' attribute set will not be\n");
|
||||||
log("flattened by this command.\n");
|
log("flattened by this command.\n");
|
||||||
log("\n");
|
log("\n");
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
*
|
*
|
||||||
* The internal logic cell simulation library.
|
* The internal logic cell simulation library.
|
||||||
*
|
*
|
||||||
* This verilog library contains simple simulation models for the internal
|
* This Verilog library contains simple simulation models for the internal
|
||||||
* logic cells ($_NOT_ , $_AND_ , ...) that are generated by the default technology
|
* logic cells ($_NOT_ , $_AND_ , ...) that are generated by the default technology
|
||||||
* mapper (see "techmap.v" in this directory) and expected by the "abc" pass.
|
* mapper (see "techmap.v" in this directory) and expected by the "abc" pass.
|
||||||
*
|
*
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
*
|
*
|
||||||
* The Simulation Library.
|
* The Simulation Library.
|
||||||
*
|
*
|
||||||
* This verilog library contains simple simulation models for the internal
|
* This Verilog library contains simple simulation models for the internal
|
||||||
* cells ($not, ...) generated by the frontends and used in most passes.
|
* cells ($not, ...) generated by the frontends and used in most passes.
|
||||||
*
|
*
|
||||||
* This library can be used to verify the internal netlists as generated
|
* This library can be used to verify the internal netlists as generated
|
||||||
|
@ -1163,7 +1163,7 @@ input A, EN;
|
||||||
`ifndef SIMLIB_NOCHECKS
|
`ifndef SIMLIB_NOCHECKS
|
||||||
always @* begin
|
always @* begin
|
||||||
if (A !== 1'b1 && EN === 1'b1) begin
|
if (A !== 1'b1 && EN === 1'b1) begin
|
||||||
$display("Assertation %m failed!");
|
$display("Assertion %m failed!");
|
||||||
$stop;
|
$stop;
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
*
|
*
|
||||||
* The internal logic cell technology mapper.
|
* The internal logic cell technology mapper.
|
||||||
*
|
*
|
||||||
* This verilog library contains the mapping of internal cells (e.g. $not with
|
* This Verilog library contains the mapping of internal cells (e.g. $not with
|
||||||
* variable bit width) to the internal logic cells (such as the single bit $_NOT_
|
* variable bit width) to the internal logic cells (such as the single bit $_NOT_
|
||||||
* gate). Usually this logic network is then mapped to the actual technology
|
* gate). Usually this logic network is then mapped to the actual technology
|
||||||
* using e.g. the "abc" pass.
|
* using e.g. the "abc" pass.
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Borrowed verilog examples from http://www.asic-world.com/.
|
Borrowed Verilog examples from http://www.asic-world.com/.
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
|
|
||||||
This test cases are copied from the hana project:
|
These test cases are copied from the hana project:
|
||||||
https://sourceforge.net/projects/sim-sim/
|
https://sourceforge.net/projects/sim-sim/
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,7 @@ for ((i = 0; i < 100; i++)); do
|
||||||
iverilog -o uut_${idx}_tb uut_${idx}_tb.v uut_${idx}.v uut_${idx}_syn.v
|
iverilog -o uut_${idx}_tb uut_${idx}_tb.v uut_${idx}.v uut_${idx}_syn.v
|
||||||
./uut_${idx}_tb | tee uut_${idx}.err
|
./uut_${idx}_tb | tee uut_${idx}.err
|
||||||
if test -s uut_${idx}.err; then
|
if test -s uut_${idx}.err; then
|
||||||
echo "Note: Make sure that 'iverilog' is an up-to-date git checkout of icarus verilog."
|
echo "Note: Make sure that 'iverilog' is an up-to-date git checkout of Icarus Verilog."
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
rm -f uut_${idx}.err
|
rm -f uut_${idx}.err
|
||||||
|
|
|
@ -65,7 +65,7 @@ always @(posedge clk, posedge arst1, posedge arst2, negedge arst3) begin
|
||||||
end
|
end
|
||||||
endmodule
|
endmodule
|
||||||
|
|
||||||
// SR-Flip-Flops are on the edge of well defined vewrilog constructs in terms of
|
// SR-Flip-Flops are on the edge of well defined Verilog constructs in terms of
|
||||||
// simulation-implementation mismatches. The following testcases try to cover the
|
// simulation-implementation mismatches. The following testcases try to cover the
|
||||||
// part that is defined and avoid the undefined cases.
|
// part that is defined and avoid the undefined cases.
|
||||||
|
|
||||||
|
|
|
@ -5,10 +5,10 @@ input [3:0] a;
|
||||||
input signed [3:0] b;
|
input signed [3:0] b;
|
||||||
output [7:0] y1, y2, y3, y4;
|
output [7:0] y1, y2, y3, y4;
|
||||||
|
|
||||||
// this version triggers a bug in icarus verilog
|
// this version triggers a bug in Icarus Verilog
|
||||||
// submod #(-3'sd1, 3'b111 + 3'b001) foo (a, b, y1, y2, y3, y4);
|
// submod #(-3'sd1, 3'b111 + 3'b001) foo (a, b, y1, y2, y3, y4);
|
||||||
|
|
||||||
// this version is handled correctly by icarus verilog
|
// this version is handled correctly by Icarus Verilog
|
||||||
submod #(-3'sd1, -3'sd1) foo (a, b, y1, y2, y3, y4);
|
submod #(-3'sd1, -3'sd1) foo (a, b, y1, y2, y3, y4);
|
||||||
|
|
||||||
endmodule
|
endmodule
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
|
|
||||||
// test case taken from amber23 verilog code
|
// test case taken from amber23 Verilog code
|
||||||
module a23_barrel_shift_fpga_rotate(i_in, direction, shift_amount, rot_prod);
|
module a23_barrel_shift_fpga_rotate(i_in, direction, shift_amount, rot_prod);
|
||||||
|
|
||||||
input [31:0] i_in;
|
input [31:0] i_in;
|
||||||
|
|
|
@ -27,14 +27,14 @@ module test04(a, y);
|
||||||
assign y = ~(a - 1'b0);
|
assign y = ~(a - 1'b0);
|
||||||
endmodule
|
endmodule
|
||||||
|
|
||||||
// .. this test triggers a bug in xilinx isim.
|
// .. this test triggers a bug in Xilinx ISIM.
|
||||||
// module test05(a, y);
|
// module test05(a, y);
|
||||||
// input a;
|
// input a;
|
||||||
// output y;
|
// output y;
|
||||||
// assign y = 12345 >> {a, 32'd0};
|
// assign y = 12345 >> {a, 32'd0};
|
||||||
// endmodule
|
// endmodule
|
||||||
|
|
||||||
// .. this test triggers a bug in icarus verilog.
|
// .. this test triggers a bug in Icarus Verilog.
|
||||||
// module test06(a, b, c, y);
|
// module test06(a, b, c, y);
|
||||||
// input signed [3:0] a;
|
// input signed [3:0] a;
|
||||||
// input signed [1:0] b;
|
// input signed [1:0] b;
|
||||||
|
|
|
@ -168,7 +168,7 @@ do
|
||||||
else
|
else
|
||||||
echo "${status_prefix}-> ERROR!"
|
echo "${status_prefix}-> ERROR!"
|
||||||
if $warn_iverilog_git; then
|
if $warn_iverilog_git; then
|
||||||
echo "Note: Make sure that 'iverilog' is an up-to-date git checkout of icarus verilog."
|
echo "Note: Make sure that 'iverilog' is an up-to-date git checkout of Icarus Verilog."
|
||||||
fi
|
fi
|
||||||
$keeprunning || exit 1
|
$keeprunning || exit 1
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue