1 Department of Electrical Engineering McGill University ECSE 221 ...

Report 2 Downloads 83 Views
Department of Electrical Engineering McGill University ECSE 221 Introduction to Computer Engineering I Final Examination Friday, April 30th, 2004 Examiner:

2:00pm

Prof. F.P. Ferrie

Associate Examiner: Prof. T. Arbel Instructions: Answer ALL questions in the examination booklet provided, showing all of your work. Calculators are permitted, but they must be the Faculty standard. All questions are equally weighted. Question 1 a) A graphics card for a PC can display an image with a maximum resolution of 1280 x 1024 pixels with 24 million color possibilities for each pixel. How much memory does this graphics card require to operate at this maximum resolution? Express your answer in bytes. [2 points] b) An IEEE-like floating representation is to be designed for a computer with a 48-bit register size. Determine the smallest mantissa field size capable of supporting 11 decimal digits of precision. [2 points] c) Using the result you obtained in Part b, encode the number 3.51x10-16 using this 48-bit floating point scheme. (If you are unsure of your answer, you may encode the number using IEEE-754, but with a 1 point penalty). [4 points] d) Determine the minimal canonical forms corresponding to the following sum of products form: ∑ (2,3,4,6,8,12,14) . [2 points] A,B ,C ,D

Question 2 € a) A single-bit full adder produces outputs ∑i and ci+1 from inputs ai, bi, and ci. Show how this device can be implemented using two 4-input multiplexers and a single inverter. [2 points] b) Produce the next state equations, state transition table, and timing diagram for the circuit shown at the top of the next page (you may ignore delays). You may assume that the circuit has been initially cleared to (Q1=0, Q0=0), and all state transitions must be shown. [4 points]

1

Q1 M

+5V

D

S

Q

C R Q

D

S

Q0

Q

C R Q

Clr' Clk

c) The combinational logic in the above circuit is to be replaced by read only memory (ROM). Determine the number of address and data lines required and the ROM contents. [2 points] d) Determine the maximum frequency of operation of the above circuit for each of the two implementations (combinational logic, ROM) assuming the following parameters: Tsu(FF) = 1nS, Th(FF) 0.5nS, Tpd(FF) 2nS, Tpd (XOR) = 0.75nS, Tpd(XNOR) = 0.5nS, Ta(ROM) = 5nS. [2 points] Question 3 a) Translate the following “C” function into MIPS assembly language. You must strictly adhere to conventions with respect to context save and restore. Function arguments must be passed on the stack. [4 points] void to_lower(char *string) { while(*string != 0) { if (*string >= ‘A’ && *string