From 5a6b07a186f9f3f718f312b6b9b365cb02da6556 Mon Sep 17 00:00:00 2001 From: manuel Date: Thu, 21 Jun 2012 19:16:26 +0200 Subject: add structs into proj2 and some simple explanations --- proj2.txt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/proj2.txt b/proj2.txt index 8dd36f2..8572b3f 100644 --- a/proj2.txt +++ b/proj2.txt @@ -104,6 +104,17 @@ an exception. >> `struct' member, global or static variable, `typedef', or >> enumeration. Identify the purpose of each in 25 words or less. +struct mmap_table: + struct mmap_table_entry **ids; + int id_free; ...lowest-index free + int id_max; ...highest-index used + int id_cap; ...mmap table capacity + +struct mmap_table_entry: + void *upage; ...virtual address of first page of mmapped file + struct file *file; ...file handle + int pages; ...number of pages the mapping needs + struct page_table_entry: union struct TODO ...structure needed for loading of memory mapped files @@ -112,11 +123,15 @@ struct page_table_entry: >> C2: Describe how memory mapped files integrate into your virtual >> memory subsystem. +for every page required by the memory mapped file we create a new page table +entry TODO >> C3: Explain how you determine whether a new file mapping overlaps >> any existing segment. +in mmap() we simply check if the required pages are still free (no entry in +the page table). TODO ---- RATIONALE ---- @@ -128,6 +143,7 @@ TODO >> implementation either does or does not share much of the code for >> the two situations. +we share the same page table entries TODO SURVEY QUESTIONS -- cgit v1.2.3