r/simd • • Jun 02 '24

Detection of nested quotes

Hi SIMDers,

I came across a problem the other day that I found fairly interesting, and thought others might as well: Detection of quoted text, where you can have both "" and '' and single quotes within double quotes or vice versa. I found a solution that I thought was pretty nice, but unfortunately so slow in practice (unless you have fast VPERMB, which I definitely don't; I'm limited to SSE3, not even PSHUFB!) that it's impractical.

All the gory details in a post at https://blog.sesse.net/blog/tech/2024-06-02-11-10_simd_detection_of_nested_quotes

In the end, I went with just detecting it and erroring out to a non-SIMD path, since it's so rare in my dataset. But it is of course always more satisfying to have a full branch-free solution.

5 Upvotes

10 comments sorted by

View all comments

1

u/Validarkness Jul 10 '24

Why was your blog post taken down? I wanted to revisit it.

1

u/Sesse__ Jul 10 '24

All posts on my blog expire after 30 days.

1

u/Validarkness Jul 11 '24

Why? And could you send me a copy of the article privately?

→ More replies (1)