mirror of
https://github.com/YosysHQ/yosys
synced 2026-07-17 20:55:45 +00:00
Extend two existing opt passes and add one new pass to collapse serial/dynamic-index structures that were leaving high logic depth: - opt_first_fit_alloc: recognize the "coalesce-matrix" first-fit allocator variant (same_cat[i][k] coalescing gated on the leader's enable, driven from a raw input enable). Rewrite both the lane_slot allocation and the xbar field gather from one shared log-depth scan. - opt_prienc: detect round-robin / rotated-priority scans (req scanned from idx_last downward with wraparound) and rewrite the depth-N idx--/req[idx] mux chain to rotate -> log-depth priority-encode -> unrotate. - opt_priokey (new): recognize priority-by-key one-hot accumulators and replace each dynamic taken[key] read ($shiftx/$bmux) with the equivalent pairwise-key-compare reduction, dropping the wide dynamic indexing. Supports -strict for full-key-range formal validation. Each includes self-contained tests (equiv_opt / sat -prove-asserts, mux-bound and negative cases) in tests/opt/. Co-authored-by: Cursor <cursoragent@cursor.com> |
||
|---|---|---|
| .. | ||
| opt_clean | ||
| CMakeLists.txt | ||
| cut_region.h | ||
| muxpack.cc | ||
| opt.cc | ||
| opt_addcin.cc | ||
| opt_andor_pmux.cc | ||
| opt_argmax.cc | ||
| opt_balance_tree.cc | ||
| opt_demorgan.cc | ||
| opt_dff.cc | ||
| opt_expr.cc | ||
| opt_ffinv.cc | ||
| opt_first_fit_alloc.cc | ||
| opt_hier.cc | ||
| opt_lut.cc | ||
| opt_lut_ins.cc | ||
| opt_mem.cc | ||
| opt_mem_feedback.cc | ||
| opt_mem_priority.cc | ||
| opt_mem_widen.cc | ||
| opt_merge.cc | ||
| opt_muxtree.cc | ||
| opt_parallel_prefix.cc | ||
| opt_prienc.cc | ||
| opt_priokey.cc | ||
| opt_priority_onehot.cc | ||
| opt_reduce.cc | ||
| opt_share.cc | ||
| peepopt.cc | ||
| peepopt_addsub_c.pmg | ||
| peepopt_formal_clockgateff.pmg | ||
| peepopt_modshr_onehot.pmg | ||
| peepopt_muldiv.pmg | ||
| peepopt_muldiv_c.pmg | ||
| peepopt_muxorder.pmg | ||
| peepopt_shiftadd.pmg | ||
| peepopt_shiftmul_left.pmg | ||
| peepopt_shiftmul_right.pmg | ||
| peepopt_shiftpow2.pmg | ||
| peepopt_sub_neg.pmg | ||
| pmux2shiftx.cc | ||
| rmports.cc | ||
| share.cc | ||
| wreduce.cc | ||