apenwarr-redo/t
Avery Pennarun 95680ed7ef Switch to using a separate lockfile per target.
The previous method, using fcntl byterange locks, was very efficient and
avoided unnecessarily filesystem metadata churn (ie. creating/deleting
inodes).  Unfortunately, MacOS X (at least version 10.6.5) apparently has a
race condition in its fcntl locking that makes it unusably unreliable
(http://apenwarr.ca/log/?m=201012#13).

My tests indicate that if you only ever lock a *single* byterange on a file,
the race condition doesn't cause a problem.  So let's just use one lockfile
per target.  Now "redo -j20 test" passes for me on both MacOS and Linux.

This doesn't measurably affect the speed on Linux, at least, in my tests.

The bad news: it's hard to safely *delete* those lockfiles when we're done
with them, so they tend to accumulate in the .redo dir.
2010-12-14 02:44:29 -08:00
..
curse Switch to using a separate lockfile per target. 2010-12-14 02:44:29 -08:00
deps Fix tests on MacOS. 2010-12-12 05:38:30 -08:00
example $3 and stdout no longer refer to the same file. 2010-12-11 00:29:04 -08:00
space dir Add a new test for filenames with spaces. 2010-11-21 06:20:16 -08:00
stamp redo-always/redo-ifcreate/redo-stamp: work inside chdir(). 2010-12-11 23:42:45 -08:00
.gitignore Add a redo-ifcreate test. 2010-12-11 23:50:12 -08:00
all.do Remove special case for "dirname" -> "dirname/all" 2010-11-24 02:48:27 -08:00
always1.do redo-always/redo-ifcreate/redo-stamp: work inside chdir(). 2010-12-11 23:42:45 -08:00
alwaystest.do redo-always/redo-ifcreate/redo-stamp: work inside chdir(). 2010-12-11 23:42:45 -08:00
bellow.do Add minimal/do, a stripped-down redo implementation in 977 bytes of sh. 2010-11-16 00:27:52 -08:00
c.c.c.b.b.a Support for default.*.do rules. 2010-11-16 03:04:11 -08:00
c.do Support for default.*.do rules. 2010-11-16 03:04:11 -08:00
CC.do $3 and stdout no longer refer to the same file. 2010-12-11 00:29:04 -08:00
chdir1.do Correctly handle dependencies for "cd somewhere; redo-ifchange somefile" 2010-11-24 03:06:33 -08:00
chdir2.do Correctly handle dependencies for "cd somewhere; redo-ifchange somefile" 2010-11-24 03:06:33 -08:00
chdir3.do This tests the chdir-related bug from the previous commit. 2010-11-25 06:37:24 -08:00
chdirtest.do Disable the tests that don't work with minimal/do. 2010-12-11 21:06:12 -08:00
clean.do Add a redo-ifcreate test. 2010-12-11 23:50:12 -08:00
default.args.do minimal/do: handle nonzero exit codes and set $1/$2 correctly. 2010-11-17 19:07:27 -08:00
default.b.do Support for default.*.do rules. 2010-11-16 03:04:11 -08:00
default.c.c.do Support for default.*.do rules. 2010-11-16 03:04:11 -08:00
default.c.do Support for default.*.do rules. 2010-11-16 03:04:11 -08:00
default.do Support for default.*.do rules. 2010-11-16 03:04:11 -08:00
deltest.do If the .do script deletes $3, don't die. 2010-11-17 17:55:16 -08:00
deltest2.do If the .do script deletes $3, don't die. 2010-11-17 17:55:16 -08:00
flush-cache.sh Disable the tests that don't work with minimal/do. 2010-12-11 21:06:12 -08:00
hello.c Add README.md and LICENSE. 2010-11-17 00:53:58 -08:00
hello.do Add minimal/do, a stripped-down redo implementation in 977 bytes of sh. 2010-11-16 00:27:52 -08:00
hello.o.do t/*.do: add some time delays. 2010-11-13 02:17:22 -08:00
ifcreate-test.do Add a redo-ifcreate test. 2010-12-11 23:50:12 -08:00
ifcreate1.do Add a redo-ifcreate test. 2010-12-11 23:50:12 -08:00
ifcreate2.do Add a redo-ifcreate test. 2010-12-11 23:50:12 -08:00
LD.do $3 and stdout no longer refer to the same file. 2010-12-11 00:29:04 -08:00
makedir.do Remove special case for "dirname" -> "dirname/all" 2010-11-24 02:48:27 -08:00
makedir2.do Fix tests on MacOS. 2010-12-12 05:38:30 -08:00
mode1.do Targets created from stdout should be rw-, not rwx. 2010-11-24 02:26:15 -08:00
modetest.do Targets created from stdout should be rw-, not rwx. 2010-11-24 02:26:15 -08:00
passfail.do Add a new passfailtest. 2010-11-21 06:12:27 -08:00
passfailtest.do Disable the tests that don't work with minimal/do. 2010-12-11 21:06:12 -08:00
silencetest.do Disable the tests that don't work with minimal/do. 2010-12-11 21:06:12 -08:00
skip-if-minimal-do.sh Disable the tests that don't work with minimal/do. 2010-12-11 21:06:12 -08:00
sleep t/*.do: add some time delays. 2010-11-13 02:17:22 -08:00
test.do Add a redo-ifcreate test. 2010-12-11 23:50:12 -08:00
test2.args.do minimal/do: handle nonzero exit codes and set $1/$2 correctly. 2010-11-17 19:07:27 -08:00
touchtest.do $3 and stdout no longer refer to the same file. 2010-12-11 00:29:04 -08:00
yellow.do Add minimal/do, a stripped-down redo implementation in 977 bytes of sh. 2010-11-16 00:27:52 -08:00
yellow.o.do t/*.do: add some time delays. 2010-11-13 02:17:22 -08:00