Skip to content

Conversation

@steffenlarsen
Copy link
Contributor

This commit adds wording specifying that access mode applies to all devices in the context for which the corresponding memory is accessible.

This commit adds wording specifying that access mode applies to all
devices in the context for which the corresponding memory is accessible.

Signed-off-by: Larsen, Steffen <[email protected]>
@steffenlarsen steffenlarsen requested a review from a team as a code owner November 6, 2025 12:14
result in undefined behavior.
result in undefined behavior. The accessibility applies to all devices in
the context associated with this instance of `physical_mem` from which the
physical memory is reachable.
Copy link
Contributor

Choose a reason for hiding this comment

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

Under what circumstances would the physical memory be reachable from another device? I assume this would only be the case if the application used sycl_ext_oneapi_peer_access to enable peer-to-peer access? If that is the case, I think we should word it more explicitly:

If other devices have enabled peer-to-peer access with this device via sycl_ext_oneapi_peer_access, those other devices also have access to this mapped memory, and the access mode applies to accesses from those devices also.

Copy link

Choose a reason for hiding this comment

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

@steffenlarsen Thanks for the update. Overall, it looks good to me.
I'd just like to confirm that sycl_ext_oneapi_peer_access only affects the regular allocation (e.g., those returned by sycl::aligned_alloc_device) and doesn't impact virtual memory introduced in this extension. The access mode for virtual memory should only be controlled by the APIs explicitly mentioned in this extension, right?

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