[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] fix for TEST_BSX in test-i386.c
From: |
Zeev Tarantov |
Subject: |
[Qemu-devel] fix for TEST_BSX in test-i386.c |
Date: |
Fri, 12 Sep 2008 16:24:49 +0000 (UTC) |
User-agent: |
Loom/3.14 (http://gmane.org/) |
Hello!
On GCC 4.3.1 with any optimization level higher than -O0, I get syntax errors
for test_bsx() in test-i386.c. The following patch fixes the problem and tests
pass. I assume gcc-3.3 didn't have any problems with this code, but I believe my
patch is objectively correct.
--- tests/test-i386.c (revision 5199)
+++ tests/test-i386.c (working copy)
@@ -716,8 +716,8 @@
asm("xor %1, %1\n"\
"mov $0x12345678, %0\n"\
#op " %" size "2, %" size "0 ; setz %b1" \
- : "=r" (res), "=q" (resz)\
- : "g" (val));\
+ : "=&r" (res), "=&q" (resz)\
+ : "r" (val));\
printf("%-10s A=" FMTLX " R=" FMTLX " %ld\n", #op, val, res, resz);\
}
-Zeev
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Qemu-devel] fix for TEST_BSX in test-i386.c,
Zeev Tarantov <=