CMPE320 FINAL EXAM

Pataasin ang iyong marka sa homework at exams ngayon gamit ang Quizwiz!

Thrashing

A state in which the system spends most of it's time swapping process pieces rather than executing instructions

What is a storage-area network?

A storage area network is a dedicated high speed network or subnetwork for interconnected storage

Segment

A variable block of secondary memory

Frame

A fixed block of main memory. Available chunks of memory.

Page

A fixed block of secondary memory (in like a disk). Chunks of a process.

Simple Paging

Main memory is divded into a number of equal size frames. Each process is divided into a number of equal sized pages of the same length as the frame. A process is loaded by loading all of its pages into available, not necessarily contiguous frames.

Fixed Partitioning

Main memory is divided into a number of static partitions at system generation time. A process may be loaded into a partition of equal or greater size.

What is a disadvantage of the SSTF scheduling algorithm

Starvation

Resident Set Managment

The OS must decide how many pages to bring into main memory.

Physical Memory

The actual location in memory

What is the main purpose of memory management?

To bring processes into main memory for execution by the processor.

Why is DMA used for devices that execute large transfers?

To lessen the burden on the CPU. DMA is a special processor that copies bytes in chunks.

What is the purpose of the TLB?

To reduce lookup time by caching the addresses essentially.

Consider a simple paging system with the following parameters... 2^32 bytes of physical memory 2^10 bytes page size 2^16 pages of logical address space a) How many bits are in the logical address? b) How many bytes in a frame c) How many bits in the physical address specify the frame? d) How many entries in the page table c) How many bits in each page table entry? Assume each page table entry contains a valid/invalid bit.

a) 2^16 pages * 2^10 bytes in a page size = 2^26 bytes = 26 bits b) 2^10 bytes c) 2^32/2^10 = 2^22 = 22 bits d) 2^16 c) 22+1 = 23

First-In-First-Out

It's in the name really....

With segmentation, a logical address consists of ___ . A. Segment and offset B. Segment name and offset C. Segment number and page number D. Segment table and segment number

A. Segment number and offset

Translation Lookaside Buffer (TLB)

Acts as a cache for virtual memory addresses to speed lookup time up.

Relative Memory

Address is expressed as a location relative to some known point

Next-Fit Placement Algorithm

Begins to scan from the last placement and chooses the first spot that fits.

First-Fit Placement Algorithm

Begins to scan memory from the beginning and chooses the first block that fits.

Page Table

Contains the frame location for each page in the process.

Fetch Policy

Determines when a page should be brought into memory.

Paging

Partition memory into equal-fixed size chunks.

Dynamic Partitioning

Partitions are created dynamically so that each process is loaded into a partition of exactly the same size as the process.

Logical Address

Reference to a memory location independent of the current assignment of data to memory. AKA Virtual Memory

What is memory management intended to satisfy requirements wise?

Relocation Protection Sharing Logical organization Physical organization

Least Recently Used (LRU)

Replaces the page that has not been referenced for the longest time.

What is the difference between simple paging and virtual memory paging?

With Virtual Memory paging, not all pages have to be in main memory and only read in as needed.

Virtual Memory Paging

As with simple paging, except that it is not necessary to load all of the pages of a process. Nonresident pages that are needed are brought in automatically later.

Virtual Memory Segmentation

As with simple segmentation, except that it is not necessary to load all of the segments of a process. Nonresident segments that are needed are brought in later automatically.

What are the three reasons that buffering is performed?

1) Handle data transfer when speed mismatch of producer and consumer occur 2) Adapt devices that have different data transfer sizes 3) Support copy semantics for application I/O

Assume a system has a TLB hit ratio of 90%. It requires 15 nanoseconds to access the TLB and 85 nanoseconds to access main memory. What is the effective memory access time in nanoseconds for this system? A. 108.5 B. 100 C. 22 D. 176.5

A. 108.5 It's TLB + PAGE TABLE + MAIN ...something I can't read my notes.

___ allows the parent and child processes to initially share the same pages, but when either process modifies a page, a copy of the shared page is created. A) Copy-on-write B) Zero-fill-on-demand C) Memory-mapped D) Virtual memory fork

A) Copy on write

A ___ matches the process with each entry in the TLB. A. Address-space identifier B. Process ID C. Stack D. Page Number

A. Address-space identifier

Which of the following statements regarding SSDs is false? A) They generally consume more power. B) Are more reliable than magnetic disks C) More expensive D) No seek time or latency

A) They generally consume more power.

___ occurs when a process spends more time paging than executing A) Thrashing B) Memory-mapping C) Demand paging D) Swapping

A) Thrashing

Given the logical address 0xAEF9 with a page size of 256 bytes, what is the page number? A. 0xAE B. 0xF9 C. 0xA D. 0x00F9

A. 0xAE No idea how to get that.

Consider the disk queue holding requests to the following cylinders in the listed order: 116, 22, 3, 11, 75, 185, 100, 87. Using the SCAN scheduling algorithm, what is the order that the requests will be serviced? A) 116 - 22 - 3 - 11 - 75 - 185 - 100 - 87 B) 100 - 116 - 185 - 87 - 75 - 22 - 11 - 3 C) 87 - 75 - 100 - 116 - 185 - 22 - 11 - 3 D) 100 - 116 - 185 - 3 - 11 - 22 - 75 - 87

B) 100 - 116 - 185 - 87 - 75 - 22 - 11 - 3

A RAID structure ____ . A) Is primarily used for security purposes. B) Is primarily used to ensure data reliability C) Stands for redundant arrays of inexpensive disks D) Is primarily used to decrease the dependencies of disk drives

B) Is primarily used to ensure data reliability

The SSTF Scheduling algorithm ___ . A) Services the request with the maximum seek time B) Services the request with the minimum seek time C) Chooses to service the request furthest from the current position. D) None of the above

B) Services the request with the minimum seek time

Consider the disk queue holding requests to the following cylinders in the listed order: 116, 22, 3, 11, 75, 185, 100, 87. Using the SSTF scheduling algorithm, what is the order that the requests will be serviced? A) 116 - 22 - 3 - 11 - 75 - 185 - 100 - 87 B) 100 - 116 - 185 - 87 - 75 - 22 - 11 - 3 C) 87 - 75 - 100 - 116 - 185 - 22 - 11 - 3 D) 100 - 116 - 185 - 3 - 11 - 22 - 75 - 87

C) 87 - 75 - 100 - 116 - 185 - 22 - 11 - 3

Host-attached storage is ___ A) A special purpose storage system that is accessed remotely over a data network. B) Not suitable for hard disks C) Accessed via local I/O ports D) Not suitable for use in raid arrays

C) Accessed via local I/O ports

DMA controllers ___. A) Do not utilize an additional special purpose processor B) Are nonstandard component in PCs of today. C) Can steal memory access cycles from the main CPU D) Can access main memory at the same time as the main CPU

C) Can steal memory cycles from the main CPU

SSDs commonly use ___ disk scheduling policy. A) SSTF B) SCAN C) FCFS D) LOOK

C) FCFS

Best-Fit Placement Algorithm

Chooses the block that is closest in size to the request

Which of the following is a principle that can improve efficiency of I/O? A) Increase the number of context switches. B) Use small data transfers C) Move processing primitives to hardware D) Decrease concurrency using DMA controllers

C) Move processing primitives into hardware.

The surface of a magnetic disk platter is divided into ___ A) Sectors B) Arms C) Tracks D) Cylinders

C) Tracks

Which of the following is a benefit of allowing a program that is only partially in memory to execute? A) Programs can be written to use more memory than is available physical memory. B) CPU utilization and throughout is increased. C) Less I/O is needed to load or swap each user program into memory. D) All of the above.

D) All of the above

Low-level formatting ___ . A) Does not usually provide an error-correcting code B) Is usually performed by the purchaser of the disk device C) Is different from physical formatting D) Divides a disk into sections that the disk controller can read and write.

D) Divides a disk into sections that the disk controller can read and write.

Belady's anomaly states that ___ . A) Giving more memory to a process will improve its performance. B) As the number of allocated frames increases, the page-fault rate may decrease for all page replacement algorithms. C) For some page replacement algorithms, the page fault rate may decrease as the number of allocated frames increases. D) For some page replacement algorithms, the page fault rate may Increase as the number of allocated frames increases.

D) For some page replacement algorithms, the page fault rate may Increase as the number of allocated frames increases.

___ is the algorithm implemented on most systems. A) FIFO B) LFU C) MFU D) LRU

D) LRU

A ___ is a buffer that holds output for a device that cannot accept interleaved data streams. A) Escape B) Block device C) Cache D) Spool

D) Spool

Replacement Policy

Deals with the selection of a page in main memory to be replaced when a new page must be brought in

Placement Policy

Determine where in real memory a process piece is to reside

Simple Segmentation

Each process is divided into a number of segments. A process is loaded by loading all of its segments into dynamic partitions that need not be contiguous.

What elements are typically found in a page table entry? Define each.

Frame Number: Corresponding page in main memory. Modify (M) Bit: Whether the contents of the corresponding page have been altered since the page was last loaded into main memory. Present (P) Bit: Indicates whether the corresponding page is in main memory or not.

What's the difference between Partitioning and Memory management?

Memory management involves virtual memory and is based on segmentation and paging. Partitioning does not involve virtual memory...it's considered obsolete.

Demand Paging

Only brings pages into main memory when a reference is made to a location on a page.

Buddy System

Segments memory by the power of 2. Basically, divide by two until there is a perfect fit block, then place it there.

Internal Fragmentation

Wasted space due to the block of data being loaded smaller than the partition.


Kaugnay na mga set ng pag-aaral

Midterm Theology 2 (AU ONLINE 2023)

View Set

Level I Antiterrorism Awareness Training

View Set

NUR 306 Test 1 Chapter 1,2,3,4,5,10 Practice Questions

View Set

Business Ethics - Chapter 5-8 test review

View Set

Financial Reporting and Analysis: Inventories (pg. 345 - 413)

View Set

All APBIO Ch. 1-55 (Pretty EPIC)

View Set

Chapter 38 - Agents to Control Blood Glucose Levels PrepU

View Set

Chapter 10: Power politics and Glory

View Set

Individual Life Insurance Contract- Provisions and Options

View Set