diff options
Diffstat (limited to 'backends/blif')
-rw-r--r-- | backends/blif/blif.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/backends/blif/blif.cc b/backends/blif/blif.cc index 27f087746..f5a982760 100644 --- a/backends/blif/blif.cc +++ b/backends/blif/blif.cc @@ -293,6 +293,11 @@ struct BlifBackend : public Backend { } extra_args(f, filename, args, argidx); + if (top_module_name.empty()) + for (auto & mod_it:design->modules) + if (mod_it.second->get_bool_attribute("\\top")) + top_module_name = mod_it.first; + fprintf(f, "# Generated by %s\n", yosys_version_str); std::vector<RTLIL::Module*> mod_list; |