mirror of
https://github.com/python/cpython.git
synced 2025-08-15 22:30:42 +00:00
bpo-36044: Reduce number of unit tests run for PGO build (GH-14702)
Reduce the number of unit tests run for the PGO generation task. This
speeds up the task by a factor of about 15x. Running the full unit test
suite is slow. This change may result in a slightly less optimized build
since not as many code branches will be executed. If you are willing to
wait for the much slower build, the old behavior can be restored using
'./configure [..] PROFILE_TASK="-m test --pgo-extended"'. We make no
guarantees as to which PGO task set produces a faster build. Users who
care should run their own relevant benchmarks as results can depend on
the environment, workload, and compiler tool chain.
(cherry picked from commit 4e16a4a311
)
Co-authored-by: Neil Schemenauer <nas-github@arctrix.com>
This commit is contained in:
parent
5b398520a8
commit
2406672984
7 changed files with 96 additions and 4 deletions
|
@ -17,6 +17,7 @@ from test.libregrtest.runtest import (
|
|||
INTERRUPTED, CHILD_ERROR, TEST_DID_NOT_RUN,
|
||||
PROGRESS_MIN_TIME, format_test_result, is_failed)
|
||||
from test.libregrtest.setup import setup_tests
|
||||
from test.libregrtest.pgo import setup_pgo_tests
|
||||
from test.libregrtest.utils import removepy, count, format_duration, printlist
|
||||
from test import support
|
||||
|
||||
|
@ -214,6 +215,9 @@ class Regrtest:
|
|||
|
||||
removepy(self.tests)
|
||||
|
||||
# add default PGO tests if no tests are specified
|
||||
setup_pgo_tests(self.ns)
|
||||
|
||||
stdtests = STDTESTS[:]
|
||||
nottests = NOTTESTS.copy()
|
||||
if self.ns.exclude:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue