precompiled regex for search, improved search profiling