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

[ESIMD] Fix test failures with new driver #15734

Merged
merged 1 commit into from
Oct 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions sycl/test-e2e/ESIMD/matrix_transpose2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -296,9 +296,8 @@ bool runTest(unsigned MZ, unsigned block_size, unsigned num_iters,
for (int i = 0; i <= num_iters; ++i) {
// make sure that image object has short live-range
// than M
sycl::image<2> imgM((unsigned int *)M, image_channel_order::rgba,
image_channel_type::unsigned_int32,
range<2>{MZ / 4, MZ});
sycl::image<2> imgM((unsigned char *)M, image_channel_order::rgba,
Copy link
Contributor

Choose a reason for hiding this comment

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

in this example it looks like M is int32. Is this one crashing too?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

M is declared as an array of MZxMZ which is 4 channels with 8 bit for each channel. This particular test was crashing

image_channel_type::unsigned_int8, range<2>{MZ, MZ});

double etime = 0;
if (block_size == 16 && MZ >= 16) {
Expand Down
9 changes: 3 additions & 6 deletions sycl/test-e2e/ESIMD/vadd_2d.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,11 @@ int main(void) {

try {
sycl::image<2> imgA(A, image_channel_order::rgba,
image_channel_type::unsigned_int32,
range<2>{Size / 4, 1});
image_channel_type::unsigned_int8, range<2>{Size, 1});
Copy link
Contributor

Choose a reason for hiding this comment

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

same question as above, A B and C seem to be ints here

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This test was not crashing but it failed. A,B,C are declared as int[Size] which is 4 channels of 8 bits each of size Sizex1
Here I am not sure what exact issue was as Size/4 of 4 int32 channels is the same as Size of 4 int8 channels, the suspicion is that we are reading it using media_block_load with uint8 type and this is somehow confuses the driver

Copy link
Contributor

Choose a reason for hiding this comment

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

got it, thanks

sycl::image<2> imgB(B, image_channel_order::rgba,
image_channel_type::unsigned_int32,
range<2>{Size / 4, 1});
image_channel_type::unsigned_int8, range<2>{Size, 1});
sycl::image<2> imgC(C, image_channel_order::rgba,
image_channel_type::unsigned_int32,
range<2>{Size / 4, 1});
image_channel_type::unsigned_int8, range<2>{Size, 1});

// We need that many workitems
range<1> GlobalRange{(Size / VL)};
Expand Down
Loading