Re: [PATCH] slow_map: minor improvements to ROM BAR handling

Michael S. Tsirkin
2009-12-23T09:18:14Z

On Tue, Dec 22, 2009 at 05:39:22PM +0200, Avi Kivity wrote:
> On 12/22/2009 05:36 PM, Alexander Graf wrote:
>>
>>> Is there a way to trap this and fprintf something?
>>>
>> I don't think so. KVM will just trap on execution outside of RAM and
>> either fail badly or throw something bad into the guest. MMIO access
>> works by analyzing the instruction that accesses the MMIO address. That
>> just doesn't work when we don't have an instruction to analyze.
>>
>
> We could certainly extend emulate.c to fetch instruction bytes from
> userspace. It uses ->read_std() now, so we'd need to switch to
> ->read_emulated() and add appropriate buffering.

You mean run with KVM, and TCG will kick in when there's
an instruction we can't support natively?

> --
> error compiling committee.c: too many arguments to function