Skip to content

Conversation

@aarongreig
Copy link
Contributor

The CL spec wording on this is kind of fuzzy but every CL driver I tested (across intel, amd, nvidia cpu + gpu) returns an error when you have a local size set in the program source/IL and you don't specify any local size in your clEnqueueNDRangeKernel call (i.e. you leave it as NULL).

Our spec does allow you to leave local size as null if you have a size specified in your program, so this change adds some logic to query out the size set in the program and passes it to the enqueue call.

Initially I was concerned this might impact performance of current users but it looks like SYCL always passes a local size when calling urEnqueueKernelLaunch so it won't hit the path with the extra query.

@github-actions github-actions bot added the conformance Conformance test suite issues. label Oct 1, 2024
@aarongreig
Copy link
Contributor Author

LLVM PR intel/llvm#15571

@aarongreig aarongreig marked this pull request as ready for review October 2, 2024 09:19
@aarongreig aarongreig requested review from a team as code owners October 2, 2024 09:19
@aarongreig aarongreig added the ready to merge Added to PR's which are ready to merge label Oct 7, 2024
The CL spec wording on this is kind of fuzzy but every CL driver I
tested (across intel, amd, nvidia cpu + gpu) returns an error when you
have a local size set in the program source/IL and you don't specify any
local size in your clEnqueueNDRangeKernel call (i.e. you leave it as
NULL).

Our spec does allow you to leave local size as null if you have a size
specified in your program, so this change adds some logic to query out
the size set in the program and passes it to the enqueue call.

Initially I was concerned this might impact performance of current users
but it looks like SYCL always passes a local size when calling
urEnqueueKernelLaunch so it won't hit the path with the extra query.
@aarongreig aarongreig force-pushed the aaron/clQuerySourceWGSize branch from 24ed565 to a97df49 Compare October 22, 2024 10:57
@aarongreig aarongreig merged commit 58abf8f into oneapi-src:main Oct 24, 2024
76 of 77 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conformance Conformance test suite issues. ready to merge Added to PR's which are ready to merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants