Skip to content

Commit

Permalink
[ipemu] fux dpi call init to X issue
Browse files Browse the repository at this point in the history
  • Loading branch information
FanShupei committed Jul 27, 2024
1 parent ce52e16 commit 841ffe4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ipemu/src/TestBench.scala
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,11 @@ class TestBench(generator: SerializableModuleGenerator[T1, T1Parameter]) extends
outstanding := outstanding + (doIssue && (issue.meta === 1.U)) - dut.response.valid
fence := Mux(doIssue, issue.meta === 2.U, fence && !dut.response.valid && !(outstanding === 0.U))

issue := RawClockedNonVoidFunctionCall("issue_vector_instruction", new Issue)(
// RawClockedNonVoidFunctionCall result is initialized to X, hack it to zero
issue := Mux(RegNext(true.B, false.B), RawClockedNonVoidFunctionCall("issue_vector_instruction", new Issue)(
clock,
doIssue,
)
), 0.U.asTypeOf(new Issue))
dut.request.bits.instruction := issue.instruction
dut.request.bits.src1Data := issue.src1Data
dut.request.bits.src2Data := issue.src2Data
Expand Down

0 comments on commit 841ffe4

Please sign in to comment.