2/7/03 4:24 PM
Activity #07 (Solution)
Activity 7.1
The single-cycle MIPS architecture
For the reduced set of MIPS instructions cfw_lw, sw, add, sub, and, or, slt, beq, answer the following questions: a. (5 points) What minimum set of functions must the A

3/2/03 9:36 PM
Homework #06 (Solution)
1. (15 points) Consider the following code on the pipelined data path of Figure 6.46 on p. 492: subi $6, $7, 50 sub $7, $4, $6 sw $4, 220($6) add $6, $4, $3 sub $3, $2, $1 In what cycle(s) is the register $6 read or

3/26/03 5:44 AM
Homework #07 (Solution)
3/26/2003 5:44 AM
1. (15 points) Problem 6.23 from the text (the worst ordering will have two stalls). lw $3, 0($5) add $7, $7, $3 #requires stall on #3 lw $4, 4($5) add $8 $8, $4 #requires stall on $4 add $10, $7,

Activity #02 (due beginning of next class)
Last Name First Name Student ID Number
2.1 50 points
2.2 50 points
Total 100 points
Grader Initials
Activity 2.1 (First hour)
A. (50 points) Consider a simple CPU with just the instructions listed below
Instructi

3/14/03 2:52 PM
Activity #14 (Solution)
3/14/2003 2:52 PM
Activity 14.1
Cache organization
We consider a cache for a computer with 24-bit byte addresses. The cache holds 8 Kbytes of data. Please calculate the information needed to fill the following table

Homework #11 (Solution)
4/15/2003 9:44 PM
Process scheduling
1. (10 points) What is the handicap of priority scheduling, and what is the solution for it? Lower priority processes gets postponed indefinitely. So, priority scheduling may cause lower priorit

Homework #08 (Solution)
3/25/2003 12:00 PM
Memory Configurations
1. (15 points) Do question 7.11 in P&H text. Assume that it takes one clock cycle to send the address to the main memory. The miss penalty is the time to transfer one block from main memory

Homework #09 (Solution)
3/28/2003 3:24 AM
Working Set
1. (30 points) The following lists represent the page references for two processes, P1, and P2. For each time interval, calculate the size of the working set (WS) of each process for window sizes (W) o

Homework #10 (Solution)
4/11/2003 8:54 AM
This homework requires use of a UNIX computer. If you havent used one of these before, stoop by the VCC help desk, and pickup some of the handouts on UNIX basics. There is also information available online. Finall

Homework #12 (Solution)
4/29/2003 8:20 AM
Semaphores
1. Consider the following two concurrent processes: Process 1: P1; Signal(Sem); P2; P3; Signal(Sem); Wait(Sem); P4; Process 2: Wait(Sem); P5; Wait(Sem); P6; P7; Signal(Sem); P8;
Assume that the value of

Last Name
Activity #01 (solutions)
First Name
Student ID Number
1.1 50 points
1.2 50 points
Total 100 points
Grader Initials
Morning Session Evening Session
Activity 1.1 (First hour)
A. (5 points) Administrative matters
1. (3 points) Click on course sylla

Activity #15 Solution
1. Cache Organization (60 points) We consider a cache for a computer with 32-bit byte
addresses. The cache holds 256 Kbytes of data. Please calculate the information needed to
fill the following table. The cache is direct mapped and

1/24/03 5:28 PM
Activity #03 (solutions)
Last Name First Name Student ID Number Email Address
3.1 50 points
3.2 50 points
Total 100 points
Grader Initials
Activity 3.1 (First hour)
A. The current machine, codenamed Jaguar, has a clock rate of 500MHz. The

2/21/03 10:04 PM
Homework #05 (Solution)
1. (10 points) P&H Q6.1. The cycle time would be 10 ns in the single-cycle implementation. For the pipelined implementation it would be 4ns. The speedup obtained from pipelining the single-cycle implementation woul

2/16/03 3:11 PM
Homework #04 (Solution)
1. Study Appendix B.5 and answer the following questions. Assume that the register file in Figure B.18 has 64 32-bit registers. a. (21 points) Write down the width (in number of bits) purpose of each of the followin

2/7/03 4:23 PM
Homework #03 (Solution)
Binary arithmetic and floating-point representation 1a. (4 points) What is the smallest and largest unsigned numbers that can be represented using 16-bits? 0 and 65,535 Grading: 2pts for each correct number, 1pt for

2/3/03 10:00 AM
Homework #02 (solution)
Last Name First Name Student ID Number Email
1 40
2 20
3 40
Total 100
Graders Initials Morning afternoon
Browse the SPEC site!
1. Point your web browser to the following web site: http:/www.specbench.org a. (5 point

1/24/03 5:33 PM
Homework #01 Solution (Individual work, due Friday 01-24-03)
Last Name First Name Student ID Number
1 20
2 15
3 10
4 5
5 20
6 10
7 10
8 10
Total 100
Graders Initials
A. Review of pre-requisite material
1a. (5 points) Express the following

2/22/02 9:16 PM
SOLUTION In-Class Activity #11
Activity 11.11 Forwarding (50 points)
Consider the execution of the following instructions on the pipelined MIPS. Fill in the table to determine the appropriate actions of the Forwarding Unit. There are usefu

2/22/02 10:03 PM
SOLUTION Activity #10
Activity 10.1
Pipeline registers
(50) Consider the example of Figures 6.11 6.18 (beginning p. 451). a. In Clock Cycle (CC) 3, what operation does the ALU perform, where does it get its operands, and where are the res

2/22/02 10:02 PM
SOLUTION Activity #09
Activity 9.1
Finite state machine control for the datapath
(40 pts, 5 each part) Consider the state diagram of Figure 5.42, p. 396. a. List the states traversed for instruction subu $s1, $s2, $s3: 0, 1, 6, 7.
Grading

1/29/03 9:49 AM
Activity #04 (solutions)
Last Name First Name Student ID Number email
4.1 50 points
4.2 50 points
Total 100 points
Grader Initials
Activity 4.1 (First hour)
1. (10 points) Translate the C statement a = (2*b + c) to MIPS code. Assume that a

2/3/03 10:03 AM
Activity #05 (solutions)
Activity 5.1 (First hour)
Learning to go from MIPS Assembler Pseudo code C Program
1. (25 points) Describe what the following MIPS code returns in the output register $v0. Assume that $a0 is used for the input and

2/4/03 5:32 PM
Activity #06 (Solution)
Activity 6.1 (first hour)
Binary Arithmetic
1. (10 points) Show the following decimal numbers in signed 8-bit and 16-bit hex format: 8-bit 16-bit +92 5C 005C -92 A4 FFA4
Grading: 2pts off for each wrong value 2. (10

Activity #16 Solution
1. (40 points) Consider a virtual memory system with the following properties:
30-bit virtual byte address
64 KB pages
20-bit physical byte address
Show your calculations for each part.
1.a. (10 points) What is the size of a frame (i

Activity #21 (Solution)
4/11/2003 5:03 PM
Activity 21.1
Process scheduling
Consider the following set of processes. Process CPU Burst Time (ms) Arrival Time (ms) P1 9 0 P2 3 1 P3 1 4 P4 2 7 P5 6 15 a. (20 points) Draw two schedule charts1 showing the exec

In-Class Activity #20 (Solution)
4/9/2003 12:04 PM
Activity 20.1 Inter-process communication
a. How is a pipe implemented? The two processes share a FIFO (first-in, first-out) buffer. b. What would happen if a pipe were implemented using a LIFO (last in,

Activity #19 (Solution)
4/1/2003 5:31 AM
Activity 19.1
OS Structure, System Calls
1. (5 points) What is the main advantage of layered approach to OS design? The main advantage of the layered approach is modularity. By selecting the layers so that they onl

Activity #18 (Solution)
3/28/2003 3:24 AM
Activity 18.1
Operating system concepts
1. The following C-like code is to be executed. The code takes integer values from user until the user enters a negative value, and then it outputs the average of the entere

Activity #17 (Solution)
3/25/2003 11:09 PM
Activity 17.1
I/O service
1. Consider a processor with a 750MHz clock rate, and a hard disk that transfers data in 16 byte chunks with a transfer rate of 12 MB/sec. 1a. (10 points) Assume the processor uses polli