3 ms·
With SSE it's 2.6-3.4 cycles/byte to unpack UTF-8 into UTF-32 (ie integers). See https://github.com/KWillets/fastdecode-utf-8 https://github.com/KWillets/fastd
by kwillets 7y ago
With SSE it's 2.6-3.4 cycles/byte to unpack UTF-8 into UTF-32 (ie integers). See https://github.com/KWillets/fastdecode-utf-8 https://github.com/KWillets/fastdecode-utf-8 .
Selection (extracting the i-th element) is actually quite fast, but there's some overhead in grabbing a whole chunk of characters and extracting all their payload bits at once.