Clean up `passes/techmap/hilomap.cc`.
authorAlberto Gonzalez <boqwxp@airmail.cc>
Thu, 9 Apr 2020 05:24:37 +0000 (05:24 +0000)
committerAlberto Gonzalez <boqwxp@airmail.cc>
Thu, 9 Apr 2020 05:28:32 +0000 (05:28 +0000)
passes/techmap/hilomap.cc

index 9ec651aefb2663907964dabd38309172f0f1912a..5aeb5ea79f21d484d3530a5722e8b9ae69d5534b 100644 (file)
@@ -105,13 +105,9 @@ struct HilomapPass : public Pass {
                }
                extra_args(args, argidx, design);
 
-               for (auto &it : design->modules_)
+               for (auto mod : design->selected_modules())
                {
-                       module = it.second;
-
-                       if (!design->selected(module))
-                               continue;
-
+                       module = mod;
                        last_hi = RTLIL::State::Sm;
                        last_lo = RTLIL::State::Sm;