From 10b5a0006c0f9bc168eca70fe13b37162f10e45d Mon Sep 17 00:00:00 2001 From: Andrew Waterman Date: Wed, 8 Feb 2012 20:11:57 -0800 Subject: [PATCH] fix mul/div to rd=0 --- rocket/src/main/scala/ctrl.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rocket/src/main/scala/ctrl.scala b/rocket/src/main/scala/ctrl.scala index d4b323b3..f3f236bb 100644 --- a/rocket/src/main/scala/ctrl.scala +++ b/rocket/src/main/scala/ctrl.scala @@ -334,8 +334,8 @@ class rocketCtrl extends Component otherwise { ex_reg_br_type <== id_br_type; ex_reg_btb_hit <== id_reg_btb_hit; - ex_reg_div_val <== id_div_val.toBool; - ex_reg_mul_val <== id_mul_val.toBool; + ex_reg_div_val <== id_div_val.toBool && id_waddr != UFix(0); + ex_reg_mul_val <== id_mul_val.toBool && id_waddr != UFix(0); ex_reg_mem_val <== id_mem_val.toBool; ex_reg_wen <== id_wen.toBool && id_waddr != UFix(0); ex_reg_fp_wen <== fpdec.io.wen;