The other half of the mul64 rework. Sorry for the breakage, I committed
an incomplete version of what I tested. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3454 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
7878ff6bc7
commit
5592a750b9
@ -25,6 +25,8 @@
|
|||||||
|
|
||||||
#include "vl.h"
|
#include "vl.h"
|
||||||
|
|
||||||
|
//#define DEBUG_MULDIV
|
||||||
|
|
||||||
/* Long integer helpers */
|
/* Long integer helpers */
|
||||||
static void add128 (uint64_t *plow, uint64_t *phigh, uint64_t a, uint64_t b)
|
static void add128 (uint64_t *plow, uint64_t *phigh, uint64_t a, uint64_t b)
|
||||||
{
|
{
|
||||||
|
@ -3724,7 +3724,7 @@ void helper_mulq_EAX_T0(void)
|
|||||||
{
|
{
|
||||||
uint64_t r0, r1;
|
uint64_t r0, r1;
|
||||||
|
|
||||||
mulu64(&r1, &r0, EAX, T0);
|
mulu64(&r0, &r1, EAX, T0);
|
||||||
EAX = r0;
|
EAX = r0;
|
||||||
EDX = r1;
|
EDX = r1;
|
||||||
CC_DST = r0;
|
CC_DST = r0;
|
||||||
@ -3735,7 +3735,7 @@ void helper_imulq_EAX_T0(void)
|
|||||||
{
|
{
|
||||||
uint64_t r0, r1;
|
uint64_t r0, r1;
|
||||||
|
|
||||||
muls64(&r1, &r0, EAX, T0);
|
muls64(&r0, &r1, EAX, T0);
|
||||||
EAX = r0;
|
EAX = r0;
|
||||||
EDX = r1;
|
EDX = r1;
|
||||||
CC_DST = r0;
|
CC_DST = r0;
|
||||||
@ -3746,7 +3746,7 @@ void helper_imulq_T0_T1(void)
|
|||||||
{
|
{
|
||||||
uint64_t r0, r1;
|
uint64_t r0, r1;
|
||||||
|
|
||||||
muls64(&r1, &r0, T0, T1);
|
muls64(&r0, &r1, T0, T1);
|
||||||
T0 = r0;
|
T0 = r0;
|
||||||
CC_DST = r0;
|
CC_DST = r0;
|
||||||
CC_SRC = ((int64_t)r1 != ((int64_t)r0 >> 63));
|
CC_SRC = ((int64_t)r1 != ((int64_t)r0 >> 63));
|
||||||
|
@ -876,13 +876,13 @@ void op_msubu (void)
|
|||||||
#if defined(TARGET_MIPSN32) || defined(TARGET_MIPS64)
|
#if defined(TARGET_MIPSN32) || defined(TARGET_MIPS64)
|
||||||
void op_dmult (void)
|
void op_dmult (void)
|
||||||
{
|
{
|
||||||
CALL_FROM_TB4(muls64, &(env->HI[0][env->current_tc]), &(env->LO[0][env->current_tc]), T0, T1);
|
CALL_FROM_TB4(muls64, &(env->LO[0][env->current_tc]), &(env->HI[0][env->current_tc]), T0, T1);
|
||||||
RETURN();
|
RETURN();
|
||||||
}
|
}
|
||||||
|
|
||||||
void op_dmultu (void)
|
void op_dmultu (void)
|
||||||
{
|
{
|
||||||
CALL_FROM_TB4(mulu64, &(env->HI[0][env->current_tc]), &(env->LO[0][env->current_tc]), T0, T1);
|
CALL_FROM_TB4(mulu64, &(env->LO[0][env->current_tc]), &(env->HI[0][env->current_tc]), T0, T1);
|
||||||
RETURN();
|
RETURN();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user