<div dir="ltr"><div>+void MapRegionCounters::combineHash(ASTHash Val) {</div><div>+  // Use Bernstein's hash.</div><div>+  Hash = Hash * 33 + Val;</div><div>+}</div><div class="gmail_extra"><br></div><div class="gmail_extra">
So, you care a lot about collisions, but you use Bernstein's hash? I don't get it. This will collide like crazy. Note that Bernstein's hashing algorithm is only ever a "good" distribution for hashing ascii-ish text, and you're hashing dense things.</div>
<div class="gmail_extra"><br></div><div class="gmail_extra">If you care about collisions, I would use the high 64 bits of an md5 (or better yet, all 128 bits). Or some other well researched and understood algorithm.</div>
</div>