aboutsummaryrefslogtreecommitdiffstats
path: root/nexus/arch.cc
diff options
context:
space:
mode:
Diffstat (limited to 'nexus/arch.cc')
-rw-r--r--nexus/arch.cc11
1 files changed, 11 insertions, 0 deletions
diff --git a/nexus/arch.cc b/nexus/arch.cc
index f804cdd9..d5bb9deb 100644
--- a/nexus/arch.cc
+++ b/nexus/arch.cc
@@ -325,6 +325,17 @@ std::vector<std::pair<IdString, std::string>> Arch::getWireAttrs(WireId wire) co
return ret;
}
+IdString Arch::getWireType(WireId wire) const
+{
+ IdString basename(wire_data(wire).name);
+ const std::string &basename_str = basename.str(this);
+ // Interconnect - derive a type
+ if ((basename_str[0] == 'H' || basename_str[0] == 'V') && basename_str[1] == '0')
+ return id(basename_str.substr(0, 4));
+ else
+ return id_GENERAL;
+}
+
// -----------------------------------------------------------------------
PipId Arch::getPipByName(IdStringList name) const