From: "Jan Beulich" <JBeulich@suse.com>
To: Andrew Cooper <andrew.cooper3@citrix.com>
Cc: xen-devel <xen-devel@lists.xenproject.org>,
Kevin Tian <kevin.tian@intel.com>,
Jun Nakajima <jun.nakajima@intel.com>
Subject: Re: [PATCH] x86: use gcc6'es flags asm() output support
Date: Tue, 02 Aug 2016 00:09:55 -0600 [thread overview]
Message-ID: <57A055530200007800101916@prv-mh.provo.novell.com> (raw)
In-Reply-To: <f70b245c-3fd0-40a5-40e3-90f67e37b2e2@citrix.com>
>>> On 01.08.16 at 19:11, <andrew.cooper3@citrix.com> wrote:
> On 01/08/16 17:06, Jan Beulich wrote:
>>>>> On 01.07.16 at 18:51, <andrew.cooper3@citrix.com> wrote:
>>> How about a different example, from the second hunk
>>>
>>> --- a/xen/arch/x86/x86_emulate/x86_emulate.c
>>> +++ b/xen/arch/x86/x86_emulate/x86_emulate.c
>>> @@ -832,8 +832,19 @@ static int read_ulong(
>>> static bool_t mul_dbl(unsigned long m[2])
>>> {
>>> bool_t rc;
>>> - asm ( "mul %1; seto %2"
>>> - : "+a" (m[0]), "+d" (m[1]), "=qm" (rc) );
>>> +
>>> + asm ( "mul %1;"
>>> +#ifndef __GCC_ASM_FLAG_OUTPUTS__
>>> + "seto %[rc];"
>>> +#endif
>>> + : "+a" (m[0]), "+d" (m[1]),
>>> +#ifdef __GCC_ASM_FLAG_OUTPUTS__
>>> + [rc] "=@cco" (rc)
>>> +#else
>>> + [rc] "=qm" (rc)
>>> +#endif
>>> + );
>>> +
>>> return rc;
>>> }
>> Looking at this again I think I really like the original, submitted version
>> better. Are you strongly biased towards the above form?
>
> I am not overly fussed between this version and the original submission.
>
> However, I definitely think that we shouldn't hide semantic bits of the
> ASM statement behind macros.
Well, the originally submitted variant doesn't do anything like that,
so may I translate the above to an ack?
Jan
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next prev parent reply other threads:[~2016-08-02 6:10 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-01 15:01 [PATCH] x86: use gcc6'es flags asm() output support Jan Beulich
2016-07-01 15:38 ` Andrew Cooper
2016-07-01 15:54 ` Jan Beulich
2016-07-01 16:10 ` Jan Beulich
2016-07-01 16:51 ` Andrew Cooper
2016-07-04 7:34 ` Jan Beulich
2016-08-01 16:06 ` Jan Beulich
2016-08-01 17:11 ` Andrew Cooper
2016-08-02 6:09 ` Jan Beulich [this message]
2016-08-02 9:15 ` Andrew Cooper
2016-08-02 10:39 ` Jan Beulich
2016-07-04 6:24 ` Tian, Kevin
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=57A055530200007800101916@prv-mh.provo.novell.com \
--to=jbeulich@suse.com \
--cc=andrew.cooper3@citrix.com \
--cc=jun.nakajima@intel.com \
--cc=kevin.tian@intel.com \
--cc=xen-devel@lists.xenproject.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.