CSE 120 Lecture Notes - Lecture 8: Binary Tree, Fits, Context Switch
Document Summary
Permissions: r, w, x ( r ead, w rite , e xecute) Note: process acts as if it owns the whole memory (it doesn"t fyi) 0 to n-1 (where n is the size of your memory) Allocated regions of physical memory (to avoid) In reality: one cpu divided up for each process, and one memory divided up for each process. Each subdivison of each process contains its own text, data, stack regions. Processes moving in and out take so much time! To allocate: find large enough hole, allocate region within hole, leave smaller hole. First (or next) fit: find the first/next hole that fits. Best fit : tightest fit fits as perfectly as possible. Worst fit: - hole that results in the largest remaining hole ( actually the worst btw xd) We would rather waste memory space than cpu time! Compaction: combine all the fragments together to create a giant fragment.