diff options
author | Marcelina KoĆcielnicka <mwk@0x04.net> | 2020-04-14 16:33:09 +0200 |
---|---|---|
committer | Marcelina KoĆcielnicka <mwk@0x04.net> | 2020-04-14 19:52:19 +0200 |
commit | 7a36728b2fd640e166188b05c901b1992ec2af6b (patch) | |
tree | 6ffd51df2ce905caf597f945bd8addc3bd8320fe /passes | |
parent | 3a27906ac65a1287d1cc4ea758e639b608e152a6 (diff) | |
download | yosys-7a36728b2fd640e166188b05c901b1992ec2af6b.tar.gz yosys-7a36728b2fd640e166188b05c901b1992ec2af6b.tar.bz2 yosys-7a36728b2fd640e166188b05c901b1992ec2af6b.zip |
dffinit: Avoid setting init parameter to zero-length value.
Fixes #1704.
Diffstat (limited to 'passes')
-rw-r--r-- | passes/techmap/dffinit.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/passes/techmap/dffinit.cc b/passes/techmap/dffinit.cc index 0424ce434..35645582b 100644 --- a/passes/techmap/dffinit.cc +++ b/passes/techmap/dffinit.cc @@ -154,9 +154,11 @@ struct DffinitPass : public Pass { value = Const(low_string); } - log("Setting %s.%s.%s (port=%s, net=%s) to %s.\n", log_id(module), log_id(cell), log_id(it.second), - log_id(it.first), log_signal(sig), log_signal(value)); - cell->setParam(it.second, value); + if (value.size() != 0) { + log("Setting %s.%s.%s (port=%s, net=%s) to %s.\n", log_id(module), log_id(cell), log_id(it.second), + log_id(it.first), log_signal(sig), log_signal(value)); + cell->setParam(it.second, value); + } } } |