3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-07-27 06:27:57 +00:00
Commit graph

342 commits

Author SHA1 Message Date
Krystine Sherwin
92ab125113
cmdref: Assigning cmds to formal group
Give formal index a proper title.
Use `Pass::formatted_help()` to assign the group, but still return `false` because the help text still comes from `Pass::help()`.
Tidy up some of the affected files' includes to make use of the shared `yosys.h` includes.
2025-07-21 10:35:56 +12:00
Krystine Sherwin
37782cb92b
Docs: Grouping changes
Keep techlibs folder hierarchy.
techlibs/* and passes/* groups are now nested under index_techlibs and index_passes respectively, with most (all?) of the passes/* pages getting proper headings, as well as backends/frontends/kernel.  `index_passes_techmap` also references `index_techlibs`.
Split command reference toc in twain, one with maxdepth=2 and one with maxdepth=3, since passes and techlibs now have an extra level of nesting.
Move the `cmd_ref` link to the command reference, instead of top of the page.
Remove `index_internal` and `index_other` from the toc, and mark the pages as orphan. Internal commands get a note callout after the command reference toc (although this doesn't work for the pdf build), while other commands are linked in the warning for missing `source_location` (since that *should* be the only time when there are any commands in the "unknown" group).
Update autodoc extension versions, and mark the directives extension as not `parallel_read_safe` (it might be, but I'm not sure about how the xref lookups work if it is parallel so better to be safe).
2025-07-21 10:35:56 +12:00
Krystine Sherwin
0ec336ba23
Docs: Add :cmd:title: directive
Calling :cmd:title:`<cmd>` will generate a cross reference to `<cmd>`, but unlike :cmd:ref: which displays a literal block and puts the title (short_help) in the hovertext (the title field of an a-ref), :cmd:title: will display "<cmd> - <short_help>" as plain text.
Thus replacing the previous use case of referring to :doc:`cmd/<cmd>`.
Also refactor util py scripts to have more descriptive names.
2025-07-21 10:35:19 +12:00
Krystine Sherwin
14fdc9e76c
cmdref: Export internal_flag to json
Commands flagged as internal will display a warning, just like experimental commands.
Drop `passes/tests` group in favour of `internal` group, which is automatically assigned for any command without an assigned group which is flagged as internal.
2025-07-21 10:35:19 +12:00
Krystine Sherwin
c97b0084b7
Docs: Show warning on experimental cmds 2025-07-21 10:34:55 +12:00
Krystine Sherwin
33be999488
cmdref: Add cmd titles
Display subheadings for each command.
Remove now redundant toc entry for `yosys> help <cmd>` line.
2025-07-21 10:34:55 +12:00
Krystine Sherwin
7647d2c741
Docs: Fix warnings
Changes a bunch of :doc:`/cmd/*` to :cmd:ref:`*` with the intention of changing it later to something that replicates the previous effect of displaying the commands `short_help`.
2025-07-21 10:34:32 +12:00
Krystine Sherwin
6f0ee43152
Docs: Downgrade missing cmdgroup warning
Log an info message, and put a warning for the content instead.
2025-07-21 10:34:32 +12:00
Krystine Sherwin
929c437b26
Docs: Group commands
Removes group parsing from command ref domain, instead relying on a 'groups' object in the cmds.json file.
`docs/source/cmd` is no longer ignored or cleaned.
2025-07-21 10:34:13 +12:00
Krystine Sherwin
00b6d96aee
docs: Working cmdref groups
Also adds note on source location if available.
2025-07-21 10:34:13 +12:00
Krystine Sherwin
a19f0103ff
Docs: Update cmdref domain
Compatible with `dump_cmds_json`.
2025-07-21 10:34:12 +12:00
Krystine Sherwin
f5ace20bf6
Docs: Improve autoref
Fix `help $cell` type references, as well as actually implement the fallback to yoscrypt.
2025-07-21 10:33:31 +12:00
Krystine Sherwin
714790c70b
Docs: Proto doc_string approach for cmd help
Add `doc_string` field to `Pass` constructor
Add `docs/util/newcmdref.py` to contain command domain
Update `docs/util/cmdref.py` with `cmd:usage` and `cmd:optiongroup` for describing commands.
Functional, but WIP.
2025-07-21 10:33:31 +12:00
Martin Povišer
9ab1946799
Merge pull request #5209 from povik/hieropt
Start `opt_hier` to enable hierarchical optimization
2025-07-17 14:12:18 +02:00
KrystalDelusion
1a215719e5
Merge pull request #5192 from garytwong/multiline-string
verilog: support newline and hex escapes in string literals
2025-07-08 10:27:01 +12:00
Miodrag Milanovic
60f126cd00 Release version 0.55 2025-07-07 11:26:04 +02:00
Martin Povišer
62067cd6cb Update docs after addition of new pass 2025-07-05 16:45:52 +02:00
Gary Wong
5feb1a1752 verilog: add support for SystemVerilog string literals.
Differences are new escape sequences (including escaped newline
continuations and hex escapes) and triple-quoted literals.
2025-07-03 20:51:12 -06:00
KrystalDelusion
82888580ac
Merge pull request #5152 from garytwong/unique-if
verilog: implement SystemVerilog unique/unique0/priority if semantics.
2025-06-13 09:56:53 +12:00
Miodrag Milanovic
db72ec3bde Release version 0.54 2025-06-09 07:23:54 +02:00
Gary Wong
10bb0f472f docs: mention related effects for multiplexers in the cell library. 2025-05-30 21:43:33 -06:00
Gary Wong
62660b221f docs: restore and update the note about if/case attributes. 2025-05-30 21:18:09 -06:00
KrystalDelusion
06db8828b2
abc.rst: Clarify larger-but-slower 2025-05-31 09:10:27 +12:00
Gary Wong
7a9d727bd0 docs: several small documentation fixes. 2025-05-29 21:26:28 -06:00
Gary Wong
370d5871f4 verilog: implement SystemVerilog unique/unique0/priority if semantics.
There are two elements involved:

1) Apply the relevant full_case and/or parallel_case attribute(s) to
the generated AST_CASE node(s), so that the existing AST frontend and
subsequent passes will generate RTLIL with appropriate behaviour.
(This is handled in the parser "if_attr" non-terminal.)

2) Rearrange the AST_CASE structure when necessary.  For "priority if"
(i.e., full_case), this requires only ensuring that directly nested
"else if" branches also inherit the full_case attribute.  For
"unique if" and "unique0 if" (i.e., parallel_case+full_case and
parallel_case alone), there are two steps:
    a) Flatten the AST_CASE structure such that any direct "else if"
    branches are mapped to additional AST_CONDs in the parent;
    b) Reverse the "direction" of the test: the constant 1 (true)
    is provided in the AST_CASE node, and the expression(s) in the
    if statement(s) are given in each AST_COND.  This is necessary
    because the constant 1, being the common factor, must occupy the
    shared AST_CASE position.
(This is handled in the parser "TOK_IF" expansion of behavioral_stmt.)

Observe that:
 * The generated AST has not been changed for bare "if"s (those
 without unique/priority).  This should minimise the risk of
 unexpected regressions.

 * It is possible that the flattening described in 2) a) above might
 affect the behaviour of expressions with side effects in "unique if"
 statements (consider "unique if( a ) ...; else if( b++ ) ...": if
 a is true, is b incremented?).  While it might be possible to provide
 precise semantics here, IEEE 1800-2012 12.4.2 seems to be deliberately
 vague ("In unique-if and unique0-if, the conditions may be evaluated
 and compared in any order[...] The presence of side effects in
 conditions may cause nondeterministic results.") and so it seems
 doubtful that there is benefit in Yosys providing stronger promises
 on the interpretation of questionable code.
2025-05-29 20:45:57 -06:00
Gary Wong
9770ece187 Accept (and ignore) SystemVerilog unique/priority if.
Add support to the "read_verilog -sv" parser to validate the
"unique", "unique0", and "priority" keywords in contexts where
they're legal according to 1800-2012 12.4.2.

This affects only the grammar accepted; the behaviour of conditionals
is not changed.  (But accepting this syntax will provide scope for
possible optimisations as future work.)

Three test cases ("unique_if", "unique_if_else", and
"unique_if_else_begin") verify that the keywords are accepted where
legal and rejected where illegal, as described in the final paragraph
of 12.4.2.
2025-05-22 19:28:28 -06:00
Miodrag Milanovic
53c22ab7c0 Release version 0.53 2025-05-06 07:45:16 +02:00
Emily Schmidt
19845be85c reflow dft docs to 80 cols 2025-04-15 09:57:14 +01:00
Emily Schmidt
bfed96ad88 some fixes and rewordings of the dft docs 2025-04-15 09:57:14 +01:00
Emily Schmidt
ea6e5b3c48 add changes to dft docs suggested by Krystine 2025-04-15 09:57:14 +01:00
Emily Schmidt
30486079f9 add dft_tag documentation 2025-04-15 09:57:14 +01:00
N. Engelhardt
3410e10ed5
Merge pull request #5000 from YosysHQ/krys/re_refactor_selections 2025-04-10 16:06:36 +00:00
Emily Schmidt
32ec5a9ccd Revert "add dft_tag documentation"
This reverts commit 2443facc46.
2025-04-09 10:34:11 +01:00
Emily Schmidt
2443facc46 add dft_tag documentation 2025-04-09 10:18:25 +01:00
Miodrag Milanovic
fee39a3284 Release version 0.52 2025-04-09 07:38:42 +02:00
Krystine Sherwin
cd3b914132
Reinstate #4768
Revert the reversion so that we can fix the bugs that the PR missed.
2025-04-08 11:58:05 +12:00
Miodrag Milanović
d49364d96f
Revert "Refactor full_selection" 2025-04-07 12:11:55 +02:00
KrystalDelusion
98d4355b82
Merge pull request #4768 from YosysHQ/krys/refactor_selections
Refactor full_selection
2025-04-05 14:15:27 +13:00
KrystalDelusion
cce7aaedf7
Merge pull request #4939 from DanielG/rsync-fallback
mk: Fall back to cp if rsync is not available
2025-03-25 10:41:27 +13:00
KrystalDelusion
644efca341
Merge pull request #4953 from YosysHQ/krys/local_docs_fixes
A few fixes, mostly local docs builds
2025-03-25 10:36:18 +13:00
Daniel Gröber
2b67ad78bf mk: Fall back to cp if rsync is not available 2025-03-24 18:06:17 +01:00
Krystine Sherwin
39a1623ac0
Docs: Don't READTHEDOCS on local builds 2025-03-18 03:57:17 +13:00
Krystine Sherwin
8877817fa9
Fix Docs issues for offline pdf builds #4777
Drop svg badges.  Even though they were only appearing in the html version, the latexpdf target was still trying to download them, leading to warnings-as-errors in offline builds.
2025-03-15 12:14:09 +13:00
Scott Ashcroft
d8af6b0616 docs: Add latex magic to make PDFs reproducible again 2025-03-14 21:48:08 +01:00
Krystine Sherwin
dac2bb7d4d
Use selection helpers
Catch more uses of selection constructor without assigning a design.
2025-03-14 14:08:13 +13:00
Martin Povišer
6da543a61a
Merge pull request #4818 from povik/macc_v2
Add `$macc_v2`
2025-03-12 22:55:40 +01:00
Miodrag Milanovic
c4b5190229 Release version 0.51 2025-03-12 08:31:37 +01:00
N. Engelhardt
c74df780b7
Merge pull request #4884 from YosysHQ/docs-preview-functional_tutorial
Docs: More on FunctionalIR
2025-03-10 15:05:55 +00:00
Krystine Sherwin
c9785584da
docs/rosette: Fix tenses 2025-03-07 08:39:21 +13:00
Krystine Sherwin
b56e3ec6e4
docs/functional: Minimal backend paragraphs
I was thinking about compiling the dummy example and including a simple example usage, but it turns out functional.h isn't (currently) available for extensions.
2025-03-01 16:15:54 +13:00