Skip to content
This repository was archived by the owner on Feb 13, 2025. It is now read-only.
This repository was archived by the owner on Feb 13, 2025. It is now read-only.

Crash when setting up a tasklet belonging to a different thread #60

Closed
@ghost

Description

Originally reported by: Kristján Valur Jónsson (Bitbucket: krisvale, GitHub: kristjanvalur)


The attached file demonstrates a crash recently discovered. If a tasklet created on a different thread gets setup, it crashes. This occurs because a cstack is being allocated using the wrong thread state.
This happens because of a call to "slp_ensure_linkage" in the "bind_task_to_frame" call. If this call is omitted, then all runs fine. But then we have failures in the unittests.

I have never understood what the slp_ensure_linkage is supposed to do. I would like to fix this without complicating the cstack allocation by using the task's thread state. What is the slp_ensure_linkage supposed to be doing?

tcrash.py.zip


Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions