KhronosGroup / KhronosGroup/SYCL-Docs

State of default constructed event should be re-considered

Open
#360 13 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
JavaScript
Stars
158
Forks
80
Avg merge
7d 6h
Merged PRs (30d)
5

Description

This issue raises a reasonable (IMHO) use case of events:
https://github.com/Apress/data-parallel-CPP/issues/20

Default constructed events initialize to the ready state in SYCL 2020:

> Constructs an event that is immediately ready

This seems like a confusing and error prone design point. Instead I'd expect the code in the linked issue to either work as the developer intended (wait and operate out of order) in the unsignaled interpretation, or to throw a synchronous exception that invalid events have been used on the initial `parallel_for` submission.

The current spec may make it easier to introduce program bugs than originally thought. Should be discussed within the Khronos WG.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading the SYCL 2020 wording that says a default-constructed event is immediately ready, then review the linked data-parallel-CPP example. Compare the proposed unsignaled interpretation and synchronous-exception behavior, and bring the alternatives to the Khronos WG; done requires a decided specification direction and corresponding wording.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
documentation
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.