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

Introduce matmul-based IP for training #2377

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

densamoilov
Copy link
Contributor

This PR introduces matmul-based IP implementation for training.

  • When IP is created for forward_training plain layouts are always used to be consistent with the corresponding formats used for backward_data and backward_weights
  • To support bias gradients for backward_weights case the matmul primitive has been extended with an internal feature that enables mamtul to reduce matrix A. The reduction is fused.
  • Verbose was not extended to cover the new internal feature intentionally because having it in verbose doesn't provide any information that would be helpful, information about bias for IP is already enough.
  • This matmul-based implementation for training is meant to be a full replacement for the existing brgemm-based one however, the latter one will stay available through the primitive descriptor iterator for some time but no further development is planned for it and it will eventually be removed.

TODO: post performance data.

@densamoilov densamoilov requested review from a team as code owners January 11, 2025 07:48
@github-actions github-actions bot added platform:cpu-x64 Intel64/AMD64 processors. Codeowner: @oneapi-src/onednn-cpu-x64 component:api Codeowner: @oneapi-src/onednn-arch labels Jan 11, 2025
@densamoilov
Copy link
Contributor Author

make test
enable device_cpu
disable device_gpu

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:api Codeowner: @oneapi-src/onednn-arch 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.

1 participant