Skip to content

[SYCL] Pass handler & instead of queue across ABI for reduction utils #18834

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 2 commits into from
Jun 6, 2025

Conversation

aelovikov-intel
Copy link
Contributor

@aelovikov-intel aelovikov-intel commented Jun 5, 2025

Queue might be nullptr in case of graph, but the information these
utilitiess query is device-specific. By passing entire handler & and having
access to graph information we'd be able to return more precise results.

Another positive side-effect is that we eliminiate explicit
std::shared_ptr<queue_impl> which is a small step forward in the
ongoing refactoring efforts to prefer passing *_impl by raw ptr/ref
with explicit shared_from_this whenever lifetimes need to be extended.

@aelovikov-intel
Copy link
Contributor Author

aelovikov-intel commented Jun 5, 2025

This is based on top of #18830, please ignore first commit during review. Also, while @intel/sycl-graphs-reviewers aren't technically owners of the reduction-related changes, it mostly affects the graph-related code path, so their review is still welcome.

Queue might be `nullptr` in case of graph, but the information this
utils query is device-specific. By passing entire `handler &` and having
access to graph information we'd be able to return more precise results.

Another positive side-effect is that we eliminiate explicit
`std::shared_ptr<queue_impl>` which is a small step forward in the
ongoing refactoring efforts to prefer passing `*_impl` by raw ptr/ref
with explicit `shared_from_this` whenever lifetimes need to be extended.
@aelovikov-intel
Copy link
Contributor Author

This is based on top of #18830, please ignore first commit during review. Also, while @intel/sycl-graphs-reviewers aren't technically owners of the reduction-related changes, it mostly affects the graph-related code path, so their review is still welcome.

Rebased, not relevant anymore. @intel/sycl-graphs-reviewers review request still stands :)

@slawekptak, this is ready for review.

aelovikov-intel added a commit to aelovikov-intel/llvm that referenced this pull request Jun 6, 2025
Initially started in intel#18830
Subsequent PRs before this final one:

intel#18794
intel#18834
Copy link
Contributor

@fabiomestre fabiomestre left a comment

Choose a reason for hiding this comment

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

@aelovikov-intel aelovikov-intel merged commit 00a716a into intel:sycl Jun 6, 2025
35 of 37 checks passed
@aelovikov-intel aelovikov-intel deleted the handler-in-red-utils branch June 6, 2025 18:38
aelovikov-intel added a commit to aelovikov-intel/llvm that referenced this pull request Jun 6, 2025
Initially started in intel#18830
Subsequent PRs before this final one:

intel#18794
intel#18834
aelovikov-intel added a commit to aelovikov-intel/llvm that referenced this pull request Jun 6, 2025
aelovikov-intel added a commit to aelovikov-intel/llvm that referenced this pull request Jun 6, 2025
aelovikov-intel added a commit to aelovikov-intel/llvm that referenced this pull request Jun 6, 2025
aelovikov-intel added a commit to aelovikov-intel/llvm that referenced this pull request Jun 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants