Eldiridge Academic Library
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Lesson 18 - Static/Dynamic Link

Go down

Lesson 18 - Static/Dynamic Link Empty Lesson 18 - Static/Dynamic Link

Post  Admin Thu Oct 11, 2012 11:06 am

you can leave curly braces out if the whole thing is one regular expression

activation record = points to memory of call

Activation Record = Frame

values stored in activiation record
compilier resolves the names
| Static Link|PTR, Dynamic Link |
| X |
| Y |
| Z |
| REturn aDdress |
| MISC |

// advantage of the pointer?
// there is no size definition fro the variables. You can have variables of various length... all the ptr needs to do is point to
// some other location.

Proc P
output 1
call Q
output 2

proc Q
output 3

when proc Q finished, it got popped. Where in procedure did it come back to? IT comes right back to Call Q. Pick up
right where you left off.

puts return ADDR in Q's Frame back right after call Q



procedure countdownup(N: Integer)


procedure f
var X
procedure g
var y;

y = x + 1;

activation for x doesn't mean it is directly behind variable G. IT could be all over the place

dynamic link = points to activation record of process that called you (or this one)

static link = points to activation record of process that defined this one

lexical scoping = also called static coping.
Admin
Admin
Admin

Posts : 9
Points : 24
Join date : 2012-10-10

https://metisscrolls.board-directory.net

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum