OS Test 2 Word Scramble
![]() E A S L F
|
Embed Code - If you would like this activity on your web page, copy the script below and paste it into your web page.
Normal Size Small Size show me how
Normal Size Small Size show me how
Question | Answer |
Reentrant code cannot be shared. | false |
How many writers may concurrently share the database with the readers-writers problem? | one |
Absolute code can be generated for ____. | compile-time binding |
A _____ could be preempted from a process. | CPU |
In RR scheduling, the time quantum should be small with respect to the context-switch time. | False |
Given the logical address 0xAEF9 (in hexadecimal) with a page size of 256 bytes, what is the page number? | 0xAE |
Mobile systems typically use swapping. | False. |
Which of the following is true of earliest-deadline-first (EDF) scheduling algorithm? | When a process becomes runnable, it must announce its deadline requirements to the system. |
One necessary condition for deadlock is ______, which states that a resource can be released only voluntarily by the process holding the resource. | no preemption |
Which of the following data structures in the banker's algorithm is a vector of length m, where m is the number of resource types? | Available |
What are the two forms of fragmentation? | External fragmentation, Internal fragmentation |
Windows XP, when accessing a global variable on a uniprocessor system, ____. | masks interrupts for all interrupt handlers that may also access the variable |
A nonpreemptive kernel is essentially free from race conditions. | True |
What are the three strategies for selecting a free hole from the set of available holes? | First-fit, Best-fit, Worst-fit |
Suppose that there are 10 resources available to three processes. Which of the following correctly characterizes this state? Process Maximum Needs Currently Owned P0 10 4 P1 3 1 P2 6 4 | It is not safe. |
What scheduling algorithm assignments the CPU to the process that first requested it? | First-Come, First-Served (FCFS) |
Consider a logical address with 18 bits used to represent an entry in a conventional page table. How many entries are in the conventional page table? | 262144 |
A relocation register is used to check for invalid memory addresses generated by a CPU. | False |
To be sharable through shared pages, code must be _____. | Reentrant. I.e. code is non-self modifying: it never changes during execution. |
The two general approaches to load balancing are __________ and ____________. | push migration, pull migration |
A calling thread becomes the owner of a lock when ______________. | It enters a synchronized method. |
Race conditions are prevented by requiring that critical regions be protected by locks. | True |
What is available in Linux for updating an integer variable without having to use locks? | atomic_t type, atomic integers. |
One necessary condition for deadlock is ______, which states that a process must be holding one resource and waiting to acquire additional resources. | Hold and Wait. |
List the three common Page Table Structures. | Hierarchical Paging, Hashed Page Tables, Inverted Page Tables |
What are the three requirements a solution to the critical-section problem must satisfy? | Mutual exclusion, Progress, Bounded waiting |
In Little's formula n = λ x W, what does n represent ? | average queue length |
A cycle in a resource-allocation graph is ____. | a necessary and sufficient condition for a deadlock in the case that each resource has exactly one instance |
In Solaris, if an interactive thread with priority 25 is waiting for I/O, what is its priority recalculated to when it is eligible to run again? | 52 |
What is the backing store? | Fast disk space. A process can be swapped out of memory into a backing store temporarily, and then returned to memory for continued execution. |
Without a mechanism such as an address-space identifier, the TLB must be flushed during a context switch. | True |
In practice, most systems implement an approximation of the _____ page-replacement algorithm. | LRU |
True or False? Linux uses spin locks for both single and multiple processor systems. | False. On single processor systems kernel preemption is enabled/disabled in place of acquiring/releasing a spinlock. |
List the three different times at which address binding may occur. | Compile time, Load time, Execution time |
The vfork() system call in UNIX ____. | allows the child process to use the address space of the parent |
What does each entry in the page table contain? | The base address of each page in physical memory. |
Consider a 32-bit address for a two-level paging system with an 8 KB page size. The outer page table has 1024 entries. How many bits are used to represent the second-level page table? | 9 |
The roll out, roll in variant of swapping is used ____. | for priority-based scheduling algorithms |
In Linux, tasks that are not real-time have dynamic priorities that are based on their ____ values plus or minus the value 5. | nice |
A transaction ____. | performs a single logical function |
The buddy system for allocating kernel memory is very likely to cause fragmentation within the allocated segments. | True |
Which of the following statements is false with regard to allocating kernel memory? | Because the kernel requests memory of varying sizes, some of which may be quite small, the system does not have to be concerned about wasting memory. |
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? | 108.5 |
Name at least one modern programming language that has incorporated the idea of a monitor. | Java |
With segmentation, a logical address consists of _____. | segment number and offset |
Which of the following is considered a benefit when using the slab allocator? | no memory fragmentation |
What are frame protection bits? | They are associated with each frame, normally kept in the page table. A bit can define a page as read-write, or read only, or extended for a finer level of protection. Additionally, one bit is generally a valid-invalid bit, used to differentiate between l |
True or False? There are no guarantees Peterson's solution works correctly on modern computer architectures. | True |
The _____ binding scheme facilitates swapping. | execution time |
The system model for deadlocks first requires a process request a resource, then use the resource, and finally release the resource. | True |
What are the two parts of an address generated by the CPU? | Page number, Page offset |
What is the problem if all philosophers simultaneously pick up their left fork? | Deadlock - each philosopher is waiting infinitely for the next. |
Hashed page tables are commonly used when handling addresses larger than 32 bits. | True |
How many philosophers at most may eat simultaneously in the Dining Philosophers problem with 5 philosophers? | 2 |
What scheduling algorithm assigns the CPU to the process with the highest priority? | Priority Scheduling |
Suppose a program is operating with execution-time binding and the physical address generated is 300. The relocation register is set to 100. What is the corresponding logical address? | 200 |
Assume the value of the base and limit registers are 1200 and 350 respectively. Which of the following addresses is legal? | 1200 |
An address generated by the CPU is also referred to as a physical address. | False. An address generated by the CPU is a logical or virtual address, an address in memory is a physical address |
A thread will immediately acquire a dispatcher lock that is the signaled state. | True |
What is the numeric priority of a Windows XP thread in the HIGH_PRIORITY_CLASS with ABOVE_NORMAL relative priority? | 14 |
A(n) ______ matches the process with each entry in the TLB. | address-space indentifier |
Ordering resources and requiring the resources to be acquired in order prevents the circular wait from occurring and therefore prevents deadlock from occurring. | False |
Consider a logical address with a page size of 8 KB. How many bits must be used to represent the page offset in the logical address? | 13 |
Which of the following is a benefit of allowing a program that is only partially in memory to execute? | All of the above |
______ allows a thread to run on only one processor. | processor affinity |
The ______ occurs in first-come-first-served scheduling when a process with a long CPU burst occupies the CPU. | Convoy effect |
What are the four necessary conditions for characterising deadlock? | Mutual exclusion, Hold and wait, No preemption, Circular wait |
What are the two operations that can be performed on a condition variable? | wait() and signal() |
In a dynamically linked library, ____. | a stub is included in the image for each library-routine reference |
What are the two states of a Windows dispatcher object? | Signaled, Nonsignaled |
In Solaris, what is the time quantum (in milliseconds) of an interactive thread with priority 35? | 80 |
What is the hardware device that maps virtual to physical addresses? | Memory Management Unit (MMU) |
In general, virtual memory decreases the degree of multiprogramming in a system. | False |
Another problem related to deadlocks is ____________. | indefinite blocking |
In a system resource-allocation graph, ____. | a directed edge from a process to a resource is called a request edge |
The wait-for graph can only be used for deadlock detection when there is a single instance of each type. | True |
The _____ is an approximation of a program's locality. | working set |
The witness software product is a ____. | lock-order verifier that uses mutual-exclusion locks to protect critical sections |
What is the numeric priority of a Windows XP thread in the BELOW_NORMAL_PRIORITY_CLASS with NORMAL relative priority? | 6 |
What are the two bursts that CPI schedulers are designed around? | CPU-burst and IO-burst |
Hierarchical page tables are appropriate for 64-bit architectures. | False |
When using semaphores, a process invokes the wait() operation before accessing its critical section, followed by the signal() operation upon completion of its critical section. Consider reversing the order of these two operations—first calling signal(), t | Several processes could be active in their critical sections at the same time. |
If a resource-allocation graph has a cycle, the system must be in a deadlocked state. | False |
Fragmentation does not occur in a paging system. | False |
____ scheduling is approximated by predicting the next CPU burst with an exponential average of the measured lengths of previous CPU bursts. | SJF |
What are the Pthreads operations for locking and unlocking a mutex lock? | pthread_mutex_lock(), pthread_mutex_unlock() |
The OpenMP #pragma omp critical directive ___________. | behaves like a mutex lock |
In multithreaded programs, the kernel informs an application about certain events using a procedure known as a(n) ____. | upcall |
The value of a counting semaphore can range only between 0 and 1. | False |
Monitors are a theoretical concept and are not practiced in modern programming languages | False |
Only a fraction of a process's working set needs to be stored in the TLB. | False |
____ is the number of processes that are completed per time unit. | throughput |
________ 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. | copy-on-write |
Round-robin (RR) scheduling degenerates to first-come-first-served (FCFS) scheduling if the time quantum is too long. | True |
What scheduling algorithm assignments the CPU to a process for only its time slice (or time quantum)? | Round-robin |
On a system with demand-paging, a process will experience a high page fault rate when the process begins execution. | True |
Which of the following scheduling algorithms must be nonpreemptive? | FCFS |
The local variables of a monitor can be accessed by only the local procedures. | True |
What are the two functions used with mutex locks? | acquire() and release() |
Systems using a one-to-one model (such as Windows XP, Solaris 9, and Linux) schedule threads using process-contention scope (PCS). | False |
A ___ type presents a set of programmer-defined operations that are provided mutual exclusion within it. | monitor |
Mutex locks and binary semaphores are essentially the same thing. | True |
With _______ a thread executes on a processor until a long-latency event (i.e. a memory stall) occurs. | coarse-grained multithreading |
Deadlock prevention and deadlock avoidance are essentially the same approaches for handling deadlock. | False |
A(n) ____ page table has one page entry for each real page (or frame) of memory. | inverted |
A(n) ___________ is a sequence of read-write operations that are atomic. | memory transaction |
What scheduling algorithm assigns the CPU to the process with the shortest burst? | Shortest Job First (SJF) |
The banker's algorithm is useful in a system with multiple instances of each resource type. | True |
A Java thread may release a lock under which of the following circumstances? | It exits a synchronized method. |
To handle deadlocks, operating systems most often _____. | pretend that deadlocks never occur |
What are the two operations that can be performed on a semaphore? | Wait() and Signal() |
Which of the following data structures is appropriate for placing into its own segment? | all of the above |
Protocols to prevent hold-and-wait conditions typically also prevent starvation. | False |
Suppose we have the following page accesses: 1 2 3 4 2 3 4 1 2 1 1 3 1 4 and that there are three frames within our system. Using the FIFO replacement algorithm, what will be the final configuration of the three frames following the execution of the given | 3,4,2 |
Assume an adaptive mutex is used for accessing shared data on a Solaris system with multiprocessing capabilities. Which of the following statements is not true? | Condition variables and semaphores are never used in place of an adaptive mutex. |
A semaphore ____. | is essentially an integer variable |
_____ is the method of binding instructions and data to memory performed by most general-purpose operating systems. | Execution time binding |
A binary semaphore is functionally equivalent to a mutex lock. | True |
The ____ is the number of entries in the TLB multiplied by the page size. | TLB reach |
Load balancing algorithms have no impact on the benefits of processor affinity. | False |
Which of the following is a benefit of allowing a program that is only partially in memory to execute? | All of the above |
The first readers-writers problem ____. | requires that no reader will be kept waiting unless a writer has already obtained permission to use the shared database. |
One necessary condition for deadlock is ____, which states that at least one resource must be held in a nonsharable mode. | Mutual Exclusion |
SMP systems that use multicore processors typically run faster than SMP systems that place each processor on separate cores. | True |
Which of the following statements is true? | An unsafe state may lead to a deadlocked state. |
If the current value of counter = 5, what are its possible values if the producer consumer processes run concurrently? | 4, 5 or 6 |
What is the purpose of the mutex semaphore in the implementation of the bounded-buffer problem using semaphores? | It ensures mutual exclusion. |
In the enhanced second chance algorithm, which of the following ordered pairs represents a page that would be the best choice for replacement? | 0,0 |
A 32-bit logical address with 8 KB page size will have 1,000,000 entries in a conventional page table. | False |
The wait-for graph scheme is not applicable to a resource allocation system with multiple instances of each resource type. | True |
In Little's formula n = λ x W, what does W represent? | average waiting time in the queue |
What are the two types of contention scope for thread scheduling? | Process-contention scope, System-contention scope |
In Solaris, if an interactive thread with priority 15 uses its entire time quantum, what is its priority recalculated to? | 5 |
____________ occurs when a higher-priority process needs to access a data structure that is currently being accessed by a lower-priority process. | Priority Inversion |
Under preemptive scheduling, when a process switches from the running to the ready state, it may lose control of the CPU. | True |
List at least two possible parts of a program that may be assigned separate segments. | Code, Global variables, The heap, Stacks for each thread, Standard C Library |
_____ is not a technique for handling critical sections in operating systems. | Peterson's solution |
A spinlock is a type of mutex lock. | True |
What size segment will be allocated for a 39 KB request on a system using the Buddy system for kernel memory allocation? | 64KB |
Solaris, Windows XP, and Linux assign higher-priority threads/tasks longer time quantums and lower-priority tasks shorter time quantums. | False |
What is the name for the state of the system if resources can be allocated to all processes in some order and deadlock can still be avoided? | Safe state |
Inverted page tables require each process to have its own page table. | False |
What is the term used to describe the segment of code where shared data is accessed and possibly manipulated? | Critical Section |
Which of the following statements is NOT true? | Spinlocks can be used to prevent busy waiting in the implementation of semaphore. |
Semaphores can provide the same functionality as mutex locks. | True |
The default scheduling class for a process in Solaris is ____. | time sharing |
Given the reference string of page accesses: 1 2 3 4 2 3 4 1 2 1 1 3 1 4 and a system with three page frames, what is the number of page faults for the given reference string, using the LRU page-replacement algorithm? | 8 |
A deadlock-free solution eliminates the possibility of starvation. | False |
The circular-wait condition for a deadlock implies the hold-and-wait condition. | True |
What is the numeric priority of a Windows XP thread in the NORMAL_PRIORITY_CLASS with HIGHEST relative priority? | 10 |
Provide at least one method for recovering from deadlock. | Abort all deadlocked processes, or, Abort one process at a time until the deadlock cycle is eliminated |
Systems in which memory access times vary significantly are known as __________. | non-uniform memory access |
Which of the following is true of multilevel queue scheduling? | Each queue has its own scheduling algorithm. |
A schedule in which each transaction is executed atomically is called a(n) ____. | serial schedule |
Load balancing is typically only necessary on systems with a common run queue. | False |
The ____ scheduling algorithm is designed especially for time-sharing systems. | RR |
__________ involves the decision of which kernel thread to schedule onto which CPU. | System-contention scope |
A page fault must be preceded by a TLB miss. | True |
A deadlocked state occurs whenever ____. | every process in a set is waiting for an event that can only be caused by another process in the set |
______ allows a portion of a virtual address space to be logically associated with a file. | memory-mapping |
In preemptive scheduling, the sections of code affected by interrupts must be guarded from simultaneous use. | True |
A spinlock ____. | does not require a context switch when a process must wait on a lock |
_______ refers to where a process is accessing/updating shared data. | critical section |
The multilevel feedback queue scheduling algorithm allows processes to migrate between different queues. | True (multilevel feedback scheduling != multilevel scheduling) |
Fragmentation can still occur in paging systems. | True. Internal fragmentation can occur. External cannot. |
If the page-fault rate is too high, the process may have too many frames. | False |
One necessary condition for deadlock is ______, which states that there is a chain of waiting processes whereby P0 is waiting for a resource held by P1, P1 is waiting for a resource held by P2, and Pn is waiting for a resource held by P0. | Circular wait |
What is the term for describing the situation where shared data may be manipulated concurrently and the outcome of the execution depends upon the order of access? | Race Condition |
_____ can be used to prevent busy waiting when implementing a semaphore. | Waiting queues |
In Little's formula n = λ x W, what does λ represent ? | average arrival rate for new processes in the queue |
Which of the following is true of the rate-monotonic scheduling algorithm? | CPU utilization is bounded when using this algorithm. |
Optimal page replacement ____. | is used mostly for comparison with other page-replacement schemes |
The _____ allocation algorithm allocates available memory to each process according to its size. | proportional |
What two registers can be used to provide a simple form of memory protection? | Relocation register, Limit register |
The mapping of a logical address to a physical address is done in hardware by the ________. | memory-management-unit (MMU) |
Solaris uses both a local and global page replacement policy. | False |
What are the two general hardware instructions that can be performed atomically? | test_and_set(), compare_and_swap() |
Suppose that there are 12 resources available to three processes. Which of the following correctly characterizes this state? Process Maximum Needs Currently Owned P0 10 4 P1 3 2 P2 7 4 | It is safe. |
List at least three different criteria for designing a CPU scheduling algorithm. | CPU utilisation (%), Throughput (# of processes completed), Turnaround time (time to complete a process), Waiting time (time spent in waiting in the ready queue), Response time (time from submission to first response) |
A race condition ____. | results when several threads try to access and modify the same data concurrently |
Which of the following statements is true? | Operations on atomic integers do not require locking. |
The most complex scheduling algorithm is the multilevel feedback-queue algorithm. | True |
Stack algorithms can never exhibit Belady's anomaly. | True |
A solution to the critical section problem does not have to satisfy which of the following requirements? | atomicity |
A system in an unsafe state will ultimately deadlock. | False |
Which one of the following statements are incorrect when a Java thread invokes the wait() method? | The thread that has been waiting the longest becomes the new owner of the lock. |
Hashed page tables are particularly useful for processes with sparse address spaces. | True |
_____ is the dynamic storage-allocation algorithm which results in the smallest leftover hole in memory. | Best fit |
_____ occurs when a process spends more time paging than executing. | Thrashing |
What is the name of the classic deadlock avoidance algorithm? | Banker's Algorithm |
In systems that support virtual memory, ____. | physical memory is separated from logical memory. |
Describe one strategy for dealing with deadlocks. | Prevent/Avoid, Detect/Recover, Ignore |
Which of the following data structures in the banker's algorithm is a vector of length m, where m is the number of resource types? | Available |
In Peterson's solution, the ____ variable indicates if a process is ready to enter its critical section. | flag[i] |
Virtualization does not allow a single-CPU system to appear as a multiprocessor system. | False |
_____ is the dynamic storage-allocation algorithm which results in the largest leftover hole in memory. | Worst Fit |
Assume there are three resources, R1, R2, and R3, that are each assigned unique integer values 15, 10, and 25, respectively. What is a resource ordering which prevents a circular wait? | R2, R1, R3. |
Non-uniform memory access has little effect on the performance of a virtual memory system. | False |
Belady's anomaly states that ____. | for some page replacement algorithms, the page-fault rate may increase as the number of allocated frames increases |
There is a 1:1 correspondence between the number of entries in the TLB and the number of entries in the page table. | False |
Given the logical address 0xAEF9 (in hexadecimal) with a page size of 256 bytes, what is the page offset? | 0xF9 |
Which of the following is true of cooperative scheduling? | A process keeps the CPU until it releases the CPU either by terminating or by switching to the waiting state. |
Windows uses a local page replacement policy _____. | when a process exceeds its working set maximum |
A Solaris interactive thread with a time quantum of 80 has a higher priority than an interactive thread with a time quantum of 120. | True |
A Solaris interactive thread with priority 15 has a higher relative priority than an interactive thread with priority 20 | False |
The Linux CFS scheduler identifies _____________ as the interval of time during which every runnable task should run at least once. | targeted latency |
What is the term that describes when a page number is not present in the TLB? | TLB miss. A memory reference to the page table is made, and the page and frame number are added to the Translation Look-aside Buffer (TLB) |
Given the reference string of page accesses: 1 2 3 4 2 3 4 1 2 1 1 3 1 4 and a system with three page frames, what is the final configuration of the three frames after the true LRU algorithm is applied? | 3,1,4, |
A significant problem with priority scheduling algorithms is _____. | Starvation |
Which of the following is true of compaction? | It is possible only if relocation is dynamic and done at execution time. |
What is the only reasonable condition that can be used to prevent deadlocks from occurring? | Circular-wait. Impose a total ordering of all resource types, and require that each process requests resources in an increasing order of enumeration. |
Lock ordering cannot guarantee protection from deadlock. | True |
Every object in Java has associated with it a single lock. | True |
An address generated by a CPU is referred to as a ____. | logical address |
Which of the following is true of cooperative scheduling? | A process keeps the CPU until it releases the CPU either by terminating or by switching to the waiting state. |
Which of the following statements is false with regard to Solaris memory management? | The speed at which pages are examined (the scanrate) is constant. |
An instruction that executes atomically ____. | executes as a single, uninterruptible unit |
Which of the following statements are false with regards to the Linux CFS scheduler? | There is a single, system-wide value of vruntime. |
The rate of a periodic task in a hard real-time system is ____, where p is a period and t is the processing time. | 1/p |
The Linux operating system does not rely on segmentation and uses it minimally. | True |
What are the names of the two processes associated with the bounded-buffer problem? | Producer and Consumer |
Created by:
bcannoles
Popular Computers sets