RnR wrote:
> What is the benefit of pointers? Is there a workaround? In other
> words, can you program to get the same end result without using
> pointers?
>
> I ask because 64bit was supposed to be better than 32bit and just a
> couple years ago, it was the going thing to get 4gb ram in new laptops
> running 64bit operating systems.
Pointers are variables that contain addresses. You can get around them by declaring
memory to be one big array and using integers as subscripts, but the problem
is not solved. If you have more than 4gb that you want to address, it takes
more than 32 bits in the pointer or in the integer subscript, just because you
need the pointer or integer to take on at least as many values as you have
real addresses, and it takes more than 32 bits to have enough values.
The most efficient way is pointers but lots of languages don't have them.
Those will have to use 64 bit integers instead of 64 bit pointers.
I don't see the point of a 64 bit O/S with 4gb of memory since 32 bits can
address that much. If you want to go more than 4gb you need a 64 bit O/S.
That's the cutover that I was talking about not working as neatly as you might
hope, depending on what your applications that you run are.
Worst case you'd need 64 bit/8gb of memory to get back to where you were with
32 bit/4gb.
Not worst case it might do pretty well. It all depends on what apps you run.
(Also cache hits will be less local, which will slow it down potentially.)
--
On the internet, nobody knows you're a jerk.