kqemu vs Standard
Hi Qemu developers & users!
I'm reporting in to say that I've lightly tested Qemu/kqemu, and found it to be significantly faster with both XP and Linux guest OSs.
I tested with the following setup:
Real Hardware: IBM Thinkpad T42p, pentium M 1.80GHz, 1GB RAM, 60G IDE HD Host OS: Fedora Core 3 "everything" installation, very slight kernel
reconfig changes.
Guest OS: XP Corp. SP1
----------------------
This feels noticeably faster. Double clicking on icons works a bit better, although it doesn't work all that well still. Instead, I right click on icons and select "Open". :) The programs run faster as well, but I'm not sure yet how I could test how much faster. Plus, I'm happy with it, so I may not spend much time figuring that out.
XP boot, all the way to the desktop:
65 seconds regular
45 seconds kqemu
Also, due to other changes that were checked in either at the same time as kqemu, or just before, I believe some bugs were fixed because some errors I used to get running some of the software I run are now gone.
Guest OS: RedHat Linux 9, modified to run a 2.6 kernel
------------------------------------------------
This boots much faster now, as the numbers below show.
Linux boot, all the way to the text (non-graphical) login prompt:
86 seconds regular
36 seconds kqemu
Probably also due to numberous bug fixes checked in recently, my Java VM/Tomcat installation now runs inside qemu without crashing with a HotSpot VM error. It used to run for a bit, then crash, and there wasn't anything I could do about it other than run a newer version of Sun's JVM. Now, it just works. :) I'm not yet sure if it works in the unaccelerated mode. I'm about to test that. Also, in unaccelerated mode, the Java VM runs very slow versus natively. But, using kqemu, it's decently fast. Fast enough to develop with it running inside qemu. Excellent!
A Little More About How I Tested
--------------------------------
This was all done with qemu source from CVS as of the day Fabrice checked in kqemu. I compiled it on FC3 like:
# ./configure # make # make install
So, nothing fancy there.
To switch between kqemu-accelerated, and standard (unaccelerated), all I did was load or unload the kqemu module. Yes, when I ran qemu with it unloaded I did get the output warning saying the acceleration was disabled.
Here's my real (laptop) hardware's CPU info:
# cat /proc/cpuinfo processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 13 model name : Intel(R) Pentium(R) M processor 1.80GHz stepping : 6 cpu MHz : 599.679 cache size : 2048 KB fdiv_bug : no hlt_bug : no f00f_bug : no coma_bug : no fpu : yes fpu_exception : yes cpuid level : 2 wp : yes flags : fpu vme de pse tsc msr mce cx8 mtrr pge mca cmov pat clflush dts acpi mmx fxsr sse sse2 ss tm pbe est tm2 bogomips : 1187.84
Signature · 1 line
Jason Brittain
Quoted 9 lines · Jason Brittain
Here's my real (laptop) hardware's CPU info:
# cat /proc/cpuinfo processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 13 model name : Intel(R) Pentium(R) M processor 1.80GHz stepping : 6 cpu MHz : 599.679
I just wonder, but do you usually work with CPU clocked-down? Or have you tested running on battery?
Cheers,
Karel
--
Karel Gardas [email protected]
ObjectSecurity Ltd. http://www.objectsecurity.com
Quoted 12 lines · Karel Gardas
Quoted 9 lines · Jason Brittain
Here's my real (laptop) hardware's CPU info:
# cat /proc/cpuinfo processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 13 model name : Intel(R) Pentium(R) M processor 1.80GHz stepping : 6 cpu MHz : 599.679
Quoted 2 lines
I just wonder, but do you usually work with CPU clocked-down? Or have you tested running on battery?
Interesting! I wrote the email about all this while riding to work on the subway. So, when I did the "cat /proc/cpuinfo", I was indeed running on battery power. But, currently, I'm not, and still says the same thing.
Anyone know what the deal is with that? Is that an accurate number saying that my cpu is throttled down? Could I make it run faster then? Hmmmm..
Signature · 1 line
Jason Brittain
Quoted 16 lines · Jason Brittain
Quoted 12 lines · Karel Gardas
Quoted 9 lines · Jason Brittain
Here's my real (laptop) hardware's CPU info:
# cat /proc/cpuinfo processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 13 model name : Intel(R) Pentium(R) M processor 1.80GHz stepping : 6 cpu MHz : 599.679Quoted 2 lines
I just wonder, but do you usually work with CPU clocked-down? Or have you tested running on battery?
Quoted 7 lines
Interesting! I wrote the email about all this while riding to work on the subway. So, when I did the "cat
/proc/cpuinfo", I was indeed running on battery power. But, currently, I'm not, and still says the same thing.Anyone know what the deal is with that? Is that an accurate number saying that my cpu is throttled down? Could I make it run faster then? Hmmmm..
On a 2.6-kernel with cpufreq enabled, have a look at the files in "/sys/devices/system/cpu/cpu0/cpufreq/". Try to echo "powersave" or "performance" to scaling_governor. Then look at "/proc/cpuinfo" to see the actual MHz.
You can also play around with acpi throttling in "/proc/acpi/processor/*/throttling". I guess * should be replaced with CPU0, but on my crappy laptop with wierd acpi info CPU1 must be used instead of CPU0.
Also, try cpufreqd or cpudyn to adjust the cpu frequency on the fly.
/ magnus
Hello,
Quoted 2 lines · Jason Brittain
Anyone know what the deal is with that? Is that an accurate number saying that my cpu is throttled down? Could I make it run faster then?
Do something like : "watch -n 1 "cat /proc/cpuinfo | grep Mhz" and then do something that needs CPU power on your laptop. Normally, you should see an increase of the frequency.
If not, it's because your laptop is not properly configured I think. You should have a look at powernowd and other frequency scaling stuff.
Thomas
Signature · 4 lines
PETAZZONI Thomas - [email protected] http://thomas.enix.org - Jabber: [email protected] KOS: http://kos.enix.org/ - SOS: http://sos.enix.org Fingerprint : 0BE1 4CF3 CEA4 AC9D CC6E 1624 F653 CB30 98D3 F7A7
Quoted 5 lines · Jason Brittain
Real Hardware: IBM Thinkpad T42p, pentium M 1.80GHz, 1GB RAM, 60G IDE HD Host OS: Fedora Core 3 "everything" installation, very slight kernel
reconfig changes.Here's my real (laptop) hardware's CPU info:
Quoted 8 lines
# cat /proc/cpuinfo processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 13 model name : Intel(R) Pentium(R) M processor 1.80GHz stepping : 6 cpu MHz : 599.679
Make sure "machine check exception" and "check for P4 thermal throttling interrupt" are both on in your kernel config, under "Processor type and features". Then check your dmesg for warnings about overheating.
Under the next menu, if you're using ACPI, then make sure to turn on IBM laptop extras. Under CPU Frequency scaling, do what seems right for your hw.
Of course, none of this actually has anything to do with qemu.
-=- James Mastros
That's just the natural effect of the Speedstep technology throttling back the cpu to lower heat because you aren't using many cpu cycles at the moment (you aren't pushing your laptop very hard :). If you were to do something like, say, compile Wine, and while it is compiling cat /proc/cpuinfo, you would see that the speed is up at 1800MHz.
Cheers,
D
Quoted 24 lines · Jason Brittain
Quoted 12 lines · Karel Gardas
Quoted 9 lines · Jason Brittain
Here's my real (laptop) hardware's CPU info:
# cat /proc/cpuinfo processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 13 model name : Intel(R) Pentium(R) M processor 1.80GHz stepping : 6 cpu MHz : 599.679Quoted 2 lines
I just wonder, but do you usually work with CPU clocked-down? Or have you tested running on battery?
Interesting! I wrote the email about all this while riding to work on the subway. So, when I did the "cat
/proc/cpuinfo", I was indeed running on battery power. But, currently, I'm not, and still says the same thing.Anyone know what the deal is with that? Is that an accurate number saying that my cpu is throttled down? Could I make it run faster then? Hmmmm..
Signature · 1 line
Darryl Dixon <[email protected]>
Quoted 5 lines · Magnus Damm
Quoted 5 lines
Interesting! I wrote the email about all this while riding to work on the subway. So, when I did the "cat
/proc/cpuinfo", I was indeed running on battery power. But, currently, I'm not, and still says the same thing.
Quoted 8 lines
Quoted 3 lines
Anyone know what the deal is with that? Is that an accurate number saying that my cpu is throttled down? Could I make it run faster then? Hmmmm..
On a 2.6-kernel with cpufreq enabled, have a look at the files in "
/sys/devices/system/cpu/cpu0/cpufreq/". Try to echo "powersave" or "performance" toscaling_governor. Then look at "/proc/cpuinfo" to see the actual MHz.
Ahh, yeah. I did:
# echo "performance" >> /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
And now my /proc/cpuinfo looks like:
processor : 0vendor_id : GenuineIntel
cpu family : 6
model : 13
model name : Intel(R) Pentium(R) M processor 1.80GHz
stepping : 6
cpu MHz : 1799.038
cache size : 2048 KBfdiv_bug : nohlt_bug : nof00f_bug : nocoma_bug : no
fpu : yesfpu_exception : yes
cpuid level : 2
wp : yes
flags : fpu vme de pse tsc msr mce cx8 mtrr pge mca cmov pat clflush dts acpi mmx fxsr sse sse2 ss tm pbe est tm2
bogomips : 3563.52
BUT, I retried my tests and the performance numbers/timings came out the same.
Quoted 6 lines
You can also play around with acpi throttling in "
/proc/acpi/processor/*/throttling". I guess * should be replaced with CPU0, but on my crappy laptop with wierd acpi info CPU1 must be used instead of CPU0.Also, try cpufreqd or cpudyn to adjust the cpu frequency on the fly.
Thanks for the tips on those. I'll look into them.
Quoted 5 lines · Darryl Dixon
That's just the natural effect of the Speedstep technology throttling back the cpu to lower heat because you aren't using many cpu cycles at the moment (you aren't pushing your laptop very hard :). If you were to do something like, say, compile Wine, and while it is compiling cat
/proc/cpuinfo, you would see that the speed is up at 1800MHz.
I believe this, since the CPU performance turned out the same either way. More good info.. thanks!
Signature · 1 line
Jason Brittain