FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

[SYCLomatic-test] test load and store headers by abhilash1910 · Pull Request #680 · oneapi-src/SYCLomatic-test · GitHub

This repository was archived by the owner on Jul 21, 2026. It is now read-only.
/ SYCLomatic-test Public archive

[SYCLomatic-test] test load and store headers - #680

Open
abhilash1910 wants to merge 12 commits into
oneapi-src:SYCLomaticfrom
abhilash1910:block_update
Open

[SYCLomatic-test] test load and store headers#680
abhilash1910 wants to merge 12 commits into
oneapi-src:SYCLomaticfrom
abhilash1910:block_update

Conversation

abhilash1910 commented Apr 14, 2024
edited
Loading

Copy link
Copy Markdown
Contributor

This is linked to composite load and store tests (PRs oneapi-src/SYCLomatic#1819 , oneapi-src/SYCLomatic#1784) from group_utils.hpp
Another standalone "store-only" test is at : #725 (WIP)
cc @yihanwg @zhimingwang36 @danhoeflinger @mmichel11

abhilash1910 requested a review from a team as a code owner April 14, 2024 07:09

yihwang-nv left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Same as 1784

abhilash1910 changed the title [SYCLomatic-test] link group_utils headers [SYCLomatic-test] test store headers May 31, 2024
abhilash1910 changed the title [SYCLomatic-test] test store headers [SYCLomatic-test] test load and store headers Jun 5, 2024

Copy link
Copy Markdown
Contributor Author

Completed testing with pass results with PR : oneapi-src/SYCLomatic#1819
@danhoeflinger @yihanwg @mmichel11 please review when available

@@ -0,0 +1,199 @@
// ====------ onedpl_test_group_load.cpp------------ *- C++ -* ----===//

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality
Suggested change
// ====------ onedpl_test_group_load.cpp------------ *- C++ -* ----===//
// ====------ util_group_load_store_test.cpp------------ *- C++ -* ----===//


template <dpct::group::load_algorithm T>
bool helper_validation_function(const int *ptr, const char *func_name) {
if constexpr (T == dpct::group::load_algorithm::BLOCK_LOAD_DIRECT) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

It seems like the only difference between verification for "direct" and "striped" load algorithms is the name. This makes sense because we should "unmap" any "map" via the store operation as long as they match.

However, it doesn't make sense to just have a branch and repeat the code. You can branch for the name, and run the same verification, or just embed the info you want in func_name.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Yes that makes sense, thanks

return true;
}

bool subgroup_helper_validation_function(const int *ptr, const uint32_t *sg_sz,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

looks like this has the same verification as well (as it should), but it can be consolidated into a single routine.

Copy link
Copy Markdown
Contributor

Can we make some of the kernels launch multiple work-groups to test for issues mentioned in the review?

sycl::local_accessor<uint8_t, 1> tacc(sycl::range<1>(temp_storage_size), h);
sycl::accessor data_accessor_read_write(buffer, h, sycl::read_write);
h.parallel_for(
sycl::nd_range<3>(sycl::range<3>(2, 2, 64), sycl::range<3>(1, 1, 64)),

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

All that seems to be different between the single and multi work group cases seems to be the range. Could we just add an nd_range parameter to a single test function and use that in the kernel submission to unify the single work-group / multi work-group functions?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

yes will add the change


sycl::host_accessor data_accessor(buffer, sycl::read_write);
const int *ptr = data_accessor.get_multi_ptr<sycl::access::decorated::yes>();
return helper_validation_function(ptr, "test_group_load_store");

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Can we add if it is the single work-group or multi work-group to the test string for more descriptive debug info?

abhilash1910 Jul 1, 2024
edited
Loading

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Added, thanks

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.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants


Back | FazBrowse Home | New Git URL