diff options
author | Eddie Hung <eddie.hung+gitlab@gmail.com> | 2018-07-21 20:08:53 +0000 |
---|---|---|
committer | Eddie Hung <eddie.hung+gitlab@gmail.com> | 2018-07-21 20:08:53 +0000 |
commit | eeb93d6eda613c0946867118c1ff93f2462e417f (patch) | |
tree | ee25b6376879c7add61b02a73a882d8518353afe /common/timing.cc | |
parent | 1f6897733b57f03cf7f5ccab46c27de811d42167 (diff) | |
parent | 926c186ec78efb086364a05ba7e83e68fa116301 (diff) | |
download | nextpnr-eeb93d6eda613c0946867118c1ff93f2462e417f.tar.gz nextpnr-eeb93d6eda613c0946867118c1ff93f2462e417f.tar.bz2 nextpnr-eeb93d6eda613c0946867118c1ff93f2462e417f.zip |
Merge branch 'redist_slack' into 'redist_slack'
Redist slack
See merge request SymbioticEDA/nextpnr!14
Diffstat (limited to 'common/timing.cc')
-rw-r--r-- | common/timing.cc | 30 |
1 files changed, 14 insertions, 16 deletions
diff --git a/common/timing.cc b/common/timing.cc index 5f744621..9723550b 100644 --- a/common/timing.cc +++ b/common/timing.cc @@ -215,24 +215,22 @@ void update_budget(Context *ctx) auto pi = &user.cell->ports.at(user.port); auto it = updates.find(pi); if (it == updates.end()) continue; - user.budget = delays.at(pi) + it->second; - - // HACK HACK HACK - if (net.second->driver.port == ctx->id("COUT")) - user.budget = 0; - // HACK HACK HACK + auto budget = delays.at(pi) + it->second; + user.budget = ctx->getBudgetOverride(net.second->driver, budget); // Post-update check -// if (user.budget < 0) -// log_warning("port %s.%s, connected to net '%s', has negative " -// "timing budget of %fns\n", -// user.cell->name.c_str(ctx), user.port.c_str(ctx), net.first.c_str(ctx), -// ctx->getDelayNS(user.budget)); -// if (ctx->verbose) -// log_info("port %s.%s, connected to net '%s', has " -// "timing budget of %fns\n", -// user.cell->name.c_str(ctx), user.port.c_str(ctx), net.first.c_str(ctx), -// ctx->getDelayNS(user.budget)); + if (ctx->verbose) { + if (user.budget < 0) + log_warning("port %s.%s, connected to net '%s', has negative " + "timing budget of %fns\n", + user.cell->name.c_str(ctx), user.port.c_str(ctx), net.first.c_str(ctx), + ctx->getDelayNS(user.budget)); + else + log_info("port %s.%s, connected to net '%s', has " + "timing budget of %fns\n", + user.cell->name.c_str(ctx), user.port.c_str(ctx), net.first.c_str(ctx), + ctx->getDelayNS(user.budget)); + } } } } |