Fix putArgStk dstCount and ConsumeReg errors
authorCarol Eidt <carol.eidt@microsoft.com>
Thu, 12 Jan 2017 20:15:16 +0000 (12:15 -0800)
committerCarol Eidt <carol.eidt@microsoft.com>
Thu, 12 Jan 2017 20:15:16 +0000 (12:15 -0800)
commit279de2294202e78bda4291a5af6dd8bbff7e550f
tree8e0d8345cf91576f9e220224f253f58ad7a796a8
parent142299faee027e53ceced80c987f8ba4c5647809
Fix putArgStk dstCount and ConsumeReg errors

The LastConsumedNode used in genCheckConsumeNode was not initialized for arm64.
Fixing this exposed several places where nodes were being consumed twice or in the wrong order.
In addition, since GT_PUTARG_STK doesn't define a register, its dstCount needs to be zero. This is enabled by checking IsValue() instead of type of TYP_VOID for the default case of TreeNodeInfoInit. This was missed for both arm and arm64.

Commit migrated from https://github.com/dotnet/coreclr/commit/3a44fd490bb83fb3c486cd9b90fe3934733f4a96
src/coreclr/src/jit/codegenarm64.cpp
src/coreclr/src/jit/emitarm64.cpp
src/coreclr/src/jit/lowerarm.cpp
src/coreclr/src/jit/lowerarm64.cpp