7 Matching Annotations
  1. Apr 2023
    1. the other purpose of this table is resourcemanagement–when a process exits, we can use this table to determine what needs to be freed.You should consider storing the page’s virtual address and other page-specific data here,

      Will be used in process_exit. I.e. process_exit needs to call something like free_SPT ();

    2. If you decide to use this data structure, you will likely want to add frames to the table as they areallocated. The easiest way to do this would be to make a function that creates a frame table entry,calls palloc_get_page, stores this frame and the frame’s owner in the entry, stores this entryin the frame table, then returns the newly allocated frame. You will likely need to add additionalfunctions and data to this table as you work through project 3

      HOW TO MANAGE FRAME BOOKKEEPING in the Frame Table

    3. An address that does not appear to be a stack access; this means if the virtual addressrequested does not to appear to be the next contiguous memory page address of the stack(within 32 bytes of the stack pointer

      Why?

    4. Now, which virtual addresses are actually invalid?• A NULL pointer• A kernel address (the virtual address is larger or equal to the PHYS_BASE)• An address below the user stack (

      CONDITIONS TO CHECK

    5. In thissituation, we want the page fault handler to allocate and install a new page for the process ANDallow the process to continue as normal (rather than killing the thread) after the page fault handlerfinishes.

      to do

    6. palloc_get_page, the global page table (the bitmap in palloc.c)flags that area of memory as mapped (the bits are set to true). When a page is freed (for example,when palloc_free_page is called)

      we'll want to add in book-keeping of the pages manipulated here into the supplemental page table (SPT).

  2. Jan 2023