mirror of https://github.com/python/cpython
bcce5e2718
This adds a 16-bit inline cache entry to the conditional branch instructions POP_JUMP_IF_{FALSE,TRUE,NONE,NOT_NONE} and their instrumented variants, which is used to keep track of the branch direction. Each time we encounter these instructions we shift the cache entry left by one and set the bottom bit to whether we jumped. Then when it's time to translate such a branch to Tier 2 uops, we use the bit count from the cache entry to decided whether to continue translating the "didn't jump" branch or the "jumped" branch. The counter is initialized to a pattern of alternating ones and zeros to avoid bias. The .pyc file magic number is updated. There's a new test, some fixes for existing tests, and a few miscellaneous cleanups. |
||
---|---|---|
.. | ||
metadata | ||
resources | ||
__init__.py | ||
_abc.py | ||
_bootstrap.py | ||
_bootstrap_external.py | ||
abc.py | ||
machinery.py | ||
readers.py | ||
simple.py | ||
util.py |