Commit Graph

857 Commits

Author SHA1 Message Date
Miodrag Milanovic
8f2b707d02 Initial conversion to pybind11 2020-07-23 18:35:18 +02:00
David Shah
c7fbdc7877 Avoid low-value and slow pip name check for ECP5
Signed-off-by: David Shah <dave@ds0.me>
2020-06-29 19:52:31 +01:00
David Shah
32e655d0af placer1: Unlock even if placement fails
Prevents a hang during routing when using --force

Fixes #462

Signed-off-by: David Shah <dave@ds0.me>
2020-06-29 16:39:31 +01:00
Miodrag Milanovic
7a95629aff Fix clangformat and execute it 2020-06-27 13:20:16 +02:00
David Shah
4f4aa53120
Merge pull request #460 from whitequark/better-embed
Simplify and improve chipdb embedding/loading
2020-06-26 11:32:13 +01:00
whitequark
89e0cc8078 Simplify and improve chipdb embedding/loading. 2020-06-26 08:36:07 +00:00
David Shah
1df8ac805a HeAP: Add timeout to IO placement
Signed-off-by: David Shah <dave@ds0.me>
2020-06-25 19:42:53 +01:00
David Shah
c9e7d1448e clangformat
Signed-off-by: David Shah <dave@ds0.me>
2020-06-12 16:19:14 +01:00
David Shah
f44498a530
Merge pull request #447 from whitequark/wasi
Port nextpnr-{ice40,ecp5} to WASI
2020-05-24 14:23:35 +01:00
whitequark
e7bb04769d Port nextpnr-{ice40,ecp5} to WASI.
This involves very few changes, all typical to WASM ports:
  * WASM doesn't currently support threads or atomics so those are
    disabled.
  * WASM doesn't currently support exceptions so the exception
    machinery is stubbed out.
  * WASM doesn't (and can't) have mmap(), so an emulation library is
    used. That library currently doesn't support MAP_SHARED flags,
    so MAP_PRIVATE is used instead.

There is also an update to bring ECP5 bbasm CMake rules to parity
with iCE40 ones, since although it is possible to embed chipdb into
nextpnr on WASM, a 200 MB WASM file has very few practical uses.

The README is not updated and there is no included toolchain file
because at the moment it's not possible to build nextpnr with
upstream boost and wasi-libc. Boost requires a patch (merged, will
be available in boost 1.74.0), wasi-libc requires a few unmerged
patches.
2020-05-23 20:57:26 +00:00
David Shah
ddf546c2cc clangformat
Signed-off-by: David Shah <dave@ds0.me>
2020-05-16 12:57:24 +01:00
Eddie Hung
e6b85f1bc0 Fix embarassing use of topographical when meaning topological 2020-05-14 08:55:28 -07:00
David Shah
e431d1a33f Add missing --top option
Signed-off-by: David Shah <dave@ds0.me>
2020-05-09 19:47:03 +01:00
David Shah
25938500d6 python: Also convert regular map keys to string
Signed-off-by: David Shah <dave@ds0.me>
2020-04-24 18:23:03 +01:00
David Shah
fd099cef52 python: Wrap map IdString key when accessed by index
Signed-off-by: David Shah <dave@ds0.me>
2020-04-24 16:31:08 +01:00
Sylvain Munaut
3573fcca80 design_utils: Set port.net to null when disconnecting
Without this the python bindings can't actually connect anything else
to a disconnected port since the assert in connect_ports will think
it's still connected

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2020-04-24 16:13:07 +02:00
Rangel Ivanov
ef4a699b72 command.cc: Use correct constant for default router
Otherwise --help reports that the default router is heap

Signed-off-by: Rangel Ivanov <rangelivanov88@gmail.com>
2020-04-04 10:39:29 +03:00
David Shah
4b54253c24 router2: Prevent overflow
Signed-off-by: David Shah <dave@ds0.me>
2020-03-22 21:17:59 +00:00
David Shah
d20ce45c1b Merge branch 'master' of ssh.github.com:YosysHQ/nextpnr 2020-03-17 10:07:29 +00:00
David Shah
564f40f6db timing: Improve robustness to dangling/undriven logic
Signed-off-by: David Shah <dave@ds0.me>
2020-03-17 10:07:21 +00:00
David Shah
54b15ed201 Replace assertion failure with error
Signed-off-by: David Shah <dave@ds0.me>
2020-03-13 11:35:09 +00:00
Sylvain Munaut
4a9981ee77 pycontainers: Properly handle KeyErrors
We raise a C++ exception to abort the rest of the execution of
the function.

At the same time we standardize on using a throw runtime error as the
method to avoid warning when not returning values. (some places
used this throw and some other used std::terminate)

Fixes #403

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2020-03-04 00:12:45 +01:00
David Shah
b6158f94f6 svg: Basic SVG graphics rendering
Signed-off-by: David Shah <dave@ds0.me>
2020-02-15 11:35:51 +00:00
David Shah
2c7d2f9e0c placer1: Add routeability optimisation (off by default)
Signed-off-by: David Shah <dave@ds0.me>
2020-02-12 10:41:27 +00:00
David Shah
9125698cb0 HeAP: backport out-of-range fix
Signed-off-by: David Shah <dave@ds0.me>
2020-02-12 10:41:27 +00:00
David Shah
1cb0e3af03 HeAP: Add X and Y scaling factors for asymmetric arches
Signed-off-by: David Shah <dave@ds0.me>
2020-02-12 10:41:27 +00:00
David Shah
7db1484c75 HeAP: Make beta configurable
Signed-off-by: David Shah <dave@ds0.me>
2020-02-12 10:41:27 +00:00
David Shah
d1f5cdcb93 HeAP: Improve handling of heterogeneous slice arches
Signed-off-by: David Shah <dave@ds0.me>
2020-02-12 10:41:27 +00:00
David Shah
1ff060c5ad HeAP: Make solver tolerance arch-configurable
Signed-off-by: David Shah <dave@ds0.me>
2020-02-12 10:41:27 +00:00
David Shah
7bda6f15a9 placer1: Allow scaling HPWL differently in each direction
Signed-off-by: David Shah <dave@ds0.me>
2020-02-12 10:41:27 +00:00
David Shah
1ceffbe0bc
Merge pull request #391 from YosysHQ/router2-upstream
Upstreaming router2
2020-02-04 16:08:08 +00:00
David Shah
b4d029a55c
Merge pull request #385 from YosysHQ/router1-arc-fixes
Fixes for partial reconfig demo
2020-02-03 13:55:07 +00:00
David Shah
2248e07b66 router2: Improve flow and log output
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 13:46:05 +00:00
David Shah
a8206ed170 router2: Add a simple timing heuristic
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 13:33:20 +00:00
David Shah
7123209324 Allow selection of router algorithm
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:54:38 +00:00
David Shah
ad1cc12df1 router2: Make magic numbers configurable
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
f82e133c7c router2: Fix case of undriven unsunk arcs
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
c27e7780d1 router2: Multi-thread in more cases
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
3b043432f5 router2: Flatten wire structure
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
2de98386a7 router2: Experiment with data structures
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
7ac43e5f00 router2: Profile nets by route time
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
72367e6cfd router2: Improvements
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
900fe98f0d router2: reduce bias cost factor
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
3b6d9c952a router2: special case improvement
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
a1c703729c router2: reduce memory footprint
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
37543ad003 router2: debugging
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
17256c680a router2: debugging
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
3d739b5916 router2: first pass at reserved wires
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
50b120528a router2: debugging some edge cases
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00
David Shah
bbc9c9b0ba router2: speedup
Signed-off-by: David Shah <dave@ds0.me>
2020-02-03 11:38:31 +00:00