Mid-Term 2 Answers

advertisement
NATIONAL UNIVERSITY OF SINGAPORE
Mid-SEMESTER TEST 2
(Computer Science)
(Semester 2: 2001/2002)
CS1104 – COMPUTER ORGANIZATION
9th April – Time Allowed: 55minutes
MAXIMUM MARKS : 100
_____________________________________________________________________
INSTRUCTIONS TO CANDIDATES
1. This test paper contains FIFTY (50) questions on total TWELVE (12)
printed pages.
2. The distribution of marks is as follows: first 40 questions are of 70 points
and last ten questions are of 30 points.
3. Answer all questions in separate answer form (red color) provided. No
marks will be given for answer at any other place.
4. Write clearly your name and Matric number on this question paper in the
space provided below.
NAME
__________________________________________
MATRIC Number:
1
1. The figure below shows a 1-bit ALU with A, B, and CarryIn as the three inputs. The
operations are selected by E and F.
What is the combination of E, F, and CarryIn (in order) required to output C = A or B.
a) 0, 2,0
b) 0,1,0 Ans
c) 0,1,1
d) 0,0,0
e) 1,1,0
2. Referring to above figure, what is the combination of E, F, and CarryIn (in order)
required to produce output C = A – B
a) 0,2,0
b) 0,1,0
c) 1,1,1
d) 1,2,1 Ans
e) 1,2,0
3. It is known that the propagation delay of AND, OR, XOR and NOT gate is 10 units
and propagation delay for multiplexers is 20 units. The full adder is constructed from
XOR, AND, OR and NOT gate. What is the maximum propagation delay for the above 1bit ALU?
a) 50 units
b) 60 units
c) 70 units Ans
d) 80 units
e) 90 units
2
4. A harddisk rotates its platters at 7200 RPM. The transfer rate is 5MBytes/sec, the
controller overhead is 2ms and the average seek time is 10ms. What is the average time
to read a file of size 100,000 bytes?
a) 56.2 ms
b) 36.2 ms
c) 40.4ms
d) 24.8ms
e) 30.2ms Ans
Consider a 32-byte direct mapped cache with 4-byte block size. The cache is initially
empty. What is the number of hits for the following sequence of byte address references
(in decimal): 0, 32, 0, 5, 4, 32, 35, 36, 4, 5 ?
(a) 1
(b) 2
(c) 3
(c) 4 Ans
(d) 5
5.
6. Suppose L1 hit time = 1 cycle, L1 hit rate = 90%, L2 hit time = 2 cycles, L2 miss
penalty = 50 cycles, L2 hit rate = 90%. What is the average access time of the memory
system?
a) 1.34 cycles
b) 1.58 cycles Ans
c) 2.12 cycles
d) 2.45 cycles
e) 2.80 cycles
7. In MIPS, lw (load) instruction is
a) R-format instruction
b) I-format instruction Ans
c) J-format instruction
8. What is the value of register $s0 at the end of the following code fragment?
addi $s0, $zero, 1
addi $s1, $zero, 2
slt $t0, $s0, $s1
beq $t0, $zero, L1
add $s0, $s0, $s1
j
L2
L1: add $s0, $s0, $t0
L2:
3
(a) 0
(b) 1
(c) 2
(d) 3 Ans
(e) 4
Ans: d
Ans: d
Ans: d
12. Which of the following statements best describes the function of the fourinstruction code fragment below:
slt $t0, $s0, $s1
bne $t0, $zero, L1
slt $t0, $s1, $s0
bne $t0, $zero, L1
(a) if ($s0 == $s1) goto L1
(b) if ( $s0 != $s1) goto L1 Ans
(c) if ( $s0 > $s1) goto L1
(d) if ( $s0 < $s1) goto L1
(e) None of the above
4
13.
Ans: a
Ans: b
Ans: c
5
Ans: a
Ans: b
Ans: 18. a
19. c
20. b
Ans: a
6
Ans: b
Ans: d
Ans: b
For True/False questions: If the answer is True, indicate by choice (a) and if the
answer is False indicate by choice (b)
7
Ans: 25. A
26. A 27. B 28. B 29. B 30. B 31. A 32. B 33. B 34. B 35. A
36. B
8
37.
Ans: d
38.
Ans: d
9
39.
Ans: c
40.
Ans: c
10
Multiple-Response question : In these questions, more than one alternative
could be correct. Marks will be given only if all the alternatives are correct
and not otherwise.
41. From the following list of properties, select those where CRTs are better than
LCDs (e.g. if a CRT is lighter than an LCD, then select “weight”):
a.
b.
c.
d.
e.
42.
Which of the following might be found in LCD displays:
a.
b.
c.
d.
e.
43.
Cost Ans
Weight
Wide viewing angle Ans
Flexible resolution. Ans
Availability of native connectors on PCs. Ans
Polarizers Ans
Electron guns
Phosphors
Cyclotrons
Waveguides
Select all of the reasons why USB cables require shielding:
a.
b.
c.
d.
USB cables must tolerate drastic changes in temperature and humidity.
High speed USB data is sensitive to electromagnetic interference. Ans
High speed USB data is sensitive to light
USB cables must support data from up to 127 devices
44. From the list below select all of the signals that are used for enforcing flow
control.
a.
b.
c.
d.
e.
Device Set Ready/Device Terminal Ready Ans
Transmit/Receive Data
Request to Send/Clear to Send Ans
Ring Indicator
Signal Ground
11
45.
Which of the following statements are true of SCSI?
a.
b.
c.
d.
e.
46.
SCSI buses support multitasking/multithreading Ans
SCSI buses can support up to 4 devices
SCSI devices are not able to heal soft errors
SCSI devices are cheaper than IDE devices
SCSI devices have a maximum cable length of 1.5m. Ans
Which of the following statements are true of IDE?
a. IDE requires more resources like port numbers and interrupt
requests (IRQs) Ans
b. IDE buses can support up to 4 devices Ans
c. IDE drives are better suited for server applications than desktop
applications.
d. You can connect printers and scanners to the IDE bus.
e. IDE devices sharing a single channel must be designated as master
and slave. Ans
47.
If a graphics card can support 6 bits per color channel (Red, Green and Blue)
how many unique shades of colors can it generate?
a.
b.
c.
d.
e.
16.8 million colors
262,144 colors Ans
32,768 colors
256 colors
128 colors
12
48. Using the graphics card in question 7, how large must your video memory be
to support 640 x 480 screen resolution?
a.
b.
c.
d.
e.
Approx 2.5 megabytes
Approx 5 megabytes
Approx 10 megabytes
Approx 12.5 megabytes
None of the above. Ans
49.
Which of the following would NOT be used by a graphics card to generate
images:
a.
b.
c.
d.
e.
50.
a.
b.
c.
d.
e.
Memory
CLUT
TLB Ans
UART Ans
Analogue signals
Which of the following characterize dot-matrix printers?
Can create carbon copies Ans
Can print many pages per minute
Noisy Ans
Cheap operational costs Ans
Requires expensive toner cartridge
13
Download