Skip to content

Spec that WaitAny doesn't return until callbacks complete #552

@kainino0x

Description

@kainino0x

Say we have event E with callback C.
Thread T1 calls WaitAny and is the first to discover that E is ready. It triggers C, and C runs for some time.
Thread T2 calls WaitAny and sees that E is already completing, so it doesn't trigger C. However, WaitAny shouldn't return until T1 finishes running the callback. Otherwise, T2 will get ahead of the callback that WaitAny was supposed to guarantee was called.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions