- The water-n2 and water-sp tests read the number of threads 
  from their input file. The input file for these tests is now 
  generated and now contains the proper number of threads.
- Some SPLASH2 benchmarks accept the syntax -p${p} but not -p ${p},
  and some accept -p ${p} but not -p${p}.
- Commented out RAYTRACE benchmark because it seems to hang with p > 1.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@8256 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/exp-drd/scripts/measurement-functions b/exp-drd/scripts/measurement-functions
index dae5696..8abd03c 100644
--- a/exp-drd/scripts/measurement-functions
+++ b/exp-drd/scripts/measurement-functions
@@ -87,7 +87,7 @@
 }
 
 ## Echo all arguments on stderr, run the command passed in $1 .. ${$#} three
-#  times, pass the file specified in ${test_input} to the command, write the
+#  times, pass the output of ${test_input} -p${p} to the command, write the
 #  command output to the file specified in ${test_output}, and print the
 #  runtime of the command on stdout.
 function measure_runtime {
@@ -96,7 +96,7 @@
   echo "$@" >&2
   for ((i=0;i<3;i++))
   do
-    echo -n "$(cat "${test_input:-/dev/null}" | \
+    echo -n "$("${test_input:-true}" $p | \
       /usr/bin/time --format="%e" "$@" 2>&1 | \
       tee "${test_output:-/dev/null}" | \
       tail -n 1) "