In BLIF, a .names without entries already always outputs 0
authorClifford Wolf <clifford@clifford.at>
Fri, 8 Jul 2016 09:41:26 +0000 (11:41 +0200)
committerClifford Wolf <clifford@clifford.at>
Fri, 8 Jul 2016 09:41:26 +0000 (11:41 +0200)
backends/blif/blif.cc

index 93953049ad2afe463912bad27adb503a1472951c..d5787c23a429819dd439af0d7278b33fcae7e7cb 100644 (file)
@@ -351,24 +351,13 @@ struct BlifDumper
                                f << stringf(" %s", cstr(output));
                                f << stringf("\n");
                                RTLIL::SigSpec mask = cell->parameters.at("\\LUT");
-                               bool one = false;
                                for (int i = 0; i < (1 << width); i++)
                                        if (mask[i] == RTLIL::S1) {
                                                for (int j = width-1; j >= 0; j--) {
                                                        f << ((i>>j)&1 ? '1' : '0');
                                                }
                                                f << " 1\n";
-                                               one = true;
                                        }
-                               /* For some reason, sometimes we get LUTs with
-                                * an all zero mask, which won't give any
-                                * .names entries, so write one entry with
-                                * all don't cares */
-                               if (!one) {
-                                       for (int j = width-1; j >= 0; j--)
-                                               f << '-';
-                                       f << " 0\n";
-                               }
                                continue;
                        }