Wisconsin benchmark

Started by Jeff Janesover 16 years ago4 messages
#1Jeff Janes
jeff.janes@gmail.com
1 attachment(s)

The Wisconsin Benchmark in src/test/bench is broken, probably since 8.2.

Attached is a tested patch that fixes it. However, it might be better
to just remove src/test/bench. The benchmark is quite useless,
because it is single user test that runs in the stand
alone mode, and because it is laughably small, taking just a couple
seconds on a 6 year old not-all-that good machine. And it doesn't
seem to be all that faithful to the Wisconsin Benchmark, as the string
fields are only 6 characters rather than 42 (I think) of the
benchmark.

Cheers,

Jeff

Attachments:

WISC-patchapplication/octet-stream; name=WISC-patchDownload
Index: src/test/bench/create.sh
===================================================================
RCS file: /home/jjanes/pgrepo/pgsql/src/test/bench/create.sh,v
retrieving revision 1.6
diff -c -r1.6 create.sh
*** src/test/bench/create.sh	1 Aug 2007 22:23:01 -0000	1.6
--- src/test/bench/create.sh	13 Aug 2009 19:46:23 -0000
***************
*** 10,25 ****
  fi
  
  echo =============== destroying old bench database... =================
! echo "drop database bench" | postgres -D"$1" postgres > /dev/null
  
  echo =============== creating new bench database... =================
! echo "create database bench" | postgres -D"$1" postgres > /dev/null
  if [ $? -ne 0 ]; then
  	echo createdb failed
  	exit 1
  fi
  
! postgres -D${1} bench < create.sql > /dev/null
  if [ $? -ne 0 ]; then
  	echo initial database load failed
  	exit 1
--- 10,25 ----
  fi
  
  echo =============== destroying old bench database... =================
! echo "drop database bench" | postgres --single -D"$1" postgres > /dev/null
  
  echo =============== creating new bench database... =================
! echo "create database bench" | postgres --single -D"$1" postgres > /dev/null
  if [ $? -ne 0 ]; then
  	echo createdb failed
  	exit 1
  fi
  
! postgres --single -D${1} bench < create.sql > /dev/null
  if [ $? -ne 0 ]; then
  	echo initial database load failed
  	exit 1
Index: src/test/bench/runwisc.sh
===================================================================
RCS file: /home/jjanes/pgrepo/pgsql/src/test/bench/runwisc.sh,v
retrieving revision 1.10
diff -c -r1.10 runwisc.sh
*** src/test/bench/runwisc.sh	19 Aug 2007 01:41:25 -0000	1.10
--- src/test/bench/runwisc.sh	13 Aug 2009 19:47:28 -0000
***************
*** 11,17 ****
  fi
  
  echo =============== vacuuming benchmark database... ================= >&2
! echo "vacuum" | postgres -D"$1" bench > /dev/null
  
  echo =============== running benchmark... ================= >&2
! time postgres -D"$1" -texecutor -tplanner -c log_min_messages=log -c log_destination=stderr -c start_log_collector=off bench < bench.sql 2>&1
--- 11,17 ----
  fi
  
  echo =============== vacuuming benchmark database... ================= >&2
! echo "vacuum" | postgres --single -D"$1" bench > /dev/null
  
  echo =============== running benchmark... ================= >&2
! time postgres --single -D"$1" -texecutor -tplanner -c log_min_messages=log -c log_destination=stderr -c logging_collector=off bench < bench.sql 2>&1
#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Jeff Janes (#1)
Re: Wisconsin benchmark

Jeff Janes <jeff.janes@gmail.com> writes:

The Wisconsin Benchmark in src/test/bench is broken, probably since 8.2.

Again? :-(

Attached is a tested patch that fixes it. However, it might be better
to just remove src/test/bench.

I tend to agree with this opinion. That benchmark is obsolete to the
point of having zero connection to the modern world; which is why we
keep not noticing when it's busted. Anyone want to argue for keeping it
in our sources?

regards, tom lane

In reply to: Tom Lane (#2)
Re: Wisconsin benchmark

Tom Lane escreveu:

I tend to agree with this opinion. That benchmark is obsolete to the
point of having zero connection to the modern world; which is why we
keep not noticing when it's busted. Anyone want to argue for keeping it
in our sources?

+1 for removing it.

--
Euler Taveira de Oliveira
http://www.timbira.com/

#4Josh Berkus
josh@agliodbs.com
In reply to: Tom Lane (#2)
Re: Wisconsin benchmark

I tend to agree with this opinion. That benchmark is obsolete to the
point of having zero connection to the modern world; which is why we
keep not noticing when it's busted. Anyone want to argue for keeping it
in our sources?

+1 on removing it.

--
Josh Berkus
PostgreSQL Experts Inc.
www.pgexperts.com