Re: [Qemu-devel] [RFC PATCH v6 08/32] icount: implement icount requesting
From: Paolo Bonzini [mailto:paolo.bonz...@gmail.com] On Behalf Of Paolo Bonzini On 10/12/2014 07:35, Pavel Dovgalyuk wrote: No, it worked well and I deleted _nocache version of that function. But I still need _raw one to get the instructions counter. Oh, great. This patch can also go in early. What's the next? Will you upstream some of the patches to simplify reviewing of the others? Pavel Dovgalyuk
Re: [Qemu-devel] [RFC PATCH v6 08/32] icount: implement icount requesting
On 11/12/2014 09:16, Pavel Dovgaluk wrote: No, it worked well and I deleted _nocache version of that function. But I still need _raw one to get the instructions counter. Oh, great. This patch can also go in early. What's the next? Will you upstream some of the patches to simplify reviewing of the others? I'm waiting for Alex to review the PPC bits, but I've already queued these: Paolo Bonzini (9): target-mips: kvm: do not use get_clock() Pavel Dovgalyuk (8): cpu-exec: fix cpu_exec_nocache cpu-exec: reset exception_index correctly icount: set can_do_io outside TB execution icount: introduce cpu_get_icount_raw cpu-exec: invalidate nocache translation if they are interrupted timer: introduce new QEMU_CLOCK_VIRTUAL_RT clock cpus: make icount warp behave well with respect to stop/cont i386: do not cross the pages boundaries in replay mode Also, more get_clock() changes were in Kevin's block pull request. Paolo
Re: [Qemu-devel] [RFC PATCH v6 08/32] icount: implement icount requesting
On 08/12/2014 08:53, Pavel Dovgalyuk wrote: if (!cpu_can_do_io(cpu)) { -fprintf(stderr, Bad clock read\n); +fprintf(stderr, Bad icount read\n); +exit(1); } icount -= (cpu-icount_decr.u16.low + cpu-icount_extra); } +return icount; +} + +/* Return the virtual CPU time, based on the instruction counter. */ +static int64_t cpu_get_icount_locked(void) +{ +int64_t icount = cpu_get_icount_raw(); return timers_state.qemu_icount_bias + cpu_icount_to_ns(icount); So it didn't work to set can_do_io? Paolo
Re: [Qemu-devel] [RFC PATCH v6 08/32] icount: implement icount requesting
No, it worked well and I deleted _nocache version of that function. But I still need _raw one to get the instructions counter. Sent using CloudMagic On вт, Дек 09, 2014 at 8:39 PM, Paolo Bonzini pbonz...@redhat.com wrote: On 08/12/2014 08:53, Pavel Dovgalyuk wrote: if (!cpu_can_do_io(cpu)) { - fprintf(stderr, "Bad clock read\n"); + fprintf(stderr, "Bad icount read\n"); + exit(1); } icount -= (cpu-icount_decr.u16.low + cpu-icount_extra); } + return icount; +} + +/* Return the virtual CPU time, based on the instruction counter. */ +static int64_t cpu_get_icount_locked(void) +{ + int64_t icount = cpu_get_icount_raw(); return timers_state.qemu_icount_bias + cpu_icount_to_ns(icount); So it didn't work to set can_do_io? Paolo
Re: [Qemu-devel] [RFC PATCH v6 08/32] icount: implement icount requesting
On 10/12/2014 07:35, Pavel Dovgalyuk wrote: No, it worked well and I deleted _nocache version of that function. But I still need _raw one to get the instructions counter. Oh, great. This patch can also go in early. Paolo