Freestudy9 comes with new post related to Storage organization.it is an important topic of the computer science.
Subdivision of Run-Time memory time: Storage organization
- The compiler demands for a block of memory to an operating system. The compiler utilizes this block of memory executing the compiled program. This block of memory called runtime storage organization.
- The runtime storage is subdivided to hold code and data such as the generated target code and Data objects.
- The size of the generated code fixed. Hence the target code occupies the determined area of the memory. The compiler places the target code at end of the memory.
- The amount of memory required by the data objects is known at the compiled time and hence data objects also can be placed at the statically determined area o the memory.of
- Moreover, A stack is used to manage the active procedure. Managing of active procedures means when a call occurs then execution of activation interrupted and information about the status of the stack is saved on the stack. When the control returns from the call this suspended activation
resumed after storing the values of relevant registers.
- Heap area is the area of runtime storage in which the other information stored. For time example memory for some data items allocated under the program control. Memory required for these data items obtained from this heap area. Memory for some activation is
Activation Records: Storage organization
- Various field of activation record is as follows:
1. Temporary values: The temporary variables needed during the evaluation of expressions. Such variables stored in the temporary field of activation record.stored
2. Local variables: The local data is a data that is local to the execution procedure stored in this field of activation record.
3. Saved machine registers: This field holds the information regarding the status of a machine just before the procedure called. This field contains the registers and program counter.
4. Control link: This field is optional.So It points to the activation record of the calling procedure.So This link also called dynamic link.
5. Similarly, Access link: This field is also optional. It refers to the nonlocal data in another activation record. This field also called static link field.
6. Actual parameters: This field holds the information about the actual parameters. Also, These actual parameters passed to the called procedure.
7. Return values: This field used to store the result of a function call.