提交 3b27fc36 编写于 作者: A aurel32

target-ppc: correctly propagate NaN in division

Signed-off-by: NAurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6048 c046a42c-6fe2-441c-8c8c-71466251a162
上级 e0147e41
...@@ -1135,7 +1135,7 @@ uint64_t helper_fdiv (uint64_t arg1, uint64_t arg2) ...@@ -1135,7 +1135,7 @@ uint64_t helper_fdiv (uint64_t arg1, uint64_t arg2)
} else if (unlikely(isinfinity(farg1.d) && isinfinity(farg2.d))) { } else if (unlikely(isinfinity(farg1.d) && isinfinity(farg2.d))) {
/* Division of infinity by infinity */ /* Division of infinity by infinity */
farg1.ll = fload_invalid_op_excp(POWERPC_EXCP_FP_VXIDI); farg1.ll = fload_invalid_op_excp(POWERPC_EXCP_FP_VXIDI);
} else if (unlikely(iszero(farg2.d))) { } else if (unlikely(!float64_is_nan(farg1.d) && iszero(farg2.d))) {
if (iszero(farg1.d)) { if (iszero(farg1.d)) {
/* Division of zero by zero */ /* Division of zero by zero */
farg1.ll = fload_invalid_op_excp(POWERPC_EXCP_FP_VXZDZ); farg1.ll = fload_invalid_op_excp(POWERPC_EXCP_FP_VXZDZ);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册