aboutsummaryrefslogtreecommitdiffstats
path: root/fpga_interchange/site_routing_cache.h
diff options
context:
space:
mode:
authorKeith Rothman <537074+litghost@users.noreply.github.com>2021-03-22 17:38:15 -0700
committerKeith Rothman <537074+litghost@users.noreply.github.com>2021-03-23 09:03:07 -0700
commit831b94cdac7af66e11d0e3d67fa3bbff29678d05 (patch)
treef87d796b133ad79be4602f4436a4cfc6c0bb4001 /fpga_interchange/site_routing_cache.h
parentae71206e1f9522542b919b0dd5b3e634a680dc03 (diff)
downloadnextpnr-831b94cdac7af66e11d0e3d67fa3bbff29678d05.tar.gz
nextpnr-831b94cdac7af66e11d0e3d67fa3bbff29678d05.tar.bz2
nextpnr-831b94cdac7af66e11d0e3d67fa3bbff29678d05.zip
Initial version of inverter logic.
For now just implements some inspection capabilities, and the site router (for now) avoids inverted paths. Signed-off-by: Keith Rothman <537074+litghost@users.noreply.github.com>
Diffstat (limited to 'fpga_interchange/site_routing_cache.h')
-rw-r--r--fpga_interchange/site_routing_cache.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/fpga_interchange/site_routing_cache.h b/fpga_interchange/site_routing_cache.h
index 942375dc..6ad218c7 100644
--- a/fpga_interchange/site_routing_cache.h
+++ b/fpga_interchange/site_routing_cache.h
@@ -40,6 +40,8 @@ struct SiteRoutingSolution
solution_offsets.clear();
solution_storage.clear();
solution_sinks.clear();
+ inverted.clear();
+ can_invert.clear();
}
size_t num_solutions() const { return solution_sinks.size(); }
@@ -58,9 +60,15 @@ struct SiteRoutingSolution
return solution_storage.begin() + solution_offsets.at(solution + 1);
}
+ bool solution_inverted(size_t solution) const { return inverted.at(solution) != 0; }
+
+ bool solution_can_invert(size_t solution) const { return can_invert.at(solution) != 0; }
+
std::vector<size_t> solution_offsets;
std::vector<SitePip> solution_storage;
std::vector<SiteWire> solution_sinks;
+ std::vector<uint8_t> inverted;
+ std::vector<uint8_t> can_invert;
};
struct SiteRoutingKey