diff --git a/cachegrind/docs/manual.html b/cachegrind/docs/manual.html
index ba6ef5c41..b86962c03 100644
--- a/cachegrind/docs/manual.html
+++ b/cachegrind/docs/manual.html
@@ -619,6 +619,37 @@ follows:
To find out if your program is blocking unexpectedly in the
read system call, run with
--trace-syscalls=yes flag.
+
+
truncate-writes Use this if you have a threaded
+ program which appears to unexpectedly block whilst writing
+ into a pipe. The effect is to modify all calls to
+ write() so that requests to write more than
+ 4096 bytes are treated as if they only requested a write of
+ 4096 bytes. Valgrind does this by changing the
+ count argument of write(), as
+ passed to the kernel, so that it is at most 4096. The
+ amount of data written will then be less than the client
+ program asked for, but the client should have a loop around
+ its write() call to check whether the requested
+ number of bytes have been written. If not, it should issue
+ further write() calls until all the data is
+ written.
+ + This all sounds pretty dodgy to me, which is why I've made + this behaviour only happen on request. It is not the + default behaviour. At the time of writing this (30 June + 2002) I have only seen one example where this is necessary, + so either the problem is extremely rare or nobody is using + Valgrind :-) +
+ On experimentation I see that truncate-writes
+ doesn't interact well with ioctl-VTIME, so you
+ probably don't want to try both at once.
+
+ As above, to find out if your program is blocking
+ unexpectedly in the write() system call, you
+ may find the --trace-syscalls=yes
+ --trace-sched=yes flags useful.
diff --git a/coregrind/docs/manual.html b/coregrind/docs/manual.html
index ba6ef5c41..b86962c03 100644
--- a/coregrind/docs/manual.html
+++ b/coregrind/docs/manual.html
@@ -619,6 +619,37 @@ follows:
To find out if your program is blocking unexpectedly in the
read system call, run with
--trace-syscalls=yes flag.
+
+
truncate-writes Use this if you have a threaded
+ program which appears to unexpectedly block whilst writing
+ into a pipe. The effect is to modify all calls to
+ write() so that requests to write more than
+ 4096 bytes are treated as if they only requested a write of
+ 4096 bytes. Valgrind does this by changing the
+ count argument of write(), as
+ passed to the kernel, so that it is at most 4096. The
+ amount of data written will then be less than the client
+ program asked for, but the client should have a loop around
+ its write() call to check whether the requested
+ number of bytes have been written. If not, it should issue
+ further write() calls until all the data is
+ written.
+ + This all sounds pretty dodgy to me, which is why I've made + this behaviour only happen on request. It is not the + default behaviour. At the time of writing this (30 June + 2002) I have only seen one example where this is necessary, + so either the problem is extremely rare or nobody is using + Valgrind :-) +
+ On experimentation I see that truncate-writes
+ doesn't interact well with ioctl-VTIME, so you
+ probably don't want to try both at once.
+
+ As above, to find out if your program is blocking
+ unexpectedly in the write() system call, you
+ may find the --trace-syscalls=yes
+ --trace-sched=yes flags useful.
diff --git a/coregrind/valgrind.in b/coregrind/valgrind.in
index fe31ce6bb..7b9927725 100755
--- a/coregrind/valgrind.in
+++ b/coregrind/valgrind.in
@@ -145,7 +145,7 @@ if [ $# = 0 ] || [ z"$dousage" = z1 ]; then
echo " --D1=
+
+ This all sounds pretty dodgy to me, which is why I've made
+ this behaviour only happen on request. It is not the
+ default behaviour. At the time of writing this (30 June
+ 2002) I have only seen one example where this is necessary,
+ so either the problem is extremely rare or nobody is using
+ Valgrind :-)
+
+ On experimentation I see that
+ As above, to find out if your program is blocking
+ unexpectedly in the
diff --git a/memcheck/docs/manual.html b/memcheck/docs/manual.html
index ba6ef5c41..b86962c03 100644
--- a/memcheck/docs/manual.html
+++ b/memcheck/docs/manual.html
@@ -619,6 +619,37 @@ follows:
To find out if your program is blocking unexpectedly in the
+
+ This all sounds pretty dodgy to me, which is why I've made
+ this behaviour only happen on request. It is not the
+ default behaviour. At the time of writing this (30 June
+ 2002) I have only seen one example where this is necessary,
+ so either the problem is extremely rare or nobody is using
+ Valgrind :-)
+
+ On experimentation I see that
+ As above, to find out if your program is blocking
+ unexpectedly in the
diff --git a/valgrind.in b/valgrind.in
index fe31ce6bb..7b9927725 100755
--- a/valgrind.in
+++ b/valgrind.in
@@ -145,7 +145,7 @@ if [ $# = 0 ] || [ z"$dousage" = z1 ]; then
echo " --D1=read system call, run with
--trace-syscalls=yes flag.
+ truncate-writes Use this if you have a threaded
+ program which appears to unexpectedly block whilst writing
+ into a pipe. The effect is to modify all calls to
+ write() so that requests to write more than
+ 4096 bytes are treated as if they only requested a write of
+ 4096 bytes. Valgrind does this by changing the
+ count argument of write(), as
+ passed to the kernel, so that it is at most 4096. The
+ amount of data written will then be less than the client
+ program asked for, but the client should have a loop around
+ its write() call to check whether the requested
+ number of bytes have been written. If not, it should issue
+ further write() calls until all the data is
+ written.
+ truncate-writes
+ doesn't interact well with ioctl-VTIME, so you
+ probably don't want to try both at once.
+ write() system call, you
+ may find the --trace-syscalls=yes
+ --trace-sched=yes flags useful.
read system call, run with
--trace-syscalls=yes flag.
+ truncate-writes Use this if you have a threaded
+ program which appears to unexpectedly block whilst writing
+ into a pipe. The effect is to modify all calls to
+ write() so that requests to write more than
+ 4096 bytes are treated as if they only requested a write of
+ 4096 bytes. Valgrind does this by changing the
+ count argument of write(), as
+ passed to the kernel, so that it is at most 4096. The
+ amount of data written will then be less than the client
+ program asked for, but the client should have a loop around
+ its write() call to check whether the requested
+ number of bytes have been written. If not, it should issue
+ further write() calls until all the data is
+ written.
+ truncate-writes
+ doesn't interact well with ioctl-VTIME, so you
+ probably don't want to try both at once.
+ write() system call, you
+ may find the --trace-syscalls=yes
+ --trace-sched=yes flags useful.