[darcs-users] Darcs 2.4 - performance testing (stage 0)
dagit at codersbase.com
Wed Jan 13 03:10:19 UTC 2010
On Tue, Jan 12, 2010 at 6:26 PM, Max Battcher <me at worldmaker.net> wrote:
> On 1/12/2010 18:01, Max Battcher wrote:
>> On 1/12/2010 17:50, Max Battcher wrote:
>>> In the not-so-silly Windows bug problems: darcs-benchmark doesn't always
>>> cleanly close file handles and processes on interruption (Ctrl+C).
>> Urgh... Let me upgrade this problem... On Windows darcs itself is having
>> all kinds of permission errors attempting to run through the benchmark.
>> For whatever reason the benchmark isn't giving darcs enough time to
>> release files between processes that subsequent tests such as unpull
>> after record are failing with permission errors.
>> Trying a "sudo" run now, to see if that helps, but it seems unfortunate
>> if darcs-benchmark needs Admin privileges on Windows.
> Who am I kidding? The permissions issues appear to be the same with or
> without Admin privileges (which I should have expected). For some reason
> "darcs-benchmark run bin1 bin2 > test.log" doesn't get standard out
> redirected to the log file properly in Windows (I'm used to it working on
> Windows, so that's pretty surpising), so I'll try to cut and paste an
> example or two from the log...
> Here's one of the most common permission errors it seems:
> C:\Users\Max\Stuff\Benchmarking\darcs-2.3.1 check --no-test +RTS
> -sdarcs-stats -
> error: user error (darcs failed with error code 1
> saying: Can't open stats file darcs-stats
Hmm...that's interesting. darcs-stats is created by GHC's run-time system.
Eg., it's a file created and opened for write by a different process and
darcs should be ignoring it. It definitely shouldn't be part of the
repository that you're benchmarking.
What about this command instead:
C:\Users\Max\Stuff\Benchmarking\darcs-2.3.1 check --no-test +RTS
In other words, what if we don't create the darcs-stats file in the same
directory as the repository? We should probably also update darcs check so
that it warns instead of fails when it cannot open a file. Lastly, why does
it even care about that file?
> Obviously the darcs-stats file is in pretty high demand and darcs-benchmark
> doesn't seem to be waiting long enough between runs to close the file
> correctly (or otherwise doesn't have the proper sharing permissions setup
> for the file).
The haskell run-time created it for the duration that darcs is executing and
I bet darcs tried to access while it was running. I think there are
essentially two solutions:
1) Create the file elsewhere
2) make it a non-fatal error
> Here's an example of a failure in darcs itself:
> C:\Users\Max\Bin\darcs.exe unpull --last 1000 --all +RTS -sdarcs-stats -RTS
> error: user error (darcs failed with error code 2
> saying: Reading pristine 31/478
> darcs failed: Can't unpull patch without reverting some unrecorded change.
I think there is some bad interaction between the repositories that Petr is
supplying and the expectations of darcs-benchmark (it doesn't expect darcs
to run into any problems or questions).
> Well, that's also interesting because it couldn't find darcs-2.3.1 in its
> place in Haskell's bin directory (despite accessibility in PATH), but it
> found this other Bin directory in my PATH.
Is it possible that the order of your paths is interfering?
> Anyway, it doesn't look like darcs-benchmark wants to run correctly on
> Windows Vista just yet.
I'm still troubleshooting the OS X case too. Thanks for trying to figure
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the darcs-users