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
JIT: consider phase to clean up mixed byref/native int uses #12122
JitUntriagedCLR JIT issues needing additional triagearea-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
There are a number of examples of cases now where the jit has difficulty with mixed byref/native int uses of some resource. These come about from pointer reinterpretation methods like Unsafe.AsRef and other places.
The idea here is to run a phase after inlining to build a globally consistent view of the type of a local, possibly introducing casts where appropriate (like morph's "cast out of gc") so that later phases can reason about type correctness in a strictly local fashion.
This comment was drafted with assistance from GitHub Copilot.
Closing as a duplicate of #10821, which has the richer discussion of repros, prior fix attempts (#48675, #56192), and current state. The "rewriter / cleanup phase for mixed byref / native int" work described here is the same fix being tracked there.
JitUntriagedCLR JIT issues needing additional triagearea-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
Activity
AndyAyersMS commentedon Jun 7, 2026
Note
This comment was drafted with assistance from GitHub Copilot.
Closing as a duplicate of #10821, which has the richer discussion of repros, prior fix attempts (#48675, #56192), and current state. The "rewriter / cleanup phase for mixed byref / native int" work described here is the same fix being tracked there.