[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCHv1 12/14] target/s390x: convert to TranslatorOps
From: |
David Hildenbrand |
Subject: |
Re: [Qemu-devel] [PATCHv1 12/14] target/s390x: convert to TranslatorOps |
Date: |
Fri, 2 Mar 2018 11:06:37 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 |
On 01.03.2018 23:53, Emilio G. Cota wrote:
> Note: I looked into dropping dc->do_debug. However, I don't see
> an easy way to do it given that TOO_MANY is also valid
> when we just translate more than max_insns. Thus, the check
> for do_debug in "case DISAS_PC_CC_UPDATED" would still need
> additional state to know whether or not we came from
> breakpoint_check.
Looks much cleaner! The do_debug() thing is fine for now.
> - if (unlikely(cpu_breakpoint_test(cs, dc.base.pc_next, BP_ANY))) {
> - status = DISAS_PC_STALE;
> - do_debug = true;
> - /* The address covered by the breakpoint must be included in
> - [tb->pc, tb->pc + tb->size) in order to for it to be
> - properly cleared -- thus we increment the PC here so that
> - the logic setting tb->size below does the right thing. */
> - dc.base.pc_next += 2;
> - break;
> - }
> + dc->base.is_jmp = DISAS_PC_STALE;
> + dc->do_debug = true;
> + /* The address covered by the breakpoint must be included in
> + [tb->pc, tb->pc + tb->size) in order to for it to be
> + properly cleared -- thus we increment the PC here so that
> + the logic setting tb->size below does the right thing. */
> + dc->base.pc_next += 2;
This comment is now wrong. ("the logic in translator_loop()" ?)
Reviewed-by: David Hildenbrand <address@hidden>
Gave this series a quick test:
kvm-unit-tests pass (you need to rebase to have all tests passing),
fedora 27 boots
--
Thanks,
David / dhildenb
- [Qemu-devel] [PATCHv1 00/14] Translation loop conversion for sh4/sparc/mips/s390x/openrisc targets, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 03/14] target/sparc: convert to DisasJumpType, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 05/14] target/sparc: convert to TranslatorOps, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 02/14] target/sh4: convert to TranslatorOps, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 08/14] target/mips: use *ctx for DisasContext, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 12/14] target/s390x: convert to TranslatorOps, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 09/14] target/mips: convert to TranslatorOps, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 04/14] target/sparc: convert to DisasContextBase, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 14/14] target/openrisc: convert to TranslatorOps, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 01/14] translator: merge max_insns into DisasContextBase, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 13/14] target/openrisc: convert to DisasContextBase, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 11/14] target/s390x: convert to DisasContextBase, Emilio G. Cota, 2018/03/01
- [Qemu-devel] [PATCHv1 06/14] target/mips: convert to DisasJumpType, Emilio G. Cota, 2018/03/01