Sunday, 2019-12-22

*** tpb has joined #yosys00:00
*** rohitksingh has joined #yosys00:13
*** dys has quit IRC00:35
*** emeb has quit IRC00:46
*** rohitksingh has quit IRC01:29
*** rohitksingh has joined #yosys01:56
tux3My LUT usage goes up 600% if I move my AXI clk from the interface declaration to the modport... that doesn't seem right02:54
ZipCPUEvenin tux302:54
tux3Hello!02:54
ZipCPUI'm not sure I follow your question ... can you share the two options you are coding?02:54
ZipCPUIs Yosys now supporting interfaces?02:56
tux3Sortof, kinda!02:56
tux3I get warnings that every wire of the interface is undefined in every module, but it synthetizes just fine02:57
tux3That's a different story though =]02:57
tux3Essentially, I have this AXI4 Lite bus in my toy softcore. It was declared as "interface axi(input aclk, input aresetn);"02:57
ZipCPUDid it build into something useful?02:57
tux3Normally, yes. The module support seems to be hanging on by a thread, but as far as I can tell if all the stars align it works02:58
tux3s/module/interface/02:58
tux3But actually, I'd like to reset that bus from one of the modports deep into the hierarchy, instead of where it's declared in the top module. Right? So I moved the aclk and aresetn in the master modport.02:58
tux3After reducing the code a little, if I move the "assign bus.clk=clk" between my top module or a submodule, it goes from using 130 LUTs to 83003:00
ZipCPUYeah ... that sounds like something's not working03:01
ZipCPUYou aren't supposed to be able to assign to something in a submodule, such as assign bus.clk=clk03:01
ZipCPUIt's  supposed to go the other way, busclk = bus.clk03:02
ZipCPUBut that's with dot notation into submodules, not interfaces03:02
ZipCPUMy point is simply that ... I don't think the standard supports it, and above that I'm not sure Yosys even fully supports the SV standard that defines those functions03:03
tux3Hhhm not sure I understand. (Apologies if I'm a little slow, it's pretty late in my timezone!)03:03
ZipCPUYeah ... getting late here03:03
ZipCPUThe "dot" notation is supposed to only be used for unsynthesizable constructs--simulation test benches, formal properties, etc03:03
tux3What I meant is I'm writing to my bus from the master side, through the master modport. The other side reads through its modport. I declare the appropriate signals as input/output and it all works — as long as there's no clk03:04
ZipCPUThat doesn't sound like it works then03:04
*** citypw has joined #yosys03:04
tux3I was convinced modports were synthetizable, though I can understand SV features are pretty hit and miss in general...03:04
ZipCPUNo clock?  What is it building that doesn't have a clock, and how do you even know its building the right thing?03:04
tux3So. The clk comes from the declaration in the top module "axi4lite sys_bus(.aclk(clk), .aresetn(!rst));"03:05
tux3And then, I pass for example "sys_bus.master" to a submodule03:05
tux3And the read side to another module03:05
tux3Then they can talk to each other through their modports03:05
ZipCPUAh, okay ... go on03:05
tux3Now, I tried moving aclk/aresetn to the master modport, because it turns out I'd like the master to be in control or the reset.03:06
tux3That blew up when I moved the clk.03:06
tux3Maybe I should stick to boring old Verilog 2005 features, I guess I am asking for trouble =]03:07
ZipCPUHave you tried using the yosys "show" command on a simple design as a way of seeing what yosys is up to with the design you've given it?03:07
tux3Nope. Not sure I'd be able to interpret the results to be entirely honest. I glanced at the routed results in the GUI, it looks like the read side of my bus is completely failing to meet timing and routed really poorly, but I don't really understand what's going on03:08
tux3(This is probably the point where I should admit that I'm a software person and I have very little clue what I'm doing!)03:08
ZipCPUSee ... that's me when I chat with clifford, "I don't know what's going on.  Clifford then says, "Let's take a look" and the first thing he does is simplify the design, then he uses the "show" command to visualize it03:09
ZipCPUI've been surprised more than once at his ability to simplify a concept down to 5-10 lines of Verilog03:09
ZipCPUThe graph then tends to make a lot of sense as we examine what's going on03:10
tux3That sounds like a good plan. I wonder if there's something like creduce for verilog.03:11
tux3I'll see if I can boil it down to a few lines tomorrow. Thanks for the help03:12
ZipCPU;)03:14
*** rohitksingh has quit IRC03:16
ZipCPUtux3: Out of curiosity ... what hardware are you using, and why are you using AXI at all?03:27
tux3I only have a tinyfpga BX right now, but I'm trying to pretend verilog is a portable language and retargetting my code to Xiling series 7 down the line will go Just Fine03:29
ZipCPUI just ask because AXI is a rather heavy-weight protocol03:30
ZipCPUOn a TinyFPGA, you're probably going to want to make every LUT count03:30
ZipCPUThere are ... cheaper protocols than AXI03:30
ZipCPU(faster ones too)03:30
tux3Well, it's AXI4-Lite and I'm implementing the bare minimum, but I'm actually trying really hard to exhaust the resources of my BX so I have an excuse to buy something bigger =]03:31
tux3I really just need a vaguely standard 64bit interface. Wishbone looked like a good alternative. Is there something else I could have used?03:32
ZipCPUA 64-bit interface?  AXI4-Lite is restricted to 32-bits only03:35
ZipCPUI'm personally very biased towards Wishbone (b4, pipelined), and I use it in everything I do03:36
ZipCPUIt's cheaper, and tends to be faster than AXI03:36
ZipCPUAre you building a slave or a master?03:36
ZipCPUAre you building a single AXI4-Lite component, or a system containing many?03:36
tux3Both03:37
tux3Right now I really just have a quad-spi flash reader on the reader side (so not exactly taking full advantage of the 64bit bandwidth!)03:38
tux3And the master is my ifetch03:38
tux3If I ever get to using a board with some kind of DDR, the plan is to plug that on the other side of the bus and not have to change any part of my core03:39
tux3I was going to go with axi4-lite for everything memory since that's the one I studied first and I don't really know any better, but I'm very open to suggestions =] !03:40
tux3Does the wishbone handshake roughly look like axi or is it something completely different?03:40
ZipCPUIt's simpler03:40
ZipCPUThe Valid/Ready request handshake is roughly the same when making a request, but there's only one request channel--not three03:41
ZipCPUThere's also no stalling on the acknowledgment channel, and the write data doesn't need to be synchronized with the write address03:41
ZipCPUSo, in AXI, you'd do ... if (AxVALID & AxREADY).  In WB, this becomes if (i_wb_stb && !o_wb_stall)03:42
ZipCPUIn AXI, you have to very carefully synchronize the AW* channel with the W* channel.  In WB, if i_wb_stb && i_wb_we, it's a write request03:43
ZipCPUThe write data is in i_wb_data, and the byte select lines in i_wb_sel03:43
ZipCPUThe addresses are similar, save that AXI's addresses are octet addressed (w/ useless LSBs) whereas WB's are word addressed03:43
*** attie has joined #yosys03:43
tux3Word addresses as in bus width?03:44
tux3(No unaligned reads?)03:44
ZipCPUNo unaligned reads.  Everything is the width of the bus03:44
tux3Hhm. That's a tradeoff, I can see how it'd make the slave side a lot simpler, but it might push some complexity into the master side03:45
ZipCPUSuch as ... ?03:45
ZipCPUAs far as I can tell, it just removes complexity03:45
ZipCPUFor example, AXI slaves have to worry about setting AxREADY low when xREADY and xVALID have been high for more backpressure than the slave can handle03:47
ZipCPUHowever, in many Xilinx configurations, Xilinx guarantees that the xREADY lines are always high03:47
ZipCPUSo that's a lot of excess slave logic you need to have that you aren't using03:48
*** attie has quit IRC03:48
tux3Yeah, it's a bit of a pain, I'll grant you that!03:48
ZipCPUOf course, if you change the Xilinx IP config, all of this changes03:48
*** klotz has quit IRC03:49
tux3However I do like that axi can expose the full capabilities of my slave side without having to emulate it right on the critical path in my core. Even though, to be fair, things like misaligned reads are pretty rare in practice03:50
ZipCPUWhat full capabilities does AXI expose?03:50
tux3Well, for example I was gawking at sifive's core designer recently03:50
ZipCPUGo on03:51
tux3(Not that I have any ambition of ever getting anywhere near what they're doing, of course)03:51
tux3They can happily swap out their bus data width between 32/64/128 AXI, and I don't think they need a whole lot of additional logic on the master side because of how flexible the bus is03:51
tux3AXI allows some pretty crazy requests03:52
ZipCPUI'll admit, AXI makes adjusting bus width easier, but that capability is lost in AXI-lite once you drop the AxSIZE field03:52
tux3That's fair03:53
tux3You probably know more about this than I do, too =]03:53
sorearthey’re not doing that in Verilog03:53
ZipCPUWe should continue this discussion later.  I'm struggling to keep my eyes open ;)03:53
tux3Yeah03:53
ZipCPUsorear: How are they then doing it?  In VHDL?  ;)03:54
sorearProbably https://github.com/chipsalliance/rocket-chip/blob/master/src/main/scala/tilelink/ToAXI4.scala03:54
tpbTitle: rocket-chip/ToAXI4.scala at master · chipsalliance/rocket-chip · GitHub (at github.com)03:54
ZipCPUChisel?  or Scala?  Okay, I'll believe that.  SiFive tends to use TileLink over AXI too.  That's another discussion to have on another day03:55
*** rohitksingh has joined #yosys04:22
*** noname_Matt has quit IRC04:25
*** pie_ has joined #yosys06:12
*** citypw has quit IRC06:48
*** Jybz has joined #yosys06:49
*** citypw has joined #yosys07:01
*** emeb_mac has quit IRC07:07
*** citypw has quit IRC07:09
*** citypw has joined #yosys07:11
*** vidbina has joined #yosys08:33
*** voxadam has joined #yosys10:46
*** attie has joined #yosys11:45
*** attie has quit IRC11:49
*** vidbina has quit IRC12:08
*** dys has joined #yosys12:54
*** rombik_su has joined #yosys13:21
*** vidbina has joined #yosys13:35
*** rohitksingh has quit IRC13:37
*** vidbina has quit IRC14:59
*** lutsabound has joined #yosys15:07
develonepi3 Hello all Does nextpnr depend on arachne-pnr chipdb*.bin files?15:24
tntit needs the chip db from icestorm. Doesn't need anything from arachne.15:26
tnt(so the icebox/chipdb-*.txt)15:27
develonepi3tnt When was chipdb-u4k added?15:28
develonepi3tnt What program creates chipdb-*.bin files?15:29
tntwhich ones ... both nextpnr and arachne have chipdb-* files and they're different ...15:30
tnteach set are created by helpers scripts in the compilation phase of each project.15:30
tnt(from the icebox text chipdb)15:31
tntNot sure when the u4k support was added ... last summer or so ...15:31
tntyou'd have to check the commit logs15:31
develonepi3tnt I have both arachne-pnr & nextpnr installed.  Only see bin files /usr/local/share/arachne-pnr.15:32
tntnextpnr doesn't install the .bin file by default. Instead they are "baked-in" the binary directly.15:33
*** citypw has quit IRC15:40
develonepi3tnt In your version of nextpnr, is --package required?  I am testing the latest ver of nextpnr on a rpi4-64 bit.15:41
tntyes15:42
*** citypw has joined #yosys15:56
*** vidbina has joined #yosys16:24
*** _whitelogger has quit IRC16:49
*** _whitelogger has joined #yosys16:51
*** Forty-Bot has quit IRC16:51
*** emeb has joined #yosys16:59
*** vidbina has quit IRC17:24
*** fsasm has joined #yosys17:58
*** adjtm has quit IRC19:23
*** dys has quit IRC19:25
*** attie has joined #yosys19:46
*** attie has quit IRC19:51
*** X-Scale has quit IRC20:28
*** X-Scale` has joined #yosys20:31
*** rombik_su has quit IRC20:39
*** emeb_mac has joined #yosys20:42
*** adjtm has joined #yosys20:53
*** fsasm has quit IRC21:18
*** lutsabound has quit IRC21:26
*** lutsabound has joined #yosys22:28
develonepi3Hello all I just pushed, to "https://github.com/develone/meta-yosys-tools/blob/master/doc-recipes/milestone.txt" and slides on a video "Containers in the embedded world" by Jeremy Rosen at youtube "https://www.youtube.com/watch?v=0S2Qow1IcQA", which might be useful for cross compiling with docker.  It appears that mmicko is using docker for his cross commpiling.22:41
*** emeb has quit IRC23:48
*** rohitksingh has joined #yosys23:59

Generated by irclog2html.py 2.13.1 by Marius Gedminas - find it at mg.pov.lt!