summaryrefslogtreecommitdiff
path: root/src/jit/codegencommon.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/jit/codegencommon.cpp')
-rw-r--r--src/jit/codegencommon.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/jit/codegencommon.cpp b/src/jit/codegencommon.cpp
index 9376666762..c7e0d6120e 100644
--- a/src/jit/codegencommon.cpp
+++ b/src/jit/codegencommon.cpp
@@ -6727,7 +6727,14 @@ void CodeGen::genZeroInitFrame(int untrLclHi,
#ifdef _TARGET_ARM_
getEmitter()->emitIns_R_R_I(INS_str, EA_PTRSIZE, rZero1, rAddr, 0);
#else // _TARGET_ARM_
- getEmitter()->emitIns_R_R_I(INS_str, EA_PTRSIZE, REG_ZR, rAddr, (uCntBytes - REGSIZE_BYTES) == 0 ? 0 : INS_OPTS_POST_INDEX);
+ if ((uCntBytes - REGSIZE_BYTES) == 0)
+ {
+ getEmitter()->emitIns_R_R_I(INS_str, EA_PTRSIZE, REG_ZR, rAddr, 0);
+ }
+ else
+ {
+ getEmitter()->emitIns_R_R_I(INS_str, EA_PTRSIZE, REG_ZR, rAddr, REGSIZE_BYTES, INS_OPTS_POST_INDEX);
+ }
#endif // !_TARGET_ARM_
uCntBytes -= REGSIZE_BYTES;
}