Skip to content

[PowerPC] Disable MKLDNN TF32 on PowerPC to fix build failure#163454

Closed
Tiwari-Avanish wants to merge 1 commit intopytorch:mainfrom
Tiwari-Avanish:powerpc_tf32_build_issue
Closed

[PowerPC] Disable MKLDNN TF32 on PowerPC to fix build failure#163454
Tiwari-Avanish wants to merge 1 commit intopytorch:mainfrom
Tiwari-Avanish:powerpc_tf32_build_issue

Conversation

@Tiwari-Avanish
Copy link
Contributor

@Tiwari-Avanish Tiwari-Avanish commented Sep 21, 2025

The commits f4d8bc4 added TF32 support for x86 CPUs,
which causes build failures on PowerPC systems with mkldnn.

This patch disables TF32 paths on PowerPC while keeping x86 TF32 support intact,
allowing PyTorch to build successfully on PowerPC.

I have run the mkldnn test case on PowerPC, and it passed successfully.

pytest test/test_mkldnn.py 87 passed, 2 skipped in 1709.02s (0:28:29

cc @jgong5 @mingfeima @XiaobingSuper @sanchitintel @ashokei @jingxu10 @jerryzh168

@pytorch-bot
Copy link

pytorch-bot bot commented Sep 21, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/163454

Note: Links to docs will display an error until the docs builds have been completed.

✅ No Failures

As of commit 30e7521 with merge base 5c827a4 (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@pytorch-bot pytorch-bot bot added the module: cpu CPU specific problem (e.g., perf, algorithm) label Sep 21, 2025
@Tiwari-Avanish
Copy link
Contributor Author

@pytorchbot label "topic: not user facing"

@pytorch-bot pytorch-bot bot added the topic: not user facing topic category label Sep 21, 2025
@janeyx99 janeyx99 added the triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module label Sep 22, 2025
@Tiwari-Avanish
Copy link
Contributor Author

Hi @jgong5 @mingfeima @albanD @malfet

Could you please review this code? I need to push these changes into the 2.9 release branch as well.
This fixes a build issue observed on Power systems related to cpuinfo_has_x86_amx_fp16() when enabling TF32 in the oneDNN (MKLDNN) code.

@Tiwari-Avanish
Copy link
Contributor Author

Hi,
Just a gentle ping — could someone please review this PR when you have time?

jgong5
jgong5 previously approved these changes Sep 27, 2025
@Tiwari-Avanish
Copy link
Contributor Author

Thanks @jgong5 for reviewing and approving this PR.

Since the contribution requires at least two approvals, could someone else please review this PR as well?
If there are any additional changes needed, please let me know and I’ll make those changes to the PR accordingly.

@Tiwari-Avanish
Copy link
Contributor Author

Hi @jgong5 @mingfeima

Could you please help review/approve so that we can proceed with merging it into the PyTorch branch?

Thanks a lot for your time and support.

@Tiwari-Avanish Tiwari-Avanish reopened this Oct 6, 2025
@pytorch-bot pytorch-bot bot dismissed jgong5’s stale review October 6, 2025 05:15

This PR was reopened (likely due to being reverted), so your approval was removed. Please request another review.

@Tiwari-Avanish Tiwari-Avanish force-pushed the powerpc_tf32_build_issue branch from 0cb4158 to da3e719 Compare October 8, 2025 18:36
@Tiwari-Avanish
Copy link
Contributor Author

Hi @jgong5,

I accidentally closed this PR earlier, which removed your approval. Could you please review and approve it again?

Since I don’t have merge access, once it’s approved, could you also help merge it?

I have rebased these changes on top of the latest main.

Thanks a lot for your help

@Tiwari-Avanish Tiwari-Avanish requested a review from jgong5 October 8, 2025 18:54
@Tiwari-Avanish Tiwari-Avanish force-pushed the powerpc_tf32_build_issue branch from da3e719 to 30e7521 Compare October 13, 2025 15:11
@Tiwari-Avanish
Copy link
Contributor Author

Hi @jgong5, @mingfeima

Could you please help me to merge this PR. I have fixed the lint error and push those changes, from now on i will keep in mind the lint error.

@Tiwari-Avanish
Copy link
Contributor Author

Hi @jgong5 @mingfeima @albanD @malfet

The PR has received an approval. Could someone with merge access please help in merging it when possible?
Thank you!

@malfet
Copy link
Contributor

malfet commented Oct 16, 2025

@pytorchbot merge

@pytorch-bot pytorch-bot bot added the ciflow/trunk Trigger trunk jobs on your pull request label Oct 16, 2025
@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

Chao1Han pushed a commit to Chao1Han/pytorch that referenced this pull request Oct 21, 2025
…h#163454)

The commits f4d8bc4 added TF32 support for x86 CPUs,
which causes build failures on PowerPC systems with mkldnn.

This patch disables TF32 paths on PowerPC while keeping x86 TF32 support intact,
allowing PyTorch to build successfully on PowerPC.

I have run the mkldnn test case on PowerPC, and it passed successfully.

`pytest test/test_mkldnn.py
87 passed, 2 skipped in 1709.02s (0:28:29`

Pull Request resolved: pytorch#163454
Approved by: https://github.com/jgong5, https://github.com/malfet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk Trigger trunk jobs on your pull request Merged module: cpu CPU specific problem (e.g., perf, algorithm) open source topic: not user facing topic category triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants