Skip to content
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

cl_khr_external_semaphore: Clarify language #938

Merged

Conversation

lakshmih
Copy link
Contributor

@lakshmih lakshmih commented Jun 9, 2023

Refined the cl_khr_external_semaphore spec. Removed references to permanence which appear to have been leveraged from the Vulkan spec but don’t apply to the OpenCL spec in its current form.

@CLAassistant
Copy link

CLAassistant commented Jun 9, 2023

CLA assistant check
All committers have signed the CLA.

@bashbaug
Copy link
Contributor

bashbaug commented Sep 5, 2023

Leaving this open until the discussion around re-importing semaphore handles is closed.

@nikhiljnv
Copy link
Contributor

@lakshmih If we still need this PR, we need to resolve conflicts at TOT.

@lakshmih lakshmih force-pushed the clarify_cl_khr_external_semaphore branch from c97958c to 8aba57a Compare April 1, 2024 23:34
Refined the cl_khr_external_semaphore spec. Removed references
to permanence which appear to have been leveraged from the
Vulkan spec but don’t apply to the OpenCL spec in its current form.
@lakshmih lakshmih force-pushed the clarify_cl_khr_external_semaphore branch from 8aba57a to 19e0a28 Compare May 20, 2024 23:42
Copy link
Contributor

@bashbaug bashbaug left a comment

Choose a reason for hiding this comment

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

This mostly looks good to me, and I really like the updated description, nice work!

If it helps other reviewers, the relevant Vulkan control for temporary vs. permanent import is VK_SEMAPHORE_IMPORT_TEMPORARY_BIT_KHR. Since there is no OpenCL equivalent, I agree we should not make any references to application control of temporary or permanent imports.

Do we still need to introduce the concept of a temporary import though, since SYNC_FD imports are temporary? Or, is this also not applicable to OpenCL, because we only support creating a semaphore from an external handle, and do not support importing an external handle into an already created semaphore?

(Note: clReImportSemaphoreSyncFdKHR is specified to behave as-if the semaphore object was destroyed and re-created with the new handle, so conceptually it is still creating a semaphore.)

|====
| Handle Type | Transference | Permanence
| Handle Type | Transference
Copy link
Contributor

Choose a reason for hiding this comment

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

Since we're modifying the number of table columns I think we also need to update the table contents for CL_SEMAPHORE_HANDLE_SYNC_FD_KHR below.

@bcalidas
Copy link

As mentioned in an earlier comment, OpenCL does not importing an external handle into an already created semaphore. This avoids the need for introducing the concept of temporary handle import.

must not affect any other semaphore or payload.

Please refer to handle specific documentation for more details on transference requirements per
handle type.
Copy link
Contributor

Choose a reason for hiding this comment

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

This feels like a good step forward. I'm wondering whether we should mention re-import commands in this paragraph. In the end the command was made specific to sync_fd while this paragraph is documents generic bits of behaviour.

Copy link
Contributor

@paulfradgley paulfradgley left a comment

Choose a reason for hiding this comment

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

Changes look good to me.

@bashbaug
Copy link
Contributor

bashbaug commented Jul 9, 2024

Merging as discussed in the July 9th teleconference.

@bashbaug bashbaug merged commit 40fbb79 into KhronosGroup:main Jul 9, 2024
2 checks passed
kpet added a commit to kpet/OpenCL-Docs that referenced this pull request Jul 10, 2024
This would have enabled the CI to catch a markup issue introduced by KhronosGroup#938.

Signed-off-by: Kevin Petit <[email protected]>
Change-Id: I49de3eaf623117f7c29d1019dedf5b342766a029
kpet added a commit to kpet/OpenCL-Docs that referenced this pull request Jul 10, 2024
Introduced by KhronosGroup#938

Signed-off-by: Kevin Petit <[email protected]>
Change-Id: Ibef16bceb5398c49a14e88818a45236d0e17acf0
@kpet kpet mentioned this pull request Jul 10, 2024
bashbaug pushed a commit that referenced this pull request Jul 10, 2024
Introduced by #938


Change-Id: Ibef16bceb5398c49a14e88818a45236d0e17acf0

Signed-off-by: Kevin Petit <[email protected]>
kpet added a commit to kpet/OpenCL-Docs that referenced this pull request Jul 10, 2024
This would have enabled the CI to catch a markup issue introduced by KhronosGroup#938.

Signed-off-by: Kevin Petit <[email protected]>
Change-Id: I49de3eaf623117f7c29d1019dedf5b342766a029
bashbaug pushed a commit that referenced this pull request Jul 10, 2024
* Fail spec creation if asciidoctor errors are encountered

This would have enabled the CI to catch a markup issue introduced by #938.

Signed-off-by: Kevin Petit <[email protected]>
Change-Id: I49de3eaf623117f7c29d1019dedf5b342766a029

* attempt to fix asciidoctor errors in API spec

Change-Id: I0f9cbeddb72e0d76ba508b336d91c4ee640d77ad

---------

Signed-off-by: Kevin Petit <[email protected]>
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.

7 participants