Koko

Only available on StudyMode
  • Topic: Operating system, Memory management, Virtual memory
  • Pages : 70 (13268 words )
  • Download(s) : 147
  • Published : April 14, 2013
Open Document
Text Preview
Final (Memory Management)

Multiple Choice
Identify the choice that best completes the statement or answers the question.

____1.The following,____, describes the first memory allocation scheme. a.|Each program to be processed was loaded into secondary storage, then swapped into memory in parts| b.|Each program to be processed was partially loaded into memory, then granted more memory as needed| c.|Each program to be processed was allocated a portion of memory and could negotiate with other programs to access more memory| d.|Each program to be processed was loaded in its entirety into memory and allocated as much contiguous space in memory as it needed|

____2.In a single-user system, jobs are processed ____.
a.|sequentially|c.|randomly|
b.|intermittently|d.|in order of longest job to shortest job|

____3.In the algorithm to load a job in a single-user system, the program counter is initially set to ____. a.|the address of the last memory location|
b.|the number of instructions|
c.|zero|
d.|the address of the first memory location|

____4.Fixed partitions are also called ____ partitions.
a.|complete|c.|direct|
b.|static|d.|sized|

____5.____ is the first step in the algorithm to load a job in a fixed partition. a.|Comparing job size to size of largest partition|
b.|Determining the job’s requested memory size|
c.|Setting counter to one|
d.|Placing the job in a waiting queue|

____6.In the partition scheme, the table that the Memory Manager uses to keep track of jobs is composed of the ____. a.|partition size, memory address, and status|
b.|status, access, and memory address|
c.|partition size, status, and access|
d.|partition size, memory address, access, and status|

____7.The fixed partition scheme works well ____.
a.|when jobs have the same size|
b.|when jobs have different sizes|
c.|when job sizes are not known in advance|
d.|when all jobs are under 100K|

____8.____ consists of fragments of free memory between blocks of allocated memory. a.|An inefficient fit|c.|External fragmentation|
b.|Indirect partitioning|d.|Internal fragmentation|

____9.The ____ keeps the free/busy lists organized by memory locations, low-order memory to high-order memory. a.|fixed partition allocation|c.|dynamic fit memory allocation| b.|first-fit memory allocation|d.|best-fit memory allocation|

____10.____ has the least wasted space and the smallest partition fitting the requirements. a.|Fixed partitioning|c.|Dynamic fit memory allocation|
b.|First-fit memory allocation|d.|Best-fit memory allocation|

____11.Consider the following space requirements for jobs 1-4 and memory blocks. Assuming a first-fit scheme is used, the job,____, is not able to run. Jobs:
J1 10K
J2 20K
J3 30K
J4 10K

Blocks:
B1 30K
B2 15K
B3 50K
B4 20K
a.|J1|c.|J3|
b.|J2|d.|J4|

____12.Consider the following space requirements for jobs 1-4 and memory blocks. Assuming a best-fit scheme is used, the job,____, is placed in the last block. Jobs:
J1 10K
J2 20K
J3 30K
J4 10K

Blocks:
B1 30K
B2 15K
B3 50K
B4 20K
a.|J1|c.|J3|
b.|J2|d.|J4|

____13.The following algorithm can be described as ____.

1 Set counter to 1
2 Do while counter memory_size(counter)
Then counter = counter + 1
Else
load job into memory_size(counter)
adjust free/busy memory lists
go to step 4
End do
3 Put job in waiting queue
4 Go fetch next job
a.|first-fit memory allocation|c.|least-fit memory allocation| b.|best-fit memory allocation|d.|fixed partition memory allocation|

____14.The following algorithm can be described as ____.

1 Initialize memory_block(0) = 99999
2 Compute initial_memory_waste = memory_block(0) – job_size 3 Initialize subscript = 0
4 Set counter to 1
5 Do while counter memory_size(counter)
Then counter = counter + 1
Else
memory_waste = memory_size(counter) – job_size
If initial_memory_waste >...
tracking img