Skip to content

Conversation

@DBDuncan
Copy link
Contributor

@DBDuncan DBDuncan commented Oct 2, 2024

Add support for device 'image_mem_handle' to 'image_mem_handle' sub-region copies and implement tests

…Region Copy

Add support for device 'image_mem_handle' to 'image_mem_handle' sub-region copies and implement tests
@DBDuncan DBDuncan requested review from a team as code owners October 2, 2024 16:11
@DBDuncan DBDuncan requested a review from cperkinsintel October 2, 2024 16:11
@DBDuncan
Copy link
Contributor Author

DBDuncan commented Oct 3, 2024

Friendly ping @intel/llvm-reviewers-runtime @cperkinsintel

const ext::oneapi::experimental::image_descriptor &ImageDesc);

// Device to device copy with offsets and extent
void ext_oneapi_copy(
Copy link
Contributor

Choose a reason for hiding this comment

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

are we sure about this name? For something so generic like ext_oneapi_copy I would expect something that handles any type of memory (not just image data) and maybe across all address spaces (host, device). Much like queue.copy() is now.

But, the comments on this routine suggest its capability is much more focused. If so, I think it's name should express that. maybe something like ext_oneapi_d2d_img_copy or ext_d2d_img_copy ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We already have a lot of overloads that perform copies. The reason we chose this originally is we just intended to extend the existing copy functionality to support new bindless images. Also, our overloads are not just images to images but also memory to memory copies.

Copy link
Contributor Author

@DBDuncan DBDuncan Oct 4, 2024

Choose a reason for hiding this comment

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

There are other new overloads planned to be added. Such as host to host and device usm to device image_mem_handle.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have been thinking that perhaps the amount of ext_oneapi_copy overloads we have is getting a bit unwieldy. Especially considering a number additional ones need to be added to support more device to device copy variants.

I don't think it would be a good idea to start making changes involving other copy functions here. But something to be looked into later.

Copy link
Contributor

Choose a reason for hiding this comment

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

sorry for not responding to your comments earlier. If there are other overloads that handle other data types, it wouldn't hurt to mention that in the comment. Even just "this overload of ext_copy is for bindless images".

Copy link
Contributor Author

@DBDuncan DBDuncan Oct 15, 2024

Choose a reason for hiding this comment

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

No problem, thanks for the approval! On your suggestion, it would likely be best to apply a comment like you suggest to all the overloads at the same time which is a bit out of scope it feels for this PR. As there are 50~ of them (Have to triple them in queue.hpp...). queue.hpp and handler.hpp need a bit of a refactor which is very tentatively planned early next year. Double checking the order of the functions and their corresponding comments. Comments stating they are overloads for bindless images can be added then.

@DBDuncan
Copy link
Contributor Author

DBDuncan commented Oct 8, 2024

@cperkinsintel Friendly ping

@DBDuncan
Copy link
Contributor Author

@intel/llvm-gatekeepers Please merge, thanks!

@sommerlukas sommerlukas merged commit 7082efa into intel:sycl Oct 15, 2024
13 checks passed
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.

5 participants