Use the correct type for interlocked instructions
authorMike Danes <onemihaid@hotmail.com>
Wed, 5 Apr 2017 05:27:37 +0000 (08:27 +0300)
committerMike Danes <onemihaid@hotmail.com>
Wed, 5 Apr 2017 05:27:37 +0000 (08:27 +0300)
commit5f5e5969ff1659860a9a69616300916a481e4a3d
tree9f2504423385c9db616e39c6ae3c4ca6c6fcb40b
parent13b43782ca7cf4447e27a86f2082fa62ef03bea5
Use the correct type for interlocked instructions

The interlocked operation type can, at least in theory, be TYP_VOID in the case of GT_LOCKADD. The first operand type is not relevant because it's the address of the memory location and not an indir.

The only option is to use the type of the second operand but that may be a small int type so genActualType needs to be used to get the correct type.
src/jit/codegenxarch.cpp
tests/src/JIT/Regression/JitBlue/GitHub_10714/GitHub_10714.cs [new file with mode: 0644]
tests/src/JIT/Regression/JitBlue/GitHub_10714/GitHub_10714.csproj [new file with mode: 0644]