From 989eeb78f9cd56dfd8679e1749b0444da889e8ed Mon Sep 17 00:00:00 2001 From: Andrew Waterman Date: Mon, 6 Nov 2017 11:04:06 -0800 Subject: [PATCH] Prevent some unnecessary pipeline replays --- src/main/scala/rocket/IBuf.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/scala/rocket/IBuf.scala b/src/main/scala/rocket/IBuf.scala index b24002de..d43e0590 100644 --- a/src/main/scala/rocket/IBuf.scala +++ b/src/main/scala/rocket/IBuf.scala @@ -60,9 +60,9 @@ class IBuf(implicit p: Parameters) extends CoreModule { buf := io.imem.bits buf.data := shiftInsnRight(io.imem.bits.data, shamt)(n*coreInstBits-1,0) buf.pc := io.imem.bits.pc & ~pcWordMask | (io.imem.bits.pc + (nICReady << log2Ceil(coreInstBytes))) & pcWordMask - ibufBTBHit := io.imem.bits.btb.valid + ibufBTBHit := io.imem.bits.btb.valid && io.imem.bits.btb.bits.bridx >= shamt ibufBTBResp := io.imem.bits.btb.bits - ibufBTBResp.bridx := io.imem.bits.btb.bits.bridx + nICReady + ibufBTBResp.bridx := io.imem.bits.btb.bits.bridx - shamt } } when (io.kill) {