Wednesday, 2021-06-02

*** richbridger has joined #yosys00:22
*** aquijoule_ has quit IRC00:24
*** stroboko1p has joined #yosys01:26
*** strobokopp has quit IRC01:29
*** nak has quit IRC01:58
*** nak has joined #yosys02:11
*** freemint has quit IRC03:23
*** yay has joined #yosys04:43
*** yay has quit IRC04:46
*** chipdsgr has quit IRC05:52
*** chipdsgr has joined #yosys05:58
*** FabM has joined #yosys06:24
*** _whitelogger has quit IRC06:51
*** _whitelogger has joined #yosys06:52
gatecatcr1901: there were scripts for some of the lists in it, but https://github.com/YosysHQ/icestorm/blob/master/icebox/iceboxdb.py is the main autogenerated part06:52
*** cr1901 has quit IRC07:47
*** cr1901 has joined #yosys07:47
*** Guest7213 has joined #yosys10:42
tntERROR: FF cpu.$auto$simplemap.cc:495:simplemap_dffsre$10047 (type $_DFFSRE_PPPP_) cannot be legalized: dffs with async set and reset are not supported ...10:53
tnt:/ I mean why generate it in the first place. I would have expected a async reset FF and a mux to 0 merged in the preceding lut.10:54
gatecatwhat code is this coming from ?10:55
tntVex10:55
tntThat's a verilog I originally gnerated for the ice40 (and that works fine there) and I was trying to reuse the same on ecp5.10:55
gatecathuh, strange it's hitting a different code path between the two10:56
gatecatneither support those kinds of DFFs10:56
tntMmm ... I only tried on the ice40 before I updated my toolchain yesterday.  Maybe it's broken now ...10:56
tntOh ... it crashes on ice40 too both on old & new toolchain, but only when I try to synth it "alone".  If I synth the full project, then it works fine.10:59
tntThat's the exact file btw : https://github.com/smunaut/ice40-playground/blob/master/projects/riscv_doom/rtl/VexRiscv.v11:02
tntI was just trying yosys -p 'synth_ecp5' VexRiscv.v to get a quick idea of resources.11:03
mwktnt: the problem here is like 430511:15
mwk      IBusCachedPlugin_fetchPc_pcReg <= externalResetVector;11:16
mwkthis one is *bad*11:16
mwkbecause it's in an async reset block, and externalResetVector is a signal, not a constant11:16
mwkso what we'd technically need to do here is synthesize a FF with async load11:16
mwkwhich is not actually supported yet, but an early pass will convert it to a FF with async set + reset wired appropriately to the externalResetVector anded with reset11:17
mwkif you use it as part of larger thing, the external reset vector is presumably wired to a const, which is why yosys is able to optimize the crazy reset structure into a plain async reset with a single value11:18
mwkI'd say this is a vexriscv bug, as it's asking for a FF that cannot be reasonably provided by most FPGA targets11:21
mwkabout emulation: yes, you can try to emulate the unsupported FF type with lots of async logic, but we cannot in good conscience do it in yosys when there's no support in the toolchain for ensuring that whatever we emit is race-free / glitch-free, then remains so in P&R11:24
tntmwk: Ah, I see. Yeah, externalResetVector is pretty much tied to constant in all instanciations, I'm not sure if chisell can generate verilog params.11:29
tntThanks for the explanation, makes more sense to me now. Somehow I had read the error as having async set and sync reset being an issue, not sure how I got that in my head.11:30
mwkah11:31
mwkyeah, sync resets are emulated without complaint whenever not supported11:31
mwkasync resets are... argh11:32
tntHeh yeah. I use them on the ice40 because of the CE affecting the sync reset line on the ice40 causing longer path than needed if both CE and sync reset/set are used.11:32
mwklet's just say I have already implemented some async reset emulation via simpler async reset FFs patterns, for "feature parity" with a certain cursed vendor synth tool11:33
mwkbut it cannot make something out of nothing11:33
*** eater has joined #yosys12:20
*** freemint has joined #yosys13:22
*** freemint has quit IRC13:49
*** freemint has joined #yosys13:50
*** strobokopp has joined #yosys14:45
*** stroboko1p has quit IRC14:45
*** FabM has quit IRC14:56

Generated by irclog2html.py 2.17.2 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!