Example #1
0
    try:
        engine.update()
        if engine.updated:
            NumUpdated += 1
        RunningEngines.append(engine)
    except Exception, e:
        import logging
        logging.exception(e)  # or pass an error message, see comment


class Slave:
    def __init__(self, machine):
        self.machine = machine


submitter = submitter.getSubmitter(options.submitter)
submit = submitter(Slave(utils.config.get('main', 'machine')))

# No updates. Report to server and wait 60 seconds, before moving on
if NumUpdated == 0 and not options.force:
    submit.Awake()
    time.sleep(60)
    sys.exit(0)

# Report all engines
submit.Start()
for e in RunningEngines:
    for modeInfo in e.modes:
        submit.AddEngine(modeInfo["name"], e.cset)

ranBenchmark = False
Example #2
0
NumUpdated = 0
RunningEngines = []
for engine in KnownEngines:
    try:
        engine.update()
        if engine.updated:
            NumUpdated += 1
        RunningEngines.append(engine)
    except Exception, e:
        import logging
        logging.exception(e) # or pass an error message, see comment

class Slave:
    def __init__(self, machine):
        self.machine = machine
submitter = submitter.getSubmitter(options.submitter)
submit = submitter(Slave(utils.config.get('main', 'machine')))

# No updates. Report to server and wait 60 seconds, before moving on
if NumUpdated == 0 and not options.force:
    submit.Awake();
    time.sleep(60)
    sys.exit(0)

# Report all engines
submit.Start()
for e in RunningEngines:
    for modeInfo in e.modes:
        submit.AddEngine(modeInfo["name"], e.cset)

ranBenchmark = False
Example #3
0
utils.config.init(options.config_name)

# Set resource limits for child processes
resource.setrlimit(resource.RLIMIT_AS, (-1, -1))
resource.setrlimit(resource.RLIMIT_RSS, (-1, -1))
resource.setrlimit(resource.RLIMIT_DATA, (-1, -1))

# Set of engines that get build.
KnownEngines = [builders.MozillaInbound(),
                builders.V8(),
                builders.Nitro()
               ]
Engines, NumUpdated = builders.build(KnownEngines, not options.noupdate, options.force)

submitter = getSubmitter(options.submitter)

# No updates. Report to server and wait 60 seconds, before moving on
if NumUpdated == 0 and not options.force:
    if options.submitter == 'remote':
        for slave in slaves.init():
            submit = submitter(slave)
            submit.Awake();
        time.sleep(60)
    sys.exit(0)

# The native compiler is a special thing, for now.
native = builders.NativeCompiler()

# A mode is a configuration of an engine we just built.
Mode = namedtuple('Mode', ['shell', 'args', 'env', 'name', 'cset'])
Example #4
0
    try:
        engine.update()
        if engine.updated:
            NumUpdated += 1
        RunningEngines.append(engine)
    except Exception, e:
        import logging
        logging.exception(e)  # or pass an error message, see comment


class Slave:
    def __init__(self, machine):
        self.machine = machine


submitter = submitter.getSubmitter("remote")
submit = submitter(Slave(utils.config.get('main', 'machine')))

# No updates. Report to server and wait 60 seconds, before moving on
if NumUpdated == 0 and not options.force:
    submit.Awake()
    time.sleep(60)
    sys.exit(0)

# Report all engines
submit.Start()
for e in RunningEngines:
    for modeInfo in e.modes:
        submit.AddEngine(modeInfo["name"], e.cset)

ranBenchmark = False
Example #5
0
utils.config.init(options.config_name)

# Set resource limits for child processes
resource.setrlimit(resource.RLIMIT_AS, (-1, -1))
resource.setrlimit(resource.RLIMIT_RSS, (-1, -1))
resource.setrlimit(resource.RLIMIT_DATA, (-1, -1))

# Set of engines that get build.
KnownEngines = [builders.MozillaInbound(),
                builders.V8(),
                builders.Nitro()
               ]
Engines, NumUpdated = builders.build(KnownEngines, not options.noupdate, options.force)

submitter = getSubmitter(options.submitter)

# No updates. Report to server and wait 60 seconds, before moving on
if NumUpdated == 0 and not options.force:
    if options.submitter == 'remote':
        for slave in slaves.init():
            submit = submitter(slave)
            submit.Awake();
        time.sleep(60)
    sys.exit(0)

# The native compiler is a special thing, for now.
native = builders.NativeCompiler()

# A mode is a configuration of an engine we just built.
Mode = namedtuple('Mode', ['shell', 'args', 'env', 'name', 'cset'])
Example #6
0
NumUpdated = 0
RunningEngines = []
for engine in KnownEngines:
    try:
        engine.update()
        if engine.updated:
            NumUpdated += 1
        RunningEngines.append(engine)
    except Exception, e:
        import logging
        logging.exception(e) # or pass an error message, see comment

class Slave:
    def __init__(self, machine):
        self.machine = machine
submitter = submitter.getSubmitter("remote")
submit = submitter(Slave(utils.config.get('main', 'machine')))

# No updates. Report to server and wait 60 seconds, before moving on
if NumUpdated == 0 and not options.force:
    submit.Awake();
    time.sleep(60)
    sys.exit(0)

# Report all engines
submit.Start()
for e in RunningEngines:
    for modeInfo in e.modes:
        submit.AddEngine(modeInfo["name"], e.cset)

ranBenchmark = False
Example #7
0
        'name' : 'sunspider',
        'version' : '1.0.1',
        'filter' : benchmark.sunspider_filter,
        'output' : None
    },
    'kraken': {
        'name' : 'kraken',
        'version' : '1.1',
        'filter' : benchmark.sunspider_filter,
        'output' : None
    }
}

utils.config.init(configFile)
if utils.config.get('main', 'local') == 'yes':
    submit = submitter.getSubmitter('print')
else:
    submit = submitter.getSubmitter('remote')
slave = slaves.Slave('main')
submit = submit(slave)

# Run benchmarks, filter and collect outputs.
for suite in benchmarks.keys():
    try:
        output = runGaiaTest(benchmarks[suite]['name'])
        benchmarks[suite]['output'] = benchmarks[suite]['filter'](output)
    except Exception as e:
        benchmarks[suite]['output'] = None
        print e

# Submit the request to the remote DB.