Commit 3b71aa3
committed
inference: Add some basic inference for PhiNode
PhiNode isn't really supported in lowered IR, but it is convenient
to be able to emit it, particularly for code that is designed to
perform transformations both on typed and on lowered IR (such as
Diffractor). Moreover, we do actually supported phinodes in untyped
IR both in the interpreter and in the compiler. At the moment,
inference assumes that PhiNodes get treated as embedded constants,
which is just not what the actual implementation does. At the very
least, it should just leave PhiNodes alone in case they accidentally
end up in lowered IR (rather than causing crashes), but we might
as well give them some basic support.1 parent 82784fe commit 3b71aa3
File tree
3 files changed
+45
-0
lines changed- base/compiler
- test/compiler
3 files changed
+45
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1413 | 1413 | | |
1414 | 1414 | | |
1415 | 1415 | | |
| 1416 | + | |
| 1417 | + | |
| 1418 | + | |
| 1419 | + | |
| 1420 | + | |
| 1421 | + | |
| 1422 | + | |
1416 | 1423 | | |
1417 | 1424 | | |
1418 | 1425 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
267 | 267 | | |
268 | 268 | | |
269 | 269 | | |
| 270 | + | |
| 271 | + | |
270 | 272 | | |
271 | 273 | | |
272 | 274 | | |
| |||
287 | 289 | | |
288 | 290 | | |
289 | 291 | | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
290 | 300 | | |
291 | 301 | | |
292 | 302 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3323 | 3323 | | |
3324 | 3324 | | |
3325 | 3325 | | |
| 3326 | + | |
| 3327 | + | |
| 3328 | + | |
| 3329 | + | |
| 3330 | + | |
| 3331 | + | |
| 3332 | + | |
| 3333 | + | |
| 3334 | + | |
| 3335 | + | |
| 3336 | + | |
| 3337 | + | |
| 3338 | + | |
| 3339 | + | |
| 3340 | + | |
| 3341 | + | |
| 3342 | + | |
| 3343 | + | |
| 3344 | + | |
| 3345 | + | |
| 3346 | + | |
| 3347 | + | |
| 3348 | + | |
| 3349 | + | |
| 3350 | + | |
| 3351 | + | |
| 3352 | + | |
| 3353 | + | |
0 commit comments