aboutsummaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorDavid Shah <davey1576@gmail.com>2018-07-30 16:59:30 +0200
committerDavid Shah <davey1576@gmail.com>2018-07-30 16:59:30 +0200
commitb09183db3bf5b08c1a1151e044f9df5f6dc445d8 (patch)
tree811784ef879ba5fa31616c8b29e6e84a9885f106 /common
parent66a5b99f02b41c415911a7f2e045d167699cd82f (diff)
downloadnextpnr-b09183db3bf5b08c1a1151e044f9df5f6dc445d8.tar.gz
nextpnr-b09183db3bf5b08c1a1151e044f9df5f6dc445d8.tar.bz2
nextpnr-b09183db3bf5b08c1a1151e044f9df5f6dc445d8.zip
Use DelayInfo for cell timing instead of delay_t
Signed-off-by: David Shah <davey1576@gmail.com>
Diffstat (limited to 'common')
-rw-r--r--common/timing.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/common/timing.cc b/common/timing.cc
index d91dea20..4486fc24 100644
--- a/common/timing.cc
+++ b/common/timing.cc
@@ -41,13 +41,13 @@ static delay_t follow_user_port(Context *ctx, PortRef &user, int path_length, de
// Follow outputs of the user
for (auto port : user.cell->ports) {
if (port.second.type == PORT_OUT) {
- delay_t comb_delay;
+ DelayInfo comb_delay;
// Look up delay through this path
bool is_path = ctx->getCellDelay(user.cell, user.port, port.first, comb_delay);
if (is_path) {
NetInfo *net = port.second.net;
if (net) {
- delay_t path_budget = follow_net(ctx, net, path_length, slack - comb_delay);
+ delay_t path_budget = follow_net(ctx, net, path_length, slack - comb_delay.maxDelay());
value = std::min(value, path_budget);
}
}
@@ -88,9 +88,9 @@ void assign_budget(Context *ctx)
IdString clock_domain = ctx->getPortClock(cell.second.get(), port.first);
if (clock_domain != IdString()) {
delay_t slack = delay_t(1.0e12 / ctx->target_freq); // TODO: clock constraints
- delay_t clkToQ;
+ DelayInfo clkToQ;
if (ctx->getCellDelay(cell.second.get(), clock_domain, port.first, clkToQ))
- slack -= clkToQ;
+ slack -= clkToQ.maxDelay();
if (port.second.net)
follow_net(ctx, port.second.net, 0, slack);
}