Week 29 (Week 4 of CST334)

 This week we learned about how free memory is tracked, which involves tracking the lengths and available spaces of free memory, how it is freed when it is no longer needed, and how the MMU determines which chunks of free memory to give over to a process (first fit, best fit, or worst fit).
We then revisited Paging, the method we found worked best to resolve memory management issues, however we still ran into issues of paging being slow, whereas it's alternative, base-and-bounds was fast. We then found that we could apply the concept of locality to paging, which involves caching page tables, working with the concept that if data that is stored in one area is accessed, it is likely that data stored close to it in memory will also be accessed, assuming that they are related. This is done with a mechanism called the "translation lookaside buffer", or TLB. This ultimately increased performance for processes that were able to utilize locality in address memory.
With this addition, we also ran into other problems--mainly that paging still suffers from a speed issue, and that the page tables are getting to be too big. To address this, we looked at using page directories, which involve chunking page tables, so we don't need to store entire pages, we can just store the part of the tables we need, but this came with an additional complication to page translation, and requires modifying the VPN format, adding a index into page table chunk value.
This additional method makes the page table space much more efficient and less cumbersome on the memory.
Lastly, we visited the method of swapping alongside paging. This is to address the issue of how to handle what to do when memory is full, and we need to swap data out of memory (RAM--which is acting as a cache for the hard drive) to store the new data. This led to a bunch of fun exercises/policies for how to best handle it, and how effective each of them can be.
At this point I'm feeling fairly confident in my understanding of how the MMU relates to these topics. The part I'm concerned about is that I am heavily reliant on my notes for working through the virtual memory exercises, the paging labs, and calculating access times. I'm unsure if I can assume the midterm/final are open-note (I believe they are?), but that would be a bit of a problem. I believe to prepare, I'll run through the practice labs again to try and memorize the different methods.

Comments

Popular Posts