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
Auto merge of #62655 - HeroicKatora:elide-uninit-static, r=<try>
Avoid copying some undef memory in MIR
Copying memory between allocations in MIR is not required to preserve the current representation of undef bytes. When the complete source of a copy is in undef state then there are no bytes that need to be copied and the function can return nearly immediately. In some cases this completely avoids writing to the allocation's memory with should have various benefits.
This for example reduces required physical memory when interpreting `const fn` involving large uninitialized values, such as `MaybeUninit::uninit()`.
(*This description has been changed from the original one after parts have been integrated into #63561 *)
0 commit comments