Commit 2390bc5
authored
Fix DeepCompile for PyTorch 2.8/2.9 compatibility (#7755)
PyTorch 2.8 added a new static_lifetime_input_indices parameter to the
partition function. This breaks DeepCompile with ZeRO stage 3.
This PR updates `partition_recompute_ds_params` to accept `**kwargs` and
forward them to the underlying partition function, maintaining backward
compatibility with PyTorch 2.6/2.7.
DeepCompile works with PyTorch v2.9 when using ZeRO Stage 1 or 2.
However, ZeRO Stage 3 is not currently supported on PyTorch v2.9 (it
still works on PyTorch <= v2.8). DeepCompile tests are skipped when
PyTorch version is v2.9 and ZeRO stage is 3.
---------
Signed-off-by: Masahiro Tanaka <mtanaka@anyscale.com>1 parent 1d140f8 commit 2390bc5
File tree
5 files changed
+17
-7
lines changed- deepspeed
- compile
- runtime
- tests/unit/v1/compile
5 files changed
+17
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | 10 | | |
12 | 11 | | |
13 | 12 | | |
14 | 13 | | |
15 | | - | |
16 | | - | |
17 | 14 | | |
18 | 15 | | |
19 | 16 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
87 | 87 | | |
88 | 88 | | |
89 | 89 | | |
90 | | - | |
91 | | - | |
| 90 | + | |
| 91 | + | |
92 | 92 | | |
93 | 93 | | |
94 | | - | |
| 94 | + | |
95 | 95 | | |
96 | 96 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
| 80 | + | |
80 | 81 | | |
81 | 82 | | |
82 | 83 | | |
| |||
4296 | 4297 | | |
4297 | 4298 | | |
4298 | 4299 | | |
| 4300 | + | |
| 4301 | + | |
| 4302 | + | |
| 4303 | + | |
4299 | 4304 | | |
4300 | 4305 | | |
4301 | 4306 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
| 85 | + | |
| 86 | + | |
85 | 87 | | |
86 | 88 | | |
87 | 89 | | |
| |||
123 | 125 | | |
124 | 126 | | |
125 | 127 | | |
| 128 | + | |
| 129 | + | |
126 | 130 | | |
127 | 131 | | |
128 | 132 | | |
| |||
156 | 160 | | |
157 | 161 | | |
158 | 162 | | |
| 163 | + | |
| 164 | + | |
159 | 165 | | |
160 | 166 | | |
161 | 167 | | |
| |||
187 | 193 | | |
188 | 194 | | |
189 | 195 | | |
| 196 | + | |
| 197 | + | |
190 | 198 | | |
191 | 199 | | |
192 | 200 | | |
| |||
0 commit comments