Hacker News new | ask | show | jobs
by LoganDark 49 days ago
I wonder if this is faster because it makes the prefetcher happy.
1 comments

I think the problem is with branches misprediction. Binary and linear searches use a lot of unpredictable branches that ruin performance. No-branch versions of search work faster. I wrote the details here: https://news.ycombinator.com/item?id=47983102