[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions
From: |
Pavel Dovgaluk |
Subject: |
Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions |
Date: |
Wed, 14 Jan 2015 12:07:27 +0300 |
> From: Paolo Bonzini [mailto:address@hidden
> On 12/01/2015 13:40, Pavel Dovgaluk wrote:
> >>>
> >> > Perhaps check the replay_interrupt() outside, in an && with "if
> >> > (unlikely(interrupt_request))"?
> > You mean that I should wrap whole condition into "unlikely"?
> >
>
> No, I wanted to have a single check of "replay_interrupt()" and/or
> "replay_has_interrupt()".
>
> BTW, I think this is incorrect:
>
> > + if ((replay_mode != REPLAY_MODE_PLAY
> > + || replay_has_interrupt())
> > + && cc->cpu_exec_interrupt(cpu, interrupt_request))
> > {
> > + replay_interrupt();
>
> because cc->cpu_exec_interrupt() can exit with cpu_loop_exit(cpu).
Haven't found any. Do you have an example?
>
> I guess it could be something like this:
>
> if (replay_mode == REPLAY_MODE_PLAY && !replay_has_interrupt()) {
> /* do nothing */
> } else if (interrupt_request & CPU_INTERRUPT_HALT) {
> replay_interrupt();
> ...
> cpu_loop_exit(cpu);
> } else if (interrupt_request & CPU_INTERRUPT_INIT) {
> replay_interrupt();
> ...
> cpu_loop_exit(cpu);
> } else {
> replay_interrupt();
> if (cc->cpu_exec_interrupt(cpu, interrupt_request)) {
> next_tb = 0;
> }
> }
Is it normal that processing of the reset request does not execute
cpu_loop_exit(cpu)?
> >>> > > #else
> >>> > > - if (interrupt_request & CPU_INTERRUPT_RESET) {
> >>> > > + if ((interrupt_request & CPU_INTERRUPT_RESET)
> >>> > > + && replay_interrupt()) {
> >>> > > cpu_reset(cpu);
> >>> > > }
> >>> > > #endif
Pavel Dovgalyuk
- [Qemu-devel] [RFC PATCH v7 04/21] replay: internal functions for replay log, (continued)
- [Qemu-devel] [RFC PATCH v7 04/21] replay: internal functions for replay log, Pavel Dovgalyuk, 2015/01/12
- [Qemu-devel] [RFC PATCH v7 05/21] replay: introduce icount event, Pavel Dovgalyuk, 2015/01/12
- [Qemu-devel] [RFC PATCH v7 07/21] cpu: replay instructions sequence, Pavel Dovgalyuk, 2015/01/12
- [Qemu-devel] [RFC PATCH v7 06/21] cpu-exec: allow temporary disabling icount, Pavel Dovgalyuk, 2015/01/12
- [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions, Pavel Dovgalyuk, 2015/01/12
- Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions, Paolo Bonzini, 2015/01/12
- Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions, Pavel Dovgaluk, 2015/01/12
- Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions, Paolo Bonzini, 2015/01/12
- Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions,
Pavel Dovgaluk <=
- Message not available
- Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions, Paolo Bonzini, 2015/01/14
- Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions, Pavel Dovgaluk, 2015/01/14
- Message not available
- Re: [Qemu-devel] [RFC PATCH v7 08/21] replay: interrupts and exceptions, Paolo Bonzini, 2015/01/14
[Qemu-devel] [RFC PATCH v7 10/21] cpus: make icount warp deterministic in replay mode, Pavel Dovgalyuk, 2015/01/12
[Qemu-devel] [RFC PATCH v7 09/21] replay: asynchronous events infrastructure, Pavel Dovgalyuk, 2015/01/12
[Qemu-devel] [RFC PATCH v7 11/21] timer: fix usage of clock functions, Pavel Dovgalyuk, 2015/01/12
[Qemu-devel] [RFC PATCH v7 12/21] replay: recording and replaying clock ticks, Pavel Dovgalyuk, 2015/01/12