I keep getting lucky with the PR numbers
28.05.2025 18:20 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0@redixhumayun.bsky.social
Engineer @conviva | Figuring out databases
I keep getting lucky with the PR numbers
28.05.2025 18:20 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0Nested match statements, as the Lord intended
10.05.2025 11:57 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0I like this thought process.
Easier to think of a database = storage layer + data model + query layer (language + optimizer)
Seems like itโs all in preparation for an IPO
06.05.2025 08:01 โ ๐ 1 ๐ 0 ๐ฌ 0 ๐ 0Its issues like this that make me thankful I finally jumped to having a dedicated Ubuntu box. Open source tools actually *just work*
05.05.2025 14:24 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0My toy database coming along quite nicely
28.04.2025 05:39 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0Me trying to write code quickly in Rust
27.04.2025 19:04 โ ๐ 3 ๐ 1 ๐ฌ 0 ๐ 0Really, really liking Rust's iterator pattern the more I use it!
Makes composition so much nicer to look at and reason about
In the year of our lord 2025, this is not a heretical opinion solely because of the abysmal state of debugging tooling in Rust z
24.03.2025 03:37 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0The more Rust I write, the more I vibe with this meme
23.02.2025 15:27 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0Kolkata got some banging food
21.02.2025 13:07 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0It has been 0 days since I've been bitten by Rust lifetimes
12.02.2025 10:36 โ ๐ 2 ๐ 0 ๐ฌ 1 ๐ 0Iโm fairly certain Amazon also does an LLM chatbot thing where itโs pretending to be a person on chat.
The formulaic responses give it away.
Isnโt this the exact same drama that happened with Ted Tsoโo?
04.02.2025 07:52 โ ๐ 0 ๐ 0 ๐ฌ 1 ๐ 0The biggest drawback of any form of writing generated by LLM's is that it just doesn't feel very honest. The vibes are off
29.01.2025 08:05 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0Functional programming got jokes
28.01.2025 07:39 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0If you found this interesting, give the full article a read which goes into much more depth and contains links to more interesting tidbits around Rust compiler optimizations
redixhumayun.github.io/performance/...
Now, we see much better performance when comparing cache stats for the 3 implementations.
It isn't enough to have contiguous memory access, you also need to be aware of the cache hardware and how many entries can fit per cache line.
Doing all of the above requires you to know some information about your hardware, like the size of your cache and the size of a cache line.
27.01.2025 14:43 โ ๐ 0 ๐ 0 ๐ฌ 1 ๐ 0We can do a more compact open addressing scheme which will fit 4 entries per cache line
Also, using u64 instead of Strings leads to better performance since Strings are always heap allocated
The problem is the memory layout of the structs used for chaining and open addressing
With chaining, we only have pointers which are 8 bytes each so that's 8 per cache line in a 64 byte cache line
With open addressing, it's 24 bytes each so that's 2 per cache line with padding
Profiling, however, shows very different results. It shows chaining and open addressing displaying roughly the same levels of cache performance.
Open addressing ends up performing better but that's only due to fewer overall instructions
You can handle collisions via open addressing (linear probing). This is where you just search through every subsequent entry until you find one where you can insert the key-value pair.
This should be more cache friendly since the entire memory is contiguously allocated
You can handle collisions via chaining where each entry becomes a linked list. This is simple but tends to lead to fragmented memory since each node is allocated separately.
Fragmented memory should theoretically lead to poorer cache performance.
Building a hash map is easy enough - a few public methods and a couple of internal methods to track when to resize the hash map
27.01.2025 14:43 โ ๐ 0 ๐ 0 ๐ฌ 1 ๐ 0My only real recommendation from the post is to not bother profiling on OSX! It's a locked down nightmare of an OS
I've covered all the steps required to get Linux up and running for profiling here: github.com/redixhumayun...
Apple requires jumping through too many hoops
Here's a link to the full post
redixhumayun.github.io/performance/...
I've been trying to understand profiling tools better and decided to build a cache conscious hash map as a way to get more familiar with the tooling.
I wrote a small blog post and I'll cover the high level points in this ๐งต
The database is the log
14.01.2025 17:45 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0Although, this does beg the question of how to ensure Strings perform well with caches. Possibly they can't?
14.01.2025 15:18 โ ๐ 0 ๐ 0 ๐ฌ 0 ๐ 0