mirror of https://github.com/proxmox/mirror_qemu
target-mips: fix ROTR and DROTR by zero
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>master
parent
c2c65dab45
commit
3399e30f56
|
@ -1475,6 +1475,8 @@ static void gen_shift_imm(CPUState *env, DisasContext *ctx, uint32_t opc,
|
||||||
tcg_gen_rotri_i32(t1, t1, uimm);
|
tcg_gen_rotri_i32(t1, t1, uimm);
|
||||||
tcg_gen_ext_i32_tl(cpu_gpr[rt], t1);
|
tcg_gen_ext_i32_tl(cpu_gpr[rt], t1);
|
||||||
tcg_temp_free_i32(t1);
|
tcg_temp_free_i32(t1);
|
||||||
|
} else {
|
||||||
|
tcg_gen_ext32s_tl(cpu_gpr[rt], t0);
|
||||||
}
|
}
|
||||||
opn = "rotr";
|
opn = "rotr";
|
||||||
break;
|
break;
|
||||||
|
@ -1494,6 +1496,8 @@ static void gen_shift_imm(CPUState *env, DisasContext *ctx, uint32_t opc,
|
||||||
case OPC_DROTR:
|
case OPC_DROTR:
|
||||||
if (uimm != 0) {
|
if (uimm != 0) {
|
||||||
tcg_gen_rotri_tl(cpu_gpr[rt], t0, uimm);
|
tcg_gen_rotri_tl(cpu_gpr[rt], t0, uimm);
|
||||||
|
} else {
|
||||||
|
tcg_gen_mov_tl(cpu_gpr[rt], t0);
|
||||||
}
|
}
|
||||||
opn = "drotr";
|
opn = "drotr";
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue