summaryrefslogtreecommitdiff
path: root/passes
diff options
context:
space:
mode:
Diffstat (limited to 'passes')
-rw-r--r--passes/opt/opt_reduce.cc1
-rw-r--r--passes/opt/opt_share.cc7
-rw-r--r--passes/techmap/techmap.cc7
3 files changed, 2 insertions, 13 deletions
diff --git a/passes/opt/opt_reduce.cc b/passes/opt/opt_reduce.cc
index 80ec8974..f947e972 100644
--- a/passes/opt/opt_reduce.cc
+++ b/passes/opt/opt_reduce.cc
@@ -22,7 +22,6 @@
#include "kernel/sigtools.h"
#include "kernel/log.h"
#include "kernel/celltypes.h"
-#include "libs/sha1/sha1.h"
#include <stdlib.h>
#include <stdio.h>
#include <set>
diff --git a/passes/opt/opt_share.cc b/passes/opt/opt_share.cc
index 26d19414..3532b124 100644
--- a/passes/opt/opt_share.cc
+++ b/passes/opt/opt_share.cc
@@ -107,12 +107,7 @@ struct OptShareWorker
hash_string += "\n";
}
- unsigned char hash[20];
- char hash_hex_string[41];
- sha1::calc(hash_string.c_str(), hash_string.size(), hash);
- sha1::toHexString(hash, hash_hex_string);
- cell_hash_cache[cell] = hash_hex_string;
-
+ cell_hash_cache[cell] = sha1(hash_string);
return cell_hash_cache[cell];
}
#endif
diff --git a/passes/techmap/techmap.cc b/passes/techmap/techmap.cc
index c2e5960f..1f812e52 100644
--- a/passes/techmap/techmap.cc
+++ b/passes/techmap/techmap.cc
@@ -99,12 +99,7 @@ struct TechmapWorker
connbits_map[bit] = std::pair<std::string, int>(conn.first, i);stringf("%s %d", log_id(conn.first), i, bit.data);
}
- unsigned char hash[20];
- char hash_hex_string[41];
- sha1::calc(constmap_info.c_str(), constmap_info.size(), hash);
- sha1::toHexString(hash, hash_hex_string);
-
- return stringf("$paramod$constmap$%s%s", hash_hex_string, tpl->name.c_str());
+ return stringf("$paramod$constmap:%s%s", sha1(constmap_info).c_str(), tpl->name.c_str());
}
TechmapWires techmap_find_special_wires(RTLIL::Module *module)