gvansickle / ucg

UniversalCodeGrep (ucg) is an extremely fast grep-like tool specialized for searching large bodies of source code.

Home Page:https://gvansickle.github.io/ucg/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Optimize the num_lines_since_last_match count, move to FileScanner base class

gvansickle opened this issue · comments

See the "/// @todo Optimize this count."'s in FileScannerPCRE.cpp and FileScannerPCRE2.cpp. These loops end up taking a surprising amount of CPU even after gcc's optimizations. Make this a base-class member and optimize it.