mirror of
https://github.com/BurntSushi/ripgrep.git
synced 2025-05-19 09:40:22 -07:00
Tweak memory maps on darwin.
Namely, don't automatically pick memory maps on darwin, ever. They appear slower than standard read calls. Closes #36.
This commit is contained in:
parent
6b2efd4d88
commit
a44735aa87
@ -292,6 +292,9 @@ impl RawArgs {
|
|||||||
} else if cfg!(windows) {
|
} else if cfg!(windows) {
|
||||||
// On Windows, memory maps appear faster than read calls. Neat.
|
// On Windows, memory maps appear faster than read calls. Neat.
|
||||||
true
|
true
|
||||||
|
} else if cfg!(darwin) {
|
||||||
|
// On Mac, memory maps appear to suck. Neat.
|
||||||
|
false
|
||||||
} else {
|
} else {
|
||||||
// If we're only searching a few paths and all of them are
|
// If we're only searching a few paths and all of them are
|
||||||
// files, then memory maps are probably faster.
|
// files, then memory maps are probably faster.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user