Skip to content

[SYCL] Implement SYCL_INTEL_enqueue_barrier DPC++ extension #1836

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 17 commits into from
Jun 11, 2020
Merged

[SYCL] Implement SYCL_INTEL_enqueue_barrier DPC++ extension #1836

merged 17 commits into from
Jun 11, 2020

Conversation

dm-vodopyanov
Copy link
Contributor

This patch adds the implementation of SYCL_INTEL_enqueue_barrier DPC++ extension.

There are situations where defining dependencies based on events is more explicit than desired or required by an application. For instance, the user may know that a given task depends on all previously submitted tasks. Instead of explicitly adding all the required handler::depends_on calls, the user could express this intent via a single call, making the program more concise and explicit.

To simplify the interface, this extension adds two new members to the handler class, and two new members to the queue class:

handler::barrier : void barrier() and void barrier(const vector_class<event> &WaitList)
queue::submit_barrier : event submit_barrier() and event submit_barrier(const vector_class<event> &WaitList)

@bader bader added the spec extension All issues/PRs related to extensions specifications label Jun 8, 2020
@dm-vodopyanov
Copy link
Contributor Author

dm-vodopyanov commented Jun 9, 2020

Also enqueue_barrier LIT test should be either updated with L0 support after merging PR #1839 as part of this PR (or as separate PR), or this test should be updated in #1839 if this PR (#1836) will be merged before merging #1839.
FYI @againull

Signed-off-by: Dmitry Vodopyanov <[email protected]>
smaslov-intel
smaslov-intel previously approved these changes Jun 9, 2020
@dm-vodopyanov
Copy link
Contributor Author

dm-vodopyanov commented Jun 9, 2020

It's Segmentation fault (core dumped) using L0 on zeCommandListAppendBarrier func call (I'm investigating this) and a non-related issue in LIT test, so please don't merge yet.

Upd: not on zeCommandListAppendBarrier func call, it's on ze_event_handle_t ZeEvent = (*Event)->ZeEvent; line.

@dm-vodopyanov
Copy link
Contributor Author

dm-vodopyanov commented Jun 9, 2020

@smaslov-intel I fixed segmentation fault in piEnqueueEventsWaitWithBarrier implementation for Level Zero, now feature works fine with it. Plus fixed a separate issue in LIT test. Could you please re-review?

@jbrodman could you review, please?

@againull
Copy link
Contributor

againull commented Jun 9, 2020

Also enqueue_barrier LIT test should be either updated with L0 support after merging PR #1839 as part of this PR (or as separate PR), or this test should be updated in #1839 if this PR (#1836) will be merged before merging #1839.
FYI @againull

Thank you very much for taking this into account!

@bader
Copy link
Contributor

bader commented Jun 10, 2020

@dm-vodopyanov, please, update your branch to fix the pre-commit tests.

@dm-vodopyanov
Copy link
Contributor Author

@bader Thanks! Updated.

Copy link
Contributor

@jbrodman jbrodman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@bader bader merged commit da6bfd0 into intel:sycl Jun 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
spec extension All issues/PRs related to extensions specifications
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants