Very fast, it turns out. Arne Babenhauserheide has a great twitter thread on how fast ripgrep is:
yes, this is “ripgrep is so fast that I can simply grep through 2 million lines of code for each line in this file”.
It’s so fast that I was able to switch from IntelliJ “find-reference-in-index” for JS development to #Emacs dumb-jump “ripgrep all code for lang-specific regex”.
— ((λ()’Dr.ArneBab)) (@ArneBab) January 17, 2020
You should click on the tweet to see the full thread but a précis is that Babenhauserheide extolled the performance of ripgrep by noting that he was able to check the usages of over 200 property-keys in 2,000,000 lines of code in less than 5 minutes. That’s technically true but significantly understates ripgrep’s performance.
The author of ripgrep, Andrew Gallant, responded that that seemed slow to him and after some back and forth it turned out that the process actually took 46 seconds. Gallant says that still seems slow but guessed that it’s because ripgrep was being called once for each of the more than 200 property-keys.
Babenhauserheide ends the thread by saying he was able to replace IntelliJ’s find-reference-in-index
by using Emacs with dumb-jump. I do the same thing and have been very happy with the result. Dumb-jump is essentially instantaneous with ripgrep even for fairly large codebases.