Skip to contentSkip to conversation

possible qemu miscompilation by latest gcc

Qemu-devel John Regehr 2 participants 2 messages Jan 21, 2010

lore
Share & tools
lore
#0 lore raw

Hi folks-

Just wanted to let you know that perhaps the function helper_neon_rshl_s8() is being miscompiled by the latest gcc.

I'm using qemu 0.12.2 and gcc rev 156103, which is a pre-version of gcc 4.5. This is on an x86 machine running Ubuntu 9.10.

At -O2 or higher this is the resulting object code:

00002060 <helper_neon_rshl_s8>:

    2060:	31 c0                	xor    %eax,%eax
    2062:	c3                   	ret

If this is not the intended result, then either the function has a latent bug or else the compiler is doing something bad.

Hope this is helpful,

John Regehr

#1 lore raw
Quoted 8 lines · John Regehr

Hi folks-

Just wanted to let you know that perhaps the function helper_neon_rshl_s8() is being miscompiled by the latest gcc.

I'm using qemu 0.12.2 and gcc rev 156103, which is a pre-version of gcc 4.5. This is on an x86 machine running Ubuntu 9.10.

Quoted 8 lines

At -O2 or higher this is the resulting object code:

00002060 <helper_neon_rshl_s8>:
2060: 31 c0 xor %eax,%eax
2062: c3 ret

If this is not the intended result, then either the function has a latent bug or else the compiler is doing something bad.

Confirmed. The compiler is at fault.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42833

r~