aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* verilog: Emit $meminit_v2 cell.Marcelina Kościelnicka2021-07-285-55/+87
| | | | Fixes #2447.
* backends/verilog: Support meminit with mask.Marcelina Kościelnicka2021-07-281-3/+18
|
* memory: Introduce $meminit_v2 cell, with EN input.Marcelina Kościelnicka2021-07-2810-13/+86
|
* Bump versiongithub-actions[bot]2021-07-281-1/+1
|
* proc: Run opt_expr at the endMarcelina Kościelnicka2021-07-271-0/+11
|
* opt_expr: Propagate constants to port connections.Marcelina Kościelnicka2021-07-273-3/+37
| | | | | | | | This adds one simple piece of functionality to opt_expr: when a cell port is connected to a fully-constant signal (as determined by sigmap), the port is reconnected directly to the constant value. This is just enough optimization to fix the "non-constant $meminit input" problem without requiring a full opt_clean or a separate pass.
* Bump versiongithub-actions[bot]2021-07-271-1/+1
|
* Add version bump workflowMiodrag Milanovic2021-07-261-0/+31
|
* Update to latest verificMiodrag Milanovic2021-07-211-3/+3
|
* Use new read_id_num helper function elsewhere in hierarchy.ccRupert Swarbrick2021-07-201-5/+6
|
* Extract connection checking logic from expand_module in hierarchy.ccRupert Swarbrick2021-07-201-23/+64
| | | | | No functional change, but pulls more logic out of the expand_module function.
* Merge pull request #2885 from whitequark/cxxrtl-fix-2883whitequark2021-07-201-2/+8
|\ | | | | cxxrtl: treat wires with multiple defs as not inlinable
| * cxxrtl: treat wires with multiple defs as not inlinable.whitequark2021-07-201-2/+8
| | | | | | | | Fixes #2883.
* | Merge pull request #2884 from whitequark/cxxrtl-fix-2882whitequark2021-07-201-10/+12
|\ \ | |/ |/| cxxrtl: treat assignable internal wires used only for debug as locals
| * cxxrtl: treat assignable internal wires used only for debug as locals.whitequark2021-07-201-10/+12
|/ | | | | | This issue was introduced in commit 4aa65f40 while fixing #2739. Fixes #2882.
* Merge pull request #2881 from whitequark/cxxrtl-sideways-colonwhitequark2021-07-201-1/+14
|\ | | | | cxxrtl: escape colon in variable names in VCD writer
| * cxxrtl: escape colon in variable names in VCD writer.whitequark2021-07-191-1/+14
|/ | | | | | | | | | | | The following VCD file crashes GTKWave's VCD loader: $var wire 1 ! x:1 $end $enddefinitions $end In practice, a colon can be a part of a variable name that is translated from a Verilog function, something like: update$func$.../hdl/hazard3_csr.v:350$2534.$result
* Merge pull request #2880 from whitequark/cxxrtl-fix-2877whitequark2021-07-181-0/+16
|\ | | | | cxxrtl: add debug_item::{get,set}
| * cxxrtl: add debug_item::{get,set}.whitequark2021-07-181-0/+16
|/ | | | Fixes #2877.
* Merge pull request #2879 from whitequark/cxxrtl-fix-2739-againwhitequark2021-07-171-0/+6
|\ | | | | cxxrtl: treat internal wires used only for debug as constants
| * cxxrtl: treat internal wires used only for debug as constants.whitequark2021-07-171-0/+6
| | | | | | | | Fixes #2739 (again).
* | Add support for parsing the SystemVerilog 'bind' constructRupert Swarbrick2021-07-1619-4/+247
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This doesn't do anything useful yet: the patch just adds support for the syntax to the lexer and parser and adds some tests to check the syntax parses properly. This generates AST nodes, but doesn't yet generate RTLIL. Since our existing hierarchical_identifier parser doesn't allow bit selects (so you can't do something like foo[1].bar[2].baz), I've also not added support for a trailing bit select (the "constant_bit_select" non-terminal in "bind_target_instance" in the spec). If we turn out to need this in future, we'll want to augment hierarchical_identifier and its other users too. Note that you can't easily use the BNF from the spec: bind_directive ::= "bind" bind_target_scope [ : bind_target_instance_list] bind_instantiation ; | "bind" bind_target_instance bind_instantiation ; even if you fix the lookahead problem, because code like this matches both branches in the BNF: bind a b b_i (.*); The problem is that 'a' could either be a module name or a degenerate hierarchical reference. This seems to be a genuine syntactic ambiguity, which the spec resolves (p739) by saying that we have to wait until resolution time (the hierarchy pass) and take whatever is defined, treating 'a' as an instance name if it names both an instance and a module. To keep the parser simple, it currently accepts this invalid syntax: bind a.b : c d e (.*); This is invalid because we're in the first branch of the BNF above, so the "a.b" term should match bind_target_scope: a module or interface identifier, not an arbitrary hierarchical identifier. This will fail in the hierarchy pass (when it's implemented in a future patch).
* Merge pull request #2874 from whitequark/cxxrtl-fix-2589whitequark2021-07-161-9/+6
|\ | | | | cxxrtl: run hierarchy pass regardless of (*top*) attribute presence
| * cxxrtl: run hierarchy pass regardless of (*top*) attribute presence.whitequark2021-07-161-9/+6
| | | | | | | | | | | | | | The hierarchy pass does a lot more than just finding the top module, mainly resolving implicit (positional, wildcard) module connections. Fixes #2589.
* | Merge pull request #2873 from whitequark/cxxrtl-fix-2500whitequark2021-07-161-3/+3
|\ \ | | | | | | cxxrtl: emit debug items for unused public wires
| * | cxxrtl: emit debug items for unused public wires.whitequark2021-07-161-3/+3
| |/ | | | | | | | | | | This greatly improves debug information coverage. Fixes #2500.
* | Merge pull request #2872 from whitequark/cxxrtl-fix-2521whitequark2021-07-161-2/+2
|\ \ | |/ |/| cxxrtl: don't expect user cell inputs to be wires
| * cxxrtl: don't expect user cell inputs to be wires.whitequark2021-07-161-2/+2
|/ | | | | | Ports can be connected to constants, too. (Usually resets.) Fixes #2521.
* Merge pull request #2871 from whitequark/cxxrtl-fix-2540-2841whitequark2021-07-161-1/+1
|\ | | | | cxxrtl: don't mark buffered internal wires as UNUSED for debug
| * cxxrtl: don't mark buffered internal wires as UNUSED for debug.whitequark2021-07-161-1/+1
|/ | | | | | | | | | Public wires may alias buffered internal wires, so keep BUFFERED wires in debug information even if they are private. Debug items are only created for public wires, so this does not otherwise affect how debug information is emitted. Fixes #2540. Fixes #2841.
* Merge pull request #2870 from whitequark/cxxrtl-fix-2739whitequark2021-07-161-4/+6
|\ | | | | cxxrtl: mark dead local wires as unused even with inlining disabled
| * cxxrtl: mark dead local wires as unused even with inlining disabled.whitequark2021-07-151-4/+6
| | | | | | | | Fixes #2739.
* | sv: fix two struct access bugsZachary Snow2021-07-155-1/+102
|/ | | | | - preserve signedness of struct members - fix initial width detection of struct members (e.g., in case expressions)
* Add a test for interfaces on modules loaded on-demandRupert Swarbrick2021-07-145-2/+48
|
* Extract missing module support in hierarchy.cc to a helper functionRupert Swarbrick2021-07-141-44/+68
| | | | | | | | | | I think the code is now a bit easier to follow (and has lost some levels of indentation!). The only non-trivial change is that I removed the check for cell->type[0] != '$' when deciding whether to complain if we couldn't find a module. This will always be true because of the early exit earlier in the function.
* Merge pull request #2866 from rswarbrick/found-initwhitequark2021-07-141-3/+0
|\ | | | | Delete unused found_init variable
| * Delete unused found_init variableRupert Swarbrick2021-07-141-3/+0
|/ | | | | | | Spotted during compilation: passes/proc/proc_init.cc: In function ‘void {anonymous}::proc_init(Yosys::RTLIL::Module*, Yosys::SigMap&, Yosys::RTLIL::Process*)’: passes/proc/proc_init.cc:31:7: warning: variable ‘found_init’ set but not used [-Wunused-but-set-variable]
* kernel/mem: Add a coalesce_inits helper.Marcelina Kościelnicka2021-07-133-1/+84
| | | | | | | While this helper is already useful to squash sequential initializations into one in cxxrtl, its main purpose is to squash overlapping masked memory initializations (when they land) and avoid having to deal with them in cxxrtl runtime.
* Add support for the Bitwuzla solverGCHQDeveloper5602021-07-121-5/+5
|
* kernel/mem: Use delayed removal for inits as well.Marcelina Kościelnicka2021-07-122-4/+20
|
* kernel/mem: Add documentation for more helper functions.Marcelina Kościelnicka2021-07-121-0/+34
|
* cxxrtl: Support memory writes in processes.Marcelina Kościelnicka2021-07-121-6/+55
|
* cxxrtl: Add support for memory read port reset.Marcelina Kościelnicka2021-07-121-1/+41
|
* cxxrtl: Add support for mem read port initial data.Marcelina Kościelnicka2021-07-121-4/+22
|
* cxxrtl: Convert to Mem helpers.Marcelina Kościelnicka2021-07-121-206/+276
| | | | | This *only* does conversion, but doesn't add any new functionality — support for memory read port init/reset is still upcoming.
* kernel/mem: Commit new values of attributes in emit.Marcelina Kościelnicka2021-07-121-0/+4
|
* kernel/mem: Make the Mem helpers inherit from AttrObject.Marcelina Kościelnicka2021-07-121-8/+4
|
* rtlil: Make Process handling more uniform with Cell and Wire.Marcelina Kościelnicka2021-07-128-25/+62
| | | | | | - add a backlink to module from Process - make constructor and destructor protected, expose Module functions to add and remove processes
* ice40: Fix LUT input indices in opt_lut -dlogic (again).Marcelina Kościelnicka2021-07-101-1/+1
| | | | Fixes #2061.
* Update to latest Verific with extensions for initial assertionsMiodrag Milanovic2021-07-092-15/+10
|