Skip to content

A loop split between two hot executors never calls CHECK_EVAL_BREAKER() #117442

Closed
@gvanrossum

Description

@gvanrossum

When a tight for loop without calls is turned into two traces that transfer directly to each other, it seems that CHECK_EVAL_BREAKER() is never called, and the loop won't be interruptible.

See faster-cpython/ideas#669 (comment), where @brandtbucher and I reasoned that this might occur in the nbody benchmark (when the max trace length is reduced to 400).

While we didn't observe the predicted speedup, we really do believe that in this case the thread is uninterruptible.

@markshannon Any thoughts?

Linked PRs

Metadata

Metadata

Assignees

Labels

interpreter-core(Objects, Python, Grammar, and Parser dirs)

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions