Hacker News new | past | comments | ask | show | jobs | submit login

Hi, I'm the MurmurHash guy. Neat stuff, and I'm amused that multiply-shift-xor has held up so well for all this time.



Xor-shift counteracts the two weaknesses of a multiply: the high bits have nothing above them to influence, and the low bits have nothing below them to be influenced by.


Like MurmurHash, I expect these are meant to be non-cryptographic.

However, that said, I feel like the Avalanche + Bias idea is missing quite a bit.

Example: This function as the last listed function.

  // exact bias: 0.020888578919738908
  uint32_t
  triple32(uint32_t x)
  {
      x ^= x >> 17;
      x *= 0xed5ad4bbU;
      x ^= x >> 11;
      x *= 0xac4c1b51U;
      x ^= x >> 15;
      x *= 0x31848babU;
      x ^= x >> 14;
      return x;
  }
Produces this image when implemented by FabriceNeyret2 on ShaderToy.

https://www.shadertoy.com/view/WttXWX

or

https://i.imgur.com/qU2P5rx.png

However, a simple normal map slope differentiation shows a quite a few obvious "crystal" lines. There's probably a technical term for those types of ridges.

https://i.imgur.com/IHWT1GM.png

Edit: Also, this entire idea is half a decade old? https://nullprogram.com/blog/2018/07/31/


> Also, this entire idea is half a decade old?

Is that a bad thing?


Yes?

In any form of hash function, cryptography field, or information warfare, five years is an enormous length of time.

That means "somebody" in humanity has been brute force algorithm generating improved integer hash functions for the last half decade.

For all I know, Google, NVidia, Microsoft, NSA, Spetssvyaz, 3PLA, and Unit 8200 may have been in an integer hash function generation arms race for the last half decade.

Long Reuters article today on drones, and how the US is floundering (they're just not spending as much money as people want). [1] However, if drone can dodge better than enemy can shoot drone, then integer hash function is suddenly not "civilian". Missiles have known this forever. Talk to the MIRV industry.

[1] https://www.reuters.com/business/aerospace-defense/sea-drone...


The big ones probably not, but I extended and ran my fast-hash generator just this year again, with new ideas and new builtin op codes, and the results didn't change since at all. You need to find a combination of fast and good-enough hashes.

But fast string search changed a lot in the last decade. The previous winners were all taken over by a new two-way algorithm as implemented in musl. This was a surprise. search is definitely more important than inthash. Maybe glibc will catchup in the next decade.

String hashing also got much better since. This is terrible forever in all stdlibs.


> Talk to the MIRV industry.

I didn't get an answer at 800-I-AM-MIRV, and don't know another way to contact this industry. Can you perhaps instead hint why you think that this industry might imply that non-cryptographic hashes are not "civilian"?




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: