diff options
author | myrtle <gatecat@ds0.me> | 2022-09-24 10:30:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-24 10:30:30 +0200 |
commit | f0f9070adb41eea3eeed5679898c88bd12a51578 (patch) | |
tree | 45e03241c72359d1e3d0f0dd7dd59a14beba7f18 | |
parent | f4e6bbd383f6c434c3285fafeb6f73d77fa4f613 (diff) | |
parent | 9572f6f03222188915633f0ab32de6d11a9a7622 (diff) | |
download | nextpnr-f0f9070adb41eea3eeed5679898c88bd12a51578.tar.gz nextpnr-f0f9070adb41eea3eeed5679898c88bd12a51578.tar.bz2 nextpnr-f0f9070adb41eea3eeed5679898c88bd12a51578.zip |
Merge pull request #1029 from airskywater/airskywater-patch-1
Fix runtime segmentation fault
-rw-r--r-- | common/kernel/timing.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/common/kernel/timing.cc b/common/kernel/timing.cc index df0c3b5e..f046ba7d 100644 --- a/common/kernel/timing.cc +++ b/common/kernel/timing.cc @@ -299,7 +299,10 @@ void TimingAnalyser::identify_related_domains() std::function<void(const NetInfo *, dict<IdString, delay_t> &, delay_t)> find_net_drivers = [&](const NetInfo *ni, dict<IdString, delay_t> &drivers, delay_t delay_acc) { // Get driving cell and port + if (ni == nullptr) return; const CellInfo *cell = ni->driver.cell; + if (cell == nullptr) return; + const IdString port = ni->driver.port; bool didGoUpstream = false; @@ -360,6 +363,9 @@ void TimingAnalyser::identify_related_domains() for (const auto &domain : domains) { const NetInfo *ni = ctx->nets.at(domain.key.clock).get(); + if (ni == nullptr) continue; + if (ni->driver.cell == nullptr) continue; + dict<IdString, delay_t> drivers; find_net_drivers(ni, drivers, 0); |