Commit 65a6d9a
committed
MemoryLifetimeVerifier: support verifying enum memory locations.
This is kind of complicated, because an enum can be trivial for one case and not trivial for another case. We need to check at which parts of the function we can prove that the enum does (or could) have a trivial case. In such a branch, it's not required in SIL to destroy the enum location.
Also, document the rules and requirements for enum memory locations in SIL.rst.
rdar://737700851 parent 13f8f73 commit 65a6d9a
File tree
13 files changed
+450
-63
lines changed- docs
- include/swift/SIL
- lib
- SILGen
- SILOptimizer/Transforms
- SIL/Verifier
- test
- SILGen
- SILOptimizer
- SIL
13 files changed
+450
-63
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2320 | 2320 | | |
2321 | 2321 | | |
2322 | 2322 | | |
| 2323 | + | |
| 2324 | + | |
| 2325 | + | |
| 2326 | + | |
| 2327 | + | |
| 2328 | + | |
| 2329 | + | |
| 2330 | + | |
| 2331 | + | |
| 2332 | + | |
| 2333 | + | |
| 2334 | + | |
| 2335 | + | |
| 2336 | + | |
| 2337 | + | |
| 2338 | + | |
| 2339 | + | |
| 2340 | + | |
| 2341 | + | |
| 2342 | + | |
| 2343 | + | |
| 2344 | + | |
| 2345 | + | |
| 2346 | + | |
| 2347 | + | |
| 2348 | + | |
| 2349 | + | |
| 2350 | + | |
| 2351 | + | |
| 2352 | + | |
| 2353 | + | |
| 2354 | + | |
| 2355 | + | |
| 2356 | + | |
| 2357 | + | |
| 2358 | + | |
| 2359 | + | |
| 2360 | + | |
| 2361 | + | |
| 2362 | + | |
| 2363 | + | |
| 2364 | + | |
| 2365 | + | |
| 2366 | + | |
| 2367 | + | |
| 2368 | + | |
| 2369 | + | |
| 2370 | + | |
2323 | 2371 | | |
2324 | 2372 | | |
2325 | 2373 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
117 | 122 | | |
118 | 123 | | |
119 | 124 | | |
| |||
142 | 147 | | |
143 | 148 | | |
144 | 149 | | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
145 | 156 | | |
146 | 157 | | |
147 | 158 | | |
| |||
178 | 189 | | |
179 | 190 | | |
180 | 191 | | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
181 | 195 | | |
182 | 196 | | |
183 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
184 | 201 | | |
185 | | - | |
| 202 | + | |
| 203 | + | |
186 | 204 | | |
187 | 205 | | |
188 | 206 | | |
| |||
207 | 225 | | |
208 | 226 | | |
209 | 227 | | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
210 | 231 | | |
211 | 232 | | |
212 | 233 | | |
| |||
262 | 283 | | |
263 | 284 | | |
264 | 285 | | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
265 | 295 | | |
266 | 296 | | |
267 | 297 | | |
| |||
0 commit comments