qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Richard Henderson <rth@twiddle.net>
To: Pranith Kumar <bobby.prani@gmail.com>,
	"Emilio G. Cota" <cota@braap.org>,
	"open list:All patches CC here" <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH] util/cacheinfo: Fix warning generated by clang
Date: Sat, 1 Jul 2017 15:20:25 -0700	[thread overview]
Message-ID: <63517903-f0e7-59db-47e2-e12f595092cf@twiddle.net> (raw)
In-Reply-To: <20170630153946.11997-1-bobby.prani@gmail.com>

On 06/30/2017 08:39 AM, Pranith Kumar wrote:
> Clang generates the following warning on aarch64 host:
> 
>    CC      util/cacheinfo.o
> /home/pranith/qemu/util/cacheinfo.c:121:48: warning: value size does not match register size specified by the constraint and modifier [-Wasm-operand-widths]
>          asm volatile("mrs\t%0, ctr_el0" : "=r"(ctr));
>                                                 ^
> /home/pranith/qemu/util/cacheinfo.c:121:28: note: use constraint modifier "w"
>          asm volatile("mrs\t%0, ctr_el0" : "=r"(ctr));
>                             ^~
>                             %w0

That is an absolutely stupid warning.  There's long precedent for the compiler 
choosing the prefix for you based on the type of the argument.

> 
> Constraint modifier 'w' is not (yet?) accepted by gcc. Fix this by increasing the ctr size.

Certainly it is -- since the beginning of time.


r~

  parent reply	other threads:[~2017-07-01 22:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-30 15:39 [Qemu-devel] [PATCH] util/cacheinfo: Fix warning generated by clang Pranith Kumar
2017-06-30 21:15 ` Emilio G. Cota
2017-07-01 22:20 ` Richard Henderson [this message]
2017-07-01 22:30   ` Peter Maydell
2017-07-01 22:35     ` Richard Henderson
2017-07-01 22:44       ` Peter Maydell
2017-07-03 21:16         ` Richard Henderson

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=63517903-f0e7-59db-47e2-e12f595092cf@twiddle.net \
    --to=rth@twiddle.net \
    --cc=bobby.prani@gmail.com \
    --cc=cota@braap.org \
    --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).