Skip to content

x64: matmul: Fix buffer B chunk size / Buffer B per thread size #3161

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

Merged
merged 1 commit into from
May 1, 2025

Conversation

inteldimitrius
Copy link
Contributor

@inteldimitrius inteldimitrius commented Apr 24, 2025

Description

It partially fixes MFDNN-13311.
buffer_b_chunk_sz should be aligned with
char *get_buf_B_ptr(int ithr, int k_blk_idx, int n_blk_idx, int gb) logic implemented here:
https://github.com/uxlfoundation/oneDNN/blob/main/src/cpu/x64/matmul/brgemm_matmul.cpp#L1688
The issue accidentally observed on the big number of threads (>193).

The PR only fixes --wtag=abcd cases. --wtag=abdc which is 31 cases of original 72 still fail

@github-actions github-actions bot added the platform:cpu-x64 Intel64/AMD64 processors. Codeowner: @oneapi-src/onednn-cpu-x64 label Apr 24, 2025
@inteldimitrius inteldimitrius force-pushed the dmitriyo/matmul_correctness_fix branch from ca5cc31 to acecacd Compare April 29, 2025 15:37
@inteldimitrius inteldimitrius changed the title [WIP]x64: matmul: Fix buffer B chunk size / Buffer B per thread size x64: matmul: Fix buffer B chunk size / Buffer B per thread size Apr 29, 2025
@inteldimitrius inteldimitrius marked this pull request as ready for review April 29, 2025 15:38
@inteldimitrius inteldimitrius requested a review from a team as a code owner April 29, 2025 15:38
Copy link
Contributor

@dzarukin dzarukin left a comment

Choose a reason for hiding this comment

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

Please revert the commit from #3179
and run GPU CI matmul testing to verify the fix.

@tprimak
Copy link
Contributor

tprimak commented Apr 30, 2025

make test
set test_scope=NIGHTLY

@tprimak
Copy link
Contributor

tprimak commented May 1, 2025

The PR only fixes --wtag=abcd cases. --wtag=abdc which is 31 cases of original 72 still fail
Nightly Pre-CI

@tprimak tprimak merged commit fc06813 into main May 1, 2025
14 of 20 checks passed
@tprimak tprimak deleted the dmitriyo/matmul_correctness_fix branch May 1, 2025 20:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform:cpu-x64 Intel64/AMD64 processors. Codeowner: @oneapi-src/onednn-cpu-x64
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants