Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Micro-ops that have side-exits are sometimes marked as "escaping", when they should not be. #137276

Copy link
Copy link
@markshannon

Description

@markshannon
Issue body actions

We tag micro-ops as "escaping", using HAS_ESCAPES_FLAG, when they call out to a function that might change the state of the world.

However, if that call only happens on an exit branch, then there is no escape if execution stays on trace.
In those cases we should not mark the micro-op as escaping.

For example: _GUARD_IS_NONE_POP is defined as follows:

            int is_none = PyStackRef_IsNone(val);
            if (!is_none) {
                PyStackRef_CLOSE(val);
                SYNC_SP();
                EXIT_IF(1);
            }
            DEAD(val);

The call to PyStackRef_CLOSE only occurs on the exit branch. So, if execution continues past _GUARD_IS_NONE_POP then no escaping call has been made. Therefore we shouldn't mark _GUARD_IS_NONE_POP as escaping.

Linked PRs

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)performancePerformance or resource usagePerformance or resource usagetopic-JIT

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.