# Algorithm for multiple extended string matching

I need to implement an algorithm for multiple extended string matching in text. Algorithms to match regular expression would be perhaps too slow.

Extended means the presence of wildcards (any number of characters instead of a star), for example:

abc*def //matches abcdef, abcpppppdef etc.


Multiple means that the search is going on simultaneously for multiple string patterns (not a separate search for each pattern), for example:

abc*def
abc
whatever
some*string


QUESTION:

What is the fast algorithm that can do multiple extended string matching?

Preferably, optimized for SIMD instructions and multicore implementation. Open source implementation (C/C++/Python) would be great as well. I'm interested in 10 Gbps+ performance on a single core of a modern CPU.

Thank you

• I suggest that we close this question on this site. It is a duplicate, cross-posted on Cross Validated and migrated to StackOverflow, where it already has an accepted answer: stackoverflow.com/q/28962097/2872891. Anyone, wanting to add their answer, can do so on SO. – Aleksandr Blekh Mar 15 '15 at 2:16