From: Zeev Tarantov <zeev.tarantov@gmail.com>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] fix for TEST_BSX in test-i386.c
Date: Fri, 12 Sep 2008 16:24:49 +0000 (UTC) [thread overview]
Message-ID: <loom.20080912T161811-727@post.gmane.org> (raw)
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
reply other threads:[~2008-09-12 16:30 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=loom.20080912T161811-727@post.gmane.org \
--to=zeev.tarantov@gmail.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).