Where's the pointer's explanation?

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Where's the pointer's explanation?

Maesltrom
it's the last thing that i saw in Chapter 7 talking about pointer: "pointer: discussed later." in page 25
Early there's it: "Basic idea: the mapping of the stack and the
global segments on the RAM is easy (fixed);
the mapping of the function-level segments is
dynamic, using pointers"

I thought that a pointer is a special location where a could point to any area of stack.

Thanks for all the help you give me until here!
Reply | Threaded
Open this post in threaded view
|

Re: Where's the pointer's explanation?

cadet1620
Administrator
Maesltrom wrote
it's the last thing that i saw in Chapter 7 talking about pointer: "pointer: discussed later." in page 25
Not sure what you are talking about. Chapter 7 begins on page 121.

Pointer is a general programming term. A pointer is like an array index, except that the "array" is all of RAM. The "stack pointer" is an index into RAM that points to the top of the stack.

The Virtual Machine "pointer segment" is a special, fixed, location in memory, like the "temp segment". When VM code sets "pointer 0" it is setting the "this" object pointer. When the VM code sets "pointer 1" it is setting the "that" pointer. The "this" and "that" pointers, in turn, point to the start of an object in RAM.

--Mark
Reply | Threaded
Open this post in threaded view
|

Re: Where's the pointer's explanation?

Maesltrom
Hi Mark! I'm reading the pdfs. But now i got it. I was reading others messages and see that the pdfs with explanations ends in chapter 6.

Thanks