aboutsummaryrefslogtreecommitdiffstats
path: root/ecp5/arch.cc
diff options
context:
space:
mode:
authorDavid Shah <dave@ds0.me>2019-06-22 16:57:00 +0100
committerDavid Shah <dave@ds0.me>2019-08-07 14:22:47 +0100
commit661237eb64a694a11900f736b07132ef8da4b0dd (patch)
tree68f7e853f8182adf931100da3c69d1ab9379a568 /ecp5/arch.cc
parent90364fc3fad72f8c23b7200160f1acc0343c94d9 (diff)
downloadnextpnr-661237eb64a694a11900f736b07132ef8da4b0dd.tar.gz
nextpnr-661237eb64a694a11900f736b07132ef8da4b0dd.tar.bz2
nextpnr-661237eb64a694a11900f736b07132ef8da4b0dd.zip
ecp5: Add --out-of-context for building hard macros
Signed-off-by: David Shah <dave@ds0.me>
Diffstat (limited to 'ecp5/arch.cc')
-rw-r--r--ecp5/arch.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/ecp5/arch.cc b/ecp5/arch.cc
index 4be9833e..9f137b9b 100644
--- a/ecp5/arch.cc
+++ b/ecp5/arch.cc
@@ -524,9 +524,15 @@ bool Arch::place()
} else {
log_error("ECP5 architecture does not support placer '%s'\n", placer.c_str());
}
-
permute_luts();
+
+ // In out-of-context mode, create a locked macro
+ if (bool_or_default(settings, id("arch.ooc")))
+ for (auto &cell : cells)
+ cell.second->belStrength = STRENGTH_LOCKED;
+
getCtx()->settings[getCtx()->id("place")] = 1;
+
archInfoToAttributes();
return true;
}