From 5c47b6034efd3898b666a18dd81cf4ae633a18c1 Mon Sep 17 00:00:00 2001 From: Miodrag Milanovic Date: Sun, 2 Jun 2019 09:13:19 +0200 Subject: added no-place and no-route options --- common/command.cc | 34 ++++++++++++++++++++++------------ 1 file changed, 22 insertions(+), 12 deletions(-) (limited to 'common') diff --git a/common/command.cc b/common/command.cc index e7ffef93..dc83f84d 100644 --- a/common/command.cc +++ b/common/command.cc @@ -137,6 +137,8 @@ po::options_description CommandHandler::getGeneralOptions() general.add_options()("placer-budgets", "use budget rather than criticality in placer timing weights"); general.add_options()("pack-only", "pack design only without placement or routing"); + general.add_options()("no-route", "process design without routing"); + general.add_options()("no-place", "process design without placement"); general.add_options()("ignore-loops", "ignore combinational loops in timing analysis"); @@ -282,25 +284,33 @@ int CommandHandler::executeMain(std::unique_ptr ctx) execute_python_file(filename.c_str()); } else #endif - if (vm.count("json") || vm.count("load")) { - run_script_hook("pre-pack"); - if (!ctx->pack() && !ctx->force) - log_error("Packing design failed.\n"); - assign_budget(ctx.get()); - ctx->check(); - print_utilisation(ctx.get()); - run_script_hook("pre-place"); - - if (!vm.count("pack-only")) { + if (vm.count("json") || vm.count("load")) { + bool do_pack = true; + bool do_place = vm.count("pack-only")==0 && vm.count("no-place")==0; + bool do_route = vm.count("pack-only")==0 && vm.count("no-route")==0; + + if (do_pack) { + run_script_hook("pre-pack"); + if (!ctx->pack() && !ctx->force) + log_error("Packing design failed.\n"); + assign_budget(ctx.get()); + ctx->check(); + print_utilisation(ctx.get()); + } + + if (do_place) { + run_script_hook("pre-place"); if (!ctx->place() && !ctx->force) log_error("Placing design failed.\n"); ctx->check(); - run_script_hook("pre-route"); + } + if (do_route) { + run_script_hook("pre-route"); if (!ctx->route() && !ctx->force) log_error("Routing design failed.\n"); + run_script_hook("post-route"); } - run_script_hook("post-route"); customBitstream(ctx.get()); } -- cgit v1.2.3