projects
/
yosys.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
eef3219
)
flowmap: when doing mincut, ensure source is always in X, not X̅.
author
whitequark
<whitequark@whitequark.org>
Tue, 12 Nov 2019 00:15:43 +0000
(
00:15
+0000)
committer
whitequark
<whitequark@whitequark.org>
Tue, 12 Nov 2019 00:15:43 +0000
(
00:15
+0000)
Fixes #1475.
passes/techmap/flowmap.cc
patch
|
blob
|
history
diff --git
a/passes/techmap/flowmap.cc
b/passes/techmap/flowmap.cc
index 96eee45db49177d2bd7199d5593627a31462f56b..a2ad87f7d279ac5868e8d81c8463ff63f2612bff 100644
(file)
--- a/
passes/techmap/flowmap.cc
+++ b/
passes/techmap/flowmap.cc
@@
-394,7
+394,7
@@
struct FlowGraph
pair<pool<RTLIL::SigBit>, pool<RTLIL::SigBit>> edge_cut()
{
- pool<RTLIL::SigBit> x
, xi;
+ pool<RTLIL::SigBit> x
= {source}, xi; // X and X̅ in the paper
NodePrime source_prime = {source, true};
pool<NodePrime> visited;
@@
-437,6
+437,7
@@
struct FlowGraph
for (auto collapsed_node : collapsed[sink])
xi.insert(collapsed_node);
+ log_assert(x[source] && !xi[source]);
log_assert(!x[sink] && xi[sink]);
return {x, xi};
}