Skip to content

Commit

Permalink
Merge branch 'parallaxsw:master' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
akashlevy authored Oct 21, 2024
2 parents e8556b7 + 2218351 commit cd06ff6
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 18 deletions.
2 changes: 1 addition & 1 deletion liberty/LibertyReader.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3089,7 +3089,7 @@ LibertyReader::visitCellUserFunctionClass(LibertyAttr *attr)
if (cell_) {
const char *user_function_class = getAttrString(attr);
if (user_function_class)
cell_->setUserFunctionClass(stringCopy(user_function_class));
cell_->setUserFunctionClass(user_function_class);
}
}

Expand Down
1 change: 1 addition & 0 deletions test/regression.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,7 @@ proc run_test_plain { test cmd_file log_file } {
cleanse_logfile $test $log_file
return "ERROR $error"
}
file delete $run_file
cleanse_logfile $test $log_file
return ""
}
Expand Down
36 changes: 19 additions & 17 deletions verilog/VerilogWriter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -411,30 +411,32 @@ VerilogWriter::writeAssigns(Instance *inst)
while (pin_iter->hasNext()) {
Pin *pin = pin_iter->next();
Term *term = network_->term(pin);
Net *net = network_->net(term);
Port *port = network_->port(pin);
if (port
&& (include_pwr_gnd_
|| !(network_->isPower(net) || network_->isGround(net)))
&& (network_->direction(port)->isAnyOutput()
|| (include_pwr_gnd_ && network_->direction(port)->isPowerGround()))
&& !stringEqual(network_->name(port), network_->name(net))) {
// Port name is different from net name.
string port_vname = netVerilogName(network_->name(port),
network_->pathEscape());
string net_vname = netVerilogName(network_->name(net),
network_->pathEscape());
fprintf(stream_, " assign %s = %s;\n",
port_vname.c_str(),
net_vname.c_str());
if (term) {
Net *net = network_->net(term);
Port *port = network_->port(pin);
if (port
&& (include_pwr_gnd_
|| !(network_->isPower(net) || network_->isGround(net)))
&& (network_->direction(port)->isAnyOutput()
|| (include_pwr_gnd_ && network_->direction(port)->isPowerGround()))
&& !stringEqual(network_->name(port), network_->name(net))) {
// Port name is different from net name.
string port_vname = netVerilogName(network_->name(port),
network_->pathEscape());
string net_vname = netVerilogName(network_->name(net),
network_->pathEscape());
fprintf(stream_, " assign %s = %s;\n",
port_vname.c_str(),
net_vname.c_str());
}
}
}
delete pin_iter;
}

////////////////////////////////////////////////////////////////

// Walk the hierarch counting unconnected nets used to connect to
// Walk the hierarchy counting unconnected nets used to connect to
// bus ports with concatenation.
int
VerilogWriter::findUnconnectedNetCount()
Expand Down

0 comments on commit cd06ff6

Please sign in to comment.