Still unsupported:
- x-prop cells ($eqx, $nex, $bweqx)
- wide muxes (`$_MUX16_` and friends)
- $pmux
Partially supported:
- $bwmux is not supported in `ConstEval::eval()`, works with `-noeval`
- $buf has no mapping in techmap.v so is unusable with `techmap -assert` (i.e. the default)
- $pow has `_TECHMAP_FAIL_` in techmap.v, `-simlib` works for some iterations but fails for others, `-aigmap` works fine
Fix `CellTypes::eval() for `$_NMUX_`.
Fix `RTLIL::Cell::fixup_parameters()` for $concat and $bwmux.
Now with `is_internal`, `is_metainfo`, and `has_effects`.
Each type property has a comment specifying usage/meaning.
Type properties (sans `is_internal`) get a default value of false.
`CellTypes::setup_*_type()` methods get their own `CellType` struct assignments with named fields being assigned true to improve readability.
Add `CellTypes::get_cell()` which takes a 'type' `IdString` and returns the corresponding `CellType` if it is in the `cell_types` dict, otherwise returns `nullptr`.
Useful for getting a cell type by name and then checking its attributes.
`b_width_capped` already exists for preventing arithmetic overflow, limiting the value of `b_width` to 30. This just changes the left shifts to also use it.
The caveat of incorrect results for extremely large values of `a_width` still applies, as does the improbability of that actually happening.
This fixes#4844 (or at least, the floating point exception; the circuit still isn't valid but I think that's fine).
The B port is for single-bit summands. These can just as well be
represented as an additional summand on the A port (which supports
summands of arbitrary width). An upcoming `$macc_v2` cell won't be
special-casing single-bit summands in any way.
In preparation, make the following changes:
* remove the `bit_ports` field from the `Macc` helper (instead add any
single-bit summands to `ports` next to other summands)
* leave `B` empty on cells emitted from `Macc::to_cell`
In commit ac988cf we made sure to undefine the CONST/VOID macros left
defined by `tcl.h`, but this in turn makes it an issue to include
additional Tcl headers later on (see issue #4808).
One way out is to avoid a global `tcl.h` include. In the process we drop
support for Tcl-enabled MXE builds, which were likely broken anyway due
to the additional Tcl APIs used from `tclapi.cc`.