ecp5: Remove obsolete db entries, add Bel z-position
Signed-off-by: David Shah <davey1576@gmail.com>
This commit is contained in:
parent
3788bd26e6
commit
d0ed23d673
@ -56,6 +56,7 @@ NPNR_PACKED_STRUCT(struct BelWirePOD {
|
||||
NPNR_PACKED_STRUCT(struct BelInfoPOD {
|
||||
RelPtr<char> name;
|
||||
BelType type;
|
||||
int32_t z;
|
||||
int32_t num_bel_wires;
|
||||
RelPtr<BelWirePOD> bel_wires;
|
||||
});
|
||||
@ -85,10 +86,6 @@ NPNR_PACKED_STRUCT(struct WireInfoPOD {
|
||||
int32_t num_uphill, num_downhill;
|
||||
RelPtr<PipLocatorPOD> pips_uphill, pips_downhill;
|
||||
|
||||
int32_t num_bels_downhill;
|
||||
BelPortPOD bel_uphill;
|
||||
RelPtr<BelPortPOD> bels_downhill;
|
||||
|
||||
int32_t num_bel_pins;
|
||||
RelPtr<BelPortPOD> bel_pins;
|
||||
});
|
||||
|
@ -401,12 +401,6 @@ def write_database(dev_name, ddrg, endianness):
|
||||
for up in wire.arcsUphill:
|
||||
write_loc(up.rel, "rel_loc")
|
||||
bba.u32(up.id, "index")
|
||||
if len(wire.belsDownhill) > 0:
|
||||
bba.l("loc%d_wire%d_downbels" % (idx, wire_idx), "BelPortPOD")
|
||||
for db in wire.belsDownhill:
|
||||
write_loc(db.bel.rel, "rel_bel_loc")
|
||||
bba.u32(db.bel.id, "bel_index")
|
||||
bba.u32(portpins[ddrg.to_str(db.pin)], "port")
|
||||
if len(wire.belPins) > 0:
|
||||
bba.l("loc%d_wire%d_belpins" % (idx, wire_idx), "BelPortPOD")
|
||||
for bp in wire.belPins:
|
||||
@ -421,15 +415,6 @@ def write_database(dev_name, ddrg, endianness):
|
||||
bba.u32(len(wire.arcsDownhill), "num_downhill")
|
||||
bba.r("loc%d_wire%d_uppips" % (idx, wire_idx) if len(wire.arcsUphill) > 0 else None, "pips_uphill")
|
||||
bba.r("loc%d_wire%d_downpips" % (idx, wire_idx) if len(wire.arcsDownhill) > 0 else None, "pips_downhill")
|
||||
bba.u32(len(wire.belsDownhill), "num_bels_downhill")
|
||||
write_loc(wire.belUphill.bel.rel, "uphill_bel_loc")
|
||||
if wire.belUphill.pin != -1:
|
||||
bba.u32(wire.belUphill.bel.id, "uphill_bel_idx")
|
||||
bba.u32(portpins[ddrg.to_str(wire.belUphill.pin)], "uphill_bel_pin")
|
||||
else:
|
||||
bba.u32(0xFFFFFFFF, "bel_uphill.bel_index")
|
||||
bba.u32(0, "bel_uphill.port")
|
||||
bba.r("loc%d_wire%d_downbels" % (idx, wire_idx) if len(wire.belsDownhill) > 0 else None, "bels_downhill")
|
||||
bba.u32(len(wire.belPins), "num_bel_pins")
|
||||
bba.r("loc%d_wire%d_belpins" % (idx, wire_idx) if len(wire.belPins) > 0 else None, "bel_pins")
|
||||
|
||||
@ -447,6 +432,7 @@ def write_database(dev_name, ddrg, endianness):
|
||||
bel = loctype.bels[bel_idx]
|
||||
bba.s(ddrg.to_str(bel.name), "name")
|
||||
bba.u32(bel_types[ddrg.to_str(bel.type)], "type")
|
||||
bba.u32(bel.z, "z")
|
||||
bba.u32(len(bel.wires), "num_bel_wires")
|
||||
bba.r("loc%d_bel%d_wires" % (idx, bel_idx), "bel_wires")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user