Commit Graph

66 Commits

Author SHA1 Message Date
Sean Anderson
df99b4ff6c ice40: Add debugs to isBelLocationValid for SB_IO
When there is a constraint conflict while placing IOs, the user gets an
error message such as

ERROR: Bel 'X0/Y27/io1' of type 'SB_IO' is not valid for cell 'my_pin' of type 'SB_IO'

While this identifies the problematic cell, it does not explain why
there is a problem. Add some verbose messages to allow users to
determine where the problem is. This can result in something like

Info: Net '$PACKER_VCC_NET' for cell 'my_pin' conflicts with net 'ce' for 'ce_pin'

which provides something actionable.

Signed-off-by: Sean Anderson <seanga2@gmail.com>
2022-12-07 10:32:38 +01:00
gatecat
603b60da8d api: add explain_invalid option to isBelLocationValid
Signed-off-by: gatecat <gatecat@ds0.me>
2022-12-07 10:27:58 +01:00
gatecat
c60fb94b6c refactor: Use IdString::in instead of || chains
Signed-off-by: gatecat <gatecat@ds0.me>
2022-08-10 18:58:22 +01:00
gatecat
6122f172e3 ice40: Fix accidental creation of empty ports
Signed-off-by: gatecat <gatecat@ds0.me>
2022-06-25 15:56:16 +01:00
gatecat
76683a1e3c refactor: Use constids instead of id("..")
Signed-off-by: gatecat <gatecat@ds0.me>
2022-02-16 17:09:54 +00:00
gatecat
2ffb081442 Fixing old emails and names in copyrights
Signed-off-by: gatecat <gatecat@ds0.me>
2021-06-12 13:22:38 +01:00
gatecat
c7c13cd95f Remove isValidBelForCell
This Arch API dates from when we were first working out how to
implement placement validity checking, and in practice is little used by
the core parts of placer1/HeAP and the Arch implementation involves a
lot of duplication with isBelLocationValid.

In the short term; placement validity checking is better served by the
combination of checkBelAvail and isValidBelForCellType before placement;
followed by isBelLocationValid after placement (potentially after
moving/swapping multiple cells).

Longer term, removing this API makes things a bit cleaner for a new
validity checking API.

Signed-off-by: gatecat <gatecat@ds0.me>
2021-02-16 13:31:36 +00:00
D. Shah
a09a62bc4a ice40: Use snake case for arch-specific functions
This makes the difference clearer between the general arch API that
everyone must implement; and helper functions specific to one arch.

Signed-off-by: D. Shah <dave@ds0.me>
2021-02-03 10:46:12 +00:00
D. Shah
b31b21fd51 ice40: Implement IdStringList for all arch object names
Signed-off-by: D. Shah <dave@ds0.me>
2021-02-02 17:00:33 +00:00
Sylvain Munaut
66b64f928b ice40: Check for SB_IO shared wires conflicts in isValidBelForCell
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2019-04-17 16:07:22 +02:00
Sylvain Munaut
a79f0db749 ice40: Add helper to know which global network is driven by a SB_GB Bel
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2018-11-26 12:51:14 +01:00
Sylvain Munaut
bc9f2da470 ice40: Introduce the concept of forPadIn SB_GB
Those are cells that are created mainly to handle the various sources a
global network can be driven from other than a user net.

When the flag is set, this means the global network usually driven by
this BEL is in fact driven by something else and so that SB_GB BEL and
matching global network can't be used.

This is also what gets used to set the extra bits during bitstream
generation.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2018-11-19 18:20:20 +01:00
Sylvain Munaut
c219d8fe4d ice40: Fix BEL validity check for PLL vs SB_IO
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2018-11-19 18:20:20 +01:00
David Shah
ea03aafc26 clangformat
Signed-off-by: David Shah <davey1576@gmail.com>
2018-09-30 15:13:18 +01:00
David Shah
d5d9fb27a6 ice40: Validity check for LVDS IO
Signed-off-by: David Shah <davey1576@gmail.com>
2018-09-24 15:14:28 +01:00
David Shah
9834b68041 ice40: Remove obsolete belType member
Signed-off-by: David Shah <davey1576@gmail.com>
2018-09-24 14:27:50 +01:00
Eddie Hung
a41500a015 Rework Arch::logicCellsCompatible() to take pointer + size, allowing use of std::array 2018-08-10 19:50:27 -07:00
Eddie Hung
396cae5118 Make containers static 2018-08-09 20:53:33 -07:00
Clifford Wolf
f875a37467 Get rid of old iCE40 id_ Arch members
Signed-off-by: Clifford Wolf <clifford@clifford.at>
2018-08-08 17:17:16 +02:00
Clifford Wolf
e03ae50e21 Get rid of PortPin and BelType (ice40, generic, docs)
Signed-off-by: Clifford Wolf <clifford@clifford.at>
2018-08-08 17:01:18 +02:00
Clifford Wolf
5e53075990 API change: Use CellInfo* and NetInfo* as cell/net handles (common, ice40)
Signed-off-by: Clifford Wolf <clifford@clifford.at>
2018-08-05 15:25:42 +02:00
Sergiusz Bazanski
2c34a50a7c ice40: after review 2018-07-25 12:01:51 +01:00
Sergiusz Bazanski
aad0d3eb35 ice40: support PLL40_*_PAD, fix pass-through LUT for LOCK 2018-07-25 11:32:21 +01:00
Sergiusz Bazanski
b31e95f82c Merge branch 'master' of gitlab.com:SymbioticEDA/nextpnr into q3k/pll 2018-07-24 15:54:03 +01:00
David Shah
5a170f286c ice40: Remove use of deprecated APIs
Signed-off-by: David Shah <davey1576@gmail.com>
2018-07-24 15:52:56 +02:00
Sergiusz Bazanski
90ba958abe ice40: fixes before review 2018-07-24 03:19:22 +01:00
Sergiusz Bazanski
eaae1d299c ice40: move PLL->IO from pseudo pip to second uphill bel 2018-07-24 02:55:40 +01:00
Sergiusz Bazanski
65ceb20784 ice40: emit list of upbels in chipdb 2018-07-24 02:55:40 +01:00
Sergiusz Bazanski
1d3147e26a ice40: Prevent placement of SB_IOs in IO blocks used by PLL outputs 2018-07-24 02:55:40 +01:00
Clifford Wolf
62b66e0208 Rename getWireBelPin to getBelPinWire
Signed-off-by: Clifford Wolf <clifford@clifford.at>
2018-07-22 10:59:21 +02:00
David Shah
3bad9c26cf ice40: Optimise reset/enable net checking
Signed-off-by: David Shah <davey1576@gmail.com>
2018-07-20 11:36:32 +02:00
David Shah
d392b5f635 ice40: Use xArchArgs in validity check
Signed-off-by: David Shah <davey1576@gmail.com>
2018-07-18 12:51:07 +02:00
Sergiusz Bazanski
57f75385b0 Revert "Make PnR use Unlocked methods"
This reverts commit 9e4f97290a.
2018-07-14 18:53:08 +01:00
Sergiusz Bazanski
447ed83638 Revert "Introduce proxies for locked access to ctx"
This reverts commit 89809a8b81.
2018-07-14 18:52:56 +01:00
Sergiusz Bazanski
b0c05c7f75 Revert "Refactor proxies to nextpnr."
This reverts commit 9b17fe385c.
2018-07-14 18:50:37 +01:00
Sergiusz Bazanski
9b17fe385c Refactor proxies to nextpnr. 2018-07-14 11:10:31 +01:00
Sergiusz Bazanski
89809a8b81 Introduce proxies for locked access to ctx 2018-07-13 18:58:59 +01:00
Sergiusz Bazanski
9e4f97290a Make PnR use Unlocked methods 2018-07-13 14:50:58 +01:00
David Shah
e0a851976f refactor: Replace assert with NPNR_ASSERT
Signed-off-by: David Shah <davey1576@gmail.com>
2018-07-04 12:15:23 +02:00
David Shah
c18b7b3f6e ice40: Reworking placement legalisation to allow integration with SA placer
Signed-off-by: David Shah <davey1576@gmail.com>
2018-06-29 12:02:34 +02:00
Miodrag Milanovic
db890d3a81 nets and cells are unique_ptr's 2018-06-25 21:33:48 +02:00
David Shah
bdd54a6847 Refactor: remove PlacementValidityChecker and move methods to Arch
Signed-off-by: David Shah <davey1576@gmail.com>
2018-06-25 11:43:59 +02:00
David Shah
1e8840b0f9 Update from increased clangformat line length
Signed-off-by: David Shah <davey1576@gmail.com>
2018-06-23 16:12:52 +02:00
Clifford Wolf
746d63f9fa Refactoring bind/unbind API
Signed-off-by: Clifford Wolf <clifford@clifford.at>
2018-06-23 15:16:24 +02:00
David Shah
289fca0976 ice40: Move global net test to Arch
Signed-off-by: David Shah <davey1576@gmail.com>
2018-06-23 12:09:01 +02:00
Miodrag Milanovic
cb92c10b99 Cleanup almost all deprecation warnings 2018-06-23 09:42:48 +02:00
Clifford Wolf
aa81f9d648 Switched from clifford@clifford.at to clifford@symbioticeda.com for copyright headers
Signed-off-by: Clifford Wolf <clifford@clifford.at>
2018-06-22 16:19:17 +02:00
David Shah
9008669867 Major performance improvement to placement validity check
Signed-off-by: David Shah <davey1576@gmail.com>
2018-06-19 14:44:49 +02:00
David Shah
7abfd36773 ice40: Don't deduplicate local tracks when counting
Signed-off-by: David Shah <davey1576@gmail.com>
2018-06-19 13:35:01 +02:00
Clifford Wolf
79d1075345 Getting rid of old IdString API users, Add ctx to many internal APIs
Signed-off-by: Clifford Wolf <clifford@clifford.at>
2018-06-18 17:08:35 +02:00