diff options
author | Clifford Wolf <clifford@clifford.at> | 2015-02-21 12:15:41 +0100 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2015-02-21 12:15:41 +0100 |
commit | 4e6ca7760f801ce5ea16c6ea9be3ad4a86aa3b1d (patch) | |
tree | 2b6f0debe78102a24b1e1cf48cdfa14752cd0892 /passes/memory | |
parent | f778a4081c9b509c0a1d886f8668b1931bfc93d6 (diff) | |
download | yosys-4e6ca7760f801ce5ea16c6ea9be3ad4a86aa3b1d.tar.gz yosys-4e6ca7760f801ce5ea16c6ea9be3ad4a86aa3b1d.tar.bz2 yosys-4e6ca7760f801ce5ea16c6ea9be3ad4a86aa3b1d.zip |
Replaced ezDefaultSAT with ezSatPtr
Diffstat (limited to 'passes/memory')
-rw-r--r-- | passes/memory/memory_share.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/passes/memory/memory_share.cc b/passes/memory/memory_share.cc index a2f89f6d9..3d241433a 100644 --- a/passes/memory/memory_share.cc +++ b/passes/memory/memory_share.cc @@ -489,8 +489,8 @@ struct MemoryShareWorker if (wr_ports.size() <= 1) return; - ezDefaultSAT ez; - SatGen satgen(&ez, &modwalker.sigmap); + ezSatPtr ez; + SatGen satgen(ez.get(), &modwalker.sigmap); // find list of considered ports and port pairs @@ -553,7 +553,7 @@ struct MemoryShareWorker if (considered_port_pairs.count(i) || considered_port_pairs.count(i+1)) { RTLIL::SigSpec sig = modwalker.sigmap(wr_ports[i]->getPort("\\EN")); - port_to_sat_variable[i] = ez.expression(ez.OpOr, satgen.importSigSpec(sig)); + port_to_sat_variable[i] = ez->expression(ez->OpOr, satgen.importSigSpec(sig)); std::vector<RTLIL::SigBit> bits = sig; bits_queue.insert(bits.begin(), bits.end()); @@ -582,7 +582,7 @@ struct MemoryShareWorker vector<int> ez_wire_bits = satgen.importSigSpec(wire); for (int i : ez_wire_bits) for (int j : ez_wire_bits) - if (i != j) ez.assume(ez.NOT(i), j); + if (i != j) ez->assume(ez->NOT(i), j); } log(" Common input cone for all EN signals: %d cells.\n", int(sat_cells.size())); @@ -590,7 +590,7 @@ struct MemoryShareWorker for (auto cell : sat_cells) satgen.importCell(cell); - log(" Size of unconstrained SAT problem: %d variables, %d clauses\n", ez.numCnfVariables(), ez.numCnfClauses()); + log(" Size of unconstrained SAT problem: %d variables, %d clauses\n", ez->numCnfVariables(), ez->numCnfClauses()); // merge subsequent ports if possible @@ -599,13 +599,13 @@ struct MemoryShareWorker if (!considered_port_pairs.count(i)) continue; - if (ez.solve(port_to_sat_variable.at(i-1), port_to_sat_variable.at(i))) { + if (ez->solve(port_to_sat_variable.at(i-1), port_to_sat_variable.at(i))) { log(" According to SAT solver sharing of port %d with port %d is not possible.\n", i-1, i); continue; } log(" Merging port %d into port %d.\n", i-1, i); - port_to_sat_variable.at(i) = ez.OR(port_to_sat_variable.at(i-1), port_to_sat_variable.at(i)); + port_to_sat_variable.at(i) = ez->OR(port_to_sat_variable.at(i-1), port_to_sat_variable.at(i)); RTLIL::SigSpec last_addr = wr_ports[i-1]->getPort("\\ADDR"); RTLIL::SigSpec last_data = wr_ports[i-1]->getPort("\\DATA"); |