Apply suggestions from code review
authorEddie Hung <eddie@fpgeh.com>
Mon, 30 Mar 2020 15:19:56 +0000 (08:19 -0700)
committerGitHub <noreply@github.com>
Mon, 30 Mar 2020 15:19:56 +0000 (08:19 -0700)
Co-Authored-By: Alberto Gonzalez <61295559+boqwxp@users.noreply.github.com>
passes/memory/memory_share.cc
passes/opt/share.cc

index 236c3c99ccb71d18d5503d189fc0b508c899cf26..0111c23096ef53348b7bea713312150e2ddbe5a6 100644 (file)
@@ -665,9 +665,7 @@ struct MemoryShareWorker
        // Setup and run
        // -------------
 
-       MemoryShareWorker(RTLIL::Design *design) :
-                       design(design), modwalker(design)
-       {
+       MemoryShareWorker(RTLIL::Design *design) : design(design), modwalker(design) {}
        }
 
        void operator()(RTLIL::Module* module)
@@ -764,7 +762,6 @@ struct MemorySharePass : public Pass {
        void execute(std::vector<std::string> args, RTLIL::Design *design) YS_OVERRIDE {
                log_header(design, "Executing MEMORY_SHARE pass (consolidating $memrd/$memwr cells).\n");
                extra_args(args, 1, design);
-
                MemoryShareWorker msw(design);
 
                for (auto module : design->selected_modules())
index fd72c762bd564b28a79fb8e6f9b1b5e1c35e3058..ec2e110a8a1f0581bd8809f5a6c32ae71631cbe5 100644 (file)
@@ -1148,11 +1148,10 @@ struct ShareWorker
        #endif
 
                limit = config.limit;
-
                modwalker.setup(module);
 
                cells_to_remove.clear();
-               recursion_state.clear();;
+               recursion_state.clear();
                topo_cell_drivers.clear();
                topo_bit_drivers.clear();
                exclusive_ctrls.clear();