[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] Qemu as Instruction Set Simulator without any OS
From: |
Anitha Boyapati |
Subject: |
Re: [Qemu-devel] Qemu as Instruction Set Simulator without any OS |
Date: |
Wed, 1 Sep 2010 18:24:41 +0530 |
Hello Robin,
>> 1. For a microcontroller which doesn't have any OS support, can QEMU be
>> ported without any OS ?
>
> On the other hand, if your question could be rephrased as 'I want to add
> support for a new microcontroller to qemu but I only want to run "bare-metal"
> (not an OS or an application under an OS) software on the model', I think
> that is certainly possible.
>
Yes, this is what I have been looking for. Adding support for a new
micro-controller which doesn't support any OS yet.
>> 2. Can QEMU be used as a simple instruction set simulator with probably
>> gdb support for remote debugging? My guess is this would require a
>> bootloader to load the application to run the application program (full
>> system emulation mode or just machine emulation if there is something
>> like that). If yes, what else can be the blocker to have gdb support?
>
> IMHO, gdb support if available, is available irrespective of the type and
> nature of the software being run on qemu. For example, you can create a
> bare-metal application that executes from the reset vector for say, the ARM
> or the MIPS models and have gdb support right from the outset. There is no
> explicit need for running boot firmware and/or a loader to load an
> application program. Not sure if that's what you were after.
>
My exact requirement is to test a gcc cross-compiler using DejaGnu for
a given target (AVR32). While the cross-compiler is ready, there is no
simulator. Since there is not much of OS support, I am trying to
evaluate if Qemu can still be considered for this purpose.
The usage scenario probably goes like this:
1. Qemu-target should be invoked with the application (yes,
bare-metal) waiting for some gdb connection.
2. target-gdb is invoked with the same application
I am referring to the example given in
http://wiki.qemu.org/download/qemu-doc.html#gdb_005fusage :
> qemu -s -kernel arch/i386/boot/bzImage -hda root-2.4.20.img -append
> "root=/dev/hda"
However, in my case kernel image doesn't exist. As to the requirement
of bootloader, I need to investigate further as various types of
memories (FLASH & SRAM for program and data sections) exist.
> This does require system-mode emulation support as opposed to user-mode
> emulation for your microcontroller to be implemented.
Agreed. System-mode emulation is what is required.
Thanks
Anitha