* [Qemu-devel] [RFC] Undeterministic behaviour with icount.
@ 2013-07-08 17:32 Frederic Konrad
2013-07-10 13:45 ` Paolo Bonzini
0 siblings, 1 reply; 3+ messages in thread
From: Frederic Konrad @ 2013-07-08 17:32 UTC (permalink / raw)
To: qemu-devel; +Cc: Paolo Bonzini, fred.konrad, Mark Burton, edgar.iglesias
[-- Attachment #1: Type: text/plain, Size: 547 bytes --]
Hi everybody,
We get some issues with reverse execution caused by indeterminism.
Something catched our attention:
static void icount_warp_rt(void *opaque), cpus.c:276
We have the feeling that icount is synchronized with rt_clock, is that
possible?
According to this Paolo's series
<http://lists.gnu.org/archive/html/qemu-devel/2011-04/msg01271.html>
this must be called when the cpus are sleeping, but
I saw this called frequently during the execution, is that the expected
behaviour?
If not what's the best way to fix that?
Thanks,
Fred
[-- Attachment #2: Type: text/html, Size: 851 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [RFC] Undeterministic behaviour with icount.
2013-07-08 17:32 [Qemu-devel] [RFC] Undeterministic behaviour with icount Frederic Konrad
@ 2013-07-10 13:45 ` Paolo Bonzini
2013-07-18 15:06 ` Frederic Konrad
0 siblings, 1 reply; 3+ messages in thread
From: Paolo Bonzini @ 2013-07-10 13:45 UTC (permalink / raw)
To: Frederic Konrad, qemu-devel, Edgar E. Iglesias, Mark Burton
Il 08/07/2013 19:32, Frederic Konrad ha scritto:
> Hi everybody,
>
> We get some issues with reverse execution caused by indeterminism.
>
> Something catched our attention:
> static void icount_warp_rt(void *opaque), cpus.c:276
>
> We have the feeling that icount is synchronized with rt_clock, is that
> possible?
When the CPU is idle, yes.
Note that the same thing happened before the series you linked. This is
the relevant code:
- /* Wait for either IO to occur or the next
- timer event. */
- add = qemu_next_deadline();
- /* We advance the timer before checking for IO.
- Limit the amount we advance so that early IO
- activity won't get the guest too far ahead. */
- if (add > 10000000)
- add = 10000000;
- delta += add;
- qemu_icount += qemu_icount_round (add);
It was adding to the icount while waiting for the next timer event to
happen.
> According to this Paolo's series
> <http://lists.gnu.org/archive/html/qemu-devel/2011-04/msg01271.html>
> this must be called when the cpus are sleeping, but
> I saw this called frequently during the execution, is that the expected
> behaviour?
What workload are you running? For anything that is not CPU bound I'd
expect that to be the case.
Paolo
> If not what's the best way to fix that?
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [RFC] Undeterministic behaviour with icount.
2013-07-10 13:45 ` Paolo Bonzini
@ 2013-07-18 15:06 ` Frederic Konrad
0 siblings, 0 replies; 3+ messages in thread
From: Frederic Konrad @ 2013-07-18 15:06 UTC (permalink / raw)
To: Paolo Bonzini; +Cc: Edgar E. Iglesias, Mark Burton, qemu-devel
On 10/07/2013 15:45, Paolo Bonzini wrote:
> Il 08/07/2013 19:32, Frederic Konrad ha scritto:
>> Hi everybody,
>>
>> We get some issues with reverse execution caused by indeterminism.
>>
>> Something catched our attention:
>> static void icount_warp_rt(void *opaque), cpus.c:276
>>
>> We have the feeling that icount is synchronized with rt_clock, is that
>> possible?
> When the CPU is idle, yes.
>
> Note that the same thing happened before the series you linked. This is
> the relevant code:
>
> - /* Wait for either IO to occur or the next
> - timer event. */
> - add = qemu_next_deadline();
> - /* We advance the timer before checking for IO.
> - Limit the amount we advance so that early IO
> - activity won't get the guest too far ahead. */
> - if (add > 10000000)
> - add = 10000000;
> - delta += add;
> - qemu_icount += qemu_icount_round (add);
>
> It was adding to the icount while waiting for the next timer event to
> happen.
>
>> According to this Paolo's series
>> <http://lists.gnu.org/archive/html/qemu-devel/2011-04/msg01271.html>
>> this must be called when the cpus are sleeping, but
>> I saw this called frequently during the execution, is that the expected
>> behaviour?
> What workload are you running? For anything that is not CPU bound I'd
> expect that to be the case.
>
> Paolo
>
>> If not what's the best way to fix that?
Hi Paolo,
Thanks for your answer.
For the moment the workload is a kernel boot. We removed everything from the
board.
So if it's the case, vm_clock will run non deterministic and we can't
replay.
I just send a series about that.
Fred
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-07-18 15:06 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-08 17:32 [Qemu-devel] [RFC] Undeterministic behaviour with icount Frederic Konrad
2013-07-10 13:45 ` Paolo Bonzini
2013-07-18 15:06 ` Frederic Konrad
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.