Skip to content

Conversation

@wdziurdz
Copy link
Contributor

@wdziurdz wdziurdz commented Sep 17, 2025

Fixes #5074

@whitneywhtsang
Copy link
Contributor

Is this for testing? If it is not ready for review, please convert to draft.

@whitneywhtsang whitneywhtsang marked this pull request as draft September 25, 2025 00:33
@wdziurdz wdziurdz force-pushed the dev/wdziurdz/test-matmul-1 branch 2 times, most recently from 84862d8 to aafbe1a Compare October 6, 2025 12:37
@wdziurdz wdziurdz marked this pull request as ready for review October 6, 2025 12:39
@wdziurdz wdziurdz force-pushed the dev/wdziurdz/test-matmul-1 branch 3 times, most recently from 5b2d42b to 990069a Compare October 8, 2025 10:32
out_matmul_scale = out_matmul_scale.data.view(torch.uint8)
if has_scratchpad and "mx_out_scale" in memory["scratchpad"]:
out_matmul_scale = memory["scratchpad"]["mx_out_scale"]
out_matmul_has_mx = out_matmul_scale is not None and out_matmul.element_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.

What is the reason for changing this line of code. This currently matches the upstream version of this file.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because, in my opinion, it is a logical mistake. In this line (https://github.com/intel/intel-xpu-backend-for-triton/blob/c2a39f4396fcd5297a57b9326ffd788a29e82ef2/python/triton_kernels/triton_kernels/matmul_ogs.py#L294C10-L294C25 ), it always initializes with float32 if split_k > 2, and then element_size == 4. I think element_size is not the most suitable condition. It would make more sense to check if out_dtype equals 8 bits. Maybe it’s a bit confusing because I didn’t update the skiplist or remove the tests that were already fixed by these changes.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I updated the skiplist. Also, all batched test cases were fixed in this Triton commit when we reland this commit all batched test cases should be resolved. However, there are still 16 test cases that need to be fixed.

Copy link
Contributor

Choose a reason for hiding this comment

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

can you please upstream the change?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added pr to upstream triton-lang/triton#8519

@wdziurdz wdziurdz force-pushed the dev/wdziurdz/test-matmul-1 branch from 990069a to f51fe27 Compare October 10, 2025 07:57
@wdziurdz wdziurdz self-assigned this Oct 10, 2025
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.

Some python/triton_kernels/tests/test_matmul.py::test_op test cases don't work

3 participants