[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] implementing architectural timers using QEMU timers
From: |
Max Filippov |
Subject: |
Re: [Qemu-devel] implementing architectural timers using QEMU timers |
Date: |
Tue, 10 Jan 2017 10:45:06 -0800 |
On Tue, Jan 10, 2017 at 1:10 AM, Frederic Konrad
<address@hidden> wrote:
> On 01/09/2017 04:18 PM, Max Filippov wrote:
>> I'm trying to reimplement xtensa CCOUNT (cycle counter) and
>> CCOMPARE (CCOUNT-based timer interrupts) using QEMU
>> timers. That is CCOUNT value is derived from the
>> QEMU_CLOCK_VIRTUAL clock and CCOMPARE interrupts are
>> generated from the QEMU_CLOCK_VIRTUAL timer callbacks.
>> The code is here:
>> https://github.com/OSLL/qemu-xtensa/commits/xtensa-ccount
>>
>> I've got the following issues doing that:
>>
>> - I thought that could be improved in -icount mode, so I tried that.
>> It is better with -icount, but it's still not 100% accurate. That is
>> I was able to observe guest reading QEMU clock value that is
>> past QEMU timer deadline before that timer callback was
>> invoked.
>>
>> That sounds like a bug to me, is it?
>
> Did you try "sleep" icount option?
>
> eg:
> -icount 1,sleep=off
That doesn't seem to change anything.
--
Thanks.
-- Max