diff options
author | YRabbit <rabbit@yrabbit.cyou> | 2021-11-04 18:55:00 +1000 |
---|---|---|
committer | YRabbit <rabbit@yrabbit.cyou> | 2021-11-04 18:55:00 +1000 |
commit | 0e8a2999bda012175c1734abbf4efb76b515746c (patch) | |
tree | c7935473f948d1659ee255094caea8fa89b89aad /gowin/arch.h | |
parent | 06d58e6eed90aa9c2d16d0fe6286ec59a2f880a2 (diff) | |
download | nextpnr-0e8a2999bda012175c1734abbf4efb76b515746c.tar.gz nextpnr-0e8a2999bda012175c1734abbf4efb76b515746c.tar.bz2 nextpnr-0e8a2999bda012175c1734abbf4efb76b515746c.zip |
gowin: Add partnumbers and packages to the chipdb
Instead of parsing the partnumber with a regular expression,
a simple table is used. This is done because the structure
of the partnumber changes as new features appear (e.g., ES instead of C6/I5)
This commit does not yet disable the very first regular expression check.
Signed-off-by: YRabbit <rabbit@yrabbit.cyou>
Diffstat (limited to 'gowin/arch.h')
-rw-r--r-- | gowin/arch.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/gowin/arch.h b/gowin/arch.h index 602c3db5..7513b93d 100644 --- a/gowin/arch.h +++ b/gowin/arch.h @@ -131,6 +131,12 @@ NPNR_PACKED_STRUCT(struct TimingClassPOD { RelPtr<TimingGroupsPOD> groups; }); +NPNR_PACKED_STRUCT(struct PartnumberPOD { + uint32_t name_id; + uint32_t package_id; + uint32_t device_id; +}); + NPNR_PACKED_STRUCT(struct PackagePOD { uint32_t name_id; uint32_t num_pins; @@ -153,6 +159,8 @@ NPNR_PACKED_STRUCT(struct DatabasePOD { RelPtr<GlobalAliasPOD> aliases; uint32_t num_speeds; RelPtr<TimingClassPOD> speeds; + uint32_t num_partnumbers; + RelPtr<PartnumberPOD> partnumber_packages; uint32_t num_variants; RelPtr<VariantPOD> variants; uint16_t num_constids; @@ -165,7 +173,7 @@ struct ArchArgs std::string device; std::string family; std::string speed; - std::string package; + std::string partnumber; // y = mx + c relationship between distance and delay for interconnect // delay estimates double delayScale = 0.4, delayOffset = 0.4; |