Skip to content

Commit 543b697

Browse files
authored
Merge pull request #3261 from dotty-staging/branchless-hash
Make the Tasty hash branchless
2 parents 458aec6 + f9b6ea3 commit 543b697

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

compiler/src/dotty/tools/dotc/core/tasty/TastyPickler.scala

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,7 @@ class TastyPickler {
8383
while (i < data.length) {
8484
h = (h << 4) + data(i)
8585
high = h & 0xF0000000L
86-
if (high != 0)
87-
h ^= high >> 24
86+
h ^= high >> 24
8887
h &= ~high
8988
i += 1
9089
}

0 commit comments

Comments
 (0)