-
Notifications
You must be signed in to change notification settings - Fork 5.4k
Description
The JIT today represents local addresses as TYP_BYREF, in particular for implicit byrefs. However, after speaking to @jkotas, we believe that implicit byrefs cannot actually point to heap today. Previously this may have been the case for remoting/reflection.
We should update the JIT to uniformly treat all local addresses as TYP_I_IMPL and to type implicit byrefs as TYP_I_IMPL, which should remove some GC reporting and write barriers we emit today.
We should also be able to get rid of impBashVarAddrsToI and various places that we retype local addresses as TYP_I_IMPL.
Return buffers should stay TYP_BYREF typed as the JIT itself will pass heap pointers as return buffers sometimes.
The following section in clr-abi should also be updated:
https://github.com/dotnet/runtime/blob/3a3692029a2a038581fdc8c1c6496e0506a7e0c7/docs/design/coreclr/botr/clr-abi.md#amd64-only-by-value-value-types