Skip to content

Commit

Permalink
[rtl] fix gather.
Browse files Browse the repository at this point in the history
  • Loading branch information
qinjun-li committed Nov 12, 2024
1 parent eecf196 commit 8913475
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion t1/src/mask/MaskUnit.scala
Original file line number Diff line number Diff line change
Expand Up @@ -633,6 +633,7 @@ class MaskUnit(parameter: T1Parameter) extends Module {
}

// select execute group
val pipeReadFire: Vec[Bool] = Wire(Vec(parameter.laneNumber, Bool()))
val selectExecuteReq: Seq[ValidIO[MaskUnitReadReq]] = exeReqReg.zipWithIndex.map { case (_, index) =>
val res: ValidIO[MaskUnitReadReq] = WireInit(0.U.asTypeOf(Valid(new MaskUnitReadReq(parameter))))
res.bits.vs := instReg.vs2 + readIssueStageState.vsGrowth(index)
Expand All @@ -649,6 +650,9 @@ class MaskUnit(parameter: T1Parameter) extends Module {
res.valid := true.B
res.bits := readVS1Req
}
pipeReadFire(index) := res.valid && !readVs1Valid && readCrossBar.input(index).ready
} else {
pipeReadFire(index) := res.valid && readCrossBar.input(index).ready
}
res
}
Expand All @@ -666,7 +670,7 @@ class MaskUnit(parameter: T1Parameter) extends Module {
}

// read control register update
val readFire: UInt = VecInit(readCrossBar.input.map(_.fire)).asUInt
val readFire: UInt = pipeReadFire.asUInt
val anyReadFire: Bool = readFire.orR
val readStateUpdate: UInt = readFire | readIssueStageState.groupReadState
val groupReadFinish: Bool = readStateUpdate === readIssueStageState.needRead
Expand Down

0 comments on commit 8913475

Please sign in to comment.