Skip to content
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

[SYCL][COMPAT] Fix slow math_extend tests #14599

Merged
merged 6 commits into from
Jul 18, 2024
Merged

Conversation

joeatodd
Copy link
Contributor

@joeatodd joeatodd commented Jul 17, 2024

The math_extend*cpp tests were very slow despite not doing a huge amount of work. This PR accelerates these tests with the following changes:

  • Split into several different kernels
  • Replace parallel_for with single_task
  • Avoid branching return statements
  • Avoid storing function names as char arrays in kernel
  • Avoid sycl::stream for output

Locally, the math_extend_v_4.cpp tests are about 5x faster. The other 2 are around 2x faster.

Signed-off-by: Joe Todd <joe.todd@codeplay.com>
Signed-off-by: Joe Todd <joe.todd@codeplay.com>
Signed-off-by: Joe Todd <joe.todd@codeplay.com>
Signed-off-by: Joe Todd <joe.todd@codeplay.com>
Signed-off-by: Joe Todd <joe.todd@codeplay.com>
Signed-off-by: Joe Todd <joe.todd@codeplay.com>
@joeatodd joeatodd requested a review from a team as a code owner July 17, 2024 12:13
@joeatodd
Copy link
Contributor Author

I have checked that these test still fail properly if impl is broken 👍

@joeatodd
Copy link
Contributor Author

@intel/llvm-gatekeepers this is ready to merge 🙏

@sommerlukas sommerlukas merged commit ac98c33 into sycl Jul 18, 2024
15 checks passed
@joeatodd joeatodd deleted the jtodd/fix-slow-tests branch July 30, 2024 11:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants