Changeset 139902 in webkit
- Timestamp:
- Jan 16, 2013 11:25:40 AM (11 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/PerformanceTests/SunSpider/ChangeLog
r124558 r139902 1 2013-01-16 Eric Seidel <eric@webkit.org> 2 3 Remove --shark* support from sunspider/run-sunspider now that Shark is dead 4 https://bugs.webkit.org/show_bug.cgi?id=99512 5 6 Reviewed by Darin Adler. 7 8 I tried to use --instruments, but that also seems broken (in the same way before/after this patch). 9 10 * sunspider: 11 (runTestsOnce): 12 1 13 2012-08-02 Filip Pizlo <fpizlo@apple.com> 2 14 -
trunk/PerformanceTests/SunSpider/sunspider
r110389 r139902 34 34 35 35 my $showHelp = 0; 36 my $runShark = 0;37 my $runShark20 = 0;38 my $runSharkCache = 0;39 36 my $runInstruments = 0; 40 37 my $ubench = 0; … … 57 54 --runs Number of times to run tests (default: $testRuns) 58 55 --tests Only run tests matching provided pattern 59 --shark Sample execution time with the Mac OS X "Shark" performance testing tool (implies --runs=1)60 --shark20 Like --shark, but with a 20 microsecond sampling interval61 --shark-cache Like --shark, but performs a L2 cache-miss sample instead of time sample62 56 --instruments Sample execution time with the Mac OS X "Instruments" tool (Time Profile) (implies --runs=1) 63 57 --suite Select a specific benchmark suite. The default is sunspider-1.0 … … 71 65 'shell=s' => \$jsShellPath, 72 66 'args=s' => \$jsShellArgs, 73 'shark' => \$runShark,74 'shark20' => \$runShark20,75 'shark-cache' => \$runSharkCache,76 67 'instruments' => \$runInstruments, 77 68 'suite=s' => \$suite, … … 93 84 $suitePath = "tests/" . $suitePath unless ($suite =~ /\//); 94 85 95 $runShark = 1 if $runSharkCache; 96 $runShark = 20 if $runShark20; 97 $testRuns = 1 if $runShark || $runInstruments; 98 if ($runShark && ! -x "/usr/bin/shark") { 99 die "Please install CHUD tools from http://developer.apple.com/tools/download/\n"; 100 } 101 102 my $sharkCacheProfileIndex = 0; 103 if ($runSharkCache) { 104 my $sharkProfileList = `shark -l 2>&1`; 105 for my $profile (split(/\n/, $sharkProfileList)) { 106 $profile =~ /(\d+) - (.+)/; 107 next unless (defined $1); 108 my $profileIndex = $1; 109 my $profileName = $2; 110 if ($profileName =~ /L2 Cache/) { 111 $sharkCacheProfileIndex = $profileIndex; 112 print "Using Shark L2 Cache Miss Profile: " . $profile . "\n"; 113 last; 114 } 115 } 116 die "Failed to find L2 Cache Miss Profile for --shark-cache\n" unless ($sharkCacheProfileIndex); 117 } 86 $testRuns = 1 if $runInstruments; 118 87 119 88 if (!$jsShellPath || $showHelp) { … … 166 135 } 167 136 168 sub runTestsOnce($ $)169 { 170 my ($use Shark, $useInstruments) = @_;137 sub runTestsOnce($) 138 { 139 my ($useInstruments) = @_; 171 140 my $shellArgs = $jsShellArgs . " -f $prefixFile -f resources/sunspider-standalone-driver.js 2> " . File::Spec->devnull(); 172 141 my $output; 173 if ($useShark) { 174 my $intervalArg = $useShark == 20 ? "-I 20u" : ""; 175 my $cacheArg = $runSharkCache ? "-c $sharkCacheProfileIndex" : ""; 176 $output = `shark $intervalArg $cacheArg -i -1-q "$jsShellPath" $shellArgs`; 177 } elsif ($useInstruments) { 142 if ($useInstruments) { 178 143 $output = `instruments -t "resources/TimeProfile20us.tracetemplate" "$jsShellPath" $shellArgs`; 179 144 } else { … … 211 176 } 212 177 die "No tests to run" unless scalar(@tests); 213 print STDERR "Running SunSpider once for warmup, then " . ($run Shark ? "under Shark" : ($runInstruments ? "under Instruments" : "$testRuns time" . ($testRuns == 1 ? "" : "s"))) . "\n";178 print STDERR "Running SunSpider once for warmup, then " . ($runInstruments ? "under Instruments" : "$testRuns time" . ($testRuns == 1 ? "" : "s")) . "\n"; 214 179 writePrefixFile(); 215 180 216 runTestsOnce(0 , 0);181 runTestsOnce(0); 217 182 print "Discarded first run.\n"; 218 183 … … 223 188 print "["; 224 189 while ($count++ < $testRuns) { 225 $result = runTestsOnce($run Shark, $runInstruments);190 $result = runTestsOnce($runInstruments); 226 191 $result =~ s/\r\n/\n/g; 227 192 chomp $result; … … 239 204 240 205 print("\nResults are located at $resultsFile\n"); 241 242 if ($runShark) {243 my $newestMShark = newestFile(".", qr/\.mshark$/);244 if ($newestMShark) {245 my $profileFile = "$resultDirectory/sunspider-profile-$timeString.mshark";246 rename $newestMShark, $profileFile or die;247 exec "/usr/bin/open", $profileFile;248 }249 }250 206 251 207 if ($runInstruments) { -
trunk/Tools/ChangeLog
r139901 r139902 1 2013-01-16 Eric Seidel <eric@webkit.org> 2 3 Remove --shark* support from sunspider/run-sunspider now that Shark is dead 4 https://bugs.webkit.org/show_bug.cgi?id=99512 5 6 Reviewed by Darin Adler. 7 8 * Scripts/run-sunspider: 9 1 10 2013-01-16 Eric Seidel <eric@webkit.org> 2 11 -
trunk/Tools/Scripts/run-sunspider
r110389 r139902 39 39 my $root; 40 40 my $testRuns = 10; # This number may be different from what sunspider defaults to (that's OK) 41 my $runShark = 0;42 my $runShark20 = 0;43 my $runSharkCache = 0;44 41 my $runInstruments = 0; 45 42 my $suite = ""; … … 60 57 --runs Number of times to run tests (default: $testRuns) 61 58 --tests Only run tests matching provided pattern 62 --shark Sample with the Mac OS X "Shark" performance testing tool (implies --runs=1)63 --shark20 Like --shark, but with a 20 microsecond sampling interval64 --shark-cache Like --shark, but performs a L2 cache-miss sample instead of time sample65 59 --instruments Sample with the Mac OS X "Instruments" tool (Time Profile) (implies --runs=1) 66 60 --suite Select a specific benchmark suite. The default is sunspider-0.9.1 … … 74 68 'runs=i' => \$testRuns, 75 69 'set-baseline' => \$setBaseline, 76 'shark' => \$runShark,77 'shark20' => \$runShark20,78 'shark-cache' => \$runSharkCache,79 70 'instruments' => \$runInstruments, 80 71 'suite=s' => \$suite, … … 126 117 # This code could be removed if we chose to pass extra args to sunspider instead of Xcode 127 118 push @args, "--set-baseline" if $setBaseline; 128 push @args, "--shark" if $runShark;129 push @args, "--shark20" if $runShark20;130 push @args, "--shark-cache" if $runSharkCache;131 119 push @args, "--instruments" if $runInstruments; 132 120 push @args, "--suite=${suite}" if $suite;
Note: See TracChangeset
for help on using the changeset viewer.