Professional Documents
Culture Documents
Bài tập Kiến trúc máy tính
Bài tập Kiến trúc máy tính
Lớp : ĐT8-K52
SHSV : 20072908
Ex. 47. Pipelining and Bypass. In this question we will explore how bypassing affects
program execution performance. To begin consider the standard MIPS 5 stage pipeline.
For your reference, refer to the figure below. For this question, we will use the following
code to evaluate the pipeline’s performance:
2 lw $t1, $t1, 0
5 lw $t1, $t1, 0
e) Identify whether the value for each register operand is coming from the bypass or
from the register file for the modified pipeline. For clarity, please write REG or BYPASS
in each box.
f) How long does the program take to execute on the modified pipeline?
Bài làm
1
Ta có minh họa cấu trúc pipeline MIPS 5 giai đoạn
Theo phần d , giả sử dây nối từ MEM quay ngược lại EX bị bỏ đi nên số chu kì dừng lại
sau khi thực hiện lệnh load phải là 2 chu kì thì mới không xảy ra xung đột dữ liệu
2
e. Xác định giá trị mỗi toán hạng thanh ghi được lấy từ sự chuyển tiếp dữ liệu hay từ
thanh ghi để pipeline thay đổi
Lệnh 1 cần 5 chu kì, các lệnh sau mỗi lệnh cần thêm 1 chu kì để thực hiện
Sau khi thực hiện lệnh Load cần phải dừng 2 chu kì để tránh xảy ra xung đột