aboutsummaryrefslogtreecommitdiffstats
path: root/ice40/arch.h
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2018-08-03 21:11:12 +0200
committerClifford Wolf <clifford@clifford.at>2018-08-03 21:11:12 +0200
commit8d372b86f3aed86c7a8ef7869e92335bd965c2ae (patch)
treea87fd652e903368fba8f79ae5614bdc342bb51a1 /ice40/arch.h
parent2a1d54389f1bcba51482daa43841436e1b854912 (diff)
downloadnextpnr-8d372b86f3aed86c7a8ef7869e92335bd965c2ae.tar.gz
nextpnr-8d372b86f3aed86c7a8ef7869e92335bd965c2ae.tar.bz2
nextpnr-8d372b86f3aed86c7a8ef7869e92335bd965c2ae.zip
Proper ice40 wire types
Signed-off-by: Clifford Wolf <clifford@clifford.at>
Diffstat (limited to 'ice40/arch.h')
-rw-r--r--ice40/arch.h21
1 files changed, 20 insertions, 1 deletions
diff --git a/ice40/arch.h b/ice40/arch.h
index 4a5157bd..50905098 100644
--- a/ice40/arch.h
+++ b/ice40/arch.h
@@ -88,6 +88,25 @@ NPNR_PACKED_STRUCT(struct WireSegmentPOD {
});
NPNR_PACKED_STRUCT(struct WireInfoPOD {
+ enum WireType : int8_t
+ {
+ WIRE_TYPE_NONE = 0,
+ WIRE_TYPE_GLB2LOCAL = 1,
+ WIRE_TYPE_GLB_NETWK = 2,
+ WIRE_TYPE_LOCAL = 3,
+ WIRE_TYPE_LUTFF_IN = 4,
+ WIRE_TYPE_LUTFF_IN_LUT = 5,
+ WIRE_TYPE_LUTFF_LOUT = 6,
+ WIRE_TYPE_LUTFF_OUT = 7,
+ WIRE_TYPE_LUTFF_COUT = 8,
+ WIRE_TYPE_LUTFF_GLOBAL = 9,
+ WIRE_TYPE_CARRY_IN_MUX = 10,
+ WIRE_TYPE_SP4_V = 11,
+ WIRE_TYPE_SP4_H = 12,
+ WIRE_TYPE_SP12_V = 13,
+ WIRE_TYPE_SP12_H = 14
+ };
+
RelPtr<char> name;
int32_t num_uphill, num_downhill;
RelPtr<int32_t> pips_uphill, pips_downhill;
@@ -503,7 +522,7 @@ struct Arch : BaseCtx
return id(chip_info->wire_data[wire.index].name.get());
}
- IdString getWireType(WireId wire) const { return IdString(); }
+ IdString getWireType(WireId wire) const;
uint32_t getWireChecksum(WireId wire) const { return wire.index; }