Re: NSInteger vs int vs int32_t
Re: NSInteger vs int vs int32_t
- Subject: Re: NSInteger vs int vs int32_t
- From: Kyle Sluder <email@hidden>
- Date: Mon, 02 Jul 2012 16:17:49 -0700
On Jul 2, 2012, at 3:56 PM, Jens Alfke wrote:
>
> On Jul 2, 2012, at 3:28 PM, Charles Srstka wrote:
>
>> NSInteger is always equal to the native integer size of the host machine; 32 bits in 32-bit, 64 bits in 64-bit. I would imagine this helps performance, as the processor will be dealing with its native integer type.
>
> It depends. 64-bit values are twice as big as 32-bit ones, so they use up twice as much L2 cache and RAM.
I would be surprised if cache is managed at anything other than multiples of register width (64 bits).
--Kyle Sluder
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden