Scalarize single-field-to-lclVar block copy
authorJoseph Tremoulet <jotrem@microsoft.com>
Mon, 13 Mar 2017 18:49:16 +0000 (11:49 -0700)
committerJoseph Tremoulet <jotrem@microsoft.com>
Thu, 23 Mar 2017 14:15:18 +0000 (10:15 -0400)
commitd41158297592422c273b6a599234b25fe7bb8fe7
treea2a5372e101070b2a277a6e1110a7222883e0fe4
parentf330be3abe7d11cc999fb5c8751c15022bfd37a1
Scalarize single-field-to-lclVar block copy

Morph has some logic to scalarize struct copies where the RHS is a scalar
and the LHS is a single-field struct.  This change adds the symmetric
logic where the LHS is a scalar and the RHS is a single-field struct.
This pattern shows up in Span<T> methods that initialize the data pointer
field, due to the way scalar replacement operates on spans.

Commit migrated from https://github.com/dotnet/coreclr/commit/a9fbca32b572413dcccfe0314766edaed9c8934a
src/coreclr/src/jit/morph.cpp