-
Notifications
You must be signed in to change notification settings - Fork 769
[SYCL] Remove OwnZeMemHandle from USMAllocator #7853
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
Conversation
I'm not entirely sure if doing |
@smaslov-intel could you please take a look at this PR? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1
b48835b
to
62936e5
Compare
@intel/llvm-gatekeepers I've just rebased the PR - I think it's ready for merge. |
@intel/llvm-gatekeepers @againull @smaslov-intel is there something pending to merge this? |
@igchor, review from @intel/llvm-reviewers-runtime is missing. |
But why is it needed? Should we change codeowner for the Unified Runtime directories? |
I think the idea was that the common part of Unified Runtime (including usm_allocator) would be eventually owned by Codeplay and the Intel UR team (people from https://github.com/orgs/oneapi-src/teams/unified-runtime-maintain) |
I suggest that we keep current ownership until https://github.com/intel/llvm/tree/sycl/sycl/plugins/unified_runtime/ur is moved into a separate repo, where the new ownership would be more natural. ETA EoQ1'23 |
Do you think it would make sense to move just the usm_allocator to the UR repo before EoQ1? We already moved the core UMA abstractions there. This would minimize changes required in the llvm repo - (we would only need to integrate L0 adapter with UMA) |
Yeah, let's do that. |
@igchor, could you resolve merge conflicts, please? |
OwnZeMemHandle is used to track whether an allocation should be freed by the runtime or not. There is no point in passing this flag to USMAllocator and then to USMFreeHelper since the allocation cannot come from the USMAllocator (it can only be from zeMemAlloc*).
62936e5
to
d56ca08
Compare
Sure, done. |
OwnZeMemHandle is used to track whether an allocation should be freed by the runtime or not.
There is no point in passing this flag to USMAllocator and then to USMFreeHelper since the allocation cannot come from the USMAllocator (it can only be from zeMemAlloc*).
I've thought about moving the memory allocation code to UR first, but there are a lot of dependencies: we would have to move the implementation of context, device, event, and queue at least. It seemed that doing this small change first made more sense.