diff --git a/kernel/rtlil_bufnorm.cc b/kernel/rtlil_bufnorm.cc index 0744a1361..f2042f361 100644 --- a/kernel/rtlil_bufnorm.cc +++ b/kernel/rtlil_bufnorm.cc @@ -326,6 +326,13 @@ void RTLIL::Design::sigNormalize(bool enable) wire->driverCell_ = nullptr; wire->driverPort_ = IdString(); } + + // TODO inefficient? + std::vector cells_snapshot = module->cells(); + for (auto cell : cells_snapshot) { + if (cell->type == ID($input_port)) + module->remove(cell); + } } flagSigNormalized = false;