Sunday 14 August 2011

what is the meaning . when we say that our program will take some space in memory ? or how this thing is technically related to storage .

when we say that our program will take that much of space in memory ... now what do you think technically about it .
    but why creator introduce this concept in programming . this is the nasty question if you are not aware with it .
    now think your program without unallocated space , understand these things .
 
                               total space in memory = 2000
1st program       1. 1st instruction executed and take 100th place in memory
                          2. 2nd instruction comes and takes 1900th space in memory .

2nd program      1. 1st instruction and takes 200th place
                           2. 2nd comes and takes 1500th place

now. you are dealing with a space which is commonly shared now if anyone hurts or damaged than seriously other-one will also affected . that is the problem with common space . means this is error generator .anyone in field of address can hurt by anyone .

now think a program with the concept of fixed or given memory spaces .

                      total space = 2000

1st program - 1000 space allocated to it .
         1.  1st instruction comes takes 100 place .
         2.  2nd comes and takes 900 place .

2nd program - 1000 space allocated to it .
        1. 1st instruction comes take 1100 space .
        2 . 2nd instruction comes take 1900 space .

now if here 1st program is affected than this affect will only reside in 0-1000 and 1000-2000 can run easily without any interruption .

affected means in both cases -
in 1st program .... any address can point any thing that may cause problem
but in second program each and every have different spaces and and if anyone is affected than anotherone will remain in safe zone . this concept is introduced in 1970 - 1980 .


No comments: