Page MenuHomePhabricator

[Support] Replace StringRef hashing algorithm with DJB
Needs ReviewPublic

Authored by ekatz on Wed, Oct 23, 5:02 AM.



DJB hashing has entered in r326091 (, for performance purposes (as described in the commit message). I am unaware of a reason for not to replace the StringRef's default hashing algorithm with DJB, instead of using it specifically for StringMap. Using StringRef as the Key for DenseMap should have the same performance boost.

Diff Detail

Event Timeline

ekatz created this revision.Wed, Oct 23, 5:02 AM

This change looks sensible but I'd like to verify the performance impact. Could you provide some numbers that compare performance before and after the change?