Skip to content

Revert "gh-107265: Ensure _PyCode_Quicken does not handle ENTER_EXECU… #108485

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 25, 2023

Conversation

corona10
Copy link
Member

@corona10 corona10 commented Aug 25, 2023

@corona10
Copy link
Member Author

(.oss) ➜  cpython git:(gh-107265-_PyCode_Quicken-revert) ✗ ./python.exe -Xuops -m test test_sys
Raised RLIMIT_NOFILE: 256 -> 1024
0:00:00 load avg: 7.68 Run tests sequentially
0:00:00 load avg: 7.68 [1/1] test_sys
Assertion failed: (opcode != ENTER_EXECUTOR), function _PyCode_Quicken, file specialize.c, line 304.
Fatal Python error: Aborted

Current thread 0x0000000104dbc580 (most recent call first):
  <no Python frame>

Extension modules: _xxsubinterpreters, _xxinterpchannels, _testinternalcapi (total: 3)
[1]    20667 abort      ./python.exe -Xuops -m test test_sys

@gvanrossum gvanrossum enabled auto-merge (squash) August 25, 2023 14:58
@gvanrossum gvanrossum merged commit 66b4d9c into python:main Aug 25, 2023
@corona10 corona10 deleted the gh-107265-_PyCode_Quicken-revert branch August 25, 2023 15:24
@corona10
Copy link
Member Author

@gvanrossum
Even if we revert this assertion, I still think that decoding instruction to JUMP_BACKWARD is not needed since it's only counter-initialization.

instructions[i + 1].cache = adaptive_counter_warmup();

static inline uint16_t
adaptive_counter_bits(int value, int backoff) {
return (value << ADAPTIVE_BACKOFF_BITS) |
(backoff & ((1<<ADAPTIVE_BACKOFF_BITS)-1));
}

We are in the same line, or do you have different ideas?

@gvanrossum
Copy link
Member

See #108488

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants