- Notifications
You must be signed in to change notification settings - Fork5.2k
Commitc8fbaff
JIT: Handle multi-reg async calls stored to promoted locals
In some cases the async transformation needs to introduce a new local tostore the result of an async call to. If the previous store was amulti-reg call stored to an independently promoted local then we wouldproduce illegal IR. For example, the IR``` t79 = ▌ CALL struct <unknown method> (async) $702 ┌──▌ t79 struct ▌ STORE_LCL_VAR struct<System.ValueTuple`3, 16>(P) V25 tmp9 ▌ ref field V25.Item3 (fldOffset=0x0) -> V275 tmp259 d:2 ▌ int field V25.Item2 (fldOffset=0x8) -> V276 tmp260 d:1 ▌ ubyte field V25.Item1 (fldOffset=0xc) -> V277 tmp261 d:1 $VN.Void```would be canonicalized into``` t79 = ▌ CALL struct <unknown method> (async) $702 ┌──▌ t79 struct ▌ STORE_LCL_VAR struct<System.ValueTuple`3, 16> V337 rat6t5027 = LCL_VAR struct<System.ValueTuple`3, 16> V337 rat6 ┌──▌ t5027 struct ▌ STORE_LCL_VAR struct<System.ValueTuple`3, 16>(P) V25 tmp9 ▌ ref field V25.Item3 (fldOffset=0x0) -> V275 tmp259 d:2 ▌ int field V25.Item2 (fldOffset=0x8) -> V276 tmp260 d:1 ▌ ubyte field V25.Item1 (fldOffset=0xc) -> V277 tmp261 d:1 $VN.Void```but that store to the promoted local with a LCL_VAR source is not legal.Fix the problem by decomposing the store when necessary.1 parent6d1a395 commitc8fbaff
1 file changed
+27
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1347 | 1347 | | |
1348 | 1348 | | |
1349 | 1349 | | |
1350 | | - | |
| 1350 | + | |
| 1351 | + | |
| 1352 | + | |
| 1353 | + | |
| 1354 | + | |
| 1355 | + | |
| 1356 | + | |
| 1357 | + | |
| 1358 | + | |
| 1359 | + | |
| 1360 | + | |
| 1361 | + | |
| 1362 | + | |
| 1363 | + | |
| 1364 | + | |
| 1365 | + | |
| 1366 | + | |
| 1367 | + | |
| 1368 | + | |
| 1369 | + | |
| 1370 | + | |
| 1371 | + | |
| 1372 | + | |
| 1373 | + | |
| 1374 | + | |
| 1375 | + | |
| 1376 | + | |
1351 | 1377 | | |
1352 | 1378 | | |
1353 | 1379 | | |
| |||
0 commit comments
Comments
(0)