Re: comparing file contents in is_exact_match?
- From
Johannes Schindelin <johannes.schindelin@gmx.de>
- Date
- Jul 18, 2006, 10:20 UTC
- Message-ID
- <Pine.LNX.4.63.0607181216290.29667@wbgn013.biozentrum.uni-wuerzburg.de>
- In-Reply-To
- <f36b08ee0607180238i34cde4deib17426f121ae269e@mail.gmail.com>
Hi,
On Tue, 18 Jul 2006, Yakov Lerner wrote:
> How about making this parameter (do-use-mmap vs not-use-mmap) > a *runtime* parameter ? (Env. var. $GIT_MMAP or $GIT_USE_MMAP ?). > What do you think ? I see two benefits: > (1) much easier to benchmark two methods against each other
You will benchmark it only once, right? No need to have this in git for one-time use.
> (2) will always work on cygwin (automatic fallback to working > method at runtime; say depending on filesystem)
I think it is too complicated to depend on the filesystem, and too system specific (but hey, those who submit a patch are more right than others...).
But an automatic fallback is not feasible: you would try to mmap(), and it would throw an "Access violation", which is MS speak for "Segmentation fault".
Besides, if you would be able to detect a failed mmap(), it would be too late: the rename() or unlink() would already have taken place.
Ciao, Dscho