-
Notifications
You must be signed in to change notification settings - Fork 796
[SYCL] Rewrite some E2E tests into unit-tests #15877
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] Rewrite some E2E tests into unit-tests #15877
Conversation
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.
Note for ESIMD reviewers: even though the test also does some computations in kernels, I assume that they are not unique to this test and was merely done to avoid submitting an empty kernel or just by copying an existing test as a baseline.
Therefore, I'm completely removing it in favor of unit-test-level checks that we pass the right JIT compilation flag down to UR program build APIs.
Please speak up if you disagree and the test should still be preserved for some reason.
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.
yeah the computation is definitely not important, the point of the test is to check the flag to IGC.
| // REQUIRES: gpu && linux && (opencl || level_zero) | ||
|
|
||
| // RUN: %{build} -o %t.out | ||
| // RUN: env NEOReadDebugKeys=1 CreateMultipleRootDevices=3 SYCL_UR_TRACE=2 %{run} %t.out |
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.
lit captures stdout/stderr, so why waste our machine resources for something that is not used anyways?
maarquitos14
left a comment
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.
sarnex
left a comment
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.
this is cool, thanks!
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.
yeah the computation is definitely not important, the point of the test is to check the flag to IGC.
| sycl::range{1024}, [=](sycl::id<1>) /* SYCL_ESIMD_KERNEL */ {}); | ||
| }); | ||
|
|
||
| EXPECT_EQ(BuildOpts, |
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.
wow cool!
The main idea behind this (and other PRs I will eventually submit) is that we shouldn't use
SYCL_UR_TRACEin our unit-tests unless absolutely necessary (like testing shutdown sequence).The reason behind this is the fact that we have unit-tests infrastructure which is more than capable of ensuring that we called the right UR APIs with the right arguments. There is no need to waste our CI time on compiling and running the same test on different devices if we can easily test the same via our UR mock infrastructure.