CS152 Review--Complex Pipelining

1.This problem deals with an out-of-order single-issue processor that is based on the basic RISC-V pipeline and has a floating-point unit. The FPU has one adder, one multiplier, and one load/store unit. The adder has a two-cycle latency and is fully pipelined. The multiplier has a six-cycle latency and is fully pipelined. Assume thatstores take one cycle and loads take two cycles.

There are 31 integer registers (x1-x32) and 32 floating-point registers (f0-f31). To maximize number of instructions that can be in the pipeline, register renaming is used. The decode stage can add up to one instruction per cycle to the re-order buffer (ROB). The CPU uses a data-in-ROB design, so there is one rename register associated with each ROB entry. Functional units write back to the ROB upon completion. The functional units share a single write port to the ROB. In the case of a write-back conflict, the older instruction writes back first. The instructions are committed in order and only one instruction may be committed per cycle. The earliest time an instruction can be committed is one cycle after write back.

Floating-point instructions (including loads writing floating-point registers) must spend one cycle in the write-back stage before theirresult can be used. Integer results are available for bypass the nextcycle after issue and write back two cycles after issue.

For the following questions, we will evaluate the performance of the code segment below.

SequenceInstruction
I 1 I_1 I1FLD f1,0(x1)
I 2 I_2 I2FMUL.D f2,f1,f0
I 3 I_3 I3FADD.D f3,f2,f0
I 4 I_4 I4ADDI x1,x1,8
I 5 I_5 I5FLD f1,0(x1)
I 6 I_6 I6FMUL.D f2,f1,f1
I 7 I_7 I7FADD.D f2,f2,f3

(a)For this part, consider an ideal case where we have an unlimited number of ROB entries.
In the table below, fill in the cycle number for when each instruction enters the ROB, issues, writes back, and commits.Also, fill in the new register names for each instruction, where applicable. (10 points)
Since we have an infinite supply of register names, you should use a new register name for each register that is written (p0, p1, … ). Keep in mind that after a register has been renamed, subsequent instructions that refer to that register must refer to the new register name.
在这里插入图片描述
Answer:
在这里插入图片描述

评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值