diff options
Diffstat (limited to 'ecp5')
-rw-r--r-- | ecp5/arch.cc | 14 | ||||
-rw-r--r-- | ecp5/arch.h | 5 | ||||
-rw-r--r-- | ecp5/main.cc | 6 |
3 files changed, 21 insertions, 4 deletions
diff --git a/ecp5/arch.cc b/ecp5/arch.cc index 6d320996..7383e0e7 100644 --- a/ecp5/arch.cc +++ b/ecp5/arch.cc @@ -23,6 +23,8 @@ #include <cstring> #include "log.h" #include "nextpnr.h" +#include "placer1.h" +#include "router1.h" #include "util.h" NEXTPNR_NAMESPACE_BEGIN @@ -288,6 +290,18 @@ delay_t Arch::estimateDelay(WireId src, WireId dst) const // ----------------------------------------------------------------------- +bool Arch::place() +{ + return placer1(getCtx()); +} + +bool Arch::route() +{ + return router1(getCtx()); +} + +// ----------------------------------------------------------------------- + std::vector<GraphicElement> Arch::getDecalGraphics(DecalId decalId) const { std::vector<GraphicElement> ret; diff --git a/ecp5/arch.h b/ecp5/arch.h index ba26682e..5f01c8c8 100644 --- a/ecp5/arch.h +++ b/ecp5/arch.h @@ -720,6 +720,11 @@ struct Arch : BaseCtx // ------------------------------------------------- + bool place(); + bool route(); + + // ------------------------------------------------- + std::vector<GraphicElement> getDecalGraphics(DecalId decal) const; DecalXY getFrameDecal() const; diff --git a/ecp5/main.cc b/ecp5/main.cc index caa28563..45774431 100644 --- a/ecp5/main.cc +++ b/ecp5/main.cc @@ -44,8 +44,6 @@ #include "design_utils.h" #include "jsonparse.h" #include "pack.h" -#include "place_sa.h" -#include "route.h" #include "timing.h" USING_NEXTPNR_NAMESPACE @@ -147,10 +145,10 @@ int main(int argc, char *argv[]) if (vm.count("no-tmdriv")) ctx.timing_driven = false; - if (!place_design_sa(&ctx) && !ctx.force) + if (!ctx.place() && !ctx.force) log_error("Placing design failed.\n"); ctx.check(); - if (!route_design(&ctx) && !ctx.force) + if (!ctx.route() && !ctx.force) log_error("Routing design failed.\n"); std::string basecfg; |