kleinai on dev
Implement addRunFlag(), needed … Merge pull request #1028 from l… (compare)
Dolu1990 on dev
Fix StateFsm API change (compare)
def streamReadSyncRegistered[T2 <: Data](cmd: Stream[UInt], linkedData: T2, crossClock:Boolean = false) : Stream[ReadRetLinked[T,T2]] = {
val ret = Stream(new ReadRetLinked(mem.wordType, linkedData))
val retData = mem.readSync(cmd.payload, cmd.ready, clockCrossing = crossClock)
val retLinked = RegNextWhen(linkedData, cmd.ready)
cmd.ready := ret.ready
ret.valid := RegNext(RegNext(cmd.valid))
ret.value := RegNext(retData)
ret.linked := RegNext(retLinked)
ret
}
i cannot for the life of me figure out how to remove the bubble from this extension to Mem.scala.
BRAM requires an additional register stage to be absorbed for better timing in Xilinx devices, so RegNext(retData) should work, but then the handshake logic breaks
always@(posedge clk) begin
ram_out <= ram[addra];
dout <= ram_out;
end
val haltIt = Bool()
val cmdHalted = cmd.haltWhen(haltIt).toFlow
val rsp = mem.flowReadSync(cmdHalted).toStream.queueLowLatency(size=2)
haltIt := rsp.isStall()
So I have like
main/
|--foo
| |--fooComp.scala
| |--fooSim.scala
|
|--bar
|--fooComp.scala
|--fooSim.scala
in the the comp and sims are in different packages (also with the package statement at the head of the file). when I run the bar/fooSim it creates simWorkspace/fooComp, after that I run foo/fooSim and it overwrites the simWorkspace/fooComp from what I saw