Skip to contentSkip to conversation

i386 emulation on PowerPC host

PATCH RESEND New Lyonel Vincent 1 participant 1 message Apr 9, 2006

lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 i386 emulation on PowerPC host

Hi all,

Having noticed very wierd behaviour of some operations under an x86 Qemu guest running on a PowerPC (32 bits), I have compiled the following test program under Linux/i386:

#include <stdio.h>
#include <math.h>

void main()
{
float x = exp(1)*exp(1);
float y = exp(2);

printf("%f = %f\n", x, y);
}

When run under native i386 Linux, this program displays:

$ ./mathtest
7.389056 = 7.389056

as expected

but with a CVS snapshot (as of 2006-03-23) of Qemu, one gets:

$ ./mathtest
7.389056 = -inf

[that's the same binary running under Linux/i386 inside Qemu on a PowerPC host]

I also have other strange symptoms like cp sometimes complaining about memory exhaustion but I haven't been able to reproduce those yet...

Does anybody have an idea of what the problem could be and how I could help to fix that?

cheers,
Lyonel.