diff options
author | David Shah <davey1576@gmail.com> | 2018-11-28 07:43:00 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-28 07:43:00 +0000 |
commit | 7a2ef27d6c27425bc39ef3a71b0df8b1c608d599 (patch) | |
tree | 0c8835c5fd78f37954094fb4772c566e4cbe5e1f /ice40/pack.cc | |
parent | e99e2f15701a761049a600e37b9e30482de44534 (diff) | |
parent | 80f7ef4b4b5a632e73c077da5810b218969132bc (diff) | |
download | nextpnr-7a2ef27d6c27425bc39ef3a71b0df8b1c608d599.tar.gz nextpnr-7a2ef27d6c27425bc39ef3a71b0df8b1c608d599.tar.bz2 nextpnr-7a2ef27d6c27425bc39ef3a71b0df8b1c608d599.zip |
Merge pull request #153 from YosysHQ/global-options
ice40: Finer-grained control of global promotion
Diffstat (limited to 'ice40/pack.cc')
-rw-r--r-- | ice40/pack.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ice40/pack.cc b/ice40/pack.cc index fc28121e..60464230 100644 --- a/ice40/pack.cc +++ b/ice40/pack.cc @@ -637,7 +637,8 @@ static void promote_globals(Context *ctx) }); if (global_clock->second == 0 && prom_logics < 4 && global_logic->second > logic_fanout_thresh && (global_logic->second > global_cen->second || prom_cens >= cens_available) && - (global_logic->second > global_reset->second || prom_resets >= resets_available)) { + (global_logic->second > global_reset->second || prom_resets >= resets_available) && + bool_or_default(ctx->settings, ctx->id("promote_logic"), false)) { NetInfo *logicnet = ctx->nets[global_logic->first].get(); insert_global(ctx, logicnet, false, false, true); ++prom_globals; @@ -1119,7 +1120,8 @@ bool Arch::pack() pack_carries(ctx); pack_ram(ctx); pack_special(ctx); - promote_globals(ctx); + if (!bool_or_default(ctx->settings, ctx->id("no_promote_globals"), false)) + promote_globals(ctx); ctx->assignArchInfo(); constrain_chains(ctx); ctx->assignArchInfo(); |