Skip to contentSkip to conversation

CPU change causes hanging of .NET apps

DISCUSSION Erik Rull 5 participants 12 messages Oct 28, 2009 – Nov 8, 2009 KVM

lore
Share & tools
lore

Erik Rull

author
#0 lore raw

Hi all,

when changing the CPU from the default QEMU32 one to e.g. the n270 or the core2duo no .NET apps will work under Windows XP as guest. Switching back and everything is fine. The Pentium Emulation on the other side works fine!

The Application loads but it hangs with 99% CPU usage and ca. 3-4 MB Memory
Consumption.

Normally, .NET is capable to run on all x86 Processors >= Pentium. XP and non-.NET Apps work fine.

Any Ideas what happens here? I also started applications that were NOT started with the QEMU32 CPU to prevent a caching - same problem.

Best regards,

Erik

#1 lore raw
Quoted 2 lines · Erik Rull

Any Ideas what happens here? I also started applications that were NOT started with the QEMU32 CPU to prevent a caching - same problem.

just a couple guesses:

- maybe there's some JIT'ed code cached somewhere in the filesystem

- maybe the exact code generator is chosen at startup time, or even at .NET installation time.

in short, if restarting windows doesn't fix it, i would reinstall .NET, or maybe the whole HAL

Signature · 1 line
Javier
#2 lore raw
In reply to Erik Rull
Quoted 5 lines · On Wednesday 28 October 2009 16:13:37 Erik Rull wrote:

Hi all,

when changing the CPU from the default QEMU32 one to e.g. the n270 or the core2duo no .NET apps will work under Windows XP as guest. Switching back and everything is fine. The Pentium Emulation on the other side works fine!

Have you tried with -cpu core2duo,-nx ?

--Iggy

Quoted 18 lines

The Application loads but it hangs with 99% CPU usage and ca. 3-4 MB Memory
Consumption.

Normally, .NET is capable to run on all x86 Processors >= Pentium. XP and non-.NET Apps work fine.

Any Ideas what happens here? I also started applications that were NOT started with the QEMU32 CPU to prevent a caching - same problem.

Best regards,

Erik
--
To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#3 lore raw
In reply to Erik Rull
Quoted 10 lines · Erik Rull

Hi all,

when changing the CPU from the default QEMU32 one to e.g. the n270 or the core2duo no .NET apps will work under Windows XP as guest. Switching back and everything is fine. The Pentium Emulation on the other side works fine!

The Application loads but it hangs with 99% CPU usage and ca. 3-4 MB Memory Consumption.

Normally, .NET is capable to run on all x86 Processors >= Pentium. XP and non-.NET Apps work fine.

Any Ideas what happens here? I also started applications that were NOT started with the QEMU32 CPU to prevent a caching - same problem.

What's your host cpu type?

Signature · 1 line
error compiling committee.c: too many arguments to function
author
#4 lore raw

Hi Avi,

the Host CPU is a Intel Core2Duo - VT capable and enabled!

Best regards,

Erik

Quoted 14 lines · Avi Kivity
Quoted 10 lines · Erik Rull

Hi all,

when changing the CPU from the default QEMU32 one to e.g. the n270 or the core2duo no .NET apps will work under Windows XP as guest. Switching back and everything is fine. The Pentium Emulation on the other side works fine!

The Application loads but it hangs with 99% CPU usage and ca. 3-4 MB Memory Consumption.

Normally, .NET is capable to run on all x86 Processors >= Pentium. XP and non-.NET Apps work fine.

Any Ideas what happens here? I also started applications that were NOT started with the QEMU32 CPU to prevent a caching - same problem.

What's your host cpu type?

#5 lore raw
Quoted 2 lines · Erik Rull

Hi Avi,

Please don't top-post.

Quoted 1 line

the Host CPU is a Intel Core2Duo - VT capable and enabled!

The problem is that one of the flags that -cpu core2duo enables is implemented incorrectly, so it leads to .net breakage.

These flags are pni, lm, nx, ssse3, syscall.

Please try -cpu core2duo,-pni,-lm,-nx,-ssse3,-syscall. If it works, remove features one by one until it doesn't and let us know the results.

Signature · 1 line
Do not meddle in the internals of kernels, for they are subtle and quick to panic.
author
#6 lore raw
Quoted 6 lines · Avi Kivity
Quoted 2 lines · Erik Rull

Hi Avi,

Please don't top-post.

Quoted 7 lines
Quoted 1 line

the Host CPU is a Intel Core2Duo - VT capable and enabled!

The problem is that one of the flags that -cpu core2duo enables is implemented incorrectly, so it leads to .net breakage.

These flags are pni, lm, nx, ssse3, syscall.

Please try -cpu core2duo,-pni,-lm,-nx,-ssse3,-syscall. If it works, remove features one by one until it doesn't and let us know the results.

I took all flags, same effect as without all of these flags. :(

Any other idea?

- Erik

#7 lore raw
Quoted 4 lines · Erik Rull

I took all flags, same effect as without all of these flags. :(

Any other idea?

It's probably the cache size query.

Does -cpu host work?

Signature · 1 line
error compiling committee.c: too many arguments to function
#8 lore raw

2009/11/3 Avi Kivity <[email protected]>:

Quoted 10 lines · Erik Rull
Quoted 4 lines

I took all flags, same effect as without all of these flags.  :(

Any other idea?

It's probably the cache size query.

Does -cpu host work?

My totally noob in QEMU guess -
my bet it's CR4.OSFXSR which is controlled by presence of cpuid.1.edx[24] - FXSR bit (FXSAVE and FXRSTOR) instructions.

I'm curious - is there any way in QEMU to redefine returned cpuid leaf values? It will be interesting to see results if that given bit will be disabled in configuration.

Best Regards,
Timur

#9 lore raw
Quoted 5 lines · Timur Safin

My totally noob in QEMU guess -
my bet it's CR4.OSFXSR which is controlled by presence of cpuid.1.edx[24] - FXSR bit (FXSAVE and FXRSTOR) instructions.

That would affect floating point as well.

Quoted 4 lines

I'm curious - is there any way in QEMU to redefine returned cpuid leaf values? It will be interesting to see results if that given bit will be disabled in configuration.

qemu -cpu host,-flag

Signature · 1 line
error compiling committee.c: too many arguments to function
author
#10 lore raw
Quoted 7 lines · Avi Kivity
Quoted 5 lines · Timur Safin

My totally noob in QEMU guess -
my bet it's CR4.OSFXSR which is controlled by presence of cpuid.1.edx[24] - FXSR bit (FXSAVE and FXRSTOR) instructions.

Quoted 9 lines

That would affect floating point as well.

Quoted 4 lines

I'm curious - is there any way in QEMU to redefine returned cpuid leaf values? It will be interesting to see results if that given bit will be disabled in configuration.

qemu -cpu host,-flag

I tried that value, result is an error:
Unable to find x86 CPU definition

- Erik

#11 lore raw
Quoted 6 lines · Erik Rull
Quoted 2 lines

qemu -cpu host,-flag

I tried that value, result is an error:
Unable to find x86 CPU definition

Please use qemu-kvm.git for this test.

Signature · 1 line
error compiling committee.c: too many arguments to function