From f4a10a4808737db87b1de5fcbdb5e8638bf30197 Mon Sep 17 00:00:00 2001 From: "Emil J. Tywoniak" Date: Mon, 20 Apr 2026 16:52:53 +0200 Subject: [PATCH] clockgate: reject $sdffe for correct priority handling --- passes/techmap/clockgate.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/passes/techmap/clockgate.cc b/passes/techmap/clockgate.cc index b68e5d93d..650719cd5 100644 --- a/passes/techmap/clockgate.cc +++ b/passes/techmap/clockgate.cc @@ -337,6 +337,8 @@ struct ClockgatePass : public Pass { FfData ff(nullptr, cell); // It would be odd to get constants, but we better handle it if (ff.has_ce) { + if (ff.has_srst && !ff.ce_over_srst) + continue; if (!ff.sig_clk.is_bit() || !ff.sig_ce.is_bit()) continue; if (!ff.sig_clk[0].is_wire() || !ff.sig_ce[0].is_wire())