Account for pre-existing `keep_hierarchy` in cost sum

This commit is contained in:
Martin Povišer 2024-12-03 11:11:59 +01:00
parent c33f7b92f7
commit 6ad4918121
1 changed files with 3 additions and 0 deletions

View File

@ -37,6 +37,9 @@ struct ThresholdHierarchyKeeping {
if (module->has_attribute(ID(gate_cost_equivalent)))
return module->attributes[ID(gate_cost_equivalent)].as_int();
if (module->has_attribute(ID(keep_hierarchy)))
return 0;
if (module->get_blackbox_attribute())
log_error("Missing cost information on instanced blackbox %s\n", log_id(module));