-
Notifications
You must be signed in to change notification settings - Fork 798
[SYCL] Implement structs that contains special types as parameters to free function kernels #20844
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
base: sycl
Are you sure you want to change the base?
Conversation
…ushi25/llvm into struct_contains_special_types
…ushi25/llvm into struct_contains_special_types
…ushi25/llvm into struct_contains_special_types
| // CHECK-NEXT: { kernel_param_kind_t::kind_pointer, 8, 0 }, | ||
| // CHECK-NEXT: { kernel_param_kind_t::kind_std_layout, 4, 8 }, | ||
| // CHECK-NEXT: { kernel_param_kind_t::kind_std_layout, 4, 12 }, | ||
| // CHECK-NEXT: { kernel_param_kind_t::kind_std_layout, 4, 0 }, |
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.
@premanandrao Regarding these changes...
The offsets for arguments of a free function kernel are somewhat meaningless since there is no concept of a closure class as is the case with lambda kernels. Therefore, I think it's less confusing to simply give them an offset of zero and reserve non-zero offsets for the fields inside a parameter struct which will help us find them in the runtime layer. So, all of these zeros are simply offsets of top-level parameters for which a non-zero offset does not make sense in the context of free function kernels.
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.
@premanandrao Also, your other suggestions in #18692 have been applied including the unused function.
Add support for structs containing special types as free function kernel parameters.