Commit ff9c766
authored
Default Docker images to GCC 13 and remove GCC 14 (#7918)
## Summary
- Default x86_64 Docker image to gcc-toolset-13, matching the
aarch64 image and legacy manylinux builders. GCC 14 caused issues
with CUDA 12.6 nvcc (only supports up to GCC 13) and ld.gold
incompatibilities with CMake 4.3's --dependency-file flag.
- Add `patch_libstdc.sh` to x86_64 Dockerfile to weaken
`recursive_directory_iterator` symbols in GCC 13's
`libstdc++_nonshared.a`, preventing them from appearing as strong
(T) symbols in `libtorch_cpu.so` (pytorch/pytorch#133437).
- Remove gcc-toolset-14 installation from both x86_64 and aarch64
images since it is no longer needed.
- Also includes CUDA 12.6 addition to the Docker image.
## Test plan
- [ ] Build CPU and CUDA x86_64 images and verify `gcc --version`
reports GCC 13
- [ ] Build aarch64 images and verify `gcc --version` reports GCC
13
- [ ] Verify `nm -g $(gcc -print-file-name=libstdc++_nonshared.a)
| grep " T .*recursive_directory_iterator"` returns empty
(symbols weakened)
- [ ] Build a PyTorch wheel in the new image and verify
`check_binary_symbols.py` passes (no strong
`recursive_directory_iterator` symbols in `libtorch_cpu.so`)
- [ ] Verify CUDA 12.6 nvcc compiles successfully with GCC 131 parent 132c856 commit ff9c766
3 files changed
Lines changed: 5 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | 58 | | |
62 | 59 | | |
63 | 60 | | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
64 | 65 | | |
65 | 66 | | |
66 | 67 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | 55 | | |
59 | 56 | | |
60 | 57 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | | - | |
| 35 | + | |
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
| |||
0 commit comments