From: Brett Cannon Date: Fri, 16 Oct 2015 19:30:20 +0000 (-0700) Subject: Issue #25188: Clean up code to pass the --pgo flag to subprocesses X-Git-Tag: v2.7.11rc1~63 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=eb2cb9737435d6b12beb48ec8e65dc55142349ad;p=thirdparty%2FPython%2Fcpython.git Issue #25188: Clean up code to pass the --pgo flag to subprocesses when running the test suite. Patch by Arfrever Frehtes Taifersar Arahesis. --- diff --git a/Lib/test/regrtest.py b/Lib/test/regrtest.py index 5c046ea52e09..a51387e93cea 100755 --- a/Lib/test/regrtest.py +++ b/Lib/test/regrtest.py @@ -508,7 +508,8 @@ def main(tests=None, testdir=None, verbose=0, quiet=False, for test in tests: args_tuple = ( (test, verbose, quiet), - dict(huntrleaks=huntrleaks, use_resources=use_resources) + dict(huntrleaks=huntrleaks, use_resources=use_resources, + pgo=pgo) ) yield (test, args_tuple) pending = tests_and_args() @@ -526,9 +527,6 @@ def main(tests=None, testdir=None, verbose=0, quiet=False, except StopIteration: output.put((None, None, None, None)) return - # required to permit running tests with PGO flag on/off - if pgo: - args_tuple[1]['pgo']=pgo # -E is needed by some tests, e.g. test_import popen = Popen(base_cmd + ['--slaveargs', json.dumps(args_tuple)], stdout=PIPE, stderr=PIPE,