[Moore][Sim][SV] Add $strobe[boh] lowering via sim.defer#10556
Conversation
Implement the SV `\$strobe[boh]`system tasks. - Add `moore.builtin.strobe` op in the Moore dialect to represent `$strobe[boh] - Add `sim.defer`op in the Sim dialect: a procedural region who schedules its body in the postponed region. Underlying primitive for `$strobe`, `$fstrobe`, `$monitor`, and VHDL postponed processes. - Add `StrobeBIOpConverion` in MooreTocore lowering. - Add `sv.strobe` op to SV dialect, analogous to `sv.write` and wire it in SVVisitors.h and ExportVerilog to emit `$strove(...)` - Extend `lowerPrintFormattedProcToSV`in SimToSV to detect `sim.proc.print` inside `sim.defer`, and emit `sv.strobe`. - Add tests for each stage of the pipeline.
|
Thanks @VecoMr. Unfortunately, I think the lowering of In simulation this will produce So, the increment that is happening within Update: |
Implement the SV
$strobe[boh]system tasks.moore.builtin.strobeop in the Moore dialect to represent$strobe[boh].sim.deferop in the Sim dialect: a procedural region who schedules its body in the postponed region. Underlying primitive for$strobe,$fstrobe,$monitor, and VHDL postponed processes.StrobeBIOpConverionin MooreTocore lowering.sv.strobeop to SV dialect, analogous tosv.writeand wire it in SVVisitors.h and ExportVerilog to emit$strobe(...)lowerPrintFormattedProcToSVin SimToSV to detectsim.proc.printinsidesim.defer, and emitsv.strobe.