From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40785) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XmiEE-0004yq-34 for qemu-devel@nongnu.org; Fri, 07 Nov 2014 07:01:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XmiE4-00074Y-Dl for qemu-devel@nongnu.org; Fri, 07 Nov 2014 07:01:21 -0500 Received: from mx1.redhat.com ([209.132.183.28]:35056) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XmiE3-00074E-Vx for qemu-devel@nongnu.org; Fri, 07 Nov 2014 07:01:12 -0500 Message-ID: <545CB477.3080202@redhat.com> Date: Fri, 07 Nov 2014 13:00:55 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <20141107103123.6136.18545.stgit@PASHA-ISP> <20141107103304.6136.29222.stgit@PASHA-ISP> <545CABF1.5070501@redhat.com> <003d01cffa80$56a2c720$03e85560$@Dovgaluk@ispras.ru> In-Reply-To: <003d01cffa80$56a2c720$03e85560$@Dovgaluk@ispras.ru> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC PATCH v4 17/25] cpus: make icount warp deterministic in replay mode List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Pavel Dovgaluk , qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, peter.crosthwaite@xilinx.com, alex.bennee@linaro.org, mark.burton@greensocs.com, real@ispras.ru, batuzovk@ispras.ru, maria.klimushenkova@ispras.ru, afaerber@suse.de, fred.konrad@greensocs.com On 07/11/2014 12:45, Pavel Dovgaluk wrote: >> From: Paolo Bonzini [mailto:pbonzini@redhat.com] >> On 07/11/2014 11:33, Pavel Dovgalyuk wrote: >>> This patch adds saving and replaying warping parameters in record and replay >>> modes. These parameters affect on virtual clock values and therefore should >>> be deterministic. >> >> Why are QEMU_CLOCK_REALTIME timers not recorded/replayed like >> QEMU_CLOCK_HOST is? > > We cannot record all QEMU_CLOCK_REALTIME timers, because they are simulator-related timers, > not the VM-related ones. If we'll record them then we'll have to replay simulator > execution. And we want just to replay VM allowing different realtime events to be > non-replayable (like screen refresh, monitor events handling, and so on). Hmm... I think you want the icount_rt timer to use what QEMU_CLOCK_VIRTUAL does in !use_icount mode. Maybe you can add a fourth clock, QEMU_CLOCK_VIRTUAL_RT and use this one independent of the replay mode. This clock can then be traced like QEMU_CLOCK_HOST. The problem is that QEMU_CLOCK_HOST can move backwards or forwards, sometimes by as much as 1 hour, so it's not the best match for this case. Paolo