diff tuning.sh @ 57:397089dccb32

Compile with -O2. Add tuning parameters and tuning results script
author Mike Pavone <pavone@retrodev.com>
date Sun, 15 Jul 2012 23:55:29 -0700
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tuning.sh	Sun Jul 15 23:55:29 2012 -0700
@@ -0,0 +1,12 @@
+#!/bin/sh
+echo $@ >> tuningresults.txt
+echo >> tuningresults.txt
+
+for file in maps/contest1.map maps/contest2.map maps/contest3.map maps/contest4.map maps/contest5.map maps/contest6.map maps/contest7.map maps/contest8.map; do
+	/usr/bin/time -f %E -o tuntiming.txt bin/lifter $@ < $file 2>tunout.txt
+	text=`tail -n 6 tunout.txt`
+	score=`echo $text | sed 's/.*score: \([0-9]*\).*/\1/'`
+	time=`cat tuntiming.txt`
+	echo "$file: $score ($time)";
+	echo "$file: $score ($time)" >> tuningresults.txt
+done