Skip to content

ice40: Maybe a connection is missing in carry_passout in the generated netlist #1605

@tarikgraba

Description

@tarikgraba

Hi,

We have sometimes issue simulating ice40 post-pr netlists generated by nextpnr (while correctly behaving on the device).

We have tried to track the issue and I think it is related to the way carry cells and lut are packed in logic cells when both the carry and lut output are used.

More precisely, we found that adding a connection between the I3 input and the CIN input here:

// If COUT also connects to a CIN; preserve the carry chain

solves the issues for me.

Something like:

         // If COUT also connects to a CIN; preserve the carry chain
         if (cin_cell) {
+            lc->connectPort(id_CIN, co_i3_net);
             NetInfo *co_cin_net = ctx->createNet(ctx->id(lc->name.str(ctx) + "$COUT"));
 
             // Connect I1 to 1 to preserve carry chain

Maybe someone with better knowledge of ICE40 arch and nextpnr internals can take a look at this/give us some hints.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions