Hacker News new | past | comments | ask | show | jobs | submit login

I talked about this in the OP. Memory maps are sometimes a little faster. See:

    $ ls -l full.txt
    -rw-rw-r-- 1 andrew users 13113340782 Sep 29 12:30 full.txt

    $ time rg -c --no-mmap Clipton full.txt
    294

    real    1.337
    user    0.470
    sys     0.866
    maxmem  15 MB
    faults  0

    $ time rg -c --mmap Clipton full.txt
    294

    real    1.045
    user    0.722
    sys     0.323
    maxmem  12511 MB
    faults  0
But in recursive search, especially when used for lots of little files, they end up provoking substantial overhead that slows everything down.

And this might change depending on the platform.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: