Closed shunshou closed 5 years ago
In rocket-chip we've created a black box for asynchronous reset flops. Looking forward to parameterized black boxes so we can at least not have to wrap every single one...
Agree that we need this. I think there were already some open threads on it. My preference is to be able to state the reset methodology on hierarchical basis, not (just) per-register.
Agreed with @mwachs5 -- which suggests that it should be part of the solution to #205.
Is this not something that can be added as a FIRRTL pass right before Verilog emission? You'd be able to do it maybe @ the per-register level or module, etc. level (Transform granularity). Seems like doing it as a parameterized black box is a little overkill...
It's just adding some lines in the section of the Verilog code that deals w/ registering?
The parameterized black box is definitely a temporary workaround and not at all the desired solution.
Actually, what's the reason we can't just use something like asyncinit in Chisel? You just need to bring it down to the template for registering stuff and add an if before the posedge clk stuff...
Doesn't work with C++ testing, but should be perfectly acceptable with Verilator?
@aswaterman does that construct exist in Chisel3 now? I actually use enables a lot in my code... never bothered to formalize it.
Not yet... as with async reset, the main problem is finding the best API. The nuts and bolts are easy.
I'm not sure what #205 has to do with this... is that what you really meant?
Typo, I meant #206
I revived parameterized blackbox support, it's in Firrtl now so is about ready for Chisel primetime
So, how's this coming along...?
It's the next item on @jackkoenig's docket!
On Thursday, December 15, 2016, Richard Lin notifications@github.com wrote:
So, how's this coming along...?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ucb-bar/chisel3/issues/343#issuecomment-267438779, or mute the thread https://github.com/notifications/unsubscribe-auth/AA-7wv0zoNE9zl_MIu-2bPw7MpuSENuxks5rIaaIgaJpZM4KioUd .
poke
Resolution: make any API-level changes in 3.0.0 (like using a reset type), the actual implementation can be delayed until later.
Hi, does it mean with Chisel, we cannot have asynchronous reset FlipFlop at this moment?
Async reset isn't available as a Chisel construct (yet). A workaround is to black box it: wrap an async reset flip flop in a Verilog module, and instantiate that module in your Chisel code.
We discussed this at the dev meeting two weeks back.
The resolution was to add reset types (with an async reset type) to FIRRTL, where defregs would emit different based on the reset type. Casts could convert between relevant types.
Detailed discussion notes:
Next action items: someone needs to write an RFC. @jackkoenig @azidar ?
If someone's putting together a Reset RFC could #938 be considered in it as well?
Front-end wise we could/should do both - for most flip-flops the reset might not explicitly matter so we can use the type approach to determine reset type, while certain circuits (e.g. async FIFO) may require AsyncReset registers regardless of the global reset type.
For anyone reaching this page via a search engine, this has been supported since Chisel 3.2.
Is there a methodology to support asynchronous reset? Just got feedback that companies doing ASICs only use asynchronous resets for power on resets of control logic state machines. I'd also really like to be able to use it for some more mixed-signal-y things.