Commit f68a0441 authored by Mikaël Salson's avatar Mikaël Salson

algo/core/kmeraffect.h: More efficient hash computation

getLabel() is way too slow as it creates a string.
parent 1b757111
......@@ -178,7 +178,7 @@ namespace std {
template <>
struct hash<KmerAffect> {
size_t operator()(const KmerAffect &affect) const {
return (affect.getLabel()[0] << 8) | affect.getLength();
return (((unsigned char) affect.affect.c << 8) | (affect.getLength()));
}
};
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment