aboutsummaryrefslogtreecommitdiffstats
path: root/icetime
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2016-05-16 15:18:25 +0200
committerClifford Wolf <clifford@clifford.at>2016-05-16 15:18:25 +0200
commit4fbc8d20b65952eeef64a2e4c54b9b0ddfb7de07 (patch)
tree86b6b02885932d613bd6ad811c4ad358c48c1246 /icetime
parent1b7253ade29f89657a0f78d3b3659bc52ad0bac0 (diff)
downloadicestorm-4fbc8d20b65952eeef64a2e4c54b9b0ddfb7de07.tar.gz
icestorm-4fbc8d20b65952eeef64a2e4c54b9b0ddfb7de07.tar.bz2
icestorm-4fbc8d20b65952eeef64a2e4c54b9b0ddfb7de07.zip
Bugfix for when e.g. PLL LOCK drives longest path
Diffstat (limited to 'icetime')
-rw-r--r--icetime/icetime.cc22
1 files changed, 13 insertions, 9 deletions
diff --git a/icetime/icetime.cc b/icetime/icetime.cc
index e77b1a8..2ba3158 100644
--- a/icetime/icetime.cc
+++ b/icetime/icetime.cc
@@ -860,19 +860,23 @@ struct TimingAnalysis
net_sym.clear();
}
- auto &driver_cell = net_driver.at(n).first;
- auto &driver_port = net_driver.at(n).second;
- auto &driver_type = netlist_cell_types.at(driver_cell);
- std::string netprop = outnetsym == n ? "" : stringf("\"net\": \"%s\", ", outnetsym.c_str());
- json_lines.push_back(stringf(" { %s\"hwnet\": \"%s\", \"cell\": \"%s\", \"cell_type\": \"%s\", \"cell_in_port\": \"[clk]\", \"cell_out_port\": \"%s\", \"delay_ns\": %.3f },",
- netprop.c_str(), n.c_str(), driver_cell.c_str(), driver_type.c_str(), driver_port.c_str(), calc_net_max_path_delay(n)));
- rpt_lines.push_back(stringf(" %s (%s) [clk] -> %s: %.3f ns", driver_cell.c_str(),
- driver_type.c_str(), driver_port.c_str(), calc_net_max_path_delay(n)));
+ if (net_driver.count(n)) {
+ auto &driver_cell = net_driver.at(n).first;
+ auto &driver_port = net_driver.at(n).second;
+ auto &driver_type = netlist_cell_types.at(driver_cell);
+ std::string netprop = outnetsym == n ? "" : stringf("\"net\": \"%s\", ", outnetsym.c_str());
+ json_lines.push_back(stringf(" { %s\"hwnet\": \"%s\", \"cell\": \"%s\", \"cell_type\": \"%s\", \"cell_in_port\": \"[clk]\", \"cell_out_port\": \"%s\", \"delay_ns\": %.3f },",
+ netprop.c_str(), n.c_str(), driver_cell.c_str(), driver_type.c_str(), driver_port.c_str(), calc_net_max_path_delay(n)));
+ rpt_lines.push_back(stringf(" %s (%s) [clk] -> %s: %.3f ns", driver_cell.c_str(),
+ driver_type.c_str(), driver_port.c_str(), calc_net_max_path_delay(n)));
+ } else {
+ rpt_lines.push_back(stringf(" no driver model at %s", n.c_str()));
+ }
break;
}
if (visited_nets.count(n)) {
- rpt_lines.push_back(stringf("loop-start at %s", n.c_str()));
+ rpt_lines.push_back(stringf(" loop-start at %s", n.c_str()));
break;
}