From 086bcf06153ea820b27f84b70b36fba77a975404 Mon Sep 17 00:00:00 2001 From: Maciej Kurc Date: Fri, 19 Nov 2021 09:28:19 +0100 Subject: [PATCH] Added an option to control LUT and FF packing Signed-off-by: Maciej Kurc --- nexus/main.cc | 3 +++ nexus/pack.cc | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/nexus/main.cc b/nexus/main.cc index 6ffc9a20..83bb02d8 100644 --- a/nexus/main.cc +++ b/nexus/main.cc @@ -51,6 +51,7 @@ po::options_description NexusCommandHandler::getArchOptions() specific.add_options()("fasm", po::value(), "fasm file to write"); specific.add_options()("pdc", po::value(), "physical constraints file"); specific.add_options()("no-post-place-opt", "disable post-place repacking (debugging use only)"); + specific.add_options()("no-pack-lutff", "disable packing (clustering) LUTs and FFs together"); return specific; } @@ -76,6 +77,8 @@ std::unique_ptr NexusCommandHandler::createContext(dict(new Context(chipArgs)); if (vm.count("no-post-place-opt")) ctx->settings[ctx->id("no_post_place_opt")] = Property::State::S1; + if (vm.count("no-pack-lutff")) + ctx->settings[ctx->id("no_pack_lutff")] = Property::State::S1; return ctx; } diff --git a/nexus/pack.cc b/nexus/pack.cc index ba6033f9..a3dc7266 100644 --- a/nexus/pack.cc +++ b/nexus/pack.cc @@ -2395,7 +2395,11 @@ struct NexusPacker pack_luts(); pack_ip(); handle_iologic(); - pack_lutffs(); + + if (!bool_or_default(ctx->settings, ctx->id("no_pack_lutff"))) { + pack_lutffs(); + } + promote_globals(); place_globals(); generate_constraints();