Using Fibonacci Hashing in hashmap.h

I’ve been noodling a lot with my single header C/C++ hashmap recently - hashmap.h. I knew from reading around that the power-of-two size requirement I had meant that it made getting a bucket location in the range was easy, but that it could result in suboptimal bucket selection. Various places on the interwebs said that using a prime number hash was better as doing the modulus by a prime would give a much better avalanche effect, but this would come at the cost of having to do an actual integer modulus operation for every hash - which is quite a bit slower.

Making Hashing Faster in hashmap.h

One of the C/C++ single header libraries I maintain is hashmap.h. This library is a super light weight and easily integrated hashmap - I’m not focused on the performance necessarily here, it’s really there primarily as a nice-to-use hashmap for when you just want to throw something in there. But that doesn’t mean I want the performance to suck either. If I can make it faster without compromising the API, I’m totally gonna do that!

New Year Cleanup

As a new year starts I generally have some long awaited cleanup to do on my C/C++ single header libraries. Maybe I need to update the CI scripts because they are out of date, maybe I have some features I want to add, or maybe I want to test more things. For those that do not know I have six main libraries that I maintain that are single header and work across C/C++:

I’m Pretty Much Done With Twitter

TL;DR - I’m pretty much done with Twitter (here-in named the “birdshite” 🦤💩). Let’s be honest - Twitter wasn’t exactly ideal for a pretty long time. The sheer amount of ads that were pushed into the feed even long before Space Karen bought the birdshite wasn’t great. I had already blocked thousands of accounts that were pushing promoted tweets into my feed, and had to fight the UI that would constantly try and move me back to the never-ending algorithmic feed that all these advert-centric businesses so love as it eeks out some percentage more time where you eyeballs are glued to their content.

I’ve Joined Epic to Work on Verse

After four relaxing weeks off since I left Unity, I’m pleased to announce I’ve joined the Verse team over at Epic. Today was my first day, so obviously this is the day that I feel the most like an impostor! I’ve done this a few times now (jumping contract to contract when I worked at Codeplay, and then moving to AMD, Unity, and now Epic), and the feeling always passes once you become familiar with the way things are done at the new gig.