Skip to content

Fix bugs in kernel submission and creation - #2382

Merged
ndgrigorian merged 4 commits into
masterfrom
bug-fixes-for-kernel-submission
Oct 2, 2026
Merged

ndgrigorian merged 4 commits into
masterfrom
bug-fixes-for-kernel-submission

Conversation

@ndgrigorian

Copy link
Copy Markdown
Collaborator

This PR addresses two bugs with dpctl's kernel bundle interoperability.

In the first bug, when creating a kernel bundle, it was possible for the resulting object to wrap a NULL reference if the creation somehow failed or could not link to a module. This would cause a crash at submission. It was also possible to get a NULL-wrapping kernel if providing a mangled name that doesn't exist.

The second bug, when submitting to a queue, if the number of arguments was incorrect, the user would not receive any feedback and it would act as if the submission succeeded.

  • Have you provided a meaningful PR description?
  • Have you added a test, reproducer or referred to an issue with a reproducer?
  • Have you tested your changes locally for CPU and GPU devices?
  • Have you made sure that new changes do not introduce compiler warnings?
  • Have you checked performance impact of proposed changes?
  • Have you added documentation for your changes, if necessary?
  • Have you added your changes to the changelog?
  • If this PR is a work in progress, are you opening the PR as a draft?

@github-actions

github-actions Bot commented Sep 16, 2026 •

Copy link
Copy Markdown

Deleted rendered PR docs from intelpython.github.com/dpctl, latest should be updated shortly. 🤞

@coveralls

coveralls commented Sep 16, 2026 •

Copy link
Copy Markdown
Collaborator

Coverage Status

coverage: 74.989% (+0.03%) from 74.959% — bug-fixes-for-kernel-submission into master

Comment thread dpctl/_sycl_queue.pyx
Comment thread dpctl/tests/test_sycl_compiler.py
Comment thread dpctl/tests/test_sycl_kernel_submit.py
Comment thread dpctl/_sycl_queue.pyx
Getting a named kernel from a kernel bundle that does not contain it could cause a crash.

It was also possible for a kernel bundle wrapping a NULL reference, which could then be submitted and crash
@ndgrigorian
ndgrigorian force-pushed the bug-fixes-for-kernel-submission branch from c1153db to 8eb2ec2 Compare October 1, 2026 05:13
antonwolfy
antonwolfy previously approved these changes Oct 1, 2026

@antonwolfy antonwolfy left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thank you @ndgrigorian, LGTM with only small optional nit.

Comment thread dpctl/_sycl_queue.pyx

@antonwolfy antonwolfy left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM

@ndgrigorian
ndgrigorian merged commit 229807a into master Oct 2, 2026
126 of 127 checks passed
@ndgrigorian
ndgrigorian deleted the bug-fixes-for-kernel-submission branch October 2, 2026 15:01
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