I think that’s a great work! As I’m not familiar with UTF8, I believe we should first evaluate the algorithm to prove it matches Swift’s use case and doesn’t spoil the Apache-2 license. I also think you can try to contact Daniel Lemire and invite him to bring the PR himself.
Vectorizing UTF8 handling has been on our list for a while. I expect at some point @scanon will get a moment in between numerics projects and do something amazing there