[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 18/20] tcg: Save insn data and use it in cpu_res
From: |
Sergey Fedorov |
Subject: |
Re: [Qemu-devel] [PATCH 18/20] tcg: Save insn data and use it in cpu_restore_state_from_tb |
Date: |
Fri, 11 Sep 2015 13:29:46 +0300 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 |
On 10.09.2015 16:49, Peter Maydell wrote:
>> @@ -2406,6 +2411,8 @@ static inline int tcg_gen_code_common(TCGContext *s,
>> > check_regs(s);
>> > #endif
>> > }
>> > + tcg_debug_assert(num_insns >= 0);
> This is claiming that every TB will have at least one insn_start,
> right? I think that most targets will violate that in the breakpoint
> case, because the "if we have a bp for this insn then generate a
> debug insn and break out of the loop" code is before the call
> to tcg_gen_insn_start().
>
> We should probably assert that num_insns < TCG_MAX_INSNS while
> we're here.
>
BTW, such skipping of instruction generation seems to be the cause of
getting a confusing "Disassembler disagrees with translator over
instruction" message in qemu log.
- [Qemu-devel] [PATCH 09/20] target-cris: Mirror gen_opc_pc into insn_start, (continued)
- [Qemu-devel] [PATCH 09/20] target-cris: Mirror gen_opc_pc into insn_start, Richard Henderson, 2015/09/02
- [Qemu-devel] [PATCH 11/20] target-sparc: Split out gen_branch_n, Richard Henderson, 2015/09/02
- [Qemu-devel] [PATCH 10/20] target-sparc: Tidy gen_branch_a interface, Richard Henderson, 2015/09/02
- [Qemu-devel] [PATCH 12/20] target-sparc: Remove gen_opc_jump_pc, Richard Henderson, 2015/09/02
- [Qemu-devel] [PATCH 13/20] target-sparc: Add npc state to insn_start, Richard Henderson, 2015/09/02
- [Qemu-devel] [PATCH 14/20] tcg: Merge cpu_gen_code into tb_gen_code, Richard Henderson, 2015/09/02
- [Qemu-devel] [PATCH 15/20] target-*: Drop cpu_gen_code define, Richard Henderson, 2015/09/02
- [Qemu-devel] [PATCH 16/20] tcg: Add TCG_MAX_INSNS, Richard Henderson, 2015/09/02
- [Qemu-devel] [PATCH 18/20] tcg: Save insn data and use it in cpu_restore_state_from_tb, Richard Henderson, 2015/09/02
- Re: [Qemu-devel] [PATCH 18/20] tcg: Save insn data and use it in cpu_restore_state_from_tb, Richard Henderson, 2015/09/15
[Qemu-devel] [PATCH 20/20] tcg: Remove tcg_gen_code_search_pc, Richard Henderson, 2015/09/02
[Qemu-devel] [PATCH 17/20] tcg: Pass data argument to restore_state_to_opc, Richard Henderson, 2015/09/02
[Qemu-devel] [PATCH 19/20] tcg: Remove gen_intermediate_code_pc, Richard Henderson, 2015/09/02
Re: [Qemu-devel] [RFC 00/20] Do away with TB retranslation, Max Filippov, 2015/09/02