Vous êtes sur la page 1sur 12

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

Section 3.1: The Functions of Operating Systems


May/June 2003
9 Describe what happens when a processor which is currently working on a job receives an interrupt from an external source. [6]

ANSWER - June 2003 p3 9 - Current cycle is completed - Priority of interrupt compared with current job If higher: - Contents of special registers saved/job placed in blocked state/in ready Q - Interrupt/program for execution of interrupt, is identified/vectored interrupt used - Interrupt serviced by running program - On completion values of special registers from original program area replaced/original job restored If lower: - Interrupt allocated position in job queue... - According to priorities - Current job continues with next cycle (1 per -, max 6) (6) October / November 2003
2 Explain how memory can be managed to allow more than one large job to appear to be stored simultaneously in the memory. [5] 9 (a) Describe the process of spooling when sending jobs for printing. [3] (b) Explain the importance of job type when a number of jobs are being processed using a multiprogramming operating system. [3]

ANSWER - Nov 2003 P3 2 - Page or partition of software in memory rather than whole job - Partitioning of memory - variable sizes to suit - varying jobs - Pages of memory - of fixed size - jobs do not have to occupy contiguous pages - mention of virtual memory - mention of swapping Note: Segmentation equivalent to partitioning (1 per -, max 5) 9 (a) - Jobs sent to storage - When storage of job complete - reference to job stored in spool queue - along with location in storage. (1 per -, max 3) (3) (b) - Processor can only process one job at a time - Two types of job, I/O bound and processor bound - I/O must have priority in order to - allow peripherals to operate while processor bound job is processed May/June 2004
5 (a) Describe the objectives of scheduling in a multi-user operating system. [3] (b) Describe two common scheduling policies. [4] (c) State five methods by which the priority of a job may be determined. [5]

(1 per -, max 3) Page 1 of 1

MK: Section 3.1: The Functions of Operating Systems

Contact: Mr. K. MUDHOO (Tel:7145790)

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

ANSWER - June 2004 P3 Question 5 (a) Maximise the use of the computer system Be fair to all users Provide a reasonable response time to all users Prevent system failure due to overloading Provide consistency to users (1 per point, max 3) (3) (b) First come/first served First to enter ready Q is first to enter running state Favours long jobs Shortest job first Jobs in ready Q are in order, shortest job first Means that jobs are seen to be completed but favours shorter jobs Round Robin Each job given time slice When time slice over, job goes to back of ready Q Shortest remaining time The job that requires the least job to complete is done first Long jobs may never be started Multi-level feedback queues Queues with different priorities Jobs can change Q dependent on amount of time already given (2 per type, max 2 types, max 4) (4) (c) (Each job given separate priority according to:) importance of job/type of job amount of time already waited size of job amount of peripheral time (I/O job high priority) Amount of processor time already given Necessary response time (1 per point, max 5) (5) October/November 2004
3 Describe how memory is managed in a typical modern computer system. Your answer should include an explanation of (i) fragmentation of memory, [3] (ii) paging, [3] (iii) segmentation, [3] (iv) virtual memory. [3]

ANSWER - Nov 2004 P3 3. (i) As jobs and files are loaded into memory they occupy space which when vacated leaves gaps in memory If a larger file is sent to that area and others It has to be broken up to fit This splitting of available memory into discontiguous pieces is called fragmentation (1 per point, max 3) (3) (ii) Memory is divided into regular sized areas called pages Jobs or files are allocated a number of pages according to size of job Pages may be discontinuous
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 2 of 2

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

Index of pages/files kept Addresses can be calculated by adding page address to raw address (1 per point, max 3) (3) (iii) Memory is divided into variable length blocks called segments Jobs or files can consist of many segments, different number each time taken into memory Segments normally match natural divide in jobs Index of segments stored which must Store base address and length of segment (1 per point, max 3) (3) (iv) A whole job does not need to be resident in memory at the same time When a new page is required it is loaded into memory over a redundant page from a reserved area of the hard drive User believes whole job in memory simultaneously Erased page may need to be saved first if it has been altered Use of cache memory Problem of threshing (1 per point, max 3) (3) May/June 2005
5 An organisation manages an intranet. (c) A network operating system (NOS) is used to control the network. Describe (i) transparency, (ii) directory services, (iii) security as components of a NOS. [6]

ANSWER - June 2005 P3 (c) (i) -Users are unaware of the hardware and software -they believe they are the sole users of a standalone -Users are unaware of communications (ii) -Allow users to manage access to their own files -while maintaining lack of access to others. -Maintain directory of software/services -available to specified users. (iii) -Security of files by restricting access -Maintain file of users and their log ins -and their rights. (1 per -, max 2 per dotty, max 6) (6) October/November 2005
5 (a) State the purpose of an interrupt in a computer system. [1] (b) Describe what is meant by a (i) timer interrupt, (ii) hardware interrupt. [4] (c) Define Linkers and loaders

ANSWER - Nov 2005 P3 5 (a) Signal indicating that a device/program requires attention/seeks attention of CPU/processor/OS [1] (b) (i) -Interrupt generated at fixed intervals -to allow for display refresh -to control access to processor in multi access system (ii) -Interrupt generated by request of hardware -(at extreme) to close down safely in the event of power failure -to pass message for servicing request/printer out of paper
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 3 of 3

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

(1 per -, max 2 per dotty, max 4) [4] (c) -Programs may be in modular form (i) -Calculates the address of the individual module -Ensures jump instruction from module to module properly addressed (ii) -Decides whereabouts to place program/modules in memory -Adjusts memory addresses according to where placed -Copies program from store to memory (1 per -, max 4) [4] May/June 2006
9 (a) Explain the meaning of the terms; (i) virtual memory, [2] (ii) paging memory, [2] (iii) segmentation of memory. [2] (b) (i) State what is meant by the term spooling. [2] (ii) Describe the process of sending jobs for printing using a spooler. [3]

ANSWER - June 2006 P3 9 (a) (i) - used when there is not enough memory available - part of the storage is allocated to act as memory - this block is then imported to memory when it is needed - especially used when a piece of software is so big that it will not fit into memory (1 per -, max 2) [2] (ii) - the division of memory into fixed size units - logical pages can then be assigned to any physical page in memory - records of the contents of each page in memory are kept in an index (1 per-, max 2) [2] (iii) - the division of software into logical parts which are of different sizes - individual segments can be present in memory without the need for the whole program to be there - an index is required to store the beginning, size and contents of each segment - leads to fractionalisation of the memory (1 per -, max 2) [2] (b) (i) - temporary storage of - input or output data - on some form of backing storage (1 per -, max 2) [2] (ii) - jobs are stored on backing store - with reference to the job and its location stored on a spool/print queue - the jobs in the spool queue can be prioritized and - the job reference can enter the queue at a position according to its priority (1 per -, max 3) [3] October/November 2006 9 (a) Explain why the operating system, of a multi-access computer system, needs to schedule the processing of jobs. [2] (b) Describe how the operating system manages the throughput of jobs. Your answer should contain references to scheduling, job queues and priorities. [5] ANSWER - Nov 2006 P3 9 (a) -a number of jobs will want to be run at the same time -processor can only run one job at a time -in order that the jobs are treated fairly -the operating system has to have rules to determine the order of execution/make maximum use of resources
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 4 of 4

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

(1 per , max 2) (2)

(b) -order of jobs according to list of priorities -each job allocated priority according to -importance/time already spent on job/need for peripheral devices -jobs can be in any of three states: ready, running or blocked -Ready Q contains list of jobs waiting for processing in the order in which they should be processed -HLS handles ready Q and loads jobs -MLS handles the swapping of data between memory and storage -LLS moves jobs in and out of running state -preemptive scheduler has control over what is in running state, non-preemptive simply follows the Q (1 per -, max 5) (5) May/June 2007 1 (a) Describe the following features of a network operating system. (i) Transparency (ii) Directory services (iii) Security [6] (b) Describe two of the main components of a typical desktop PC operating system. [4]
ANSWER - June 2007 P3

1 (a) (i) - OS controls the hardware in such a way that - the individual does not know that they are using a network - OS hides the communication necessary. (ii) - Storage space partitioned into many logical areas - Storage is allocated to users of the network (by system manager) - OS allows normal file manipulation of a stand alone/examples (search,delete) - Some file areas may be shared (iii) - Different user types given different rights - R/O, other protections on files/data - Passwords and ID to establish identity (1 per -, max 2 per dotty, max 6) [6] October/November 2007 5 (a) State two different types of interrupt and give an example of how each may be generated. [4] (b) Explain the process carried out by the operating system on receipt of an interrupt. [5] ANSWER - Nov 2007 5 (a) I/O interrupt printer out of paper or not connected Timer interrupt processor has used too much time on one process/do something else time share system Hardware power failure/allow I/O interrupt example Software invalid instruction attempted/division by zero (1 per , max 2 pairs, max 4) [4] (b) Present cycle completed Priority of interrupt compared with priority of present task If lower priority then stored in job queue in relevant position for its priority (If higher) then contents of registers stored
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 5 of 5

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

on stack Interrupt routine found and run When complete, next highest priority run Mention/description of vectored interrupts (1 per , max 5) [5] May/June 2008 8 One of the main features of an operating system is the ability to schedule job throughput. (a) Explain the purpose of scheduling job throughput. [2] (b) Describe three scheduling policies which lead to different scheduling algorithms. [6] ANSWER - June 2008 8 (a) -When more than one program resident... -and requiring processing... -the operating system uses scheduling to decide on processing to be done -Allocation of processing... -in a multi-access/multi programming environment -to be fair to all programs/users -to use the peripherals wisely -to prevent system failure -maximise use of processor (1 per -, max 2) [2] (b) -FCFS/first job to enter ready queue is first to enter running queue/favours long jobs -SJF/sort jobs into time expected to run, shortest first/new jobs place in queue in correct order -RR/gives time slice to each job in turn/after slice job returns to back of queue -SRT/jobs sorted according to run time left to do/long jobs may never be done -MLQ/involves a number of queues/jobs migrate through the queues according to importance -PD (peripheral dependency)/non peripheral dependent jobs given low priority (2 per -, max 3-, max 6) [6] October/November 2008 6 Explain how memory is managed in a typical modern computer system. You should use the following as headings for your answer. (i) Paging [3] (ii) Segmentation [3] (iii) Virtual memory [3] ANSWER - October/November 2008 6 (i) Memory divided into fixed sized units IAS is organised into physical pages Jobs/Data are divided into page sized pieces O.S. keeps an index of which jobs/data are in which pages Pages requiring processing need to be in memory Address may be in form of page and distance from start of page (ii) Jobs/Data are divided up into logical amounts each of which is of a different size Memory tends to become fractured leading to compaction of memory being necessary Address complicated by need to calculate from start of segment (iii) Used when not enough space in memory Part of backing store used as though it were memory Contents must be copied to memory to be used Previous contents must be saved first Too much use of virtual memory leads to disk threshing

MK: Section 3.1: The Functions of Operating Systems

Contact: Mr. K. MUDHOO (Tel:7145790)

Page 6 of 6

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

May/June 2009 9 Explain how interrupts are dealt with by a processor and how interrupted jobs may later be resumed. [6] ANSWER - June 2009 9 -Interrupt given a priority -Placed in queue with other interrupts to be done -according to priority. -When it becomes the highest priority interrupt it is dealt with -Contents of special registers are placed on a stack/saved -Interrupt (and others) dealt with -values read from stack into special registers. -Check for interrupt(s) at end of each cycle before fetching next instruction -Vectored interrupts (1 per -, max 6) [6]

October/November 2009 p31 9 (a) A typical desktop PC operating system is a single-user operating system. (i) State what is meant by a single-user operating system. [1] (ii) Describe two components of a typical desktop PC operating system. [4] (b) A network operating system offers other components. Describe the following components of a network operating system: (i) transparency, [2] (ii) directory services. [2]

ANSWER - Nov 2009 p31 9 (a) (i) Only one user has access at a time. [1] (ii) -Application Programming Interface -provides platform to run software -file management -manipulation of files -memory management -paging/virtual memory/scheduling -processor management -interrupt handling/scheduling -I/O management / handles data transfers -between areas of processor/between primary memory and secondary storage. -device drivers / handles data between processor and I/O peripherals -using instructions in device drivers and control of buffers - user interface -a method of communicating with computer/suitable example -Utility software -offers series of software to carry out housekeeping/monitor and maintain and use the hardware. -Security/privacy -will protect data by copying to other media automatically/sets up passwords to restrict access to files. (1 per -, max 2 components, max 4) [4] (b) (i) -O.S. hides the complexities of the system from users. -User believes that their computer is a stand-alone. -User is unaware of sharing resources.
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 7 of 7

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

(1 per -, max 2) [2] (ii) -Sets up files and directories for user. -Allows group access to some files. -Access to files dictated by user I.D.(1 per -, max 2) [2] October/November 2009 p32 8 Explain how scheduling, job queues and priorities are used to manage job throughput. [6] ANSWER - Nov 2009 p32 8 Scheduling is used to provide an algorithm to be followed which... determines the order in which jobs are selected and length of time to be processed. e.g. of scheduling algorithm. Jobs are rated in importance according to... I/O requirements current length of wait (accept any 2 criteria to max of 2). Job importance dictates position in ready Q relative to other ready jobs Job moved from running to blocked state when waiting on peripheral then returned to ready Q May/June 2010 P32 6 (a) Describe the difference between the use of pages and the use of segmentation in managing memory. [2] (b) A job is split by the operating system into a number of pages. At any one time, only some of the pages are in memory. Explain how the operating system keeps track of the different pages and the part played by virtual memory in their movement. [6] ANSWER - June 2010 p32 6 (a) -Pages are fixed size/rely on physical divisions -Segments are variable size/are based on logical divisions (b) -Index of pages is maintained... -If an instruction is to be executed it must be in main memory -When page is completed it can be over-written... -by the next page to be accessed... -which may be stored in virtual memory -which allows faster access than simply from storage -Virtual memory is using backing store to act as memory -Page management table... -used to keep track of where in memory the pages are stored -Pointer to next page May/June 2010 P33 6 (a) A job which is being processed is in one of three states: ready, running or blocked. Explain how the scheduler manages jobs in the processor. [6] (b) State two types of scheduling algorithm. [2] ANSWER - June 2010 P33 6 (a) -Job is moved into ready queue -Position in queue is determined by priority of job (according to rules laid down by the scheduler) -Part of scheduler which loads jobs into ready queue is called the High Level Scheduler (HLS)
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 8 of 8

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

-When currently running job leaves running state the job at top of ready queue is loaded into process and run -This is done by the low level scheduler (LLS) -If a job requires peripheral time it is moved to the blocked state to await servicing -After it has been serviced it must return to the ready queue to await its next turn to use the processor. -The task of moving jobs between the secondary storage and the primary memory is carried out by the medium level scheduler (MLS) (b) -IO and processor bound jobs give priority to IO bound jobs -FCFS -Round robin or time share systems -Shortest job first -Shortest remaining time -Multi level feedback queues October/November 2010 p31 5 (a) Describe two different types of interrupt. [4] (b) Explain how interrupts are dealt with by a processor and how interrupted jobs may later be resumed. [5] ANSWER - Nov 2010 P31 5 (a) -Software interrupt... -e.g. generated by the current program/may need to use printer/... -I/O interrupt... -e.g. Initiated by I/O hardware/user pressed a key/... -Timer interrupt... -e.g. end of time slice -Hardware interrupt... -e.g. power off (b) -current process halted -Interrupt given a priority -Placed in queue with other interrupts to be done... -according to priority -When interrupt reaches top of queue it is processed // highest priority is handled first -Contents of registers placed on stack -values read from stack to registers. October/November 2010 p33 5 Describe how memory is managed in a typical computer system. Your answer should include an explanation of (i) segmentation, (ii) paging, (iii) virtual memory. [9] ANSWER - Nov2010 P33 5 (i) Memory is divided into variable length segments Programs can consist of many segments Segment size is determined according to logical reasons dictated by the program to be executed Segments normally match natural divide in program (ii) Memory/program is divided into fixed sized pages Program is allocated a number of pages according to the size of the program Page size is determined according to physical factors of the way storage is defined
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 9 of 9

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

Pages may be discontiguous Index of pages kept Addresses can be calculated by adding the page address to base address (iii) A whole program does not need to be resident in memory at the same time When a new page is needed it is loaded into memory over a redundant page from a reserved area of storage Part of storage is required to act as though it were memory Use of cache to act as very fast transfer storage between main storage and memory User believes whole program is stored in memory simultaneously Erased page needs to be stored before being overwritten if it has been altered Problem of thrashing mentioned May/June 2011 P31 5 (a) Describe what is meant by the spooling of files.[2] (b) (i) State why files which are sent to a shared printer on a local network will be spooled. (ii) Explain how this spooling is carried out. [5] ANSWER - June2011 P31 5 (a) -Temporarily storing data for output later -several computers can send data to be printed at the same time -when queuing jobs sent to a single device (b) (i) -Jobs can be queued to ensure that none are missed -Stops jobs being frozen/lost when printer unavailable -complete documents are printed (ii) -print jobs are stored on secondary storage -jobs can be given a print priority -jobs are maintained by a queue / priority queue data structure -data structure consists of reference data to each print job -When printer free, job with highest priority / at head of queue is printed -print files are sent from secondary storage to print buffer. May/June 2011 P33 5 (a) Describe what is meant by virtual memory. [2] (b) Describe how segmentation can be used to manage the memory in a typical modern computer system. (You may use a diagram to illustrate your answer.) [5] ANSWER - June 2011 P33 5 (a) -Part of secondary storage // hard disk -allocated to be used as if it were main memory -Contents must be transferred to main memory to be used but -provides high speed input to main memory -Description of problem of disk thrashing // data continually having to be loaded to and from the main memory (b) -Main memory is divided into fixed or variable length blocks called segments -each segment forms a memory partition // each segment is a logical area of memory -program is loaded into an available partition -OS must maintain a list of the used-unused segments / what programs occupy what segments -OS maintains a list of their start address / size -Available segments are matched to the list of jobs waiting to be scheduled (Mark points shown on a diagram to be given full credit)
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 10 of 10

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

Nov 2011 p31 1 Describe the following components of a typical PC operating system and explain how they are used. (a) File allocation table (FAT)[3] (b) Boot file[3] ANSWER NOV 2011 P31 1 (a) -disk space is organised into allocation units (clusters) -FAT is a map of which clusters are used to store which files // Individual sectors on the disk are organised into clusters which are used to store the files -Details where files are stored on backing store -Acts as an index on the hard drive -Shows unused/unusable clusters (1 per -, max 3) [3] (b) -The boot file contains user-defined information... -to tailor the operating system // Contains parameters by which the system will operate -boot file stored on backing store/CMOSRAM... -read/written to by the boot program (held on ROM) (1 per -, max 3) [3] Nov 2011 p32 1 (a) State what is meant by spooling and why it is used.[2] (b) A network of computers has a single printer. Each of the computers can send a job for printing at any time. Explain how a print spooler can be used to control the printing of jobs on the network. [4] ANSWER - Nov 2011 p32 1 (a) -Temporarily storing data -ensures jobs are kept separate (// ensures no jobs are lost) -to compensate for different speeds of operation of devices -when jobs sent to a single device (1 per -, max 2) [2] (b) -Print jobs are stored on central/temporary storage -Reference to job is stored -along with location of print job on the storage medium -Jobs are held in print queue -Jobs may be given a priority -the job at the top of the print queue/ highest priority is the next to be printed(1 per -, max 4) [4] NOV 2011 P33 1 (a) State what is meant by the boot (bootstrap) program.[2] (b) Explain how the boot program is used when a PC is turned on.[4] ANSWER NOV 2011 P33 1 (a) -A short sequence of machine code instructions -Stored in the ROM -available when the power is switched on -Used to load the operating system (1 per -, max 2) [2] (b) -Power-up process places address of first instruction in PC -Carries out the POST (power on self-test) -Uses the user-defined parameters in the boot file to configure the system -Mention of BIOS/autoexec.bat/config.sys -First instruction of OS is loaded into memory and address passed to PC (1 per -, max 4) [4]
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 11 of 11

Reinforcement: Paper 3 relevant CIE 9691 past papers questions.

Mr. K.MUDHOO (Tel: 7145790)

NOV 2011 P31 6 Explain how interrupts are handled by a computer system. [6] ANSWER NOV 2011 P31 6 -Interrupts have a priority -on receipt of an interrupt all interrupts of a lower priority are masked out/refused -Contents of registers are placed on stack -the appropriate interrupt service routine (ISR) is loaded and run -on completion of the ISR - values read from stack and loaded to registers -all interrupts are re-enabled -the interrupted process is resumed -Mention of use of vectored interrupt to point to code that needs to be run. (1 per -, max 6) [6] NOV 2011 P32 6 Explain how scheduling manages job throughput in a computer.[6] ANSWER NOV 2011 P32 6 -scheduling is designed to maximise use of resources -Scheduling uses three states for jobs -ready/runable/Waiting in ready queue -blocked/suspended because they are waiting for resource to become available -running the job being processed -HLS manages which job is the next to be loaded into ready queue -LLS manages which runable job is allocated processor time next -Name of a scheduling algorithm, e.g. round robin, priority queue -with explanation (1 per -, max 6) [6] NOV 2011 P33 8 Explain how the following memory management techniques may be used: (i) Paging (ii) Segmentation [6] ANSWER NOV 2011 P33 8 (I) Paging -memory is divided into equal-sized units called page frames -program/data file is divided into equal-size units called pages -one or more pages may be loaded into memory at any one time -Pages may be discontiguous -Pages swapped in and out as required -pages not in main memory are stored in virtual memory/backing store -page table/Index of pages/processes kept -absolute address is calculated by adding page address to relative address in instruction -paging is transparent to the programmer (II)Segmentation -Memory is divided into variable length blocks -Programs can consist of many segments -Segments normally match natural divide in jobs/logical blocks -Index of segments stored which must -store base address and length of segment -programmer will organise code modules into segments (1 per -, max 4 per dotty, max 6) [6]
MK: Section 3.1: The Functions of Operating Systems Contact: Mr. K. MUDHOO (Tel:7145790)

Page 12 of 12

Vous aimerez peut-être aussi