CS370 Final

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

Consider the code snippet: childPID = fork(). The parent has a process-ID of 31425 and the newly created child has a process-ID of 27182. . The value of the variable childPID in the child is:

0

How many processes in the process tree, constructed by the code-snippet below, have no child? for (int i=1; i < 4; i++) { if (childid = fork()) { break; } }

1

Consider the code snippet: childPID = fork(). The parent has a process-ID of 31425 and the newly created child has a process-ID of 27182. The value of the variable childPID in the parent is

27182

Consider a 2-level, hierarchical paging scheme that is used for a 32-bit address space. The addressing bits are partitioned as follows: Outer-page: 12-bits Inner-Page: 11-bits Page offset: 9-bits What is the size of the physical memory frame in this system?

512-bytes

Registers are managed by the

Compiler

A resource allocation graph is being used to represent resource requests by processes and allocation of resources to processes. In the system that we consider, there are multiple instances of a given resource type. In this resource allocation graph, the presence of a cycle in the directed edges representing the request and assignment edges for a set of resources and processes indicates that a deadlock has definitely occurred.

False

An unsafe state is a deadlocked state

False

As CPUs get fasters, the average process becomes more and more CPU-bound.

False

Consider the case where the processes are scheduled using round-robin. When an executing process needs to perform I/O, the CPU scheduler performs a context-switch to another process. In the particular case where a process needs to perform this I/O while it still has some of the quanta that was set aside for it, that part of the quanta is spent by idling away the CPU.

False

Contiguous allocation of file blocks avoids external fragmentation of the disk.

False

Data structure organization, and how elements within the data structure are accessed, have no impact on page fault rates experienced by the corresponding process.

False

Deadlock prevention algorithms must target all four of the conditions viz. mutual exclusion, hold-and-wait, no preemption, and circular wait - to eliminate the possibility of deadlocks.

False

Dynamic linking results in wasted disk space and memory utilization because of the duplication inefficiency that can result in multiple copies of key libraries.

False

For files that are in the order of a few bytes, the inode may be used to store the contents of that file instead of being used to manage pointers to disk blocks that comprise the file.

False

Frame replacements based on the local policy increases system throughput.

False

If in 2018 there is a technology that allows main memory to be just as fast as the CPU, then continuing to use a cache would be just as valid as it is now

False

If the physical server hosting the hypervisor fails, the virtual machines continue to be available.

False

In high-end computing systems, page tables with up to a million entries is typically implemented using registers.

False

In paging systems, the logical address space of a process must not exceed the available physical memory.

False

In paging-based memory allocations, the physical address space of a process must be contiguous.

False

In paging-based memory allocations, the physical memory is subject to external fragmentation

False

In the FIRST readers-writers problem, no reader should wait for other readers to finish simply because a writer is waiting. In this case the readers may starve.

False

In the case of particularly large files (> 10 GB) it is possible that each file may have more than 1 inode associated with it.

False

In the producer-consumer problem with a bounded-buffer, if the buffer is full and the producer is ready to add content, the size of the buffer is automatically extended to reduce producer wait times.

False

Increasing the degree of multiprogramming in a system always results in increased CPU utilization.

False

LRU based replacements suffer from Belady's anomaly.

False

Paravirtualization aims to present a virtual machine that looks just like the actual underlying hardware.

False

Prior to support for VT/SVM on the x86 architecture, the hypervisor was stored in ring 1.

False

Random access within files managed using linked list allocations is just as effective as sequential accesses.

False

Since memory is several orders of magnitude faster than disk, compaction of memory spaces is viable and performed periodically (every second) by the OS in contiguous memory allocations.

False

Spinlocks are suited for cases where critical section segments have thousands of lines of code.

False

The Banker's Algorithm allocates resources to requests based on the order in which they arrive i.e. they do not stall any requests for resource allocations.

False

The First-Come-First-Served scheduling algorithm will perform well for interactive applications.

False

The Type-2 hypervisor executes on bare metal.

False

The cost-per-bit increases as you traverse down (registers-to-tape) the memory hierarchy.

False

The defragmentation (or compaction) overhead for the swap space on disk is low enough that the OS can perform this operation periodically.

False

The degree of multiprogramming in pure-paging is higher than in demand-paging systems

False

The first-come, first-served (FCFS) scheduling algorithm could result in starvation.

False

The hypervisor makes decisions about process scheduling and memory management.

False

The lottery scheduling algorithm could result in starvation; assume that every process in the system has been assigned at least one ticket.

False

The page fault rate for a process increases when its working set is in memory.

False

The process control block (PCB) contains information about a process and is used during context-switching between processes. The PCB for every process is maintained in the cache.

False

The round robin scheduling algorithm could result in starvation.

False

The working set for a process must be of the same size throughout the duration of its execution.

False

There are limits to the number of entries in the process table, open file tables, and such. To cope with deadlocks in such situations, it is common for the OS designers to first decide on the number of users N who would be concurrently active at a given time and then place restrictions on users based on this choice of N. That is, if the number of concurrent processes is restricted to say 30000 then each user is allowed to spawn a maximum of 30000/N processes.

False

Threads can be blocked on more than one object at a time.

False

To ensure efficiency and uninterrupted execution, processes executing in the user mode are allowed to disable timer interrupts

False

Unlike processor exceptions, interrupts are triggers by process executions

False

WITHOUT demand paging all pages of process need not be in physical memory.

False

When fork() fails, it is possible that a child may still be created.

False

When the inode is corrupted, it can be reconstructed by sequentially traversing the disk blocks that comprise that inode.

False

When using ballooning, the hypervisor makes decisions about which pages to evict for a particular virtual machine.

False

When using segmentation, it is not possible to have multiple logical address spaces within the same process.

False

The on-board cache is managed by the

Hardware

Consider a situation where there are infinite instances of all different resources types in the system. Within a set of N processes, how many safe sequences are possible?

N!

Main memory is managed by the

OS

A livelock situation involves processes A, B and C. This has the potential to increase the execution time for a completely unrelated CPU-bound process D executing on the same machine.

True

A pure swapping-based approach brings the entire process in to memory at a time.

True

A sensitive instruction behaves differently depending on whether it was executed in user-mode or kernel-mode.

True

A transaction can be context-switched in the middle of its execution.

True

A whole number of inodes can fit within a disk block.

True

All processes in UNIX are created using the fork() system call.

True

Caches are important because of the difference in speed between the CPU and main memory

True

Consider a system where the optimal page size to ensure a good trade-off between fragmentation and page table entries using the formula √2𝑠𝑒 is 999 bytes: here, s is the average size of process and e is the size of an entry in the page table. However, a decision was made to go with a page-size of 1024 bytes. Is this a good design choice?

True

Contiguous allocations of file blocks minimize disk head movements.

True

Deduplication reduces memory requirements by allowing virtual machines to share pages with the same content.

True

Every process needs its own stack and heap.

True

FIFO page replacements suffer from Belady's anomaly.

True

For a set of processes, at any given instant there may be more than one safe sequence.

True

In paging-based systems, a process may suffer from internal fragmentation.

True

In segmentation, each segment can be of a different size.

True

In segmentation, each segment can have different protections associated with it.

True

In the Goldberg-Popek model, a machine is virtualizable if sensitive instructions are a subset of privileged instructions.

True

It is impossible to avoid external fragmentation in contiguous memory allocations.

True

It is impossible to avoid internal fragmentation in contiguous memory allocations.

True

Linked list allocation of file blocks can utilize all available disk blocks.

True

Mutual exclusion is provided within a monitor.

True

One limitation of a file system based on inodes is that each file must fit within a single disk partition.

True

Temporary variables of a function/method are allocated on the stack.

True

The Banker's Algorithm allows us to identify safe sequences for a set of processes based on the current allocation of resources and the maximum needs of each process.

True

The access times decrease as you traverse up the memory (tapes-to-registers) hierarchy

True

The binary semaphore can be used in settings involving more than two processes trying to coordinate accesses to the critical section.

True

The file control block is a per-file data structure used to manage information about files.

True

The interrupt vector table allows the processor to quickly identify the precise kernel routine to handle interrupts, processor exceptions, and system call traps

True

The number of memory-resident processes in contiguous memory allocation systems is typically lower than that of paging-based systems.

True

The priority scheduling algorithm could result in starvation; assume that this is the most basic form of priority scheduling where process priorities do not change over time.

True

The reason that the child executes the instruction after fork()is that the child's address-space is a bitwise identical copy of the parent, including the values of the program counter.

True

The shortest jobs first (SJF) scheduling algorithm could result in starvation.

True

The shortest jobs first (SJF) scheduling algorithm provides optimal waiting times for a set of jobs that arrive simultaneously.

True

The signal() operation on a monitor is not persistent. If a signal() is performed, and no process is waiting that signal is ignored.

True

Timestamp-based locking protocols do not suffer from deadlocks.

True

Turnstiles are queue structures containing threads blocked on a lock. Turnstiles are associated with threads not objects.

True

Two processes A and B are executions of the same program X. This program X has an execution sequence that results in access to a hardcoded logical-memory location 0x100ACFFED. When there are two running instances of this program, such as processes A and B, this would mean that accesses from A and B to the hardcoded logical-memory location will result in accesses to two different physical memory locations.

True

Unlike deadlock avoidance algorithms, approaches based on deadlock-detection-and-recovery do not inspect every resource request.

True

WINE is an example of process-level virtualization.

True

When page buffering is used, during page replacements it is possible to bring a new page into physical memory, without having to write a victim page out.

True

Without a hardware timer, preemption of processes is not possible.

True

Without address space identifiers, the translation lookaside buffer must be flushed with every context switch.

True


संबंधित स्टडी सेट्स

PARAGRAPHS: Identifying Main Point and Support in Paragraphs, paragraph editing

View Set

Module 12.1 Intro to Nursing Standards

View Set

Behavioral Modification-Chapter 10 Practice Test

View Set

Understanding Business Chapter 11 1003

View Set

Unit 5: Nutrition Essentials 3rd Edition

View Set

Unit 1: The Early Twentieth Century: Modernism

View Set