Preview

Midterm 2 Solutions

Powerful Essays
Open Document
Open Document
1903 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
Midterm 2 Solutions
CSCI 4061: Introduction to Operating Systems Fall 2008 Mid-Term Exam II Sample Solution

NAME: STUDENT ID:

General Instructions: • Write your name and student ID clearly above. • You have 1 hour and 15 minutes to write the exam. No extra time will be given. • There are 4 questions in the exam, all with subparts. The questions combine for a maximum of 100 points. • You must write your answers clearly in the space provided for each question. You might use the backside of each page, as well as any additional sheets as required. If you are using additional space, you must clearly label the question no. that you are answering. Any loose sheets must have your name and student ID written clearly. • The exam is open book/open notes, however, no exchange of materials is allowed. You must use your own notes/book. • Electronic devices (laptops, notebooks, PDAs, cell phones, etc.) are strictly prohibited. • Read each question carefully before answering. • Good luck with the exam!

For Grading Use Only

1 2 3 4 TOTAL

1. Consider a 32-bit machine with 128 MB of physical memory, that uses virtual memory and demand paging for memory management. If the page size is 4 KB, answer the following questions. (Note: For ease of calculation, you can assume 1K=1000, 1M=1000K, etc.) (a) (3 pts) How many physical frames are there in the system? Ans: 128M = 32K 4K (b) (3 pts) What is the maximum number of pages that a process can have in its virtual address space? Ans: The amount of virtual address space addressable by each process = 232 = 4GB. Therefore, maximum number of pages = 4G = 1M 4K (c) (12 pts) Suppose the page table for a process P contains the following entries. Page No. 3 2 1 0 Frame No. 1 3 4 7

Specify what physical address does each of the following virtual addresses maps to? Show your calculations here. i. 3456 Ans: Note that a virtual address can be represented in terms of its page number and offset within the page as follows: Virtual address = Page no.* Page

You May Also Find These Documents Helpful

  • Good Essays

    This chapter describes the concepts behind how a CPU reads the contents from RAM. Which of the following is true about the process of read data, as described in the chapter?…

    • 957 Words
    • 4 Pages
    Good Essays
  • Good Essays

    Nt1210 Chapter 1 Review

    • 1315 Words
    • 6 Pages

    5. This chapter describes the concepts behind how a CPU reads the contents from RAM. Which of the following is true about the process of read data. As described in the chapter?…

    • 1315 Words
    • 6 Pages
    Good Essays
  • Satisfactory Essays

    CHAPTER3 REVEIW

    • 527 Words
    • 3 Pages

    5. This chapter describes the concepts behind how a CPU reads the contents from RAM. Which of the following is true about the process of read data, as described in the chapter?…

    • 527 Words
    • 3 Pages
    Satisfactory Essays
  • Satisfactory Essays

    Nt1310 Unit 7

    • 468 Words
    • 2 Pages

    Describe the common points between virtual circuit switching and circuit switching, and the common points between virtual circuit switching and datagram switching.…

    • 468 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    This chapter describes the concepts behind how a CPU reads the contents from RAM. Which of the following is true about the process of read data, as described in the chapter?…

    • 605 Words
    • 3 Pages
    Good Essays
  • Powerful Essays

    SVAD111 Session 1 Project

    • 917 Words
    • 4 Pages

    Now go to the chapter review questions on page 30 t0 32 of your Hands-On Virtual Computing book. For questions 1 through 10 identify the correct answer below, then EXPLAIN WHY the other answers are wrong.…

    • 917 Words
    • 4 Pages
    Powerful Essays
  • Satisfactory Essays

    For Question 9 -- Paste you pseudo code here. DO NOT paste Visual Basic program code as your design solution. That will result in 10 points deducted from the homework assignment.…

    • 651 Words
    • 4 Pages
    Satisfactory Essays
  • Good Essays

    a) This code is horrible because it returns the memory address of a local variable…

    • 775 Words
    • 2 Pages
    Good Essays
  • Satisfactory Essays

    6. Now verify the result by noting the values in different memory locations and comparing it with the expected result.…

    • 328 Words
    • 2 Pages
    Satisfactory Essays
  • Satisfactory Essays

    Vmware

    • 662 Words
    • 3 Pages

    Allocating Compute Resources to Business Functions © 2011 VMware Inc. All rights reserved CPU Management Supports Server Consolidation A virtual machine can have up to 32 virtual CPUs (vCPUs). When a vCPU must be scheduled, the VMkernel maps a vCPU to a hardware execution context (HEC).…

    • 662 Words
    • 3 Pages
    Satisfactory Essays
  • Powerful Essays

    Tkt Module 3 Test Sample

    • 2615 Words
    • 11 Pages

    INSTRUCTIONS TO CANDIDATES Do not open this booklet until you are told to do so. Write your name, Centre number and candidate number on the answer sheet if they are not already printed. There are eighty questions in this paper. Answer all questions. Mark your answers on the separate answer sheet. Use a pencil. You may write on the question paper, but you must mark your answers in pencil on the answer sheet. You will have no extra time for this, so you must finish in one hour and twenty minutes. At the end of the test, hand in both the question paper and the answer sheet. INFORMATION FOR CANDIDATES Each question in this paper carries one mark.…

    • 2615 Words
    • 11 Pages
    Powerful Essays
  • Satisfactory Essays

    ----------- incremental allocation of new pages is possible in this scheme without requiring relocation of program address space. ( pure paging, virtual paging, contiguous , dynamic)…

    • 305 Words
    • 2 Pages
    Satisfactory Essays
  • Satisfactory Essays

    Operating System

    • 730 Words
    • 3 Pages

    | Virtual memory: demand paging, performance of demand paging, page replacement and algorithm, allocation of frames, thrashing…

    • 730 Words
    • 3 Pages
    Satisfactory Essays
  • Good Essays

    Virtual Memory

    • 566 Words
    • 3 Pages

    Virtual memory, also known as a page file or swap file, is a file on your hard drive (C:\pagefile.sys by default) that Windows and applications use in addition to physical memory (RAM) as needed. The default and recommended size of this file is 1.5 times the amount of physical memory. Virtual memory is the sum of physical memory and the page file. So if your computer has 512 MB RAM, it will have a 768 MB page file by default, for a total of 1.25 GB of physical + virtual memory.…

    • 566 Words
    • 3 Pages
    Good Essays