From 3f2c4f6f83b699c02fdad90aef8afdc0052531b4 Mon Sep 17 00:00:00 2001 From: Robert O'Callahan Date: Sun, 17 Aug 2025 23:34:11 +0000 Subject: [PATCH] Remove redundant construction of `assign_map`. We call 'assign_map.set()' below which wipes the `SigMap` and reconstructs it. This operation is expensive because it scans the whole module. I think it's better to make heavyweight operations more visible so I'm removing the less obvious operation. --- passes/opt/opt_merge.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/passes/opt/opt_merge.cc b/passes/opt/opt_merge.cc index b519d33d6..5ca19bc2f 100644 --- a/passes/opt/opt_merge.cc +++ b/passes/opt/opt_merge.cc @@ -227,7 +227,7 @@ struct OptMergeWorker } OptMergeWorker(RTLIL::Design *design, RTLIL::Module *module, bool mode_nomux, bool mode_share_all, bool mode_keepdc) : - design(design), module(module), assign_map(module), mode_share_all(mode_share_all) + design(design), module(module), mode_share_all(mode_share_all) { total_count = 0; ct.setup_internals();