diff options
-rw-r--r-- | generic/archdefs.h | 8 | ||||
-rw-r--r-- | ice40/pack.cc | 4 |
2 files changed, 10 insertions, 2 deletions
diff --git a/generic/archdefs.h b/generic/archdefs.h index f5999776..06d4ec6e 100644 --- a/generic/archdefs.h +++ b/generic/archdefs.h @@ -52,7 +52,11 @@ typedef IdString PipId; typedef IdString GroupId; typedef IdString DecalId; -struct ArchNetInfo { }; -struct ArchCellInfo { }; +struct ArchNetInfo +{ +}; +struct ArchCellInfo +{ +}; NEXTPNR_NAMESPACE_END diff --git a/ice40/pack.cc b/ice40/pack.cc index 78df00f6..7e2e389c 100644 --- a/ice40/pack.cc +++ b/ice40/pack.cc @@ -307,6 +307,10 @@ static void set_net_constant(const Context *ctx, NetInfo *orig, NetInfo *constne if ((is_lut(ctx, uc) || is_lc(ctx, uc) || is_carry(ctx, uc)) && (user.port.str(ctx).at(0) == 'I') && !constval) { uc->ports[user.port].net = nullptr; + } else if ((is_sb_mac16(ctx, uc) || uc->type == ctx->id("ICESTORM_DSP")) && + (user.port != ctx->id("CLK") && + ((constval && user.port == ctx->id("CE")) || (!constval && user.port != ctx->id("CE"))))) { + uc->ports[user.port].net = nullptr; } else { uc->ports[user.port].net = constnet; constnet->users.push_back(user); |