alt.hn

12/28/2025 at 10:40:57 PM

Parsing IP addresses quickly (portably, without SIMD magic)

https://lemire.me/blog/2025/12/27/parsing-ip-addresses-quickly-portably-without-simd-magic/

by ibobev

12/29/2025 at 12:34:24 AM

I like skeeto's version [0], but it allows for unbounded parsing due to unbounded zero padding of decimals, so therefore not constant time. Probably only requires an additional counter for the number of digits seen to mitigate that, but it would probably yucky the code a bit.

[0]: https://github.com/skeeto/scratch/blob/2af9b076117838b93fc2f...

by commandersaki

12/28/2025 at 11:35:25 PM

Given that its 2025, a blog post that only covers parsing IPv4 addresses doesn't deserve much of my time.

I visited the blog post hoping the author would be presenting a dual-stack algorithm. I was sadly disappointed.

by traceroute66

12/29/2025 at 2:02:45 AM

2025 and we still get smug comments like this one. I am sadly disappointed.

by blell

12/29/2025 at 12:25:19 AM

this was vibe-coded and then human improved.

references to faster version of it are already provided.

by signa11