Practical Auto-Vectorization

In this post, we'll use Vectorization to optimize our Base64 implementation to perform tens of gigabytes per second. We'll also take a brief look at an implementation that performs ~30 GB/s.

We'll see how I made Apple's swift-foundation Base64 encoding ~3 times faster, and how you can even surpass that.

I'll also share some tips and tricks for leveraging Auto-Vectorization. Tips that the latest and greatest LLMs repeatedly failed to figure out at their maximum effort, when I was first trying out Auto-Vectorization.

##

##

You can checkout this post's related commit to test out the implementations and measurements.