diff options
author | Eddie Hung <eddie@fpgeh.com> | 2019-08-13 09:06:11 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-08-13 09:06:11 -0700 |
commit | 19d6b8846f55b4c7be705619f753bec86deadac8 (patch) | |
tree | 25282a84ce8be23f15ce5a4ad9e93277b1c0b61b /passes | |
parent | 78b30bbb1102047585d1a2eac89b1c7f5ca7344e (diff) | |
parent | e4a09715814d4fa9019c69d2305973030755c379 (diff) | |
download | yosys-19d6b8846f55b4c7be705619f753bec86deadac8.tar.gz yosys-19d6b8846f55b4c7be705619f753bec86deadac8.tar.bz2 yosys-19d6b8846f55b4c7be705619f753bec86deadac8.zip |
Merge pull request #1288 from YosysHQ/eddie/fix_1284
Since $_ANDNOT_ is not symmetric, do not sort leaves
Diffstat (limited to 'passes')
-rw-r--r-- | passes/techmap/extract_fa.cc | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/passes/techmap/extract_fa.cc b/passes/techmap/extract_fa.cc index b541ceb6b..befaf68a4 100644 --- a/passes/techmap/extract_fa.cc +++ b/passes/techmap/extract_fa.cc @@ -153,12 +153,10 @@ struct ExtractFaWorker } } - void check_partition(SigBit root, pool<SigBit> &leaves) + void check_partition(SigBit root, const pool<SigBit> &leaves) { if (config.enable_ha && GetSize(leaves) == 2) { - leaves.sort(); - SigBit A = SigSpec(leaves)[0]; SigBit B = SigSpec(leaves)[1]; @@ -196,8 +194,6 @@ struct ExtractFaWorker if (config.enable_fa && GetSize(leaves) == 3) { - leaves.sort(); - SigBit A = SigSpec(leaves)[0]; SigBit B = SigSpec(leaves)[1]; SigBit C = SigSpec(leaves)[2]; @@ -237,7 +233,7 @@ struct ExtractFaWorker } } - void find_partitions(SigBit root, pool<SigBit> &leaves, pool<pool<SigBit>> &cache, int maxdepth, int maxbreadth) + void find_partitions(SigBit root, const pool<SigBit> &leaves, pool<const pool<SigBit>> &cache, int maxdepth, int maxbreadth) { if (cache.count(leaves)) return; @@ -293,8 +289,8 @@ struct ExtractFaWorker continue; SigBit root = it.first; - pool<SigBit> leaves = { root }; - pool<pool<SigBit>> cache; + const pool<SigBit> leaves = { root }; + pool<const pool<SigBit>> cache; if (config.verbose) log(" checking %s\n", log_signal(it.first)); |