mirror of https://gitee.com/openkylin/qemu.git
target-s390: Convert MVPG
Signed-off-by: Richard Henderson <rth@twiddle.net>
This commit is contained in:
parent
d62a4c97f2
commit
ee6c38d5b1
|
@ -394,6 +394,8 @@
|
||||||
C(0x0e00, MVCL, RR_a, Z, 0, 0, 0, 0, mvcl, 0)
|
C(0x0e00, MVCL, RR_a, Z, 0, 0, 0, 0, mvcl, 0)
|
||||||
/* MOVE LONG EXTENDED */
|
/* MOVE LONG EXTENDED */
|
||||||
C(0xa800, MVCLE, RS_a, Z, 0, a2, 0, 0, mvcle, 0)
|
C(0xa800, MVCLE, RS_a, Z, 0, a2, 0, 0, mvcle, 0)
|
||||||
|
/* MOVE PAGE */
|
||||||
|
C(0xb254, MVPG, RRE, Z, r1_o, r2_o, 0, 0, mvpg, 0)
|
||||||
|
|
||||||
/* MULTIPLY */
|
/* MULTIPLY */
|
||||||
C(0x1c00, MR, RR_a, Z, r1p1_32s, r2_32s, new, r1_D32, mul, 0)
|
C(0x1c00, MR, RR_a, Z, r1p1_32s, r2_32s, new, r1_D32, mul, 0)
|
||||||
|
|
|
@ -398,12 +398,9 @@ uint32_t HELPER(clst)(CPUS390XState *env, uint32_t c, uint32_t r1, uint32_t r2)
|
||||||
void HELPER(mvpg)(CPUS390XState *env, uint64_t r0, uint64_t r1, uint64_t r2)
|
void HELPER(mvpg)(CPUS390XState *env, uint64_t r0, uint64_t r1, uint64_t r2)
|
||||||
{
|
{
|
||||||
/* XXX missing r0 handling */
|
/* XXX missing r0 handling */
|
||||||
|
env->cc_op = 0;
|
||||||
#ifdef CONFIG_USER_ONLY
|
#ifdef CONFIG_USER_ONLY
|
||||||
int i;
|
memmove(g2h(r1), g2h(r2), TARGET_PAGE_SIZE);
|
||||||
|
|
||||||
for (i = 0; i < TARGET_PAGE_SIZE; i++) {
|
|
||||||
cpu_stb_data(env, r1 + i, cpu_ldub_data(env, r2 + i));
|
|
||||||
}
|
|
||||||
#else
|
#else
|
||||||
mvc_fast_memmove(env, TARGET_PAGE_SIZE, r1, r2);
|
mvc_fast_memmove(env, TARGET_PAGE_SIZE, r1, r2);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1034,18 +1034,6 @@ static void disas_b2(CPUS390XState *env, DisasContext *s, int op,
|
||||||
LOG_DISAS("disas_b2: op 0x%x r1 %d r2 %d\n", op, r1, r2);
|
LOG_DISAS("disas_b2: op 0x%x r1 %d r2 %d\n", op, r1, r2);
|
||||||
|
|
||||||
switch (op) {
|
switch (op) {
|
||||||
case 0x54: /* MVPG R1,R2 [RRE] */
|
|
||||||
tmp = load_reg(0);
|
|
||||||
tmp2 = load_reg(r1);
|
|
||||||
tmp3 = load_reg(r2);
|
|
||||||
potential_page_fault(s);
|
|
||||||
gen_helper_mvpg(cpu_env, tmp, tmp2, tmp3);
|
|
||||||
tcg_temp_free_i64(tmp);
|
|
||||||
tcg_temp_free_i64(tmp2);
|
|
||||||
tcg_temp_free_i64(tmp3);
|
|
||||||
/* XXX check CCO bit and set CC accordingly */
|
|
||||||
gen_op_movi_cc(s, 0);
|
|
||||||
break;
|
|
||||||
case 0x55: /* MVST R1,R2 [RRE] */
|
case 0x55: /* MVST R1,R2 [RRE] */
|
||||||
tmp32_1 = load_reg32(0);
|
tmp32_1 = load_reg32(0);
|
||||||
tmp32_2 = tcg_const_i32(r1);
|
tmp32_2 = tcg_const_i32(r1);
|
||||||
|
@ -2654,6 +2642,14 @@ static ExitStatus op_mvcs(DisasContext *s, DisasOps *o)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
static ExitStatus op_mvpg(DisasContext *s, DisasOps *o)
|
||||||
|
{
|
||||||
|
potential_page_fault(s);
|
||||||
|
gen_helper_mvpg(cpu_env, regs[0], o->in1, o->in2);
|
||||||
|
set_cc_static(s);
|
||||||
|
return NO_EXIT;
|
||||||
|
}
|
||||||
|
|
||||||
static ExitStatus op_mul(DisasContext *s, DisasOps *o)
|
static ExitStatus op_mul(DisasContext *s, DisasOps *o)
|
||||||
{
|
{
|
||||||
tcg_gen_mul_i64(o->out, o->in1, o->in2);
|
tcg_gen_mul_i64(o->out, o->in1, o->in2);
|
||||||
|
|
Loading…
Reference in New Issue