Quiz
Quiz 1
Create a free account to finish this quiz
Save your progress and see your final score.
Already have an account? Sign in
Questions in this quiz (200)
1The first microprocessors did not have separate modes for the kernel or supervisor and user.Of what significance is this to the operating system for such a microprocessor?
- APlenty! In these systems there is no way to prevent user programs and applications from intentionally or unintentionally corrupting code and data structures belonging to the operating system, or from attempting to use a shared I/O device.
- BThe significance of this is that only one user program is allowed to be in memory at a time, since there is no way to prevent interaction between multiple user programs should they be simultaneously resident.
- CAs long as the user applications are developed using interpretive languages like Perl,PHP, and Python, there really shouldn't be any problems for the operating system, sincethe interpreter can detect user actions that would cause problems before they occur
2It has been said that the operating system is that portion of a system's software that runs inkernel mode or supervisor mode. Why is this definition inadequate?
- ASome systems (like MINIX 3) run traditional operating system components in user mode. Still others may run multiple operating systems in user mode, with special virtualization software used to multiplex the real hardware resources between the operating systems.
- BIt fails to include important operating system components like the shell (command interpreter), editors, and compilers.
- CSome machines may have more than two modes, and in these cases it is impossible toassociate a single mode with the kernel.
3At the machine language level, how are devices controlled?
- ADevices are not controlled by anything at the machine language level. All device control is done at the micro architecture level.
- BSpecial registers called device registers can be loaded to direct a device to perform an operation.
- CEach unique device has some read-only memory that contains a set of functions written in machine language, and these functions can be called to control the device. Thus a serial port on a Intel system would necessarily be different from a serial port on a Sun SPARC system.
4What are the major functions of an operating system?
- AProvide an extended machine which is easier to use than the bare hardware, and manage the use of complex system resources.
- BGuarantee that only appropriately licensed users may execute commands, and take corrective action when security problems are detected.
- CProvide the tools needed for a particular domain of use for a computer system. Forexample, to a software developer the operating system might provide at least one texteditor, compiler, linker and debugger. For an office worker the operating system might
provide a word processor, spreadsheet, web browser, and e-mail client programs. Whatthe operating system provides depends on the user's application domain
5A computer system's resources can be shared in two ways. What are these?
- ASharing in time: user 1, user 2, user 1, ...; and sharing in space: user 1 and user 2 each get part of the resource
- BSharing by priority: highest priority user gets the resource until it is finished, then second highest priority user gets it, ...; and round-robin sharing: each user gets the resource for a fixed amount of time, then repeat.
- CSharing by need: a user whose work cannot be completed without the resource is first given the resource; and sharing by demand: a user whose work explicitly demans theresource (whether it is needed now or not) is given the resource
6Who designed the first true digital computer?
- AKonrad Zuse
- BCharles Babbage
- CJ. Presper Eckert
7Which of the following devices was used in the first generation of real digital computers(that is, those that were actually built and used)?
- Abioelectronic circuits
- Bintegrated circuits
- Cvacuum tubes
8Who was the father of the person after whom the Ada (reg tm) programming language wasnamed?
- AFred Brooks
- BLord Mountbatten
- CLord Byron
9What device(s) was(were) used for the input of jobs to, and output of results from, the maincomputer in a batch computing system?
- Amagnetic tape
- Bpaper tape
- CCD-ROMs
10For what purpose was the IBM 1401 computer frequently used?
- AIt was often used to copy jobs from punched cards to magnetic tape, and to copy results from magnetic tape to line printers.
- BWith very large disk drives (for the time), it was used to provide processing of SQLqueries for other computer systems
- CIt was often used as a web server.
11Actions taken by a computer in processing a batch job were primarily controlled by what?
- AA script (of sorts) selected by the setting of a group of switches on the front panel of thecomputer
- BCommands from a control operator at a message forwarding system
- CControl cards such as $JOB, $LOAD, and $RUN
12Just before the introduction of IBM 360 computer systems, what were the main types ofcomputers available?
- ASystems that used wired plugboards for input, those that used punched cards, and thosethat used magnetic tapes
- BSystems that used vacuum tubes and systems that used transistors
- CNumber-crunching scientific systems and character-oriented systems for sorting andprinting
13The first major computer to use integrated circuits was
- Athe Bendix G-15
- Bthe IBM 360
- Cthe IBM 1620
14Multiprogramming attempts to eliminate significant waste of what computer systemre source(s)?
- ACPU
- Bcard readers and printers
- Cdisks
15Which of the following special features is needed to support multiprogramming?
- Amemory protection hardware
- Bfast carry look-ahead generators
- Cmercury delay lines
16What unrealistic goal was associated with the OS/360 operating system?
- AIt had to run well on small and large systems, on commercial and scientific systems, on systems with few and with many peripheral devices, and it had to be efficient in all cases
- BIt had to eliminate the need for the use of punched cards.
- CIt had to provide emulation for programs that previously ran on systems with 32, 36, and60 bits per word
17To what does the acronym spooling refer?
- AStored Program Operations Off Line
- BShared Partial Object-Oriented Linking
- CSimultaneous Peripheral Operations On Line
18When a system uses spooling,
- Aseveral sequential system calls from a program can be submitted as a group to saveoverhead during kernel entry.
- Bprograms are validated for execution by the presence of digital signatures called licenses.
- Coff-line systems to copy cards to tape and tape to print are not necessary
19How are timesharing and multiprogramming related?
- ATimesharing is a variant of multiprogramming where each user has an online terminal
- BTimesharing is used to allow multiple users at online terminals to access the same program but different data (for example, airline reservation systems)
- CTimesharing and multiprogramming are different approaches to optimizing the use of primary memory which is typically underutilized if only a single program at a time is executed.
20CTSS is the acronym for
- ACPU-Terminal Synchronization System
- BCompatible Time Sharing System
- CComputer Time Sharing System
21The MULTICS concept is most similar to which of the following?
- Aa trash collection service
- Ba power distribution system
- Ca national television network
22The MULTICS system was designed to run on which of the following processors?
- AGE 645
- BUnivac 1108
- CIBM System/360
23In what programming language was MULTICS written?
- AJOVIAL
- BPL/I
- Cassembler language
24One possible advantage of connecting a group of PCs or workstations via a LAN to afileserver is that
- Athe PC or workstation processors do not need to be as powerful as the processor in thefileserver
- Bthe administrator has to install and protect only one set of programs and data.
- Cthe PCs can be used as a parallel system.
25The term middleware is used to describe
- Asoftware used in heterogeneous environments to bridge the gap between local users and remote servers
- Boperating systems for medium-sized systems (for example, not laptops or mainframes)
- Coperating systems used on systems that normally run a different operating system (for example, software that allows Windows executables to run on a Macintosh.)
26In which generation of computers was the first minicomputer developed?
- Athe first generation
- Bthe fifth generation
- Cthe third generation
27What company developed the first minicomputer?
- ACray
- BUNIVAC
- CDEC
28What was the PDP-1?
- AIt was the first minicomputer
- BIt was the first mainframe computer manufactured by Digital Equipment Corporation
- CIt was the first system manufactured by Paradyne Data Products
29What was the last computer in the PDP series?
- Athe PDP-10
- Bthe PDP-11
- Cthe PDP-8
30On which computer system was UNIX development first started?
- ABendix G15
- BPDP-7
- CIBM 360
31What is POSIX?
- AIt is the first Apple operating system that ran on Intel processors.
- BIt is a standard for UNIX that defines a minimal system call interface.
- CIt is the variant of UNIX that was developed for use on PDP-11 computer systems.
32In what year was the Intel 8080 introduced?
- A1968
- B1984
- C1974
33The Intel 8080 is what class of computer?
- Aparallel computer
- Bmicrocomputer
- Cmainframe
34What was the name of the most popular operating system used on Intel 8080 computersystems?
- AAOS
- BMS-DOS
- CCP/M: Control Program for Microcomputers
35What was the 6800?
- Athe microprocessor used in Apple-II computer systems
- Bthe first 16-bit microprocessor
- Cthe first microprocessor manufactured by Motorola
36What was the 6502?
- Athe first microprocessor to use TTL circuits
- Bthe first microprocessor manufactured by Motorola
- Cthe microprocessor used in Apple II computer systems
37Which microprocessor was used in the first IBM PC?
- Athe 8080
- Bthe 8088
- Cthe 6502
38Which operating system dominated the early IBM PC market?
- AMS-DOS
- BMULTICS
- CNone of the above
39The acronym GUI stands for what?
- AGeneral Utility Instructions
- BGross Utility Index
- CGraphical User Interface
40What processor was first used in the Apple Macintosh?
- Aan IBM RISC chip
- Bthe Motorola 68000
- Cthe Sun SPARC
41The acronym ROM stands for what?
- ARead Only Memory
- BRAID Only Multiplexor
- CRelative Offset Mask
42What was the major distinguishing feature of the operating system for the Apple Macintosh?
- AIt was built on top of the Apple II's operating system.
- BIt provided a graphical user interface
- CIt was built on top of IBM's OS-360.
43The Microsoft Windows operating system
- Awas originally a derivative of the NT operating system.
- Bwas the first to run on a 32-bit processor
- Cwas originally a GUI that ran on top of MS-DOS
44Which of the following operating systems is most frequently used on high-end computer workstations and network servers?
- AMAC OS X
- BDEC's VAX/VMS
- CUNIX (or a derivative)
45The X Window system is
- Athe predecessor to the Y Window system
- Bthe windowing system most commonly found on UNIX systems
- Cthe current Apple operating system for the Macintosh.
46What is a major difference between a network operating system and a distributed operatingsystem?
- AA network OS obviously requires a network to connect the individual machines; a distributed OS only needs multiple processors (as in, for example, a modern multicore processor)
- BWith a network OS, users are aware of the existence of multiple computers; a distributed OS appears to users as a traditional uniprocessor OS.
- CNothing; they are interchangeable terms for the same concept.
47The developer of Linux was significantly influenced by which of the following operating systems?
- AMINIX
- BOS-390
- CMAC OS X
48The acronym LAMP is sometimes used to refer to
- Athe first microprocessor operating system
- BLinux, Apache, MySQL, and Perl or PHP
- CLimited API MultiProcessors
49System calls are
- Athe extended instructions provided by an operating system.
- Bnetwork requests made by a network or distributed operating system
- Ccalls from the operating system to device drivers
50The MULTICS operating system
- Autilized hardware support for a series of concentric rings, with more privileged code executing running in smaller-numbered rings.
- Bwas designed as an illustration of the layering concept, but was never actuallyimplemented
- Csupported the concept of virtual machines with multiple virtual clock ticks occurringduring every real clock tick
51One modern processor that provides hardware support for the ring mechanism is
- Athe Intel Pentium
- Bthe Zilog Z80
- Call of the above
52The CMS system
- Awas the first operating system used on the Intel 8080
- Bis a single-user interactive system commonly used with VM/370.
- Cnone of the above.
53How many bytes of data were contained on a punched card?
- A500
- B80
- C256
54A process is
- Athe set of control cards used to run a batch program.
- Bthe microcode associated with a device controlle
- Ca program in execution
55A process table is
- Aan array or linked list of structures with one entry for each process in existence
- Bthe table maintained by each process that records the current position associated witheach file open in the process
- Can array in which a copy of the contents of the memory for a process is saved when that process is not running.
56A shell is
- Aa container for multiple related processes.
- Ba representation of the memory region that will be used by a process that is being created.
- Ca process that reads commands and arranges for their execution
57Suppose a process successfully executes the system call to create a new process. That new process is usually referred to as a
- Aslave process
- Bsecondary process.
- Cchild process
58Which of the following will result in a signal being sent to a process?
- AA timer set by a process expires.
- BA process executes an instruction that attempts to divide by zero
- CEach of the above will result in a signal being sent
59A signal is the software analog of
- Aa system call
- Ba processor failure
- Ca hardware interrupt
60Every user of a MINIX 3 (or UNIX) system is identified by
- Aa UID and a GID
- Ba UID.
- Ca biometric signature
61In UNIX, which user is endowed with special powers, and may violate many of the protection rules?
- Athe primary user
- Bthe operator
- Cthe superuser
62A directory is
- Aa list of all users on a system, ordered by group.
- Ba way of grouping files together
- Can alphabetical listing of the files on a system.
63Entries in directories may be files or
- Auser IDs
- Bdirectories.
- Cprocess IDs
64A hierarchy of directories gives rise to the concept of
- Aa file system
- Ba disk drive
- Ca b-tree
65Each file in a directory hierarchy can be identified by giving its
- Ahash code
- Blabel.
- Cpath name
66The directory at the top of the directory hierarchy is called
- Athe root directory
- Bthe master directory.
- Cthe primary allocation
67An absolute path starts with
- Athe primary allocation
- Bthe root directory
- Cthe first entry in the file system hash table
68If a path is not absolute, it begins with
- Athe first entry in the file system hash table
- Bthe current working directory.
- Cthe root directory
69A process can change its current working directory
- Aby closing the current working directory and opening the new working directory
- Bby using therenamesystem call
- Cby issuing the appropriate system call
70The binary protection code in MINIX 3 has
- A10 bits
- B8 bits.
- C11 bits
71Suppose the owner's rwx bits for a particular file are set to --x. This means the owner may
- Aexecute the file.
- Bread and write the file, but not execute it
- Cunencrypt the file
72If the x permission bit is set for a directory, then
- Athe directory may be searched
- Bthe directory is encrypted
- Cthe directory is being exclusively used by a user.
73A file descriptor is
- Aa small integer returned from a file open operation
- Bthe directory index of a file
- Ca checksum of a file's contents used to detect tampering
74A mounted file system is
- Aattached to a directory using themountsystem call
- Bcopied into a predefined region of memory
- Cone that has been copied from a removable device
75A special file
- Amakes an I/O device look like a file.
- Bone to which no user has read or write access
- Ca file that contains a script that can be interpreted.
76A block special file
- Acan only appear in a mounted file system
- Bcan be used to model a disk
- Ccontains compressed blocks of other files (like a zip file).
77A pipe is
- Aa path from primary memory to a device like a disk
- Ba secure network communication channel
- Cused to allow two processes to communicate by reading and writing the pipe.
78A shell is
- Aan application program that is not part of the operating system
- Ba system call that is not currently implemented
- Can archaic name for a directory.
79When a shell is given a user command to execute, it
- Achecks to see if the owner of the file containing the program to be executed has explicitly allowed the current user to execute the command
- Bcreates a child process to execute the command
- Cchecks to see if the user is logged in.
80If a shell is given the command who | wc -l, it will
- Arun the who and wc -l commands at the same time, and terminate the longer-running command if the shorter-running command terminates successfully.
- Bconnect the output of the who command to the input of the wc -l command and run both commands at the same time.
- Crun the who command, and it if completes successfully, then run the wc -l command
81Placing an ampersand after a command
- Acauses the output of the command to be discarded
- Bdirects the shell to not wait for the command to complete before prompting for another command
- Ccauses the command to be treated as a comment (that is, not executed).
82POSIX procedure calls generally return ____ to indicate an error
- ANULL
- B999
- C-1
83If the fork system call returns successfully
- Aa child process has been created
- Ban additional thread has been created for the process that called fork.
- Cone or more additional threads have been created for the process that called fork.
84In most cases, after calling fork a new child process will
- Aimmediately terminate.
- Bcall one of the exec* system calls to load and execute a different program
- Cwait for a signal from its parent to indicate it should begin executing
85A shell, after creating a process to execute a command, will typically
- Aallocate memory for the next command to be executed
- Bdelay a few seconds to allow the new process to get started
- Cwait for the child process to terminate.
86The first argument to the function with which the execution of a process begins
- Ais an integer that indicates the number of string arguments pointed to by entries in the second argument.
- Bis a pointer to an array of pointers to character strings.
- Ca pointer to an integer that indicates the number of command line arguments
87The regions of memory into which a MINIX 3 process are divided are
- Aallocated using memory that originally belonged to the parent process
- Btext (containing code), data (containing variables), and stack
- Ctext (containing code), data (containing variables), const (containing constants), heap(containing dynamically-allocated storage), and stack
88The sbrk system call
- Ais used to change the size of the data segment for a process
- Bis used to implement thebreakstatement in C, C++, and Java
- Cis used to set breakpoints during a debugging session
89Which system call returns the process ID of the caller?
- Apidextr
- Brpid
- Cgetpid
90Which system call may be used by a process to announce that it is prepared to handle aparticular type of signal?
- Asignal_setup
- Bsigaction
- Cregistersig
91What happens when a signal is sent to a process, and the process has indicated it is willing to handle that particular signal?
- AThe signal handler for the signal is called, if the signal's delivery has not been blocked
- BThe signal handler for the signal is called
- CA new process is created automatically to handle the execution of the signal handler; thisprocess terminates when the signal handler returns
92What is the difference between ignoring a signal and blocking a signal?
- AAn ignored signal is discarded; a blocked signal remains pending and will be delivered if the signal is later unblocked.
- BThe only difference is that there are a few signal types that may not be blocked, but can be ignored.
- CA blocked signal is delivered to a signal handler that always immediately returns; an ignored signal is never delivered to any signal handler. Thus blocked signals take longer to handle than ignored signals.
93Which of the following system calls may be used to send a signal?
- Apost
- Btransmit
- Ckill
94Which of the following system calls may be used to create a file?
- Acreat
- Bfconstr
- Cmake_file
95Which of the following system calls may be used to create a special file?
- Afcspec
- Bcrspec
- Cmknod
96Which of the following system calls is probably the most heavily used?
- Adup
- Bread
- Cfork
97The read and writes ystem calls have three parameters. The second parameter is
- Aa pointer to an integer into which will be stored the number of bytes actually read orwritten when the call completes
- Ban integer containing the file descriptor
- Ca pointer to a buffer
98The lseek system call is used to
- Aspecify the file offset of the next byte in a file to be read or written
- Bseek to the beginning of the next line in a file
- Clocate a point in a file from which aseekoperation can be issued
99The dup system call
- Aduplicates the contents of a file and gives it a new file name.
- Bduplicates the contents of a region of memory by dynamically allocating a region of memory the same size and copying the contents of the region to it.
- Creturns a file descriptor that references the same file as another that referenced by another open file descriptor.
100The pipe system call, if successful,
- Aresults in the creation of two open file descriptors, one for reading, and one for writing
- Breturns a file descriptor that can be read or written.
- Cis only used by a shell to connect the standard output of one command to the standardinput of another
101Which of the following system calls may be used to change a terminal's mode to raw?
- Asettmode
- Bioctl
- Ctcsetattr
102When a terminal is in raw (or non-canonical) mode
- Ainput characters are echoed without change except for non-printing characters (space,tab, end of line) and those that generate a signal
- Bevery input character is passed directly to a reading program with no special processing
- Cevery input character is passed directly to a reading program after checking forcharacters that might result in the generation of a signal
103When a terminal is in cooked (or canonical) mode
- Ainput characters are not passed to a reading program until the end of line character or a character that generates a signal has been entered
- Bevery input character is passed directly to a reading program after checking for characters that might result in the generation of a signal.
- Cinput characters are queued and not passed to a reading program until at least a specified number of characters have been entered
104When the control-C character is typed on a terminal's keyboard
- Athe system's response depends on the terminal mode
- Bthe process associated with the terminal is terminated
- Ca SIGINT signal is sent to the process associated with the terminal.
105Which of the following system calls can be used to control advisory file locking?
- Afcntl
- Balock
- Copen
106The rmdir system call is used toa
- Aremove a directory and any files it contains
- Bremove a directory if it is empty
- Csend a request to a remote (network-attached) directory
107A link system call, if successful
- Amakes a new entry in a directory
- Bchanges the size of a file
- Cconcatenates two files
108 In UNIX/LINUX/MINIX, a directory is essentially
- Aa set of (disk locations, ASCII name) pairs
- Ba set of (i-number, ASCII name) pairs.
- Ca regular file with contents arranged in a well-defined format.
109 In traditional UNIX/LINUX/MINIX file systems, a link
- Amay be used to allow a file to have multiple names, often in multiple directories
- Ba pointer (perhaps one of many) identifying the disk addresses of the blocks comprising a file.
- Cis the connection between a file and its owner
110In many operating systems ablock cacheis used to
- Akeep track of which processes are blocked waiting on a disk read or write operation tocomplete
- Bkeep copies of blocks that have been read from a device and changed after they were read
- Ckeep copies of recently used blocks to avoid having to repeatedly read them
111 In MINIX 3 (and other similar UNIX systems), the sync system call
- Atells the system to begin writing all modified blocks back to the devices from which they were originally read
- Bcauses the block cache to be cleared
- Csynchronizes the system time with the time from a well-known stable time source
112The chdir system call
- Achanges the current working directory for a process.
- Badds or removes a directory entry
- Cchanges the name of a directory
113The chroot system call change
- Athe name of a file in the root directory.
- Bthe identity of the superuser.
- Cthe interpretation of absolute path names for a process.
114The chmod system call
- Achanges the protection bits associated with a file.
- Bis used to change the state of a dynamically linked kernel module.
- Cswitches the hierarchical mode of a file system between hierarchical and flat.
115When a program marked SETUID is executed
- Athe UID of the file is changed temporarily to the UID of the owner of the directory in which the program's executable file is located
- Bthe process acquires an effective UID potentially different from its real UID
- CNone of the above
116The umask system call
- Amasks the UID and GID associated with the owner of an executable file
- Bcan be executed by ordinary user processes.
- Ccan only be executed by the superuser
117The access system call
- Ais used to read or write a file on a remote file system.
- Btests if a particular type of file access will be permitted for the real owner of a process
- CNone of the above
118The time system call
- Areturns the total CPU time used in user and kernel mode by the current process.
- Breturns the current time, in seconds, since midnight on on January 1, 1970
- CNone of the above
119 The most common operating system structure is called
- Aa layered system
- Ban exokernel
- Ca monolithic system
120When an monolithic operating system is constructed
- Aall the files containing the code are compiled and linked together in a single object file
- Bthe individual functions are compiled, but are not linked with the remainder of the operating system kernel until a process requests use of a service provided by that function.
- CNone of the above
121A supervisor or kernel call instruction
- Aoperates exactly like a regular function call instruction, but also verifies that the callingprogram is executing in user mode
- Bswitches the machine from user mode to kernel mode and transfers control to the operating system.
- Ccan only be executed when it is placed in a memory location that is accessed using a real(not virtual) memory address.
122The THE operating system was
- Aa simple batch system organized as a set of layers.
- Borganized as a client-server system
- Cdesigned by Edgser Dijkstra at the University of Texas
123 In a layered system, code running in a particular layer
- Aexecutes in user mode, with the sole exception of the code in layer 0, which executed in kernel mode
- Bcan only call services in the layers below it
- CNone of the above.
124 Each mount system call, if successful
- Adynamically creates a new drive letter (C:, D:, etc.) and makes the files on the media in a drive available for reading and writing
- Ballows the files in one file system to be accessed through a directory in another filesystem
- Ccauses a CD-ROM or DVD-ROM to close (if it was open), and a check to be made for the presence of media in the drive.
125 In a monolithic system, system calls provided by the operating system
- Aare dynamically linked to a process that wants to use them
- Bare requested by executing a kernel call or a supervisor call.
- Care requested by sending a message to the kernel
126Threads are sometimes also called
- Aprocess binders
- Blightweight processes
- Cprocess stitches
127Each application that is currently active in a system will have
- Aat least one related process
- Bhad at least one process to get it started, but the process may have terminated when a thread took over.
- Cat least one process and two threads
128Consider the number of processes and processors in a typical system. The likely relationshipbetween these is
- Aimpossible to predict
- Bthat there are more processes than processors
- Cthat there must be at least as many processors as there are processes
129Using multiple processes in the implementation of a single application may be appropriate to take advantage of multiple processing elements in a computer system. What other reason might motivate the use of multiple processes in a single application?
- AIt is often easier to develop an algorithm for a problem if each of several tasks can be assigned to separate processes.
- BIn systems that maintain resource accounting records, using the same amount of processor time to complete some work, but dividing it among multiple processors, will be less expensive than doing all the work on a single processor.
130A disadvantage of using multiple processes to solve a problem is that
- Ait will reduce the number of applications that can be supported by the computer system
- Bthere is additional overhead needed in the operating system to switch the processoramong the various processes
131A program is
- Aa static set of instructions and data for a processor
- Ba set of instructions being executed by one or more processors in a computer system.
- Cone or more processes being executed by one or more processors
132A process is
- Athe data and the contents of the processor registers while the processor is executing aprogram
- Bone or more programs being executed by one or more processors
- Cthe activity of a processor in carrying out the actions associated with a set of instructions.
133Which of the following is not part of a process?
- Athe processor on which the process is being executed
- Bthe set of instructions being executed
- Cthe quotas (if any) associated with the use of various system resources by the process
134Processes may be created in UNIX systems by using which of the following system calls?
- Apipe
- Bcreat
- Cfork
135Consider the hierarchy of processes in a UNIX system. What data structure best characterizes this hierarchy?
- Aa singly-linked list
- Ba doubly-linked list
- Ca general tree
136In what position in the hierarchy of processes in a UNIX system will we find processes that have no child processes of their own?
- AThey will be leaf nodes.
- BThey will be immediately pointed to by the head pointer of an element in the hash table
137Why must some components of an operating system usually be written in assembly (orassembler) language?
- AHigh-level languages are generally designed to be independent of specific processor architecture, and thus cannot be used to write code to control the unique features of a given processor
- BThe code generated by compilers for high-level language is just too inefficient, in general
138Recall that special trap instructions (like INT on Intel X86 processors and SVC on IBM mainframes) are often used to invoke system calls. For high-level languages, these instructions are
- Ausually found in libraries of functions specific to the language and the operating system being used
- Bgenerated by the compiler
139How is possible that the fork system call can be used to create processes on so many different UNIX systems when we know that different machine language instructions are used by different processor architectures to invoke system calls?
- AEvery processor ever built can interpret a limited subset of instructions that are used toallow the execution of a limited set of system calls, including fork
- BA fork function is provided for each unique system (and language), and it is this function that actually includes the specific machine language instruction(s) necessary to invoke the fork system call.
140The typical states in which any process exists are called
- Arunning, blocked, and terminated
- Bready, running, and blocked.
141A process in the running state
- Ais actively using a processor
- Bis also in the ready state
142The number of processes in the running state
- Ais never greater than the number of processors on a system.
- Bis always less than the sum of the number of processes in the blocked and ready states
143A process in the ready state
- Ahas all resources required for execution except a processor
- Bis actively using a processor, since it has all the resources needed for execution.
144Immediately before a process enters the running state
- Ait must be in the ready state
- Bit must be in the waiting state
145A process in the blocked state
- Ais preventing another process from executing
- Bis not capable of being executed because it does not possess one of the resources requiredfor execution
146Processes in the blocked state are sometimes said to be
- Adead
- Bsleeping
147If a process is waiting on keyboard input from a user, then it will be in the ____ state
- Ablocked
- Bterminated
148Which of the following is not a valid state transition for a process?
- Ablocked to ready
- Bblocked to running
149When a processor becomes available to execute a process, the operating system's scheduler selects an appropriate process from those in
- Athe running state
- Bthe ready state.
150A process is moved from the running state to the blocked state
- Awhen a more appropriate process becomes ready to execute, and the scheduler decides to preempt it.
- Bwhen it requests a resource that is not currently available, but which will become available in the future.
151A process is moved from the blocked to the ready state
- Awhen the idle process terminates
- Bwhen the resource on which it has been waiting becomes available
152A process is moved from the running state to the ready state
- Awhen the scheduler decides another process is more suitable for execution (for example,a ready process has higher priority than a running process)
- Bwhen it wishes to terminate
153A request by a process for the current time of day
- Awill not likely cause the process to block
- Bwill cause the process to block until the clock can be read.
154When a process has consumed its fair share of processor time, the operating system may move it to the ______ state
- Aready
- Brunning
155When a process is moved out of the running state
- Athe processor's registers are reset to the values they had when the process entered the running state
- Bstate information (processor register contents, for example) is preserved so it can be restored when the process is next selected for execution
156When a process is moved into the running state
- Athe processor registers are set to the values they containing when the process was last moved out of the running state.
- Bit is also retained in the ready state so if additional processors become available theprocess can be run on multiple processors
157The act of moving one process out of the running state and replacing it with another isusually called
- Aa context switch
- Ban event transition.
158When a process is moved from the blocked state to the ready state
- Atwo context switches are required
- Bno context switch is required
159Where is the unique identification of a process normally found?
- Athe process table entry for the process
- Bthe process ID register in the processor
160Interrupts are used to notify the processor of various events, usually those related to the hardware. For example, notifying the processor that a disk input/output operation has completed is generally sent as _____ notification.
- Aa low-priority
- Ban asynchronous
161The event being reported to the processor by an interrupt
- Aalways occurs before the execution of the current instruction.
- Bmay have nothing whatever to do with the process that is currently being executed
162The priority associated with an interrupt
- Ais always one larger than the priority associated with the process currently being executed.
- Bis higher for faster or more important devices than for slower or less important devices
163If an interrupt is masked
- Ait will not be reported to the processor, but it remains pending
- Bit causes all other interrupts to be ignored until it has been recognized by the processor
164If interrupts are globally disabled, then
- Ano processor can execute any input/output instructions
- Binterrupts from most devices are prevented from being recognized by the processor
165An interrupt handler
- Ais the set of instructions executed as a result of an interrupt being reported to a processor
- Bruns only when a process is blocked
166An interrupt handler is not allowed to
- Ablock
- Bbe preempted
167When an interrupt occurs, the type of interrupt is used to
- Adetermine how much processor time will be allowed for the completion of the interrupt handler.
- Bdetermine the location of the interrupt handler.
168An interrupt vector is
- Aa one-dimensional array containing the addresses of interrupt handlers, indexed by interrupt number, and used in many processor architectures
- Ban array of interrupts, each of which is simultaneously generated by some special events
169A trap
- Aoccurs synchronously with the execution of an instruction
- Bis a section of code used to identify and thus prevent the execution of various Trojan-horse viruses
170A trap can be generated for each of the following reasons except
- Aattempting to execute an invalid instruction
- Bcompleting a disk operation
171The process which generates a fault
- Ais the currently executing process
- Bis the last process moved to the running state
172The operating system frequently translates a trap into
- Aa decrement of the number of such traps that were originally permitted when the currently-executing process was started.
- Ba signal to the currently-executing process.
173When a trap or an interrupt is successfully recognized by the processor,
- Athe processor is always placed in supervisor mode
- Bthe processor terminates execution of the current process, and begins or resumes execution of the process that caused the trap or interrupt.
174A signal is
- Aa software report to a process that an exceptional condition has occurred
- Balways sent to the last process that was moved to the ready state
175Which of the following will usually cause the generation of a SIGINT signal in a UNIX system?
- Apressing the control-C key
- Bpressing any key on the keyboard
176Which of the following UNIX functions may be used to register a signal handler to deal with a floating point exception?
- ASIGFPE
- Bregister
177Conceptually, each process has how many threads when it begins execution?
- Aa variable number, depending on how the process was created
- Bone
178Which of the following resources does a thread not share with other threads in the same process?
- Athe resource usage quotas
- Bits stack
179A thread represents
- Aa separately scheduled unit of work for a processor.
- Bthe connection between a signal and the signal handler that is registered to handle occurrences of that signal.
180One advantage of threads over processes is that
- Amultiple threads share the same address space
- Bmultiple threads share the same stack
181If threads are implemented as part of the kernel of an operating system, then
- Aa context switch is required each time a processor is switched between threads, even if the threads belong to the same process
- Bthey will be immune to the delivery of signals
182If threads are implemented through user library functions, then
- Athere is much less overhead (due to context switches) required when switching from one user thread to another in the same process
- Beach thread must necessarily have a separate stack, which is not required with a kernel thread implementation.
183The acronym IPC stands for _____ .
- Ainterprocess communication
- Binterprocessor communication
184A race condition exists when
- Atwo or more threads/processes attempt to use a resource in a manner that doesn't guarantee consistency,
- Btwo or more threads/processes are attempting to use a set of resources in a manner that causes each of them to wait on a resource that one of the others holds.
185When we say an operation is atomic we mean
- Aall parts of the operation are completed without the possibility of any other operation on any processor manipulating the resources being used by the operation.
- Bonly one processor (on a multiprocessor system) may be executing instructions while the atomic operation is in progress
186A sequence of instructions that modifies, updates or accesses a resource shared by multiple threads or processes is called
- Aa perfect storm
- Ba critical section
187The mutual exclusion problem
- Adeals with techniques designed to guarantee that code segments accessing the same resources are executed atomically.
- Bwas first solved by Donald Knuth
188The most obvious condition necessary for a good solution to the race condition problem is that no two processes may be
- Asimultaneously inside their critical sections
- Bsharing any region of memory at the same time.
189What assumptions may we make about the speed with which processes are being executed by processors, and the number of processors?
- ANo assumptions may be made
- BAll processes must be executed at the same speed
190Which of the following is not a necessary condition for a good solution to the mutual exclusion problem?
- ANo process should have to limit the size of the memory region it is using
- BNo process running outside its critical section may block other processes from entering their critical sections
191The ability to disable recognition of interrupts (in particular, timer interrupts) can sometimes be used to implement a solution to the critical section problem. This solution will not work if
- Athere are multiple processors.
- Bwe are using threads instead of processes
192There are some proposed solutions to the mutual exclusion problem that utilize a lock variable. This variable is set to 0 if the shared resource is not being used, and set to 1 when the resource is in use. So if we want to use the resource, we have but to check the lock variable. If it is 1, we continually repeat the test until the lock variable becomes 0. Then we set it to 1, access the shared resource, and set the lock variable back to 0. What can go wrong with this solution?
- AThere is a race condition present. Multiple processes (or threads) could check the lock variable, find it 0, and then set it to 1 and enter their critical sections
- BThe solution, as presented, will not work if there are more than two processes.
193Solutions to the mutual exclusion problem that require a process to check a lock variable repeatedly until it has a specified value, even if implemented correctly (that is, if they prevent multiple processes from entering their critical sections at the same time), still have a significant problem. What is that problem?
- AThe process that is waiting to enter its critical section is continually consuming the processor resource, checking and checking again, significantly delaying other processes from using the processor and potentially relinquishing their use of the desired rsource
- BThe solution will not work correctly on systems with multiple processors.
194By adding a turn variable to a proposed mutual exclusion solution using a lock variable we can guarantee that the critical sections of several processes will be executed atomically. Which of the following is a problem with this type of solution?
- AProcesses must enter their critical sections in strict alternation; one process will not be allowed to execute its critical section twice in a row, even if no other process is ready to execute.
- BThe solution will only work if there is at least one processor for every process
195Dekker presented the first recognized solution to the mutual exclusion problem. What hardware property is assumed by his solution?
- AWrite operations by multiple processors to the same memory location will be done atomically.
- BDekker's solution requires that there be only a single processor
196Peterson's solution to the mutual exclusion problem is much less cryptic than Dekker's solution. It also uses a turn variable. What else distinguishes Peterson's solution to the problem?
- AHis solution uses an array with one element per process to indicate which processes are interested in entering their critical sections.
- BNone of the other choices characterize Peterson's solution to the mutual exclusion problem
197Modern processors usually have special instructions that make implementation of solutions to the mutual exclusion problem much simpler. What is the name of an instruction found on IBM mainframe computer systems to support such operations?
- ASignal and wait
- BTest and set
198The IBM mainframe instruction used to simplify the implementation of critical sections works by doing what?
- AIt eliminates the possibility of another process (or even another processor) examining the value of the control variable in memory between examining its value and then setting it to a known state.
- BIt shifts 1-bits out of a special shift register into a per-processor register, eliminating the possibility that two processors could perform the same operation simultaneously.
199What instruction on the Intel X86 family of processors could be used to achieve the same effect as that provided by the IBM mainframe instruction used to assist in the
- AExchange (XCHG)
- BCache line flush (CLFUSH)
200If processes have associated priorities, then a general rule is that
- Athe priority of a process is directly related to the amount of memory it requires to execute.
- Bthe highest priority ready processes are those allowed to use the processors
Information
- Description
- Quiz on Quiz 1, created by Myles Allbee on 01/05/2016.
- Author
- Myles Allbee
- Language
- English
- Views
- 3
- Rating
- No ratings yet Rate this quiz