Skip to content

[BE] Use sccache if available - #175556

Closed
malfet wants to merge 6 commits into
gh/malfet/723/basefrom
gh/malfet/723/head
Closed

malfet wants to merge 6 commits into
gh/malfet/723/basefrom
gh/malfet/723/head

Conversation

@malfet

@malfet malfet commented Feb 23, 2026 •

Copy link
Copy Markdown
Collaborator

Stack from ghstack (oldest at bottom):

Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
but add CUDA wrapper as well

Found the above with the help of LLM, when asked the question where those environment variables are defined.

Good thing about defining them early in the game are to allow more objects natively compile with sccache. Next step is to remove wrappers from our docker, and notice there are no perf regression (please note, that nccl build steps are not really cacheable, as headers gets generated all the time)

Fixes #8433

[ghstack-poisoned]
@pytorch-bot

pytorch-bot Bot commented Feb 23, 2026 •

Copy link
Copy Markdown

🔗 Helpful Links

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

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

✅ No Failures

As of commit 459c832 with merge base b0784e2 (image):
💚 Looks good so far! There are no failures yet. 💚

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

malfet added a commit that referenced this pull request Feb 23, 2026
Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
But add CUDA wrapper as well


ghstack-source-id: 4520c20
Pull-Request: #175556
@pytorch-bot pytorch-bot Bot added the topic: not user facing topic category label Feb 23, 2026
@malfet
malfet requested a review from Skylion007 February 23, 2026 19:25
[ghstack-poisoned]
malfet added a commit that referenced this pull request Feb 23, 2026
Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
But add CUDA wrapper as well

ghstack-source-id: 2735123
Pull-Request: #175556
[ghstack-poisoned]
malfet added a commit that referenced this pull request Feb 23, 2026
Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
But add CUDA wrapper as well

ghstack-source-id: 2175104
Pull-Request: #175556
[ghstack-poisoned]
@malfet malfet added the ciflow/trunk Trigger trunk jobs on your pull request label Feb 24, 2026
@malfet
malfet requested a review from a team as a code owner February 24, 2026 00:26
malfet added a commit that referenced this pull request Feb 24, 2026
Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
But add CUDA wrapper as well

ghstack-source-id: e6ec538
Pull-Request: #175556
[ghstack-poisoned]
malfet added a commit that referenced this pull request Feb 24, 2026
Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
But add CUDA wrapper as well

ghstack-source-id: 9682e33
Pull-Request: #175556
[ghstack-poisoned]
malfet added a commit that referenced this pull request Feb 24, 2026
Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
But add CUDA wrapper as well

ghstack-source-id: f7b10c2
Pull-Request: #175556
@malfet

malfet commented Feb 24, 2026

Copy link
Copy Markdown
Collaborator Author

@pytorchbot merge

@pytorchmergebot

Copy link
Copy Markdown
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

norx1991 pushed a commit that referenced this pull request Feb 24, 2026
Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
but add CUDA wrapper as well

Found the above with the help of LLM, when asked the question where those environment variables are defined.

Good thing about defining them early in the game are to allow more objects natively compile with sccache. Next step is to remove wrappers from our docker, and notice there are no perf regression (please note, that nccl build steps are not really cacheable, as headers gets generated all the time)

Fixes #8433
Pull Request resolved: #175556
Approved by: https://github.com/Skylion007
ghstack dependencies: #175574
pytorchmergebot pushed a commit that referenced this pull request Feb 27, 2026
I.e. if either ccache or sccache are present on the system, use it
Pull Request resolved: #175696
Approved by: https://github.com/Skylion007
ghstack dependencies: #175574, #175556
@github-actions
github-actions Bot deleted the gh/malfet/723/head branch March 27, 2026 02:23
EmanueleCoradin pushed a commit to EmanueleCoradin/pytorch that referenced this pull request Mar 30, 2026
Rather than rely on a weird wrapper everywhere

This essentially copies logic from https://github.com/pytorch/gloo/blob/bcd1672ee07538123ea8f4fac76832efc58fb8ef/CMakeLists.txt#L73
but add CUDA wrapper as well

Found the above with the help of LLM, when asked the question where those environment variables are defined.

Good thing about defining them early in the game are to allow more objects natively compile with sccache. Next step is to remove wrappers from our docker, and notice there are no perf regression (please note, that nccl build steps are not really cacheable, as headers gets generated all the time)

Fixes pytorch#8433
Pull Request resolved: pytorch#175556
Approved by: https://github.com/Skylion007
ghstack dependencies: pytorch#175574
EmanueleCoradin pushed a commit to EmanueleCoradin/pytorch that referenced this pull request Mar 30, 2026
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 topic: not user facing topic category

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants