You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ifConversion can hoist invalid managed references. #124807
There are similar problems in other areas. I suspect the real general fix would be to set GTF_ORDER_SIDEEFF on any byref arithmetic or possible unmanaged to managed reinterpretations, but it's a big hammer to use.
Here is an example where forward sub does similar reordering:
Activity
dotnet-policy-service commentedon Feb 24, 2026
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch
See info in area-owners.md if you want to be subscribed.
jakobbotsch commentedon Feb 25, 2026
There are similar problems in other areas. I suspect the real general fix would be to set
GTF_ORDER_SIDEEFFon any byref arithmetic or possible unmanaged to managed reinterpretations, but it's a big hammer to use.Here is an example where forward sub does similar reordering:
(morph ends up reordering things again to turn it back into the original evaluation order, but the IR is still out of order for a while.)
Also I think
gtSetEvalOrdercould probably cause similar things to happen.EgorBo commentedon Jul 9, 2026
Moving to 12.0 as it has always been like that (at least since ifConversion was introduced)