[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] xenalyze: Use types which have consistent sizes across 32- and 64-bit compiles


  • To: Tim Deegan <Tim.Deegan@xxxxxxxxxx>
  • From: George Dunlap <George.Dunlap@xxxxxxxxxxxxx>
  • Date: Thu, 25 Nov 2010 12:09:03 +0000
  • Cc: Olaf Hering <olaf@xxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Thu, 25 Nov 2010 04:10:23 -0800
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=QXSu5nyB3vQJL8XuOAHy8xrbegDo+QX3se2Df7AGjFuOhQ96irMWF1sEX3aYYGD1ai Ua5Csqf5fFPvtPU5JZtpHb7CNeAkSm5kL/6jUnEMsWmmCDaa6a75VIHIQpji/eEXulDO ox3Ky9theJH4v/4cBheZLEjpuEb+l8uME98ns=
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

On Thu, Nov 25, 2010 at 11:22 AM, Tim Deegan <Tim.Deegan@xxxxxxxxxx> wrote:
> At 11:17 +0000 on 25 Nov (1290683878), Olaf Hering wrote:
>> On Mon, Nov 22, George Dunlap wrote:
>>
>> > Always use [unsigned] long long for 64-bit, [unsigned] int for 32-bit.
>>
>> George,
>>
>> there are two unsigned long left in hvm_mmio_assist_process().
>> I think the sizeof(unsigned long) should be sizeof(unsigned int).
>
> Why not use the stdint.h explicit-width types?

Because using them with printf() is ugly and clunky?

I was thinking at some point I'd need to go over to using stdint
types, but was putting it off as I deemed it unpleasant.  However, if
simply not using "long" works for x32 and x64, I'm happy.  I'd
consider patches switching over to stdint.h, but I probably won't
write one myself unless there's a compelling reason to do so.

 -George

>
> Tim.
>
> --
> Tim Deegan <Tim.Deegan@xxxxxxxxxx>
> Principal Software Engineer, Xen Platform Team
> Citrix Systems UK Ltd.  (Company #02937203, SL9 0BG)
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/xen-devel
>

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.