Skip to contentSkip to conversation

Qemu workstation

Qemu-devel Jean-Michel POURE 9 participants 19 messages Apr 5, 2004 – Apr 8, 2004

lore
Share & tools
lore
#1 lore raw

Sweet Jesus... a new name, vmware shell look alike (not a step in the right direction IMHO... we could probably come up with a better UI than to rehash vmware's...) and the win32 port is not really operational yet (unless 0.5.3 actually made it process .iso files... I haven't built yet...)

Well I guess there's something to be said for multi-tasking.

Does anyone know who this is? I'd like to find out what kind of magic they are performing to get ReactOS running in win32 port.

Alas I suspect GIMP at work...

-- John.

#2 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

i agree. i don't know anything about the windows port, but personally, i think the draft of the linux-frontend looks more functional.
one thing about multitasking: there should probably be an option in the preferences dialog allowing to STOP the vm as soon as the focus goes to another one and to CONT that one. that would definitely be a step ahead of vmware, since they don't allow stopping a vm without dumping the memory to the hd.
it is probably too early to talk about these things, but it came to my mind today, so why not post it today.
another question: are there sources available for the linux frontend? many people on this list will also test the frontend, which would certainly speed up its development.
€0.06

"Re: [Qemu-devel] Qemu workstation" (John R. Hogerhuis, Monday 05 April 2004 11:10):

Quoted 6 lines

Sweet Jesus... a new name, vmware shell look alike (not a step in the right direction IMHO... we could probably come up with a better UI than to rehash vmware's...) and the win32 port is not really operational yet (unless 0.5.3 actually made it process .iso files... I haven't built yet...)

Quoted 8 lines

Well I guess there's something to be said for multi-tasking.

Does anyone know who this is? I'd like to find out what kind of magic they are performing to get ReactOS running in win32 port.

Alas I suspect GIMP at work...

-- John.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFAcScc1nTg39QS/TsRAt72AJ4wGaL9c/iwA+a7R8dL5qznUZVf7ACeJtDs v4GGCxmFBog9WbCrmLO7DHg=
=mdod
-----END PGP SIGNATURE-----

#17 lore raw
In reply to John R. Hogerhuis

Dear all,

Quoted 5 lines

Sweet Jesus... a new name, vmware shell look alike (not a step in the right direction IMHO... we could probably come up with a better UI than to rehash vmware's...) and the win32 port is not really operational yet (unless 0.5.3 actually made it process .iso files... I haven't built yet...)

Unless further evidence, source-code of QEWS for Win32 is not made available.

Quoted 4 lines

Well I guess there's something to be said for multi-tasking. Does anyone know who this is? I'd like to find out what kind of magic they are performing to get ReactOS running in win32 port. Alas I suspect GIMP at work...

Do you mean this project might be a hoax?

On the other hand, I would very like appreciate Alex (from the Morphix project) to commit his GNU/Linux code to Qemu CVS. It would probably be time/energy saving to build the GUI from Qemu CVS.

Cheers,
Jean-Michel

#18 lore raw
Quoted 1 line · Jean-Michel POURE

Do you mean this project might be a hoax?

I definitely wouldn't go that far. Haven't looked into it enough to say anything like that.

More like saying the Win32 version is probably vaporware (i.e. implementation not complete, with initial mock-up of running system for marketing purposes).

Has anyone gotten ReactOS to run in QEMU on Win32? The only one I know could have gotten that far is Mike. Otherwise, one would have to posit the existance of yet another win32 port of qemu.

-- John.

#4 lore raw

Hi,

I am interested by a GTK GUI for QEMU and I think it should be commited in the main QEMU CVS.

Some notes about the GUI:

- Avoid using SDL or SDL wrappers: it is simpler to use plain GTK or GDK to draw the VGA frame buffer.

- I am not sure that handling multiple VMs running at the same time is very useful (some architectural changes are needed in QEMU). But switching easily between VM configurations seems interesting.

- The VM description management must be integrated in the QEMU core. I plan to work on it soon (Renzo Davoli sent patch I need to study).

- The VM console should be available in a separate TAB for the hackers !

- Of course there should be commands to eject/insert medias, to change the hard disk images and to update the VM configuration (ideally a simple dialog for dummies and a more technical one to change IRQs, IO ports, number of interfaces).

Fabrice.

Quoted 22 lines · Jean-Michel POURE
Quoted 4 lines · Rudi Lippert

another question: are there sources available for the linux frontend? many people on this list will also test the frontend, which would certainly speed up its development.
€0.06

Dear Rudi,

I contacted Alex on Morphix mailing list about this issue. My post is:
http://www.morphix.org/modules/newbb/viewtopic.php?topic_id=1239&forum=3&jump=1

Cheers,
Jean-Michel

_______________________________________________
Qemu-devel mailing list
[email protected]
http://mail.nongnu.org/mailman/listinfo/qemu-devel

#5 lore raw
Quoted 3 lines

I am not sure that handling multiple VMs running at the same time is very useful (some architectural changes are needed in QEMU). But switching easily between VM configurations seems interesting.

I think that multiple VM's is a worthy goal as long as you can minimise CPU usage. Having multiple VM's gives you the ability to do some very cool things. I use VMWARE in Windows and sometimes have both Linux and FreeBSD running in VM's so I can test software against all 3 OS's at once. I imagine it would be very useful to developers of cluster software.

I tried the Win32 port the other day, running Linux, and it sat using 100% of the CPU whilst doing next to nothing at a command prompt. Using VMWARE, and waiting at a command prompt uses very little CPU time.

Is QEMU sat in a busy loop all the time?

Jamie.

#6 lore raw
Quoted 10 lines · Jamie Burns
Quoted 3 lines

I am not sure that handling multiple VMs running at the same time is very useful (some architectural changes are needed in QEMU). But switching easily between VM configurations seems interesting.

I think that multiple VM's is a worthy goal as long as you can minimise CPU usage. Having multiple VM's gives you the ability to do some very cool things. I use VMWARE in Windows and sometimes have both Linux and FreeBSD running in VM's so I can test software against all 3 OS's at once. I imagine it would be very useful to developers of cluster software.

Quoted 5 lines

I tried the Win32 port the other day, running Linux, and it sat using 100% of the CPU whilst doing next to nothing at a command prompt. Using VMWARE, and waiting at a command prompt uses very little CPU time.

Is QEMU sat in a busy loop all the time?

it is not QEMU but the hosted OS that is in the busy loop. QEMU will have to recognise "idle loops" to fix this - this could be really tricky.

Richard

#7 lore raw
Quoted 16 lines · Richard Zidlicky
Quoted 14 lines · Jamie Burns
Quoted 3 lines

I am not sure that handling multiple VMs running at the same time is very useful (some architectural changes are needed in QEMU). But switching easily between VM configurations seems interesting.

I think that multiple VM's is a worthy goal as long as you can minimise CPU usage. Having multiple VM's gives you the ability to do some very cool things. I use VMWARE in Windows and sometimes have both Linux and FreeBSD running in VM's so I can test software against all 3 OS's at once. I imagine it would be very useful to developers of cluster software.

I tried the Win32 port the other day, running Linux, and it sat using 100% of the CPU whilst doing next to nothing at a command prompt. Using VMWARE, and waiting at a command prompt uses very little CPU time.

Quoted 6 lines
Quoted 1 line

Is QEMU sat in a busy loop all the time?

it is not QEMU but the hosted OS that is in the busy loop. QEMU will have to recognise "idle loops" to fix this - this could be really tricky.

I guess if QEMU emulates the hlt instruction and the OS supports it then it's pretty easy.
I note above it said running linux, which does idle nicely when the hlt instruction is present, perhaps there is a not too difficult way for intelligent OS's. DOS is a lost cause however.

Brad

#15 lore raw
In reply to Richard Zidlicky

Isnt there an instruction that gets sent when the OS is idle? To keep processors cool etc?

VMWare describes some of this in:

http://www.vmware.com/support/kb/enduser/std_adp.php?p_faqid=1077

:o)

----- Original Message -----
From: "Richard Zidlicky" <[email protected]>
To: <[email protected]>
Sent: Tuesday, April 06, 2004 1:17 PM
Subject: Re: [Qemu-devel] Qemu workstation

Quoted 6 lines · Jamie Burns
Quoted 5 lines
Quoted 3 lines

I am not sure that handling multiple VMs running at the same time is very useful (some architectural changes are needed in QEMU). But switching easily between VM configurations seems interesting.

I think that multiple VM's is a worthy goal as long as you can minimise

CPU

Quoted 2 lines
Quoted 2 lines

usage. Having multiple VM's gives you the ability to do some very cool things. I use VMWARE in Windows and sometimes have both Linux and

FreeBSD

Quoted 1 line
Quoted 1 line

running in VM's so I can test software against all 3 OS's at once. I

imagine

Quoted 3 lines
Quoted 3 lines

it would be very useful to developers of cluster software.

I tried the Win32 port the other day, running Linux, and it sat using

100%

Quoted 1 line
Quoted 1 line

of the CPU whilst doing next to nothing at a command prompt. Using

VMWARE,

Quoted 16 lines
Quoted 3 lines

and waiting at a command prompt uses very little CPU time.

Is QEMU sat in a busy loop all the time?

it is not QEMU but the hosted OS that is in the busy loop. QEMU will have to recognise "idle loops" to fix this - this could be really tricky.

Richard

_______________________________________________
Qemu-devel mailing list
[email protected]
http://mail.nongnu.org/mailman/listinfo/qemu-devel

#8 lore raw
In reply to Brad Campbell
Quoted 2 lines · Brad Campbell

I guess if QEMU emulates the hlt instruction and the OS supports it then it's pretty easy.
I note above it said running linux, which does idle nicely when the hlt instruction is present, perhaps there is a not too difficult way for intelligent OS's. DOS is a lost cause however.

To clarify it, it's not 'HLT' instruction (Halt processor), but the 'NOP' instruction (No operation).

- Filip

#9 lore raw
Quoted 7 lines · Filip Navara
Quoted 2 lines · Brad Campbell

I guess if QEMU emulates the hlt instruction and the OS supports it then it's pretty easy.
I note above it said running linux, which does idle nicely when the hlt instruction is present, perhaps there is a not too difficult way for intelligent OS's. DOS is a lost cause however.

To clarify it, it's not 'HLT' instruction (Halt processor), but the 'NOP' instruction (No operation).

How does that work then?
I have some code that uses a NOP loop for accurate timing? That spins at 100% cpu usage, how does a NOP tell the processor to idle? HLT does.

Brad

#10 lore raw
Quoted 1 line · Brad Campbell

How does that work then?

I don't know the exact details.

Quoted 3 lines

I have some code that uses a NOP loop for accurate timing? That spins at 100% cpu usage, how does a NOP tell the processor to idle? HLT does.

HLT instruction halts the CPU so no more instructions are processed and the CPU freezes. That's usable only in situation like Windows blue screens.

- Filip

Signature · 5 lines
ANONYMNI PRIPOJENI K INTERNETU - bez registrace, zdarma, ihned!
Pripojeni na cisle 971 200 111 z cele CR,
v Praze navic na cisle 971 200 555.
Uzivatelske jmeno "volny", heslo "volny".
http://sluzby.volny.cz/product/dialup/anon/
#11 lore raw
Quoted 8 lines · Filip Navara
Quoted 1 line · Brad Campbell

How does that work then?

I don't know the exact details.

Quoted 7 lines
Quoted 2 lines

I have some code that uses a NOP loop for accurate
timing? That spins at 100% cpu usage, how does a NOP tell the processor to idle? HLT does.

HLT instruction halts the CPU so no more instructions are processed and the CPU freezes. That's usable only in situation like Windows blue screens.

It does? My information tells me that it halts the processor until an interrupt or other wakeup source occurs. Check arch/i386/kernel/process.c

/*
* We use this if we don't have any better
* idle routine..
*/
void default_idle(void)

{
        if (current_cpu_data.hlt_works_ok && !hlt_counter) {
                __cli();
                if (!current->need_resched)
                        safe_halt();
                else
                        __sti();
        }
}

and in include/asm/system.h

system.h:#define safe_halt() __asm__ __volatile__("sti; hlt": : :"memory")

Looks like a hlt to me and not a nop in site.
The kernel does a check at boot time to see if the processor supports the hlt instruction and if it does it uses that in the idle loop.

Am I wrong?

Brad

#12 lore raw
Quoted 38 lines · Brad Campbell
Quoted 8 lines · Filip Navara
Quoted 1 line · Brad Campbell

How does that work then?

I don't know the exact details.

Quoted 8 lines
Quoted 3 lines

I have some code that uses a NOP loop for accurate timing? That spins at 100% cpu usage, how does a NOP tell the processor to idle? HLT does.

HLT instruction halts the CPU so no more instructions are processed and the CPU freezes. That's usable only in situation like Windows blue screens.

It does? My information tells me that it halts the processor until an interrupt or other wakeup source occurs. Check arch/i386/kernel/process.c

/*
* We use this if we don't have any better
* idle routine..
*/
void default_idle(void)

{
         if (current_cpu_data.hlt_works_ok && !hlt_counter) {
                 __cli();
                 if (!current->need_resched)
                         safe_halt();
                 else
                         __sti();
         }
}

and in include/asm/system.h

Quoted 7 lines

system.h:#define safe_halt() __asm__ __volatile__("sti; hlt": : :"memory")

Looks like a hlt to me and not a nop in site.
The kernel does a check at boot time to see if the processor supports the hlt instruction and if it does it uses that in the idle loop.

Am I wrong?

You are right.

HLT will block only until interrupt arrives. And there is at least clock interrupt from time to time.

It helps to cool down the processor too. And autodetection on some processors / motherboards is not correct, so there is nohalt kernel parameter.

For blue screens (for me red since I use some tweaker :-) - *no more blue screens*(TM)) win probably uses JMP $ or something like that (depending on their/your assembler syntax).

And NOP instruction is not good candidate for wasting time anymore on newer processrs (since PII I think, maybe later) since processor can optimize it out and the only thing that survives that optimization is conditional jump, but in cache, so latency is very small.

regards

Grzegorz Kulewski

#14 lore raw
In reply to Brad Campbell

----- PŮVODNÍ ZPRÁVA -----
Od: "Brad Campbell" <[email protected]>
Komu: [email protected]
Předmět: Re: [Qemu-devel] Qemu workstation
Datum: 7.4.2004 - 10:24:12

...

Quoted 24 lines

It does? My information tells me that it halts the processor until an interrupt or other wakeup source occurs. Check arch/i386/kernel/process.c

/*
* We use this if we don't have any better
* idle routine..
*/
void default_idle(void)
{
if (current_cpu_data.hlt_works_ok && !hlt_counter) { __cli();
if (!current->need_resched)
safe_halt();
else
__sti();
}
}

and in include/asm/system.h

system.h:#define safe_halt() __asm__
__volatile__("sti; hlt": : :"memory")

Quoted 9 lines

Looks like a hlt to me and not a nop in site. The kernel does a check at boot time to see if the processor supports the hlt instruction and if it does it uses that in the idle loop.

Am I wrong?

Brad

You are right and I'm wrong, sorry.

- Filip

Signature · 5 lines
ANONYMNI PRIPOJENI K INTERNETU - bez registrace, zdarma, ihned!
Pripojeni na cisle 971 200 111 z cele CR,
v Praze navic na cisle 971 200 555.
Uzivatelske jmeno "volny", heslo "volny".
http://sluzby.volny.cz/product/dialup/anon/
#13 lore raw
In reply to Grzegorz Kulewski
Quoted 46 lines · Grzegorz Kulewski
Quoted 44 lines · Brad Campbell
Quoted 8 lines · Filip Navara
Quoted 1 line · Brad Campbell

How does that work then?

I don't know the exact details.

Quoted 8 lines
Quoted 3 lines

I have some code that uses a NOP loop for accurate timing? That spins at 100% cpu usage, how does a NOP tell the processor to idle? HLT does.

HLT instruction halts the CPU so no more instructions are processed and the CPU freezes. That's usable only in situation like Windows blue screens.

It does? My information tells me that it halts the processor until an interrupt or other wakeup source occurs. Check arch/i386/kernel/process.c

/*
* We use this if we don't have any better
* idle routine..
*/
void default_idle(void)

{
         if (current_cpu_data.hlt_works_ok && !hlt_counter) {
                 __cli();
                 if (!current->need_resched)
                         safe_halt();
                 else
                         __sti();
         }
}

and in include/asm/system.h

system.h:#define safe_halt() __asm__ __volatile__("sti; hlt": : :"memory")

Looks like a hlt to me and not a nop in site.
The kernel does a check at boot time to see if the processor supports the hlt instruction and if it does it uses that in the idle loop.

Quoted 6 lines
Quoted 1 line

Am I wrong?

You are right.

HLT will block only until interrupt arrives. And there is at least clock interrupt from time to time.

.. anyone remembers the Pentium(tm) "halt" bug ? How should QEMU emulate that ?;)

it is easy when the guest OS uses hlt of course but a brief look at some Linux kernel sources suggests there are a few more methods to do it. Well x86 assembly was never my strong point.

Richard