[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3] Optimize record/replay checkpointing for all
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH v3] Optimize record/replay checkpointing for all clocks it applies to |
Date: |
Thu, 18 Oct 2018 19:25:45 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.0 |
On 18/10/2018 19:10, Artem Pisarenko wrote:
>
>> No, you're right. The if should remain in the caller, or
>> need_replay_checkpoint must be initialized with replay_mode.
>
> If initialize 'need_replay_checkpoint', then it should also account for
> clock != QEMU_CLOCK_REALTIME.
Or you just get a unlock/lock pair for QEMU_CLOCK_REALTIME (which should
really never happen if e.g. you have no UI).
> And here we come to what if+switch block
> actually (mostly) does in my version. Finally, you will get duplication
> of this whole condition usage between source function and extracted
> function, which isn't nice.
> Why do you want to split up such tightly coupled code?
Because it's *too* coupled and not very readable.
Paolo
- Re: [Qemu-devel] [PATCH v3 4/4] Optimize record/replay checkpointing for all clocks it applies to, (continued)
Re: [Qemu-devel] [PATCH v3 0/4] Introduce attributes for timers subsystem and remove QEMU_CLOCK_VIRTUAL_EXT clock type, Artem Pisarenko, 2018/10/18
[Qemu-devel] [PATCH v3 4/4] Optimize record/replay checkpointing for all clocks it applies to, Artem Pisarenko, 2018/10/18