qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Question about target port


From: Paul Brook
Subject: Re: [Qemu-devel] Question about target port
Date: Mon, 16 Oct 2006 00:15:11 +0100
User-agent: KMail/1.9.4

On Tuesday 10 October 2006 12:07, Martin Guy wrote:
> > How can I change target CPU to Atmel's AVR and don't care about host.
> > i.e:host CPU is X86(PC),target CPU is Atmel's AVR.
>
> Hi
>   Atmel AVR is a different processor from the ones that QEMU emulates.
> You would need to implement an entire new emulation inside QEMU; that
> is a LOT of work in C programming. It is also an 8-bit processor,
> while all the ones that qemu currently emulates are 32-bit, so you may
> need to restructure the code as well to support 8-bit.

I got the impression the AVR was a fairly straightforward CPU. I wouldn't 
expect the 8-bitness to be a particular problem. x86 has lots of crufty 16 
and 8-bit corners :-) It might not be amazingly efficient, but real AVR 
silicon is really slow anyway.

IIRC AVR has separate code and data address spaces. However as these are both 
<32-bit you can probably fake this by implementing them as offsets within a 
single 32-bit address space.

That said, porting qemu to a new cpu is a fair amount of work, especially if 
you're not familiar with qemu internals. I recommend looking back in the list 
archives to CVS for where the mips and SH ports were added. That will give 
you some indication of the magnitude of the changes required.

Paul




reply via email to

[Prev in Thread] Current Thread [Next in Thread]