Page 105 - DCAP408_WEB_PROGRAMMING
P. 105

Unit 6: Memory Management (II)




          applications simultaneously, etc., you may get away with it. Sooner or later, though, it will  Notes
          become a problem.
          Now we’ve defined the problem. What is the solution? If you build up software, web sites , or
          graphics (by means of high end software), the answer, even though you may not like it, is to
          advance the operating system. The WindowsNT memory model is the answer. WindowsNT,
          Windows2000 and WindowsXP share a hugely different memory model. Under this NT based
          memory management system, resources are not restricted. As long as you have sufficient physical
          memory (RAM) or virtual memory (disk space) your applications will not run out of resources.
          The WindowsNT memory system assigns resources dynamically. As long as  the memory is
          obtainable, your application can have it.
          Even better, every application obtains its own virtual copy of the operating system. That means
          that, applications are isolated and, if an error appears, system memory is not corrupted. When
          an  application  terminates, all the memory assigned to it is released  back  to the  operating
          system. That means that resource, or memory leakage is also almost nonexistent. It is likely for
          an application to incessantly demand more and more memory and the system will provide it,
          until memory turns out to be short, but closing the application releases all that memory without
          the requirement to reboot the machine.
          The following chart displays the memory assigned for each particular purpose by the various
          operating systems:

          6.3.2 Resource  Comparison


             Window/Menu Handles        about 200           32KB (each)    Unlimited
             Timers                     32                  Unlimited      Unlimited
             COM/LPT ports              4 each              Unlimited      Unlimited
             Listbox items (per listbox)   8KB              32KB           Unlimited
             Listbox data (per listbox)   64KB              Unlimited      Unlimited
             Edit control data (per control)   64KB         Unlimited      Unlimited
             Regions                    All in 64KB segment   Unlimited    Unlimited
             Logical pens, brushes      All in 64KB segment   64KB segment   Unlimited
             Physical pens, brushes     All in 64KB segment   Unlimited    Unlimited
             Logical fonts              All in 64KB segment   750-800      Unlimited
             Installed fonts            250-300 (best case)   1000         Unlimited
             Device Contexts            200 (best case)     16KB           Unlimited

          While  Windows95,  Windows98  and  WindowsMe  operating  systems  enhanced  memory
          management enormously over Windows 3.1, they were still intended for the home user. They
          were never proposed to be a severe development platform. Coming across errors is a part of
          software development. An operating system that is not fault tolerant has no place in the software
          development  environment.  If  you develop  software, or  web  sites  by  means  of  a  serious
          development tool, you should be using WindowsNT, Windows2000, or WindowsXP.




              Task  Illustrate the function of User resources.








                                           LOVELY PROFESSIONAL UNIVERSITY                                   99
   100   101   102   103   104   105   106   107   108   109   110