Changeset 157887 in webkit


Ignore:
Timestamp:
Oct 23, 2013 2:15:50 PM (10 years ago)
Author:
fpizlo@apple.com
Message:

Have a way of dealing with slow tests in run-jsc-stress-tests
https://bugs.webkit.org/show_bug.cgi?id=123221

Tools:

Reviewed by Mark Hahnenberg.

If you add the slow! command to @ then all subsequent plans are prepended to the run list
rather than appended to it. This means that slow tests get queued up first and are less likely
to block completion.

  • Scripts/run-jsc-stress-tests:

LayoutTests:

Reviewed by Mark Hahnenberg.

  • js/regress/script-tests/stepanov_container.js: This test is slow!
Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r157886 r157887  
     12013-10-23  Filip Pizlo  <fpizlo@apple.com>
     2
     3        Have a way of dealing with slow tests in run-jsc-stress-tests
     4        https://bugs.webkit.org/show_bug.cgi?id=123221
     5
     6        Reviewed by Mark Hahnenberg.
     7       
     8        * js/regress/script-tests/stepanov_container.js: This test is slow!
     9
    1102013-10-23  Alexey Proskuryakov  <ap@apple.com>
    211
  • trunk/LayoutTests/js/regress/script-tests/stepanov_container.js

    r157637 r157887  
     1//@ slow!
    12//@ runDefault
    23//@ runDefaultFTL if $enableFTL
  • trunk/Tools/ChangeLog

    r157882 r157887  
     12013-10-23  Filip Pizlo  <fpizlo@apple.com>
     2
     3        Have a way of dealing with slow tests in run-jsc-stress-tests
     4        https://bugs.webkit.org/show_bug.cgi?id=123221
     5
     6        Reviewed by Mark Hahnenberg.
     7       
     8        If you add the slow! command to //@ then all subsequent plans are prepended to the run list
     9        rather than appended to it. This means that slow tests get queued up first and are less likely
     10        to block completion.
     11
     12        * Scripts/run-jsc-stress-tests:
     13
    1142013-10-23  Alex Christensen  <achristensen@webkit.org>
    215
  • trunk/Tools/Scripts/run-jsc-stress-tests

    r157557 r157887  
    7272end
    7373
    74 numProcessors = `sysctl -n hw.availcpu`.to_i
    75 if numProcessors == 0
    76     numProcessors = `nproc --all 2>/dev/null`.to_i
    77 end
    78 if numProcessors == 0
    79     numProcessors = 1
     74$numProcessors = `sysctl -n hw.availcpu`.to_i
     75if $numProcessors == 0
     76    $numProcessors = `nproc --all 2>/dev/null`.to_i
     77end
     78if $numProcessors == 0
     79    $numProcessors = 1
    8080end
    8181
     
    270270end
    271271
     272$runCommandOptions = {}
     273
    272274class Plan
    273275    attr_reader :directory, :arguments, :name, :outputHandler, :errorHandler
     
    280282        @outputHandler = outputHandler
    281283        @errorHandler = errorHandler
     284        @isSlow = !!$runCommandOptions[:isSlow]
    282285    end
    283286   
     
    347350
    348351def addRunCommand(kind, command, outputHandler, errorHandler)
    349     $runlist << Plan.new($benchmarkDirectory, command, baseOutputName(kind), outputHandler, errorHandler)
     352    plan = Plan.new($benchmarkDirectory, command, baseOutputName(kind), outputHandler, errorHandler)
     353    if $numProcessors > 1 and $runCommandOptions[:isSlow]
     354        $runlist.unshift plan
     355    else
     356        $runlist << plan
     357    end
    350358end
    351359
     
    355363def parseRunCommands
    356364    didRun = false
     365    $runCommandOptions = {}
    357366    File.open($benchmarkDirectory + $benchmark) {
    358367        | inp |
     
    372381    }
    373382    didRun
     383end
     384
     385def slow!
     386    $runCommandOptions[:isSlow] = true
    374387end
    375388
     
    660673    # In the worst case, the processors just interfere with each other.
    661674    # Increase the timeout proportionally to the number of processors.
    662     ENV["JSC_timeout"] = (ENV["JSC_timeout"].to_i.to_f * Math.sqrt(numProcessors)).to_i.to_s
     675    ENV["JSC_timeout"] = (ENV["JSC_timeout"].to_i.to_f * Math.sqrt($numProcessors)).to_i.to_s
    663676end
    664677
     
    741754Dir.chdir(parallelDir) {
    742755    unless $progressMeter
    743         mysys("make", "-j", numProcessors.to_s, "-s", "-f", "Makefile")
     756        mysys("make", "-j", $numProcessors.to_s, "-s", "-f", "Makefile")
    744757    else
    745         cmd = "make -j #{numProcessors} -s -f Makefile"
     758        cmd = "make -j #{$numProcessors} -s -f Makefile"
    746759        running = {}
    747760        didRun = {}
Note: See TracChangeset for help on using the changeset viewer.