summaryrefslogtreecommitdiff
path: root/src/jit/codegenlinear.cpp
diff options
context:
space:
mode:
authorHanjoung Lee <hanjoung.lee@samsung.com>2017-08-10 15:35:38 +0900
committerHanjoung Lee <hanjoung.lee@samsung.com>2017-08-10 15:40:11 +0900
commit7c3b04a5ef20104e842135ac59ec11309123147e (patch)
treede7ad0736eb2f2765808d33b783c0f03a5ac82b2 /src/jit/codegenlinear.cpp
parent3e4965efc916cae2040aa0abd766a470a45aa658 (diff)
downloadcoreclr-7c3b04a5ef20104e842135ac59ec11309123147e.tar.gz
coreclr-7c3b04a5ef20104e842135ac59ec11309123147e.tar.bz2
coreclr-7c3b04a5ef20104e842135ac59ec11309123147e.zip
[RyuJIT/armel] Introduce GetRegCount() for MultiRegOp
Abstract getting reg count with method GetRegCount() Added the case when the reg count is 0.
Diffstat (limited to 'src/jit/codegenlinear.cpp')
-rw-r--r--src/jit/codegenlinear.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/jit/codegenlinear.cpp b/src/jit/codegenlinear.cpp
index dfe0458c51..eb49edbf8d 100644
--- a/src/jit/codegenlinear.cpp
+++ b/src/jit/codegenlinear.cpp
@@ -1037,7 +1037,7 @@ void CodeGen::genUnspillRegIfNeeded(GenTree* tree)
else if (unspillTree->OperIsMultiRegOp())
{
GenTreeMultiRegOp* multiReg = unspillTree->AsMultiRegOp();
- unsigned regCount = multiReg->gtOtherReg == REG_NA ? 1 : 2;
+ unsigned regCount = multiReg->GetRegCount();
// In case of split struct argument node, GTF_SPILLED flag on it indicates that
// one or more of its result regs are spilled. Call node needs to be
@@ -1685,7 +1685,7 @@ void CodeGen::genProduceReg(GenTree* tree)
else if (tree->OperIsMultiRegOp())
{
GenTreeMultiRegOp* multiReg = tree->AsMultiRegOp();
- unsigned regCount = multiReg->gtOtherReg == REG_NA ? 1 : 2;
+ unsigned regCount = multiReg->GetRegCount();
for (unsigned i = 0; i < regCount; ++i)
{