From 0dacdc3c73a27384f5228e4eb64bd57f8c10aefe Mon Sep 17 00:00:00 2001 From: bdemsky Date: Wed, 1 Jul 2009 01:54:24 +0000 Subject: [PATCH] make setup for benchmarks --- .../src/Benchmarks/SingleTM/Genome/makefile | 8 +-- .../src/Benchmarks/SingleTM/KMeans/makefile | 9 ++-- .../Benchmarks/SingleTM/Labyrinth/makefile | 12 ++--- Robust/src/Benchmarks/SingleTM/SSCA2/makefile | 13 +++-- Robust/src/Benchmarks/SingleTM/compileall | 16 ++++++ Robust/src/Benchmarks/SingleTM/runall | 53 +++++++++++++++++++ 6 files changed, 88 insertions(+), 23 deletions(-) create mode 100755 Robust/src/Benchmarks/SingleTM/compileall create mode 100755 Robust/src/Benchmarks/SingleTM/runall diff --git a/Robust/src/Benchmarks/SingleTM/Genome/makefile b/Robust/src/Benchmarks/SingleTM/Genome/makefile index d18720dd..9184f110 100644 --- a/Robust/src/Benchmarks/SingleTM/Genome/makefile +++ b/Robust/src/Benchmarks/SingleTM/Genome/makefile @@ -1,4 +1,6 @@ MAINCLASS=Genome +include ../common/Makefile.flags + SRC=${MAINCLASS}.java \ ../common/Random.java \ Bitmap.java \ @@ -10,10 +12,10 @@ SRC=${MAINCLASS}.java \ Sequencer.java \ Table.java \ Hashtable.java -FLAGS=-mainclass ${MAINCLASS} -singleTM -optimize -debug -fastmemcpy -abcclose -dcopts -joptimize -default: - ../../../buildscript ${FLAGS} -o ${MAINCLASS} ${SRC} +include ../common/Makefile.builds + +prep: clean: rm -rf tmpbuilddirectory diff --git a/Robust/src/Benchmarks/SingleTM/KMeans/makefile b/Robust/src/Benchmarks/SingleTM/KMeans/makefile index d40c8996..aa6fe7bb 100644 --- a/Robust/src/Benchmarks/SingleTM/KMeans/makefile +++ b/Robust/src/Benchmarks/SingleTM/KMeans/makefile @@ -6,13 +6,12 @@ SRC=${MAINCLASS}.java \ Common.java \ GlobalArgs.java \ ../../../ClassLibrary/JavaSTM/Barrier.java -FLAGS=-mainclass ${MAINCLASS} -singleTM -optimize -debug -dcopts -joptimize -stmstats -fastmemcpy -FLAGS2=-mainclass ${MAINCLASS} -singleTM -optimize -debug -joptimize -fastmemcpy -abcclose -dcopts -FLAGS3=-mainclass ${MAINCLASS} -optimize -debug -joptimize -thread +include ../common/Makefile.flags -default: - ../../../buildscript ${FLAGS2} -o GEN${MAINCLASS} ${SRC} +include ../common/Makefile.builds + +prep: clean: rm -rf tmpbuilddirectory diff --git a/Robust/src/Benchmarks/SingleTM/Labyrinth/makefile b/Robust/src/Benchmarks/SingleTM/Labyrinth/makefile index 5f084bcd..2659558d 100644 --- a/Robust/src/Benchmarks/SingleTM/Labyrinth/makefile +++ b/Robust/src/Benchmarks/SingleTM/Labyrinth/makefile @@ -15,13 +15,11 @@ SRC=ttttmp${MAINCLASS}.java \ Solve_arg.java \ ../../../ClassLibrary/JavaSTM/Barrier.java -FLAGS=-mainclass ${MAINCLASS} -singleTM -optimize -debug -delaycomp -joptimize -fastmemcpy -profile -32bit -inlineatomic 2 +include ../common/Makefile.flags -FLAGS2=-mainclass ${MAINCLASS} -thread -optimize -debug -joptimize -32bit +include ../common/Makefile.builds -FLAGS3=-mainclass ${MAINCLASS} -singleTM -nooptimize -debug -32bit - -default: +prep: cpp ${MAINCLASS}.java > tmp${MAINCLASS}.java cpp Grid.java > tmpGrid.java cpp Router.java > tmpRouter.java @@ -34,9 +32,7 @@ default: ./extractLines tmpMaze.java ./extractLines tmpQueue_t.java ./extractLines tmpQueue_Int.java -# ../../../buildscript ${FLAGS} -o ${MAINCLASS} ${SRC} - ../../../buildscript ${FLAGS3} -o STM${MAINCLASS} ${SRC} -# ../../../buildscript ${FLAGS2} -o LOCK${MAINCLASS} ${SRC} + clean: rm -rf tmpbuilddirectory diff --git a/Robust/src/Benchmarks/SingleTM/SSCA2/makefile b/Robust/src/Benchmarks/SingleTM/SSCA2/makefile index b01d83e1..c9f1b72e 100644 --- a/Robust/src/Benchmarks/SingleTM/SSCA2/makefile +++ b/Robust/src/Benchmarks/SingleTM/SSCA2/makefile @@ -14,19 +14,18 @@ SRC=tmp${MAINCLASS}.java \ VList.java \ ../common/Random.java \ ../../../ClassLibrary/JavaSTM/Barrier.java -FLAGS=-mainclass ${MAINCLASS} -singleTM -optimize -debug -dcopts -stmstats -fastmemcpy -transstats -joptimize -abcclose -# -joptimize -default: +include ../common/Makefile.flags + +include ../common/Makefile.builds + +prep: # cpp -DUSE_PARALLEL_DATA_GENERATION ${MAINCLASS}.java > tmp1${MAINCLASS}.java # ./extractLines # ../../../buildscript ${FLAGS} -o ${MAINCLASS} ${SRC} cpp -DENABLE_KERNEL1 ${MAINCLASS}.java > tmp1${MAINCLASS}.java ./extractLines - ../../../buildscript ${FLAGS} -o ${MAINCLASS} ${SRC} -# cpp -DENABLE_KERNEL2 -DENABLE_KERNEL3 ${MAINCLASS}.java > tmp1${MAINCLASS}.java -# ./extractLines -# ../../../buildscript ${FLAGS} -o ${MAINCLASS} ${SRC} + clean: rm tmp1SSCA2.java diff --git a/Robust/src/Benchmarks/SingleTM/compileall b/Robust/src/Benchmarks/SingleTM/compileall new file mode 100755 index 00000000..a293e670 --- /dev/null +++ b/Robust/src/Benchmarks/SingleTM/compileall @@ -0,0 +1,16 @@ +#!/bin/bash +cd KMeans +make & +cd .. + +cd SSCA2 +make & +cd .. + +cd Labyrinth +make & +cd .. + +cd Genome +make & +cd .. \ No newline at end of file diff --git a/Robust/src/Benchmarks/SingleTM/runall b/Robust/src/Benchmarks/SingleTM/runall new file mode 100755 index 00000000..afd1de64 --- /dev/null +++ b/Robust/src/Benchmarks/SingleTM/runall @@ -0,0 +1,53 @@ +#/bin/bash +function run { +dir="$1" +command="$2" +shift +shift +args="$@" +cd $dir +echo ============================================================ +echo Running Fission $command $@ +time ./FIS$command $args +echo +echo +echo Running STM $command $@ +time ./STM$command $args +echo +echo +echo Running Optimized STM $command $@ +time ./OPTSTM$command $args +echo +echo +echo Running Lock $command $@ +time ./LOCK$command $args +echo +echo +cd .. +} +#get plenty of stack space +ulimit -s 40000 + +#Kmeans +run KMeans KMeans.bin -m 15 -n 15 -t 0.00001 -i inputs/random-n65536-d32-c16.txt -nthreads 1 +run KMeans KMeans.bin -m 15 -n 15 -t 0.00001 -i inputs/random-n65536-d32-c16.txt -nthreads 2 +run KMeans KMeans.bin -m 15 -n 15 -t 0.00001 -i inputs/random-n65536-d32-c16.txt -nthreads 4 +run KMeans KMeans.bin -m 15 -n 15 -t 0.00001 -i inputs/random-n65536-d32-c16.txt -nthreads 8 + +#SSCA2 +run SSCA2 SSCA2.bin -s 20 -i 1.0 -u 1.0 -l 3 -p 3 -t 1 +run SSCA2 SSCA2.bin -s 20 -i 1.0 -u 1.0 -l 3 -p 3 -t 2 +run SSCA2 SSCA2.bin -s 20 -i 1.0 -u 1.0 -l 3 -p 3 -t 4 +run SSCA2 SSCA2.bin -s 20 -i 1.0 -u 1.0 -l 3 -p 3 -t 8 + +#Labrynth +run Labyrinth Labyrinth.bin -i inputs/random-x512-y512-z7-n512.txt -t 1 +run Labyrinth Labyrinth.bin -i inputs/random-x512-y512-z7-n512.txt -t 2 +run Labyrinth Labyrinth.bin -i inputs/random-x512-y512-z7-n512.txt -t 4 +run Labyrinth Labyrinth.bin -i inputs/random-x512-y512-z7-n512.txt -t 8 + +#Genome +run Genome Genome.bin -g 8192 -s 32 -n 167721 -t 1 +run Genome Genome.bin -g 8192 -s 32 -n 167721 -t 2 +run Genome Genome.bin -g 8192 -s 32 -n 167721 -t 4 +run Genome Genome.bin -g 8192 -s 32 -n 167721 -t 8 \ No newline at end of file -- 2.34.1