Hi David and gnu ppl!
Q: Would it be bad to change the DD(1) util like this?
--- src/dd.bak 2004-01-21 23:27:02.000000000 +0100
+++ src/dd.c 2006-10-10 23:16:20.000000000 +0200
@@ -1058,6 +1058,7 @@
if (ibuf == obuf) /* If not C_TWOBUFS. */
{
size_t nwritten = full_write (STDOUT_FILENO, obuf, n_bytes_read);
+ posix_fadvise(STDOUT_FILENO,0,0,POSIX_FADV_DONTNEED);
if (nwritten != n_bytes_read)
{
error (0, errno, _("writing %s"), quote (output_file));
I'am doing so in order to benchmark writing files several times the
physical memory without invalidating all imported cached pages. In my
case the bandwidth did increase while the system didnt have noticable
latency (the default dd would expire all dentries etc).
--
Leroy