Commit 9040405e authored by Junliang Yan's avatar Junliang Yan Committed by Commit Bot

s390x: fix high 32-bit word corruption issue

R=joransiu@ca.ibm.com

Change-Id: I9a2cf0f3e4a33dc4b86c83acfefcd27968bbcdb4
Reviewed-on: https://chromium-review.googlesource.com/1176424Reviewed-by: 's avatarJoran Siu <joransiu@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#55143}
parent e1a76995
...@@ -329,12 +329,12 @@ ArchOpcode SelectLoadOpcode(Node* node) { ...@@ -329,12 +329,12 @@ ArchOpcode SelectLoadOpcode(Node* node) {
/* Float unary op*/ \ /* Float unary op*/ \
V(BitcastFloat32ToInt32) \ V(BitcastFloat32ToInt32) \
/* V(TruncateFloat64ToWord32) */ \ /* V(TruncateFloat64ToWord32) */ \
/* V(RoundFloat64ToInt32) */ \ V(RoundFloat64ToInt32) \
/* V(TruncateFloat32ToInt32) */ \ V(TruncateFloat32ToInt32) \
/* V(TruncateFloat32ToUint32) */ \ V(TruncateFloat32ToUint32) \
/* V(TruncateFloat64ToUint32) */ \ V(TruncateFloat64ToUint32) \
/* V(ChangeFloat64ToInt32) */ \ V(ChangeFloat64ToInt32) \
/* V(ChangeFloat64ToUint32) */ \ V(ChangeFloat64ToUint32) \
/* Word32 unary op */ \ /* Word32 unary op */ \
V(Word32Clz) \ V(Word32Clz) \
V(Word32Popcnt) \ V(Word32Popcnt) \
......
...@@ -796,6 +796,9 @@ void TurboAssembler::ConvertDoubleToInt32(const Register dst, ...@@ -796,6 +796,9 @@ void TurboAssembler::ConvertDoubleToInt32(const Register dst,
UNIMPLEMENTED(); UNIMPLEMENTED();
break; break;
} }
#ifdef V8_TARGET_ARCH_S390X
lghi(dst, Operand::Zero());
#endif
cfdbr(m, dst, double_input); cfdbr(m, dst, double_input);
} }
...@@ -820,6 +823,9 @@ void TurboAssembler::ConvertFloat32ToInt32(const Register result, ...@@ -820,6 +823,9 @@ void TurboAssembler::ConvertFloat32ToInt32(const Register result,
UNIMPLEMENTED(); UNIMPLEMENTED();
break; break;
} }
#ifdef V8_TARGET_ARCH_S390X
lghi(result, Operand::Zero());
#endif
cfebr(m, result, double_input); cfebr(m, result, double_input);
} }
...@@ -844,6 +850,9 @@ void TurboAssembler::ConvertFloat32ToUnsignedInt32( ...@@ -844,6 +850,9 @@ void TurboAssembler::ConvertFloat32ToUnsignedInt32(
UNIMPLEMENTED(); UNIMPLEMENTED();
break; break;
} }
#ifdef V8_TARGET_ARCH_S390X
lghi(result, Operand::Zero());
#endif
clfebr(m, Condition(0), result, double_input); clfebr(m, Condition(0), result, double_input);
} }
...@@ -916,6 +925,9 @@ void TurboAssembler::ConvertDoubleToUnsignedInt32( ...@@ -916,6 +925,9 @@ void TurboAssembler::ConvertDoubleToUnsignedInt32(
UNIMPLEMENTED(); UNIMPLEMENTED();
break; break;
} }
#ifdef V8_TARGET_ARCH_S390X
lghi(dst, Operand::Zero());
#endif
clfdbr(m, Condition(0), dst, double_input); clfdbr(m, Condition(0), dst, double_input);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment