qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Avi Kivity <avi@redhat.com>
To: Blue Swirl <blauwirbel@gmail.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v3 2/2] bitops: fix types
Date: Mon, 16 Jul 2012 18:25:40 +0300	[thread overview]
Message-ID: <50043274.7020302@redhat.com> (raw)
In-Reply-To: <0e5d35008c438b250c66b1ab4e774bd718521d8c.1342269249.git.blauwirbel@gmail.com>

On 07/14/2012 03:34 PM, Blue Swirl wrote:
> bitops.h uses inconsistently 'unsigned long' and 'int' for bit numbers.
> 
> Unify to 'unsigned long' because it generates better code on x86_64.
> Adjust asserts accordingly.
> 


Actually, plain unsigned generates the best code.  unsigned longs
require an extra byte for many instructions.  It also requires more
stack space if spilled.  Unsigned does not, but is compatible with
unsigned long in case it needs to be used in pointer arithmetic (unlike
signed int which needs a sign extension instruction).

-- 
error compiling committee.c: too many arguments to function

  reply	other threads:[~2012-07-16 15:25 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-14 12:34 [Qemu-devel] [PATCH v3 0/2] bitops patches Blue Swirl
2012-07-14 12:34 ` [Qemu-devel] [PATCH v3 1/2] bitops: drop volatile qualifier Blue Swirl
2012-07-14 12:36   ` Peter Maydell
2012-07-16 14:40   ` Eric Blake
2012-07-23 16:38     ` Blue Swirl
2012-07-14 12:34 ` [Qemu-devel] [PATCH v3 2/2] bitops: fix types Blue Swirl
2012-07-16 15:25   ` Avi Kivity [this message]
2012-07-16 15:34   ` Peter Maydell
2012-07-17 12:36     ` Markus Armbruster
2012-07-23 17:33       ` Blue Swirl
2012-07-23 17:44         ` Peter Maydell
2012-07-24  9:26           ` Markus Armbruster
2012-07-24 19:51             ` Blue Swirl

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=50043274.7020302@redhat.com \
    --to=avi@redhat.com \
    --cc=blauwirbel@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).