Re: Mac Pro memory sizes
Re: Mac Pro memory sizes
- Subject: Re: Mac Pro memory sizes
- From: Kenneth Bruno II <email@hidden>
- Date: Mon, 12 Jan 2009 18:46:55 -0500
On Jan 12, 2009, at 5:51 PM, Schultz Keith J. wrote:
Hi Julius,
If I understand your problem correctly you are:
1) processing a very large amount of intergers
2) using highly optimized code that is:
a) you are manipulating the data directly via pointers
b) the data in memory is expected to be in a specific
order/structure
c) the data is stored on disk in pure binary form
that is the same format as in memory
Several years back I had optimized the code of a C program and
gained a
speed bump by the factor of 100 by doing the above and doing the
pointer
arithmatic by hand for accessing the data in the structure instead
of using
builtins and standard structures.
So you do not need to worry about the size of your data just how you
access it,
I had to have the program work on different architectures with
different word sizes.
The inital data where in text for so the conversion to integer was
easy. The trick was
to use the sizeof function to get the correct values for the pointer
math.
Far as stuffing two 32-bit values into a 64-bit value to avoid
possible context
switching is probaly a very bad trade off as the handling to such
values and doing
any kind of math with will hurt you badly speed wise with no space
savings.
Of course if you can do the math with bitwise operation directly you
could process
two integers at one time. But, I do not know exactly what you are up
to.
And of course you should take a look at the Apple documentation for
this topic:
Memory Usage Performance Guidelines
<http://developer.apple.com/documentation/Performance/Conceptual/ManagingMemory/ManagingMemory.html
>
- Ken
_______________________________________________
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