-
Notifications
You must be signed in to change notification settings - Fork 787
[SYCL] Reuse plugin information so that it's not copied when sycl::detail::plugin is copied #5049
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
…tail::plugin is copied Signed-off-by: Sergey Kanaev <[email protected]>
@smaslov-intel , do you see any potential caveats here? |
Signed-off-by: Sergey Kanaev <[email protected]>
Signed-off-by: Sergey Kanaev <[email protected]>
Signed-off-by: Sergey Kanaev <[email protected]>
Signed-off-by: Sergey Kanaev <[email protected]>
Signed-off-by: Sergey Kanaev <[email protected]>
Signed-off-by: Sergey Kanaev <[email protected]>
@@ -236,7 +241,7 @@ class plugin { | |||
std::shared_ptr<std::mutex> getPluginMutex() { return MPluginMutex; } | |||
|
|||
private: | |||
RT::PiPlugin MPlugin; | |||
std::shared_ptr<RT::PiPlugin> MPlugin; |
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.
Shouldn't we have one to one mapping between plugin
and RT::PiPlugin
and one to many between plugin
and platform
?
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.
You're right. Though, adding such a change to this patch will make it more complex for review.
Shifting to 1-1 plugin-pi_plugin and 1-n plugin-platform is the next step.
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.
Don't we already have 1:many mapping to platforms at line 253?
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.
@smaslov-intel , there's such a mapping between sycl::detail::plugin
and pi_platform
. Though, I have an intent to add the same mapping for sycl::detail::plugin
and sycl::detail::platform_impl
as opposed to copying sycl::detail::plugin
for each platform.
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
No description provided.