Sample Question Paper for 9210-123 Graduate Diploma in Engineering
Transcription
Sample Question Paper for 9210-123 Graduate Diploma in Engineering
Sample Question Paper for 9210-123 Graduate Diploma in Engineering Computer architecture and operating systems Duration: three hours You should have the following for this examination • one answer book • non-programmable calculator • pen, pencil, drawing instruments General instructions • This paper consists of nine questions. • Answer any five questions. • A non-programmable electronic calculator may be used but candidates must show sufficient steps to justify their answers. • Drawings should be clear, in good proportion and in pencil. Do not use red ink. • All questions carry equal marks. The maximum marks for each section within a question are shown. 1 a) b) c) d) What are the main operations involved in a C program compilation? What is meant by platform dependence in a C program execution? What is the special feature of a cross-compiler? Given that ASCII values of characters A=>65, a => 97, b => 98 and ! =>33, evaluate the outputs of the following C program. (5 marks) (5 marks) (5 marks) (5 marks) #include <stdio.h> void main(){ char c = 'A'; char cc = '!'; printf ("%c \n", c); printf ("%d \n", c); printf ("%c \n", c + 32); printf ("%c \n", c + cc); printf ("%x", cc); return; } 2 a) b) c) d) 3 4 a) b) c) d) The Cycles Per Instruction (CPI) and Instructions Per Cycle (IPC) are popular metrics used to describe computer performance. What is the meaning of CPI and IPC? A given program consists of 120 instructions that when executed, loops 40 times. i) If the system takes 16,000 clock cycles to complete the program, what are the CPI and IPC values of the system? ii) If the system clock operates at 2 GHz rate, calculate the time taken to complete the program. Describe the number of bits used in IEEE single precision floating-point number representation with internal organisation details. Represent -1.75 in IEEE short real binary form (with labelled regions). What is meant by the stored program concept in computers? What is the major drawback of Von Neumann architecture? Briefly describe the memory organisation in Harvard Architecture. Describe the operation of the following addressing modes with suitable examples. i) Direct addressing. ii) Register addressing. iii) Immediate addressing. There are a number of levels in a computer, from the user level down to the transistor level. a) Describe different levels in a computer system between user programs and transistor level by using a diagram. b) Define the following terms. i) Response time. ii) Throughput. iii) CPU time. iv) Elapsed time. c) Describe the use of Benchmark programs in computer system designing. d) Define Amdahl’s Law of computer performance. e) In two computers, the following performance factors were listed: (4 marks) (4 marks) (4 marks) (4 marks) (4 marks) (5 marks) (3 marks) (3 marks) (3 marks) (3 marks) (3 marks) (4 marks) (4 marks) (4 marks) (4 marks) Machine A: clock 1ns, CPI 2.0, for program x Machine B: clock 2ns, CPI 1.2, for program x Which computer is faster and by how much? 2 (4 marks) 5 a) b) c) d) e) 6 7 a) d) a) b) c) d) 9 a) b) c) d) (2 marks) (3 marks) Registers, magnetic disk, CD-ROM, cache, main memory, USB flash drive, magnetic tape, CD-RW, DVD-RW, Storage Area Network (SAN). (6 marks) What are the significant features of common computer memory hierarchy? (Describe by using different levels of the hierarchy). Describe three main types of buses in a computer system? (6 marks) (3 marks) The computer memory characteristics will depend on location, capacity, unit of transfer, access method, performance, physical type, physical characteristics and organisation. a) Describe three memory access methods with examples. b) Describe the following terms. i) Access time. ii) Memory cycle time. iii) Transfer rate. c) In a two level computer memory, derive an expression for the average memory access time? Define each term that you use. d) Suppose a processor has two levels of memory. Level 1 contains 1000 words and has access time of 0.01 µs. Level 2 contains 100000 words and has access time of 0.1 µs. Level 1 can be directly accessed. If it is in Level 2, then words are first transferred into level 1 and then accessed by the processor. What is the average memory access time if 95% of the memory accesses are found in Level 1? b) c) 8 What is meant by disk cache? Describe the use of the disk cache. Classify the following memory types into the categories of inboard memory, outboard memory and off-line storage. What is meant by ‘temporal coherence’ and ‘spatial coherence’ with respect to the program execution? What is the main objective of using ‘pipeline’ techniques in processor design? When comparing a non-pipelined processor with a pipelined processor, which one has the higher instruction latency? Give reasons for your answer. An un-pipelined processor has an instruction cycle time of 25 ns. i) What is the cycle time of a processor with 5 evenly divided pipeline stages, if each pipeline latch has a latency of 1 ns? ii) Explain the situation if the processor is divided into 50 pipeline stages? What is the key feature of a multi-programmed batch system compared to a uni-programming system? Describe the characteristics of a time-sharing system. Describe a process in the context of an operating system. Describe the design techniques of paged virtual memory? Describe the methods used by an operating system to provide information protection and security. What are the factors considered by an operating system in scheduling and resource management? What is meant by a ‘deadlock’ in the context of a multi-programming operating system? Describe three necessary conditions for a ‘deadlock’. 3 (6 marks) (3 marks) (5 marks) (6 marks) (4 marks) (4 marks) (5 marks) (4 marks) (3 marks) (4 marks) (6 marks) (4 marks) (6 marks) (6 marks) (4 marks) (4 marks) (6 marks)