Summary
Description: Unnamed repository; edit this file to name it for gitweb.
Last Change: Wed 2/3/10 13:04
Recent Commits
>
--git a/pts/benchmark-profiles/gtkperf.xml b/pts/benchmark-profiles/gtkperf.xml
index a6ecd04..482ea0d 100644
--- a/pts/benchmark-profiles/gtkperf.xml
+++ b/pts/benchmark-profiles/gtkperf.xml
@@ -1,6 +1,6 @@
<PTSBenchmark>
<PhoronixTestSuite>
- <Version>0.2</Version>
+ <Version>0.3</Version>
<BenchmarkType>Graphics</BenchmarkType>
<ApplicationType>Utility</ApplicationType>
<License>FREE</License>
@@ -14,13 +14,37 @@
<Executable>gtkperf</Executable>
<ExternalDependencies>gtk-development</ExternalDependencies>
<TimesToRun>1</TimesToRun>
- <ResultScale>FPS</ResultScale>
+ <ResultScale>Seconds</ResultScale>
<Description>This test calculates the average frame-rate in some GTK tests.</Description>
<Notes> </Notes>
</Information>
<Settings>
- <Default>
- <Arguments>-a -c 1000</Arguments>
- </Default>
+ <Option>
+ <DisplayName>GTK Widget</DisplayName>
+ <Identifier>gtk-test</Identifier>
+ <ArgumentName></ArgumentName>
+ <Menu>
+ <Entry>
+ <Name>GtkComboBox</Name>
+ <Value>COMBOBOX</Value>
+ </Entry>
+ <Entry>
+ <Name>GtkToggleButton</Name>
+ <Value>TOGGLE_BUTTON</Value>
+ </Entry>
+ <Entry>
+ <Name>GtkRadioButton</Name>
+ <Value>RADIO_BUTTON</Value>
+ </Entry>
+ <Entry>
+ <Name>GtkTextView - Add Text</Name>
+ <Value>TEXTVIEW_ADD</Value>
+ </Entry>
+ <Entry>
+ <Name>GtkTextView - Scroll</Name>
+ <Value>TEXTVIEW_SCROLL</Value>
+ </Entry>
+ </Menu>
+ </Option>
</Settings>
</PTSBenchmark>
diff --git a/pts/benchmark-resources/gtkperf/install.sh b/pts/benchmark-resources/gtkperf/install.sh
index ca208fb..9f95917 100644
--- a/pts/benchmark-resources/gtkperf/install.sh
+++ b/pts/benchmark-resources/gtkperf/install.sh
@@ -19,5 +19,29 @@ cd ..
rm -rf gtkperf/
echo "#!/bin/sh
-./gtkperf_env/bin/gtkperf \$@" > gtkperf
+
+if [ ! -f $THIS_RUN_TIME.result ]
+ then
+ rm -f *.result
+ ./gtkperf_env/bin/gtkperf -a -c 1000 > $THIS_RUN_TIME.result
+fi
+
+case "\$1\" in
+\"COMBOBOX\")
+ cat \$THIS_RUN_TIME.result | grep \"GtkComboBox \"
+ ;;
+\"TOGGLE_BUTTON\")
+ cat \$THIS_RUN_TIME.result | grep \"GtkToggleButton \"
+ ;;
+\"RADIO_BUTTON\")
+ cat \$THIS_RUN_TIME.result | grep \"GtkRadioButton \"
+ ;;
+\"TEXTVIEW_ADD\")
+ cat \$THIS_RUN_TIME.result | grep \"GtkTextView - Add text\"
+ ;;
+\"TEXTVIEW_SCROLL\")
+ cat \$THIS_RUN_TIME.result | grep \"GtkTextView - Scroll\"
+ ;;
+esac
+" > gtkperf
chmod +x gtkperf
diff --git a/pts/benchmark-resources/gtkperf/parse-results.php b/pts/benchmark-resources/gtkperf/parse-results.php
index 3320f72..dc08839 100644
--- a/pts/benchmark-resources/gtkperf/parse-results.php
+++ b/pts/benchmark-resources/gtkperf/parse-results.php
@@ -1,8 +1,6 @@
<?php
-//$BENCHMARK_RESULTS = substr($argv[1], strrpos($argv[1], "WAV To MP3 Encode Time:") + 23);
-//echo trim(substr($BENCHMARK_RESULTS, 0, strpos($BENCHMARK_RESULTS, "Seconds")));
-
-echo $BENCHMARK_RESULTS;
+$BENCHMARK_RESULTS = substr($argv[1], strrpos($argv[1], "time:") + 5);
+echo trim(substr($BENCHMARK_RESULTS, 0, strpos($BENCHMARK_RESULTS, "\n")));
Copyright © 2010 by Phoronix Media