Eddie Hung
fe273faad1
Merge pull request #2081 from YosysHQ/eddie/blackbox_ast
...
blackbox: use Module::makeblackbox() method
2020-05-30 08:59:20 -07:00
Xiretza
edd8ff2c07
Add flooring division operator
...
The $div and $mod cells use truncating division semantics (rounding
towards 0), as defined by e.g. Verilog. Another rounding mode, flooring
(rounding towards negative infinity), can be used in e.g. VHDL. The
new $divfloor cell provides this flooring division.
This commit also fixes the handling of $div in opt_expr, which was
previously optimized as if it was $divfloor.
2020-05-28 22:59:04 +02:00
Xiretza
17163cf43a
Add flooring modulo operator
...
The $div and $mod cells use truncating division semantics (rounding
towards 0), as defined by e.g. Verilog. Another rounding mode, flooring
(rounding towards negative infinity), can be used in e.g. VHDL. The
new $modfloor cell provides this flooring modulo (also known as "remainder"
in several languages, but this name is ambiguous).
This commit also fixes the handling of $mod in opt_expr, which was
previously optimized as if it was $modfloor.
2020-05-28 22:59:03 +02:00
Alberto Gonzalez
5896ffd56f
printattrs: Simplify `get_indent_str()`.
...
Co-Authored-By: Xiretza <xiretza@xiretza.xyz>
2020-05-28 05:34:28 +00:00
Alberto Gonzalez
f671c99cb8
printattrs: Refactor indentation string building for clarity.
...
Co-Authored-By: whitequark <whitequark@whitequark.org>
2020-05-27 23:15:07 +00:00
Alberto Gonzalez
e50e4ee285
printattrs: Use `flags` to pretty-print the `RTLIL::Const` appropriately.
...
Co-Authored-By: whitequark <whitequark@whitequark.org>
2020-05-27 08:00:00 +00:00
Alberto Gonzalez
b8365547e9
misc: Add `printattrs` command.
2020-05-27 08:00:00 +00:00
Eddie Hung
721283ac2a
blackbox: re-use existing Module::makeblackbox() method
2020-05-25 10:53:49 -07:00
Alberto Gonzalez
8297afe925
log: Use `dict` instead of `std::vector<std::pair>` for `log_expect_{error, warning, log}` to better express the intent that each element is unique.
2020-05-15 00:55:32 +00:00
Eddie Hung
425867d175
logger: clean up doc
2020-05-14 10:38:31 -07:00
Eddie Hung
65395168a0
logger: fix for multiple calls with same pattern
2020-05-14 10:32:07 -07:00
whitequark
b43c282e4e
Add WASI platform support.
...
This includes the following significant changes:
* Patching ezsat and minisat to disable resource limiting code
on WASM/WASI, since the POSIX functions they use are unavailable.
* Adding a new definition, YOSYS_DISABLE_SPAWN, present if platform
does not support spawning subprocesses (i.e. Emscripten or WASI).
This definition hides the definition of `run_command()`.
* Adding a new Makefile flag, DISABLE_SPAWN, present in the same
condition. This flag disables all passes that require spawning
subprocesses for their function.
2020-04-30 18:56:25 +00:00
Eddie Hung
56dd036b97
bugpoint: improve messaging
2020-04-24 13:41:19 -07:00
Eddie Hung
e602184856
bugpoint: (* keep *) to (* bugpoint_keep *); also apply to modules/cells
2020-04-24 13:26:04 -07:00
Eddie Hung
4bfe6ebea9
bugpoint: skip ports with (* keep *) on; add header
2020-04-24 11:17:09 -07:00
Eddie Hung
bf021a0e1f
bugpoint: improve help text
2020-04-23 12:16:55 -07:00
Eddie Hung
fa9df06c9d
Merge pull request #1949 from YosysHQ/eddie/select_blackbox
...
select: do not select inside black-/white- boxes unless '=' prefix used
2020-04-22 15:35:05 -07:00
Claire Wolf
beb9e4b299
Update passes/cmds/select.cc
...
Co-Authored-By: Eddie Hung <eddie@fpgeh.com>
2020-04-22 21:31:32 +02:00
Eddie Hung
eaa5a3e786
select: do not select black/white boxes by default, '=' prefix to do so
2020-04-22 10:15:56 -07:00
Eddie Hung
28623f19ee
Merge pull request #1950 from YosysHQ/eddie/design_import
...
design: -import to not count black/white-boxes as candidates for top
2020-04-22 09:32:13 -07:00
Marcelina Kościelnicka
cd82afb740
bugpoint: Don't remove modules or cells while iterating over them.
...
Reported by @ZirconiumX.
2020-04-22 00:09:01 +02:00
Claire Wolf
d834cc7afb
Add '=' selection pattern prefix for non-blackbox only patterns
...
Signed-off-by: Claire Wolf <claire@symbioticeda.com>
2020-04-21 14:23:24 +02:00
whitequark
f2064c8131
Merge pull request #1888 from boqwxp/cleanup_scatter
...
Clean up `passes/cmds/scatter.cc`.
2020-04-17 02:21:23 +00:00
whitequark
5c428996a9
Merge pull request #1882 from boqwxp/cleanup_rename
...
Clean up pseudo-private member usage in `passes/cmds/rename.cc`.
2020-04-17 02:20:54 +00:00
Eddie Hung
dac5adde12
design: -import to not count black/white-boxes as candidates for top
2020-04-16 12:46:07 -07:00
Eddie Hung
47c8ee7fe4
select: do not select inside blackboxes
2020-04-16 12:23:34 -07:00
Alberto Gonzalez
2e3647f567
Use `dict` instead of `std::map`.
...
Co-Authored-By: Eddie Hung <eddie@fpgeh.com>
2020-04-16 18:56:50 +00:00
Alberto Gonzalez
b94f38295a
Revert to `stringf()` rather than stringstreams.
2020-04-16 18:56:50 +00:00
Alberto Gonzalez
6081c1bbd3
Clean up pseudo-private member usage in `passes/cmds/rename.cc`.
2020-04-16 18:56:50 +00:00
Alberto Gonzalez
ff8be2364e
Replace `std::map` with `dict`.
...
Co-Authored-By: Eddie Hung <eddie@fpgeh.com>
2020-04-16 18:49:55 +00:00
Alberto Gonzalez
0424555702
Replace pseudo-private member access to `connections_` in `passes/cmds/scatter.cc`.
...
Co-Authored-By: N. Engelhardt <nak@symbioticeda.com>
2020-04-16 18:49:55 +00:00
Alberto Gonzalez
0787af947f
Clean up `passes/cmds/scatter.cc`.
2020-04-16 18:49:55 +00:00
Eddie Hung
254d38ca67
select: add select -unset option
2020-04-16 10:51:58 -07:00
Eddie Hung
8d3f6d0d79
Merge pull request #1928 from YosysHQ/eddie/design_delete
...
kernel: add design -delete option
2020-04-16 10:51:09 -07:00
Eddie Hung
aa552cefa3
Merge pull request #1927 from YosysHQ/eddie/design_remove_assert
...
kernel: Design::remove(RTLIL::Module *) to check refcount_modules_
2020-04-16 08:06:12 -07:00
Eddie Hung
a9ec0defb9
kernel: add design -delete option
2020-04-16 08:05:18 -07:00
Marcelina Kościelnicka
d7da491002
setundef: Improve error messages.
...
Fixes #1092 .
2020-04-15 16:13:28 +02:00
Eddie Hung
75bb2c8c24
design: do not delete when iterating over Design::modules() directly
2020-04-14 10:43:05 -07:00
Marcelina Kościelnicka
516857f3ba
[NFCI] Deduplicate builtin FF cell types list
...
A few passes included the same list of FF cell types. Make it a global
const instead.
The zinit pass also seems to include a list like that, but given that
it seems to be completely broken at the time (see #1568 discussion),
I'm going to pretend I didn't see that.
2020-04-09 18:05:06 +02:00
whitequark
42e7e44207
Merge pull request #1857 from whitequark/splitnets-skip-processes
...
splitnets: skip modules with processes
2020-04-09 04:03:30 +00:00
Alberto Gonzalez
64a5936bd7
Clean up `passes/cmds/connect.cc`.
2020-04-08 22:11:06 +00:00
whitequark
b350398c04
Merge pull request #1874 from boqwxp/cleanup_show
...
Clean up `passes/cmds/show.cc`.
2020-04-06 18:32:20 +00:00
Alberto Gonzalez
f4346a0400
Use more descriptive variable name.
...
Co-Authored-By: whitequark <whitequark@whitequark.org>
2020-04-06 14:48:27 +00:00
whitequark
ebf23cd62e
Merge pull request #1870 from boqwxp/cleanup_setattr
...
Clean up `passes/cmds/setattr.cc`.
2020-04-06 11:04:49 +00:00
whitequark
df95dc7d4a
Merge pull request #1872 from boqwxp/cleanup_copy
...
Clean up private member usage in `passes/cmds/copy.cc`.
2020-04-06 11:03:46 +00:00
whitequark
41f0c38478
Merge pull request #1871 from boqwxp/cleanup_splice
...
Clean up `passes/cmds/splice.cc`.
2020-04-06 11:03:34 +00:00
whitequark
db66371915
Merge pull request #1869 from boqwxp/cleanup_connwrappers
...
Clean up `passes/cmds/connwrappers.cc`.
2020-04-06 11:01:44 +00:00
whitequark
30934e425d
Merge pull request #1868 from boqwxp/cleanup_delete
...
Clean up `passes/cmds/delete.cc`.
2020-04-06 10:58:38 +00:00
whitequark
d3615ee445
Merge pull request #1867 from boqwxp/cleanup_stat
...
Clean up `passes/cmds/stat.cc`.
2020-04-06 10:58:02 +00:00
whitequark
0d69d532e0
Merge pull request #1859 from boqwxp/design_duplicate
...
Add `-push-copy` option to the `design` command.
2020-04-06 10:39:26 +00:00