whitequark [Mon, 29 Jun 2020 12:34:09 +0000 (12:34 +0000)]
Merge pull request #2197 from Xiretza/test_cell-shifts
test_cell: don't generate directional shifts with \B_SIGNED=1
Xiretza [Sun, 28 Jun 2020 19:30:16 +0000 (21:30 +0200)]
test_cell: don't generate directional shifts with \B_SIGNED=1
This was made an explicit error in
e97e33d, "kernel: require \B_SIGNED=0
on $shl, $sshl, $shr, $sshr.".
Miodrag Milanovic [Fri, 26 Jun 2020 18:11:01 +0000 (20:11 +0200)]
Fix crash in verific frontend
whitequark [Fri, 26 Jun 2020 08:48:15 +0000 (08:48 +0000)]
Merge pull request #2193 from whitequark/cxxrtl-help-text
cxxrtl: update help text
whitequark [Fri, 26 Jun 2020 08:30:44 +0000 (08:30 +0000)]
cxxrtl: update help text.
whitequark [Fri, 26 Jun 2020 07:30:27 +0000 (07:30 +0000)]
Merge pull request #2188 from antmicro/missing-operators
Add logic-assignments operators
whitequark [Fri, 26 Jun 2020 07:29:24 +0000 (07:29 +0000)]
Merge pull request #2189 from antmicro/optional-labels
Add support for optional labels
clairexen [Thu, 25 Jun 2020 16:21:51 +0000 (18:21 +0200)]
Merge pull request #2168 from whitequark/assert-unused-exprs
Use (and ignore) the expression provided to log_assert in NDEBUG builds
clairexen [Thu, 25 Jun 2020 16:18:09 +0000 (18:18 +0200)]
Merge pull request #2135 from boqwxp/qbfsat-timeinfo
log and qbfsat: Also include child process usage in `PerformanceTimer::query()` and report the time for each call to the QBF-SAT solver
clairexen [Thu, 25 Jun 2020 16:14:17 +0000 (18:14 +0200)]
Merge pull request #2093 from boqwxp/qbfsat-bugfixes
qbfsat: Multiple bugfixes
clairexen [Thu, 25 Jun 2020 14:40:30 +0000 (16:40 +0200)]
Merge pull request #2192 from YosysHQ/verific_netbus_attr
verific - import attributes for net buses
Kamil Rakoczy [Thu, 25 Jun 2020 12:20:47 +0000 (14:20 +0200)]
Add sub-assign and and-assign tests
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
Kamil Rakoczy [Thu, 25 Jun 2020 12:17:41 +0000 (14:17 +0200)]
Move combined assign tests to single file
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
Kamil Rakoczy [Thu, 25 Jun 2020 11:29:06 +0000 (13:29 +0200)]
Support missing sub-assign and and-assign operators
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
Miodrag Milanovic [Thu, 25 Jun 2020 07:18:53 +0000 (09:18 +0200)]
optimization, all items should have same attributes
Kamil Rakoczy [Wed, 24 Jun 2020 12:38:03 +0000 (14:38 +0200)]
Add xor-assignment test
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
Lukasz Dalek [Tue, 23 Jun 2020 16:50:50 +0000 (18:50 +0200)]
Support missing xor-assign operator
Signed-off-by: Lukasz Dalek <ldalek@antmicro.com>
Lukasz Dalek [Fri, 19 Jun 2020 18:46:38 +0000 (20:46 +0200)]
Support optional labels at the end of package definition
Signed-off-by: Lukasz Dalek <ldalek@antmicro.com>
Lukasz Dalek [Tue, 19 May 2020 14:58:48 +0000 (16:58 +0200)]
Support optional labels at the end of module definition
Signed-off-by: Lukasz Dalek <ldalek@antmicro.com>
Kamil Rakoczy [Wed, 24 Jun 2020 09:45:38 +0000 (11:45 +0200)]
Add or-assignment and plus-assignment tests
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
Kamil Rakoczy [Wed, 3 Jun 2020 14:44:02 +0000 (16:44 +0200)]
Add plus-assignment operator
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
Kamil Rakoczy [Wed, 3 Jun 2020 11:51:57 +0000 (13:51 +0200)]
Add or-assignment operator
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
Miodrag Milanovic [Wed, 24 Jun 2020 09:01:06 +0000 (11:01 +0200)]
verific - import attributes for net buses as well
whitequark [Wed, 24 Jun 2020 05:40:01 +0000 (05:40 +0000)]
Merge pull request #2185 from YosysHQ/mwk/cxxrtl-ff-types
cxxrtl: Add support for the new FF types.
Marcelina Kościelnicka [Wed, 24 Jun 2020 00:15:08 +0000 (02:15 +0200)]
cxxrtl: Add support for the new FF types.
Marcelina Kościelnicka [Tue, 23 Jun 2020 21:16:43 +0000 (23:16 +0200)]
simplemap: Fix $dffsre mapping.
clairexen [Tue, 23 Jun 2020 18:25:52 +0000 (20:25 +0200)]
Merge pull request #1818 from YosysHQ/mwk/new-ff-types
Add new FF types to library.
Marcelina Kościelnicka [Tue, 23 Jun 2020 15:25:46 +0000 (17:25 +0200)]
Update
dff2dffe, dff2dffs, zinit to new FF types.
Marcelina Kościelnicka [Tue, 23 Jun 2020 13:39:25 +0000 (15:39 +0200)]
Add add* functions for the new FF types
Marcelina Kościelnicka [Thu, 9 Apr 2020 01:55:56 +0000 (03:55 +0200)]
Add new FF types to simplemap.
Marcelina Kościelnicka [Wed, 8 Apr 2020 22:26:17 +0000 (00:26 +0200)]
Add support for new FF types in some opt passes.
Marcelina Kościelnicka [Wed, 8 Apr 2020 19:42:50 +0000 (21:42 +0200)]
Add new builtin FF types
The new types include:
- FFs with async reset and enable (`$adffe`, `$_DFFE_[NP][NP][01][NP]_`)
- FFs with sync reset (`$sdff`, `$_SDFF_[NP][NP][01]_`)
- FFs with sync reset and enable, reset priority (`$sdffs`, `$_SDFFE_[NP][NP][01][NP]_`)
- FFs with sync reset and enable, enable priority (`$sdffce`, `$_SDFFCE_[NP][NP][01][NP]_`)
- FFs with async reset, set, and enable (`$dffsre`, `$_DFFSRE_[NP][NP][NP][NP]_`)
- latches with reset or set (`$adlatch`, `$_DLATCH_[NP][NP][01]_`)
The new FF types are not actually used anywhere yet (this is left
for future commits).
whitequark [Mon, 22 Jun 2020 17:01:59 +0000 (17:01 +0000)]
Merge pull request #2182 from whitequark/update-abc
Update ABC
whitequark [Mon, 22 Jun 2020 14:18:07 +0000 (14:18 +0000)]
Update ABC.
whitequark [Mon, 22 Jun 2020 00:10:25 +0000 (00:10 +0000)]
Merge pull request #2181 from whitequark/minisat-wasm-signal
minisat: add missing include guard for WASI
whitequark [Sun, 21 Jun 2020 21:26:21 +0000 (21:26 +0000)]
minisat: add missing include guard for WASI.
Including signal.h used to be allowed in WASI by mistake, but it's
an error since SDK 11.
whitequark [Sun, 21 Jun 2020 15:19:23 +0000 (15:19 +0000)]
Merge pull request #2180 from Xiretza/pyosys-override
pyosys: Use C++11 override keyword for bindings
Xiretza [Sun, 21 Jun 2020 14:27:33 +0000 (16:27 +0200)]
pyosys: Use C++11 override keyword for bindings
7191dd16 dropped the YS_OVERRIDE macro, but it was still being generated
by the python bindings generator, resulting in errors like these when
compiled with ENABLE_PYOSYS=1:
kernel/python_wrappers.cc:350:21: error: expected ‘;’ at end of member declaration
350 | virtual void help() YS_OVERRIDE;
| ^
| ;
kernel/python_wrappers.cc:350:23: error: ‘YS_OVERRIDE’ does not name a type
350 | virtual void help() YS_OVERRIDE;
| ^~~~~~~~~~~
Alberto Gonzalez [Wed, 10 Jun 2020 18:21:07 +0000 (18:21 +0000)]
log: Remove unused `_POSIX_TIMERS` branch in `PerformanceTimer::query()`.
Alberto Gonzalez [Sun, 7 Jun 2020 07:45:24 +0000 (07:45 +0000)]
log, qbfsat: Include child process time in `PerformanceTimer::query()` and report the time for each call to the QBF-SAT solver.
Alberto Gonzalez [Tue, 9 Jun 2020 21:44:45 +0000 (21:44 +0000)]
qbfsat: Simplify solution recovery parsing and tweak the solution regexes.
Alberto Gonzalez [Tue, 9 Jun 2020 21:31:58 +0000 (21:31 +0000)]
qbfsat: Avoid instantiating `AttrObject`s directly.
Co-Authored-By: Claire Wolf <claire@symbioticeda.com>
Alberto Gonzalez [Tue, 9 Jun 2020 05:27:09 +0000 (05:27 +0000)]
qbfsat: Simplify solution format and replace `SigBit::str()` with `log_signal()`.
Co-Authored-By: Claire Wolf <claire@symbioticeda.com>
Alberto Gonzalez [Tue, 26 May 2020 23:12:15 +0000 (23:12 +0000)]
qbfsat: Fixes three bugs.
1. Infinite loop in the optimization procedure when the first solution found while maximizing is at zero.
2. A signed-ness issue when maximizing.
3. Erroneously entering bisection mode with no wire to optimize.
Alberto Gonzalez [Fri, 22 May 2020 04:48:33 +0000 (04:48 +0000)]
qbfsat: Use bit precise mapping for hole value wires and a more robust hole spec for writing to and specializing from a solution file.
whitequark [Sun, 21 Jun 2020 02:05:12 +0000 (02:05 +0000)]
Merge pull request #2177 from boqwxp/dict-iterator-jump
hashlib, rtlil: Add `operator+()` and `operator+=()` to `dict` iterators
Alberto Gonzalez [Fri, 19 Jun 2020 20:57:27 +0000 (20:57 +0000)]
dict: Remove guard for past-the-end iterators that might mask problems in static analysis.
Co-Authored-By: whitequark <whitequark@whitequark.org>
whitequark [Fri, 19 Jun 2020 19:57:25 +0000 (19:57 +0000)]
Merge pull request #2178 from boqwxp/design-select
rtlil: Add `Design::select()` for selecting whole modules
Alberto Gonzalez [Wed, 17 Jun 2020 20:28:56 +0000 (20:28 +0000)]
rtlil: Add `Design::select()` for selecting whole modules.
Alberto Gonzalez [Wed, 17 Jun 2020 22:32:34 +0000 (22:32 +0000)]
hashlib, rtlil: Add `operator+=()` to `dict<>::iterator` and `dict<>::const_iterator` and add `operator+()` and `operator+=()` to `ObjIterator`.
whitequark [Fri, 19 Jun 2020 15:45:52 +0000 (15:45 +0000)]
Use [[maybe_unused]] instead of YS_ATTRIBUTE(unused).
[[maybe_unused]] is available since C++17, so this commit adds
a polyfill YS_MAYBE_UNUSED. Once we require C++17 we can drop it.
whitequark [Fri, 19 Jun 2020 01:32:48 +0000 (01:32 +0000)]
Remove YS_ATTRIBUTE(unused) where present just for log_assert()/log_debug().
whitequark [Fri, 19 Jun 2020 01:51:53 +0000 (01:51 +0000)]
Use (and ignore) the expression provided to log_debug in NDEBUG builds.
whitequark [Wed, 17 Jun 2020 19:30:53 +0000 (19:30 +0000)]
Use (and ignore) the expression provided to log_assert in NDEBUG builds.
This avoids warnings in NDEBUG builds emitted when a variable is only
used in log_assert, but is always defined.
whitequark [Fri, 19 Jun 2020 15:46:54 +0000 (15:46 +0000)]
Merge pull request #2175 from Xiretza/missing-noreturn
Add missing [[noreturn]] to log_file_error()
Xiretza [Fri, 19 Jun 2020 09:46:06 +0000 (11:46 +0200)]
Add missing [[noreturn]] to log_file_error()
Previously this was tagged only with YS_ATTRIBUTE(noreturn), but not
YS_NORETURN, so it got lost in #2173, resulting in warnings in
frontends/ast/simplify.cc:
frontends/ast/simplify.cc:267:1: warning: function declared 'noreturn' should not return [-Winvalid-noreturn]
}
^
frontends/ast/simplify.cc:379:1: warning: function declared 'noreturn' should not return [-Winvalid-noreturn]
}
^
whitequark [Fri, 19 Jun 2020 06:15:33 +0000 (06:15 +0000)]
Merge pull request #2173 from whitequark/use-cxx11-final-override
Use C++11 final/override/[[noreturn]]
whitequark [Fri, 19 Jun 2020 06:09:42 +0000 (06:09 +0000)]
Merge pull request #2174 from whitequark/fix-github-linguist
Fix GitHub misidentifying *.v files as Coq
whitequark [Fri, 19 Jun 2020 06:08:18 +0000 (06:08 +0000)]
Fix GitHub misidentifying *.v files as Coq.
whitequark [Fri, 19 Jun 2020 03:52:29 +0000 (03:52 +0000)]
Merge pull request #2171 from whitequark/cxxrtl-accessors
cxxrtl: add .get() and .set() accessors on value<> and wire<>
whitequark [Thu, 18 Jun 2020 21:51:30 +0000 (21:51 +0000)]
cxxrtl: add .get() and .set() accessors on value<> and wire<>.
For several reasons:
* They're more convenient than accessing .data.
* They accommodate variably-sized types like size_t transparently.
* They statically ensure that no out of range conversions happen.
For now these are only provided for unsigned integers, but eventually
they should be provided for signed integers too. (Annoyingly this
affects conversions to/from `char` at the moment.)
Fixes #2127.
whitequark [Fri, 19 Jun 2020 01:13:19 +0000 (01:13 +0000)]
Merge pull request #2170 from boqwxp/cutpoint-efficiency
cutpoint: Improve efficiency by iterating over module ports instead of module wires
whitequark [Fri, 19 Jun 2020 01:05:59 +0000 (01:05 +0000)]
Use C++11 [[noreturn]] attribute.
whitequark [Thu, 18 Jun 2020 23:34:52 +0000 (23:34 +0000)]
Use C++11 final/override keywords.
Alberto Gonzalez [Thu, 18 Jun 2020 17:42:36 +0000 (17:42 +0000)]
cutpoint: Improve efficiency by iterating over module ports instead of module wires.
N. Engelhardt [Thu, 18 Jun 2020 17:16:55 +0000 (19:16 +0200)]
Merge pull request #2153 from boqwxp/splitnets-cleanup
splitnets: Cleanup and efficiency improvements
whitequark [Thu, 18 Jun 2020 16:57:51 +0000 (16:57 +0000)]
Merge pull request #2167 from whitequark/cxxrtl-fix-ndebug
cxxrtl: don't compute vital values in log_assert()
whitequark [Thu, 18 Jun 2020 16:57:24 +0000 (16:57 +0000)]
Merge pull request #2142 from whitequark/splitnets-hdlname
splitnets: propagate (*hdlname*) and disambiguate via start_offset
Miodrag Milanović [Thu, 18 Jun 2020 10:44:21 +0000 (12:44 +0200)]
Merge pull request #2164 from madebr/msvc
Get yosys building on Visual Studio
whitequark [Wed, 17 Jun 2020 19:27:47 +0000 (19:27 +0000)]
cxxrtl: don't compute vital values in log_assert().
This breaks NDEBUG builds.
Fixes #2166.
Anonymous Maarten [Wed, 17 Jun 2020 11:53:57 +0000 (13:53 +0200)]
msvc does not support designated initializers in structs
Anonymous Maarten [Wed, 17 Jun 2020 11:52:45 +0000 (13:52 +0200)]
MSVC does not understand __builtin_unreachable
Anonymous Maarten [Wed, 17 Jun 2020 11:51:02 +0000 (13:51 +0200)]
MSVC cannot omit operand in conditional
Anonymous Maarten [Wed, 17 Jun 2020 13:08:55 +0000 (15:08 +0200)]
MSVC defines TRANSPARENT too
whitequark [Wed, 17 Jun 2020 06:07:41 +0000 (06:07 +0000)]
Merge pull request #2163 from jfng/cxxrtl-blackbox-debuginfo
cxxrtl: restrict the debug info of a blackbox to its ports.
whitequark [Wed, 17 Jun 2020 06:06:58 +0000 (06:06 +0000)]
Merge pull request #2160 from whitequark/cxxrtl-fix-warning
cxxrtl: avoid unused variable warning for transparent $memrd ports
Jean-François Nguyen [Tue, 16 Jun 2020 13:28:35 +0000 (15:28 +0200)]
cxxrtl: restrict the debug info of a blackbox to its ports.
N. Engelhardt [Tue, 16 Jun 2020 10:31:34 +0000 (12:31 +0200)]
Merge pull request #2156 from XarkLabs/master
Fix Verilator sim warnings: 1 BLKSEQ and 3 WIDTH
whitequark [Mon, 15 Jun 2020 06:08:17 +0000 (06:08 +0000)]
Merge pull request #2159 from MerryMage/cxxrtl-mul
cxxrtl: Implement chunk-wise multiplication
whitequark [Sun, 14 Jun 2020 05:42:52 +0000 (05:42 +0000)]
cxxrtl: avoid unused variable warning for transparent $memrd ports. NFC.
MerryMage [Sun, 14 Jun 2020 14:52:43 +0000 (15:52 +0100)]
cxxrtl: Implement chunk-wise multiplication
whitequark [Mon, 15 Jun 2020 01:37:05 +0000 (01:37 +0000)]
Merge pull request #2158 from miek/sshr-sign-extension
cxxrtl: fix sshr sign-extension.
Mike Walters [Sun, 14 Jun 2020 13:42:20 +0000 (14:42 +0100)]
cxxrtl: fix sshr sign-extension.
Xark [Sun, 14 Jun 2020 07:45:22 +0000 (00:45 -0700)]
Fix Verilator sim warnings: 1 BLKSEQ and 3 WIDTH
whitequark [Sat, 13 Jun 2020 23:28:18 +0000 (23:28 +0000)]
Merge pull request #2155 from whitequark/fix-wasm-wasi-sdk-11
kernel: guard include of signal.h more precisely
whitequark [Sat, 13 Jun 2020 22:37:04 +0000 (22:37 +0000)]
kernel: guard include of signal.h more precisely.
Upgrading to WASI SDK 11.0 caused the WASM build to fail because WASM
does not have signals. (Arguably Yosys was broken even before, it was
just broken silently.)
whitequark [Sat, 13 Jun 2020 22:18:35 +0000 (22:18 +0000)]
Merge pull request #2151 from whitequark/cxxrtl-fix-rzext
cxxrtl: fix rzext()
Alberto Gonzalez [Sat, 13 Jun 2020 05:47:55 +0000 (05:47 +0000)]
splitnets: Clean up pseudo-private member usage
Alberto Gonzalez [Sat, 13 Jun 2020 05:26:30 +0000 (05:26 +0000)]
splitnets: Slightly improve efficiency by avoiding some unnecessary lookups
whitequark [Sat, 13 Jun 2020 04:23:22 +0000 (04:23 +0000)]
Merge pull request #2145 from whitequark/cxxrtl-splitnets
cxxrtl: handle multipart signals
whitequark [Sat, 13 Jun 2020 04:17:49 +0000 (04:17 +0000)]
Merge pull request #2152 from whitequark/cxxrtl-always-inline
cxxrtl: always inline internal cells and slice/concat operations
whitequark [Sat, 13 Jun 2020 01:50:53 +0000 (01:50 +0000)]
cxxrtl: always inline internal cells and slice/concat operations.
This can result in massive reduction in runtime, up to 50% depending
on workload. Currently people are using `-mllvm -inline-threshold=`
as a workaround (with clang++), but this solution is more portable.
whitequark [Sat, 13 Jun 2020 00:49:44 +0000 (00:49 +0000)]
cxxrtl: fix rzext().
This was a correctness issue, but one of the consequences is that it
resulted in jumps in generated machine code where there should have
been none. As a side effect of fixing the bug, Minerva SoC became 10%
faster.
whitequark [Fri, 12 Jun 2020 08:50:57 +0000 (08:50 +0000)]
Merge pull request #2150 from whitequark/cxxrtl-elide-pmux
cxxrtl: elide $pmux cells
whitequark [Fri, 12 Jun 2020 02:40:30 +0000 (02:40 +0000)]
cxxrtl: elide $pmux cells.
On Minerva, this improves runtime by around 10%, mostly by ensuring
that the logic driving FFs is packed into edge conditionals.
whitequark [Fri, 12 Jun 2020 01:59:35 +0000 (01:59 +0000)]
Merge pull request #2149 from whitequark/cxxrtl-unbuffer-outputs
cxxrtl: unbuffer output wires of toplevel module
whitequark [Fri, 12 Jun 2020 00:35:18 +0000 (00:35 +0000)]
cxxrtl: annotate port direction as comments.
whitequark [Fri, 12 Jun 2020 00:05:05 +0000 (00:05 +0000)]
cxxrtl: unbuffer output wires of toplevel module.
Without unbuffering output wires of, at least, toplevel modules, it
is not possible to have most designs that rely on IO via toplevel
ports (as opposed to using exclusively blackboxes) converge within
one delta cycle. That seriously impairs the performance of CXXRTL.
This commit avoids unbuffering outputs of all modules solely so that
in future, CXXRTL could gain fully separate compilation, and not for
any present technical reason.
whitequark [Thu, 11 Jun 2020 22:21:30 +0000 (22:21 +0000)]
cxxrtl: simplify unbuffering of input wires.
This also fixes an edge case with (*keep*) input ports.
whitequark [Thu, 11 Jun 2020 13:31:16 +0000 (13:31 +0000)]
cxxrtl: handle multipart signals.
This avoids losing design visibility when using the `splitnets` pass.