The memory management in Macintosh is the process of allocating memory during program runtime.The macintosh is no memory protection. The instruction protection is not available its is because the application code runs in supervisor mode. The virtual memory system uses hard disk storage to hold data not currently in use. The Macintosh will try to get disk data to make a possible free memory.
In Macintosh Operating System there are activity monitor, in which free, wired, active and inactive memory. The meaning of Free Memory in which the memory is not yet be used. Next,the wired memory is about the data that is always store in RAM and it is never be moved to the disk. Moreover, the memory cannot be swap and is used by kernel. Another type of memory is active, in whivch the data is currently in RAM and has been recently used. It is also as memory that can be swap and released. In addition , inactive memory is not actively being used but recently used.
To avoid from any problem occur in the memory management, Mac OS create a strategy to all modern operation system known as Virtual Memory(VM). Moreover, the key activity of VM is a paging. In addition, paging involves copying data between RAM and special files on startup disk known as swap files. The need of swap files is for gives the appearance of the system that having more RAM than is physically installed. In these paging involves page-outs and page-ins.
There are two main problem that result from incorrect memory management, which is :
1. Freeing or Overwriting data that is already in use
Results : memory corruption, application crashing and corrupted user data.
2. Data is not longer in use is not be freeing
Results: memory leaks, may poor system performance.