Pipeline Processor · Computer Organization and Architecture
53 questions · asked in 25 of 27 years (2000–2026)
MCQ 29 · MSQ 2 · NAT 221-mark 23 · 2-mark 30
2000Questions per year2026
Questions 1–5 of 53
Which one of the following dependencies among the register operands of different instructions can cause a data hazard in a pipelined processor?
Answer: (B)
A data hazard happens when an instruction needs the result of a nearby instruction that is still not finished in the pipeline.
- Read-after-Write (RAW): a later instruction reads a register before an earlier instruction has written the new value. This is a true (flow) dependency. It causes a real data hazard in a pipeline.
- Write-after-Read (WAR) and Write-after-Write (WAW) are anti-dependency and output-dependency. They cause hazards only in pipelines that allow out-of-order completion. A simple in-order pipeline does not have them.
- Read-after-Read is not a dependency. Two reads never conflict.
Answer: Read-after-write
- Read-after-Write (RAW): a later instruction reads a register before an earlier instruction has written the new value. This is a true (flow) dependency. It causes a real data hazard in a pipeline.
- Write-after-Read (WAR) and Write-after-Write (WAW) are anti-dependency and output-dependency. They cause hazards only in pipelines that allow out-of-order completion. A simple in-order pipeline does not have them.
- Read-after-Read is not a dependency. Two reads never conflict.
Answer: Read-after-write
The EX stage of a pipelined processor performs the memory read operations for LOAD instructions, and the operations for the arithmetic and logic instructions. Let denote the time taken by the EX stage to perform the operation for an instruction. For each instruction type, the values of and (the number of instructions of that type in a sequence of instructions for a program P ), are given in the table below.
The duration of the pipeline clock cycle is nanosecond. Assume that the latch time for the interstage buffers in the pipeline is negligible.
When program is executed, the number of clock cycles for which the pipeline is stalled due to structural hazards in the EX stage is ________. (answer in integer)
The duration of the pipeline clock cycle is nanosecond. Assume that the latch time for the interstage buffers in the pipeline is negligible.
When program is executed, the number of clock cycles for which the pipeline is stalled due to structural hazards in the EX stage is ________. (answer in integer)
Answer: 95
The EX stage has one shared functional unit. Only one instruction can be in the EX stage in a clock cycle (cycle time ns). Suppose the real execution time is more than ns. Then the instruction stays in the EX stage for clock cycles. This gives stall cycles from structural hazard, for each instruction of that type.
Total stall cycles: .
Answer: 95
Total stall cycles: .
Answer: 95
A non-pipelined instruction execution unit that operates at GHz clock takes an average of clock cycles to complete the execution of an instruction. To improve the performance, the system was pipelined with a goal of achieving an average throughput of one instruction per clock cycle. However, it could operate only at GHz due to pipeline overheads. While executing a program in the pipelined design, of instructions encountered a stall of cycles due to pipeline hazards. The speed-up obtained by the pipelined design over the non-pipelined one for this program is ________(rounded off to two decimal places)
Note:
Note:
Answer: 2.3 to 2.4
Non-pipelined design: the time for one instruction ns.
Pipelined design: the cycle time ns. The ideal CPI is . But of the instructions get a stall of cycles.
So the average CPI cycles per instruction.
The average time for one instruction in the pipelined design ns.
The speedup .
Answer: 2.34
Pipelined design: the cycle time ns. The ideal CPI is . But of the instructions get a stall of cycles.
So the average CPI cycles per instruction.
The average time for one instruction in the pipelined design ns.
The speedup .
Answer: 2.34
A 5-stage instruction pipeline has stage delays of 180, 250, 150, 170, and 250, respectively, in nanoseconds. The delay of an inter-stage latch is 10 nanoseconds. Assume that there are no pipeline stalls due to branches and other hazards. The time taken to process 1000 instructions in microseconds is __________ . (rounded off to two decimal places)
Answer: 260.2 to 261.2
In a -stage pipeline, one clock cycle must be long enough for the slowest stage plus the inter-stage latch delay. So each cycle takes ns.
The total time to run instructions in a pipeline takes cycles. Here is the number of pipeline stages, and this counts the first fill of the pipeline. So the time is ns, which s.
Answer: 261.04
The total time to run instructions in a pipeline takes cycles. Here is the number of pipeline stages, and this counts the first fill of the pipeline. So the time is ns, which s.
Answer: 261.04
An application executes number of instructions in 6.3 seconds. There are four types of instructions, the details of which are given in the table. The duration of a clock cycle in nanoseconds is _________. (rounded off to one decimal place)
Answer: 3
Find the total number of clock cycles :
cycles.
The duration of one clock cycle ns.
Answer: 3
cycles.
The duration of one clock cycle ns.
Answer: 3
Keep practising