whitequark changed the topic of #yosys to: Yosys Open SYnthesis Suite: https://github.com/YosysHQ/yosys/ | Channel logs: https://libera.irclog.whitequark.org/yosys/ | Bridged to #yosys:matrix.org
tpb has quit [Remote host closed the connection]
tpb has joined #yosys
skipwich has joined #yosys
skipwich has quit [Remote host closed the connection]
skipwich has joined #yosys
ec has quit [Ping timeout: 260 seconds]
ec has joined #yosys
Stary has quit [Quit: ZNC - http://znc.in]
Stary has joined #yosys
cr1901_ has joined #yosys
cr1901 has quit [Ping timeout: 252 seconds]
FabM has joined #yosys
FabM has quit [Changing host]
FabM has joined #yosys
krispaul has joined #yosys
kristianpaul has quit [Ping timeout: 248 seconds]
lexano has quit [Remote host closed the connection]
lexano has joined #yosys
krispaul has quit [Quit: WeeChat 3.5]
kristianpaul has joined #yosys
FabM has quit [Ping timeout: 276 seconds]
bjorkintosh has quit [Quit: "Every day, computers are making people easier to use." David Temkin]
bjorkintosh has joined #yosys
danderson has joined #yosys
<danderson> Hi! I need to write a sim model for ECP5's DP16KD. Beyond "look at what other FPGA memory sims do and be consistent with those", any docs/styles I should follow to make it a useful contrib to yosys?
<danderson> I _think_ I understand the primitive's behavior enough to take a stab at the model, just wondering if there's any well known gotchas or style rules I should obey.
<lofty> danderson: I think my advice would be to remember you're not writing a simulation model, as paradoxical as that is
<lofty> Yosys will read and parse the sim model from a synthesis point of view, so if you throw in a bunch of simulation-specific things Yosys might just reject the model outright
<danderson> lofty: hm, interesting. That complicates things a bit, because the model requires doing illegal things with clock domain crossing to detect misuses...
<danderson> sounds like that might make yosys quite mad, or trigger incorrect optimizations?
<danderson> I guess I'll start hacking and see how it does. I assume that means I should also not use '?' values to represent states where the hardware says the state is undefined?
<danderson> Sounds like I should print a warning and pick a binary state instead
<lofty> I assume that means I should also not use '?' values to represent states where the hardware says the state is undefined? <-- doing this is entirely okay
<lofty> danderson: ^
<lofty> (although, I assume you mean 'x', and not '?' AKA 'z')
<danderson> er yes sorry, I've been bouncing between languages too much. I mean the state to represent "you maybe just did a metastability, that's bad" :)
<lofty> e.g. the Yosys memory inference code detects conditional x for at least one use case
<danderson> right on. The other thing I'm not sure how to express is async reset and reset release, but my plan there was to look at other models and... generally go learn how to do it.
<danderson> But I understand the internal memory layout and I think I know how to detect the read-write and write-write port conflicts, which I think are the main spicy parts of this primitive.
<danderson> thanks for the wisdom!
ec has quit [Ping timeout: 260 seconds]
so-offish has joined #yosys
nonchip has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
nonchip has joined #yosys
bjorkint0sh has joined #yosys
bjorkintosh has quit [Ping timeout: 260 seconds]