This repository was archived by the owner on Mar 2, 2026. It is now read-only.
[SYCL][Graph] Support for read and write for 1d and 2d buffers#238
Merged
mfrancepillois merged 1 commit intosycl-graph-developfrom Jun 27, 2023
Merged
Conversation
Bensuo
reviewed
Jun 23, 2023
Collaborator
Bensuo
left a comment
There was a problem hiding this comment.
Good work! Mostly minor comments/nitpicks.
sycl/plugins/unified_runtime/ur/adapters/level_zero/ur_level_zero_command_buffer.cpp
Outdated
Show resolved
Hide resolved
sycl/plugins/unified_runtime/ur/adapters/level_zero/ur_level_zero_command_buffer.cpp
Outdated
Show resolved
Hide resolved
sycl/test-e2e/Graph/Explicit/buffer_copy_host2target_offset.cpp
Outdated
Show resolved
Hide resolved
sycl/test-e2e/Graph/Explicit/buffer_copy_host2target_offset.cpp
Outdated
Show resolved
Hide resolved
sycl/test-e2e/Graph/Explicit/buffer_copy_target2host_offset.cpp
Outdated
Show resolved
Hide resolved
4ffa711 to
3292593
Compare
EwanC
reviewed
Jun 26, 2023
Collaborator
EwanC
left a comment
There was a problem hiding this comment.
Looks great overall, have some minor comments.
sycl/plugins/unified_runtime/ur/adapters/level_zero/ur_level_zero_command_buffer.cpp
Outdated
Show resolved
Hide resolved
EwanC
reviewed
Jun 26, 2023
3292593 to
7cae0f2
Compare
EwanC
reviewed
Jun 26, 2023
EwanC
reviewed
Jun 26, 2023
7cae0f2 to
719f400
Compare
EwanC
reviewed
Jun 27, 2023
EwanC
pushed a commit
that referenced
this pull request
Jun 27, 2023
Pulls in changes from #238 which requires bumping the UR commit to oneapi-src/unified-runtime#644 Co-authored-by: Maxime France-Pillois <maxime.francepillois@codeplay.com>
719f400 to
0c4f0b6
Compare
EwanC
approved these changes
Jun 27, 2023
Collaborator
EwanC
left a comment
There was a problem hiding this comment.
Final couple files where the parameter naming needs touched up, but looks good to go otherwise.
sycl/plugins/unified_runtime/ur/adapters/level_zero/ur_level_zero_command_buffer.cpp
Outdated
Show resolved
Hide resolved
…uffers
Adds support required to handle:
- host to buffer memcpy for 1d and 2d buffers
- buffer to host memcpy for 1d and 2d buffers
This commit also fixes a bug in buffer to buffer memcpy enabling to copy
from/to buffers accessed with user-defined offsets.
Adds basic tests to check all use-cases of mixed host/buffer memcpy, and
buffer to buffer memcpy with user-defined offsets.
Addresses Issue: #196
0c4f0b6 to
4589950
Compare
EwanC
pushed a commit
that referenced
this pull request
Jun 27, 2023
Fix some build errors I've seen with clang-17 after #238 was merged. 1) Arithmitic on void pointer, fixed by passing a `char*` rather than `void*` when an offset is needed ``` /home/ewan/Development/dpcpp/sycl/source/detail/memory_manager.cpp:1316:44: error: arithmetic on a pointer to void 1316 | SrcAccessRangeWidthBytes, DstMem + DstXOffBytes, Deps.size(), | ~~~~~~ ^ /home/ewan/Development/dpcpp/sycl/source/detail/memory_manager.cpp:1372:44: error: arithmetic on a pointer to void 1372 | DstAccessRangeWidthBytes, SrcMem + SrcXOffBytes, Deps.size(), | ~~~~~~ ^ 2) Fixup use of `numEventsInWaitList` when should be `numSyncPointsInWaitList` /home/ewan/Development/dpcpp/sycl/plugins/unified_runtime/ur/adapters/level_zero/ur_level_zero_command_buffer.cpp:611:13: error: use of undeclared identifier 'numEventsInWaitList' 611 | size, numEventsInWaitList, pSyncPointWaitList, pSyncPoint); ```
EwanC
pushed a commit
that referenced
this pull request
Jun 27, 2023
Fix some build errors I've seen with clang-17 after #238 was merged. 1) Arithmitic on void pointer, fixed by passing a `char*` rather than `void*` when an offset is needed ``` /home/ewan/Development/dpcpp/sycl/source/detail/memory_manager.cpp:1316:44: error: arithmetic on a pointer to void 1316 | SrcAccessRangeWidthBytes, DstMem + DstXOffBytes, Deps.size(), | ~~~~~~ ^ /home/ewan/Development/dpcpp/sycl/source/detail/memory_manager.cpp:1372:44: error: arithmetic on a pointer to void 1372 | DstAccessRangeWidthBytes, SrcMem + SrcXOffBytes, Deps.size(), | ~~~~~~ ^ 2) Fixup use of `numEventsInWaitList` when should be `numSyncPointsInWaitList` /home/ewan/Development/dpcpp/sycl/plugins/unified_runtime/ur/adapters/level_zero/ur_level_zero_command_buffer.cpp:611:13: error: use of undeclared identifier 'numEventsInWaitList' 611 | size, numEventsInWaitList, pSyncPointWaitList, pSyncPoint); ```
EwanC
pushed a commit
that referenced
this pull request
Jun 29, 2023
…uffers (#238) Adds support required to handle: - host to buffer memcpy for 1d and 2d buffers - buffer to host memcpy for 1d and 2d buffers This commit also fixes a bug in buffer to buffer memcpy enabling to copy from/to buffers accessed with user-defined offsets. Adds basic tests to check all use-cases of mixed host/buffer memcpy, and buffer to buffer memcpy with user-defined offsets. Addresses Issue: #196
EwanC
pushed a commit
that referenced
this pull request
Jun 29, 2023
Fix some build errors I've seen with clang-17 after #238 was merged. 1) Arithmitic on void pointer, fixed by passing a `char*` rather than `void*` when an offset is needed ``` /home/ewan/Development/dpcpp/sycl/source/detail/memory_manager.cpp:1316:44: error: arithmetic on a pointer to void 1316 | SrcAccessRangeWidthBytes, DstMem + DstXOffBytes, Deps.size(), | ~~~~~~ ^ /home/ewan/Development/dpcpp/sycl/source/detail/memory_manager.cpp:1372:44: error: arithmetic on a pointer to void 1372 | DstAccessRangeWidthBytes, SrcMem + SrcXOffBytes, Deps.size(), | ~~~~~~ ^ 2) Fixup use of `numEventsInWaitList` when should be `numSyncPointsInWaitList` /home/ewan/Development/dpcpp/sycl/plugins/unified_runtime/ur/adapters/level_zero/ur_level_zero_command_buffer.cpp:611:13: error: use of undeclared identifier 'numEventsInWaitList' 611 | size, numEventsInWaitList, pSyncPointWaitList, pSyncPoint); ```
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds support required to handle:
- host to buffer memcpy for one-dimensional and 2d buffers
- buffer to host memcpy for 1d and 2d buffers
This commit also fixes a bug in buffer to buffer memcpy enabling to copy from/to buffers accessed with user-defined offsets.
Adds basic tests to check all use-cases of mixed host/buffer memcpy, and buffer to buffer memcpy with user-defined offsets.
Addresses Issue: #196