Himbaechel Xilinx : XDC commands : Also search nets with lowercase for better interoperability with other synthesis tools and RTL languages

This commit is contained in:
Adrien Prost-Boucle 2024-10-01 11:23:33 +02:00 committed by myrtle
parent 3d00b97e0a
commit 7f33329fe1

View File

@ -128,6 +128,14 @@ void XilinxImpl::parse_xdc(const std::string &filename)
return tgt_nets; return tgt_nets;
IdString netname = ctx->id(str); IdString netname = ctx->id(str);
NetInfo *maybe_net = ctx->getNetByAlias(netname); NetInfo *maybe_net = ctx->getNetByAlias(netname);
if (maybe_net != nullptr) {
tgt_nets.push_back(maybe_net);
return tgt_nets;
}
// Also test the lowercase variant, for better interoperability with synthesis tools
boost::algorithm::to_lower(str);
netname = ctx->id(str);
maybe_net = ctx->getNetByAlias(netname);
if (maybe_net != nullptr) if (maybe_net != nullptr)
tgt_nets.push_back(maybe_net); tgt_nets.push_back(maybe_net);
return tgt_nets; return tgt_nets;