提交 86f1f2ae 编写于 作者: B Blue Swirl

sparc64: fix incorrect BPcc target sign extension

Fix wrong number of bits used when sign extending the branch offset of BPcc
instructions.
Reported-by: NArtyom Tarasenko <atar4qemu@gmail.com>
Signed-off-by: NBlue Swirl <blauwirbel@gmail.com>
上级 a2589e5c
......@@ -1893,7 +1893,7 @@ static void disas_sparc_insn(DisasContext * dc)
int cc;
target = GET_FIELD_SP(insn, 0, 18);
target = sign_extend(target, 18);
target = sign_extend(target, 19);
target <<= 2;
cc = GET_FIELD_SP(insn, 20, 21);
if (cc == 0)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册