arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1612.01506cs.DS
收藏

技术击败算法(在精确字符串匹配中)

Technology Beats Algorithms (in Exact String Matching)

Jorma Tarhio, Jan Holub, Emanuele Giaquinta

摘要:

在过去的40年里,已经开发了120多种算法来进行精确的字符串匹配。我们通过实验表明,\naive{}算法利用SIMD指令的现代CPU(与符号比较,在一个特殊的顺序)是最快的一个模式的长度高达约50个符号和非常好的较长的模式和小的字母。该算法分别应用SSE 2或AVX2指令并行比较16或32个字符。此外,它使用循环剥离,以进一步加快搜索阶段。我们尝试了几种顺序来比较模式符号,并且它们在文本中的概率的增加顺序是最好的。

英文摘要:

More than 120 algorithms have been developed for exact string matching within the last 40 years. We show by experiments that the \naive{} algorithm exploiting SIMD instructions of modern CPUs (with symbols compared in a special order) is the fastest one for patterns of length up to about 50 symbols and extremely good for longer patterns and small alphabets. The algorithm compares 16 or 32 characters in parallel by applying SSE2 or AVX2 instructions, respectively. Moreover, it uses loop peeling to further speed up the searching phase. We tried several orders for comparisons of pattern symbols and the increasing order of their probabilities in the text was the best.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑