





Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Briefly answer the following questions: a) What is the difference between computer architecture and computer organization? b) What are the two locality ...
Typology: Study notes
1 / 9
This page cannot be seen from the preview
Don't miss anything!






1. Tomasulo’s algorithm
Consider the following MIPS code: Label: L.D. F2, 10(R2) SUB.D F2, F2, F MUL.D F6, F0, F ADD.D F0, F2, F SUB1 R2, R2, 100 BEQZ R2, Label Show the execution of single issue Tomasulo algorithm in the form of status tables for the above code sequence for two iterations of the above loop. Assume the following:
Show the status table (similar to the one in the text book) with three stages: Issue, Execute and Write Result.
3. Performance: For the same program, two different compilers are used. The table below shows the execution time of the two different compiled programs. Compiler A Compiler B
Program 1 1.00 E+09 1s 1.20 E+09 1.4s Program 2 1.00 E+09 0.8s 1.20 E+09 0.7s
a) Find the average CPI for each program given that the processor has a clock cycle time of 1ns. b) Assume the average CPIs found in part (a), but that the compiled programs run on two different processors. If the execution times on the two processors are the same, how much faster is the clock of the processor running compiler A’s code versus the clock of the processor running compiler B’s code? c) A new compiler is developed that uses only 600 million instructions and has an average CPI of 1.1. What is the speed-up of using this new compiler versus using Compiler A or B on the original processor of part (a)?
4. Briefly answer the following questions: a) What is the difference between computer architecture and computer organization? b) What are the two locality principles observed with respect to user programs? How are these principles exploited in computer design? c) What is virtual memory? Explain the need for virtual memory. d) What are the main differences between a multi-processor system and a multi-computer system? e) In a shared memory system, explain two schemes to maintain cache-coherence.
6. Cache Mapping: A computer system has a 128 byte cache. It uses four-way set-associative mapping with 8 bytes in each block. The physical address size is 32 bits, and the smallest addressable unit is 1 byte. a) Draw a diagram showing the organization of the cache and indicating how physical addresses are related to cache addresses. b) To what block frames of the cache can the address 000010AF 16 be assigned? c) If the addresses 000010AF 16 and FFFF7A xy 16 can be simultaneously assigned to the same cache set, what values can the address digits x and y have?
7. Assembly Programming:
Consider a hypothetical machine called SIC, for Single Instruction Computer. As its name implies, SIC has only one instruction: subtract and branch if negative, or sbn for short. The sbn instruction has three operands, each consisting of the address of a word in memory:
sbn a, b, c, #Mem[a] = Mem[a] – Mem[b]; if (Mem[a] < 0) go to c
The instruction will subtract the number in memory location b from the number in location a and place the result back in a, overwriting the previous value. If the result is greater than or equal to 0, the computer will take its instruction just after the current instruction. If the result is less than 0, the next instruction is taken from memory location c. SIC has no registers and no instructions other than sbn.
(a) Identify what the following does: start: sbn temp, temp, .+ sbn temp, a, .+ sbn b, b, .+ sbn b, temp, .+ In the above program .+1 means “the address after this one.”
(b) Write a SIC program to add a and b, leaving the result in a and leaving b unmodified.