git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1224 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
bellard 2005-01-16 01:07:28 +00:00
parent bb2d531499
commit d52cf7a64a
2 changed files with 17 additions and 3 deletions

View File

@ -528,7 +528,7 @@ void OPPROTO glue(op_maskmov, SUFFIX) (void)
s = (Reg *)((char *)env + PARAM2);
for(i = 0; i < (8 << SHIFT); i++) {
if (s->B(i) & 0x80)
stb(A0, d->B(i));
stb(A0 + i, d->B(i));
}
}
@ -565,6 +565,20 @@ void OPPROTO glue(op_pshufw, SUFFIX) (void)
*d = r;
}
#else
void OPPROTO op_shufps(void)
{
Reg r, *d, *s;
int order;
d = (Reg *)((char *)env + PARAM1);
s = (Reg *)((char *)env + PARAM2);
order = PARAM3;
r.L(0) = d->L(order & 3);
r.L(1) = d->L((order >> 2) & 3);
r.L(2) = s->L((order >> 4) & 3);
r.L(3) = s->L((order >> 6) & 3);
*d = r;
}
void OPPROTO op_shufpd(void)
{
Reg r, *d, *s;
@ -572,7 +586,7 @@ void OPPROTO op_shufpd(void)
d = (Reg *)((char *)env + PARAM1);
s = (Reg *)((char *)env + PARAM2);
order = PARAM3;
r.Q(0) = s->Q(order & 1);
r.Q(0) = d->Q(order & 1);
r.Q(1) = s->Q((order >> 1) & 1);
*d = r;
}

View File

@ -2292,7 +2292,7 @@ static GenOpFunc2 *sse_op_table1[256][4] = {
[0x5f] = SSE_FOP(max),
[0xc2] = SSE_FOP(cmpeq),
[0xc6] = { (GenOpFunc2 *)gen_op_pshufd_xmm, (GenOpFunc2 *)gen_op_shufpd },
[0xc6] = { (GenOpFunc2 *)gen_op_shufps, (GenOpFunc2 *)gen_op_shufpd },
/* MMX ops and their SSE extensions */
[0x60] = MMX_OP2(punpcklbw),