3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2026-07-15 19:55:41 +00:00
Commit graph

5823 commits

Author SHA1 Message Date
Akash Levy
139caf991c opt_compact_prefix: scope per-sweep clean to module, warn on non-convergence
Address review feedback on the fixpoint loop:
- Scope the per-sweep cleanup to the module under rewrite via
  Pass::call_on_module(..., "clean -purge") instead of running clean over
  the whole design selection. This avoids O(N^2) work across modules and
  keeps untouched modules' dangling cells until their own sweep, matching
  the original single-call behavior.
- Emit a log_warning if a module fails to reach a fixpoint within
  max_sweeps, so silent truncation of compaction is visible.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-24 23:52:30 -07:00
Akash Levy
da947b72d8 opt_compact_prefix fix 3 2026-06-24 22:40:21 -07:00
Akash Levy
9bfe32bffc Reduce port resize to warning 2026-06-24 17:21:38 -07:00
Mohamed Gaber
0e7671c1b3 Merge remote-tracking branch 'origin/main' into update_from_upstream 2026-06-21 15:07:32 +03:00
Akash Levy
8cdbd62394 opt_first_fit_alloc: address Greptile review
- pack_lanes: assert elem_w < 32 and pack the full element width instead
  of silently dropping bits >= 31.
- Remove the dead `cell` struct member and its unused assignment in run()
  (every emit helper shadows it with its own local `cell`).
- Decorrelate the pseudo-random bc bits from en (independent mix) so they
  no longer share an LFSR bit (e.g. en[7]/bc[0] for n=8).
- Add purpose comments to fingerprint_dsel and lane_of_bit.

Declined the std::stoi/std::stoll arg-parsing suggestion: it matches the
established convention in sibling passes (opt_argmax, opt_priority_onehot).

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-21 01:21:06 -07:00
Akash Levy
dc995eba98 opt_first_fit_alloc 2026-06-21 00:56:39 -07:00
Mohamed Gaber
4db5fe5f6d
Merge remote-tracking branch 'silimate/main' into update_from_upstream 2026-06-19 00:07:08 +03:00
Akash Levy
fe9689eaaf Small update 2026-06-18 05:26:28 -07:00
Akash Levy
db7cfd404d Fix cut_region.h debug 2026-06-18 04:02:52 -07:00
Akash Levy
9df378f8ac opt_carry_select pass 2026-06-18 02:36:29 -07:00
Mohamed Gaber
a4042f69b1
passes/silimate: remove leftover Makefile.inc 2026-06-17 21:14:44 +03:00
Mohamed Gaber
98a1db2756
equiv_opt: support -ignore-unknown-cells 2026-06-17 21:10:02 +03:00
Mohamed Gaber
8267cf87b5
infer_ce: remove pass 2026-06-17 21:01:20 +03:00
Mohamed Gaber
bd7c32f8a6
CMake: Linux fixes + Merge fallout fix 2026-06-16 19:32:45 +03:00
Mohamed Gaber
1d94aa6965
misc: fix unused variable in new main branch merge 2026-06-16 02:14:27 +03:00
Mohamed Gaber
569ab1231b
Merge remote-tracking branch 'silimate/main' into update_from_upstream 2026-06-16 02:02:41 +03:00
Akash Levy
23b021a26b Fix opt_compact_prefix wide packs and opt_priority_onehot max-width test
The tests/silimate suite (which aborted the Run tests CI job) exposed two
issues in the generalized passes:

- opt_compact_prefix: the forward dense pack regressions at 64 and 128 bits
  no longer rewrote. The ConstEval fingerprint was uint64_t-based (capped at
  62 bits) and the per-cone cell cap (max_width*96) was below the O(width^2)
  cell count of a wide pack. The fingerprint now drives whole-width Const
  bit patterns (no width cap) and the cone cap scales quadratically; total
  work stays bounded by the shared walk/eval budgets.

- opt_priority_onehot: the "max-width below lane count" negative test set
  max_width=8 on a 16-lane design expecting no rewrite, but the generalized
  matcher legitimately (and equivalence-provably) rewrites the 8-lane
  sub-region. The test now uses max_width=3 (below min_width 4) to verify
  the width gate suppresses all matching.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-15 12:02:09 -07:00
Akash Levy
1cc985314a Cleanup 2026-06-15 09:09:27 -07:00
Akash Levy
83baed6731 Generalize and refactor opt_* passes of Silimate 2026-06-12 16:31:41 -07:00
Mohamed Gaber
0217efb67d
Merge remote-tracking branch 'silimate/main' into update_from_upstream 2026-06-10 20:33:33 +03:00
Mohamed Gaber
d986ee91ac
CMake: integrate silimate additions and extensions
- update CMakeLists.txt to load two new files:
  - SilimateConfig.cmake: sets Silimate configuration options and defaults
  - SilimateVerific.cmake: compiles Verific library, optionally with Silimate modifications
- include silimate tests in test Makefile
2026-06-10 20:27:52 +03:00
Akash Levy
3743c4795a opt_priority_onehot 2026-06-09 22:18:20 -07:00
Akash Levy
faea2d904a Make opt_compact_prefix match more 2026-06-09 10:55:10 -07:00
Mohamed Gaber
e58125b605
Merge remote-tracking branch 'upstream/main' into silimate 2026-06-09 16:22:51 +03:00
Akash Levy
b60d2daa41
Merge pull request #183 from Silimate/opt_argmax_fix1
opt_argmax fixes
2026-06-09 02:54:05 -07:00
Akash Levy
4a35c0ab87 opt_argmax fixes 2026-06-09 01:57:11 -07:00
Akash Levy
30c510041a Fix opt_compact_prefix up 2026-06-09 00:34:13 -07:00
Akash Levy
28455c01e4 Support cell_footprint as indicator of stdcell 2026-06-04 00:40:38 -07:00
Miodrag Milanović
693d5a7eb0
Merge pull request #5903 from YosysHQ/krys/verific_memsize
verific: Fix non-contiguous memory flattening producing out of bounds accesses in some cases
2026-06-04 05:43:04 +00:00
Miodrag Milanovic
a599999d1f Fixed warnings found by gcc-16 2026-06-03 13:09:38 +02:00
Catherine
afc0e78d11 Update top-level Python project for CMake compatibility.
This commit reimplements the (no longer recommended) setuptools based
build system using a standards-based in-tree PEP517 build backend.
The implementation is partially based on
  https://codeberg.org/ziglang/zig-pypi/src/branch/main/make_wheels.py
which is licensed under BSD-0-clause.

It also adds a new option `YOSYS_BUILD_PYTHON_ONLY` that is available
only if the binary or the library aren't going to be installed, which
turns off these targets entirely, as well as some dependent ones
(e.g. tests).

Co-authored-by: Mohamed Gaber <me@donn.website>
2026-06-03 09:03:23 +00:00
Catherine
a727e7f6e7 Migrate build system to CMake
See #5895 for details.

This commit does not include CI or documentation changes.
2026-06-03 08:58:10 +00:00
Stan Lee
09b2bdfb27 better comment 2026-06-02 15:45:52 -07:00
Stan Lee
96ee0f6ec5 Merge branch 'main' of github.com:silimate/yosys into annotate_ff_width 2026-06-02 15:20:18 -07:00
Stan Lee
6b7e5e2685 update annotate_ff_width pass 2026-06-02 15:17:55 -07:00
Akash Levy
b3ea5770cd opt_argmax pass 2026-06-02 04:11:17 -07:00
Akash Levy
c7b2c16405
Merge pull request #179 from Silimate/opt_compact_prefix
Add opt_compact_prefix pass
2026-06-02 02:14:37 -07:00
Akash Levy
24b75b65db Fix UB issue 2026-06-02 01:18:29 -07:00
Akash Levy
950cdf925c
Update passes/silimate/opt_compact_prefix.cc
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-06-02 01:15:18 -07:00
Akash Levy
e03c54c695
Merge pull request #178 from Silimate/opt_balance_tree_improve1
Improvement to opt_balance_tree
2026-06-02 01:03:20 -07:00
Akash Levy
a730032f5f Add opt_compact_prefix pass 2026-06-01 23:00:33 -07:00
Stan Lee
3d8f4999d6 selected cells and modules 2026-06-01 19:20:47 -07:00
Akash Levy
0c3446e8af Fixups for Greptile 2026-06-01 19:03:52 -07:00
Akash Levy
9cc69a3c49 Improvement to opt_balance_tree 2026-06-01 17:56:44 -07:00
Stan Lee
1b707c61f7 necessary clock gate pass modifications 2026-06-01 17:19:23 -07:00
Stan Lee
483b1536d7 update pass 2026-06-01 17:10:18 -07:00
Stan Lee
e3134c6692 annotate_ff_width pass 2026-06-01 16:35:30 -07:00
Philippe Sauter
c89cfe1e6e peepopt: add shiftpow2 pattern
Rewrite power-of-two indexed word selects to $bmux when the shift
amount already carries the scale as low zero bits.

Keep the rule to non-overlapping selections and bound the generated
mux ways. Add regressions for aligned shifts, padding, signed
extension, and shiftmul handoff cases.
2026-05-31 02:01:32 +02:00
Krystine Sherwin
f6327cc444
check_mem: Add -non-const option
Can identify potentially dangerous addressing, but also prone to false-positives.
2026-05-29 18:40:24 +12:00
Krystine Sherwin
07e3d648aa
Add check_mem command
Comes with a set of tests which (currently) pass with `read_verilog` but fail with `verific` based on #5878.
Add `--check-sv`, an alternative to `--prove-sv` with generator defined yosys commands.  Helpful for when you want to run the same set of commands on a bunch of sv files.
2026-05-29 18:40:23 +12:00