aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorgatecat <gatecat@ds0.me>2021-04-15 10:14:19 +0100
committerGitHub <noreply@github.com>2021-04-15 10:14:19 +0100
commit1631cdffb8a5a84d86669a286bdf32c9714d631d (patch)
treec7445be1c2652c6002680b2bede0804b40b9f7a8
parent8f5185c3814f5fcf90aa33b07b99568d465bb5cd (diff)
parentd14db5c98f98659746ff89f61d68eeee1cc9d84c (diff)
downloadnextpnr-1631cdffb8a5a84d86669a286bdf32c9714d631d.tar.gz
nextpnr-1631cdffb8a5a84d86669a286bdf32c9714d631d.tar.bz2
nextpnr-1631cdffb8a5a84d86669a286bdf32c9714d631d.zip
Merge pull request #680 from YosysHQ/gatecat/fix-util
Fix utilisation report when bel buckets are used
-rw-r--r--common/design_utils.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/common/design_utils.cc b/common/design_utils.cc
index b81449b7..7eaffdc3 100644
--- a/common/design_utils.cc
+++ b/common/design_utils.cc
@@ -67,12 +67,12 @@ void print_utilisation(const Context *ctx)
// Sort by Bel type
std::map<IdString, int> used_types;
for (auto &cell : ctx->cells) {
- used_types[cell.second.get()->type]++;
+ used_types[ctx->getBelBucketName(ctx->getBelBucketForCellType(cell.second.get()->type))]++;
}
std::map<IdString, int> available_types;
for (auto bel : ctx->getBels()) {
if (!ctx->getBelHidden(bel)) {
- available_types[ctx->getBelType(bel)]++;
+ available_types[ctx->getBelBucketName(ctx->getBelBucketForBel(bel))]++;
}
}
log_break();