Skip to content

Fix Bug in MX Builds #2284

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 31, 2025
Merged

Fix Bug in MX Builds #2284

merged 1 commit into from
May 31, 2025

Conversation

drisspg
Copy link
Contributor

@drisspg drisspg commented May 31, 2025

Stacked PRs:


Fix Bug in MX Builds

Copy link

pytorch-bot bot commented May 31, 2025

🔗 Helpful Links

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

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

✅ No Failures

As of commit 919480d with merge base e51ffd9 (image):
💚 Looks good so far! There are no failures yet. 💚

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

drisspg added a commit that referenced this pull request May 31, 2025
stack-info: PR: #2284, branch: drisspg/stack/62
@drisspg drisspg force-pushed the drisspg/stack/62 branch from b30cf69 to 6fb51f2 Compare May 31, 2025 01:05
@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label May 31, 2025
@drisspg drisspg added the topic: not user facing Use this tag if you don't want this PR to show up in release notes label May 31, 2025
@drisspg drisspg requested a review from gau-nernst May 31, 2025 01:08
@drisspg
Copy link
Contributor Author

drisspg commented May 31, 2025

This fixes it but there is another problem that is if no torch_cuda_arch_list is set the cutlass files dont' get build...

@gau-nernst
Copy link
Collaborator

Actually as long as we have a sufficiently new CUDA toolkit (12.8 I think?), we can compile for sm100a? Regardless of actual compute capability available at compile time.

The downside is that compile time is longer for non-sm100a users building from source.

@drisspg
Copy link
Contributor Author

drisspg commented May 31, 2025

So there was 2 problems:

  1. the accidental downgrade of Cutlass fixed in the PR
  2. The second is that cuda extensions doesn't let you compile w/ perfile flags, In the past for cutlass utilzing the 'a' variants if you try to compile with anything but that sm+a you would get a compile time error, e.g. Fixes MX formats build for blackwell #2214

I think the problem right now is that I unconditionally remove remove the sources

e.g.
if I set 90a, and 100a I get

INFO:root:copying build/lib.linux-x86_64-cpython-312/torchao/_C.abi3.so -> torchao
INFO:root:copying build/lib.linux-x86_64-cpython-312/torchao/_C_cutlass_90a.abi3.so -> torchao
INFO:root:copying build/lib.linux-x86_64-cpython-312/torchao/_C_cutlass_100a.abi3.so -> torchao

which is right

ahh its just 90a nd 100a are not in the arch_flags w/ no TORCH_CUDA_ARCHLIST set

stack-info: PR: #2284, branch: drisspg/stack/62
@drisspg drisspg force-pushed the drisspg/stack/62 branch from 6fb51f2 to 919480d Compare May 31, 2025 01:54
@drisspg drisspg merged commit ce27731 into main May 31, 2025
35 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. topic: not user facing Use this tag if you don't want this PR to show up in release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants