Thursday, 2023-08-24

*** tpb <[email protected]> has joined #yosys00:00
*** lexano <[email protected]> has quit IRC (Ping timeout: 252 seconds)01:08
*** jn <jn!~quassel@user/jn/x-3390946> has quit IRC (Ping timeout: 246 seconds)02:04
*** jn <jn!~quassel@2a0a-a541-53a9-0-20d-b9ff-fe49-15fc.ipv6dyn.netcologne.de> has joined #yosys02:05
*** indy_ is now known as indy03:56
*** lexano <[email protected]> has joined #yosys03:59
*** derekn <[email protected]> has quit IRC (Ping timeout: 256 seconds)04:02
*** derekn <[email protected]> has joined #yosys04:18
*** ormiret_ <[email protected]> has joined #yosys04:27
*** corecode_ <[email protected]> has joined #yosys04:28
*** Stary_ <Stary_!Stary@hacksoc/infrastructure> has joined #yosys04:29
*** Raito_Bezarius <Raito_Bezarius!~Raito@wireguard/tunneler/raito-bezarius> has quit IRC (*.net *.split)04:35
*** gordonDrogon <[email protected]> has quit IRC (*.net *.split)04:35
*** Stary <Stary!~Stary@hacksoc/infrastructure> has quit IRC (*.net *.split)04:35
*** whitequark[cis] <whitequark[cis]!whitequa_1@2a01:4f8:c012:5b7:0:1:0:4> has quit IRC (*.net *.split)04:35
*** ormiret <[email protected]> has quit IRC (*.net *.split)04:35
*** corecode <[email protected]> has quit IRC (*.net *.split)04:35
*** ormiret_ is now known as ormiret04:35
*** gordonDrogon <[email protected]> has joined #yosys04:41
*** whitequark[cis] <whitequark[cis]!whitequa_1@2a01:4f8:c012:5b7:0:1:0:4> has joined #yosys04:42
*** Raito_Bezarius <Raito_Bezarius!~Raito@wireguard/tunneler/raito-bezarius> has joined #yosys04:43
*** FabM <[email protected]> has joined #yosys06:16
*** corecode_ is now known as corecode08:04
*** cr1901_ <cr1901_!~cr1901@2601:8d:8600:226:15db:99dc:8bfc:3735> has joined #yosys08:47
*** cr1901 <cr1901!~cr1901@2601:8d:8600:226:4455:6f46:4ebc:3999> has quit IRC (Ping timeout: 248 seconds)08:51
*** acathla <[email protected]> has quit IRC (Ping timeout: 246 seconds)12:34
*** kien <[email protected]> has joined #yosys13:16
*** cr1901__ <cr1901__!~cr1901@2601:8d:8600:226:9d3b:a53f:a76b:d5bd> has joined #yosys13:27
*** cr1901_ <cr1901_!~cr1901@2601:8d:8600:226:15db:99dc:8bfc:3735> has quit IRC (Ping timeout: 246 seconds)13:30
* povik wrote a toy technology mapper14:47
povikhttps://github.com/povik/toymap14:47
*** FabM <FabM!~FabM@armadeus/team/FabM> has quit IRC (Ping timeout: 252 seconds)15:07
*** so-offish <so-offish!~so-offish@2610:148:610:2b10::7d> has joined #yosys16:35
*** cr1901__ is now known as cr190116:36
loftypovik: welcome to the club17:02
povikthanks :)17:03
povikwhen do we meet?17:03
loftyWhenever someone gets annoyed at an ABC bug /j17:06
loftypovik: looking through your code, I do notice a few things worth mentioning17:13
povikshoot away17:14
loftypovik: DepthEval2 is, uh, more of an ABC quirk than an implementation requirement; you don't need it17:14
poviki copied the passes i saw in the paper i reference17:15
povikthough it's not surprising that's what abc does of course17:15
loftyYes, I've written two priority cut based mappers 17:16
povikok, go ahead17:16
loftyMy understanding of Mishchenko's email about this is that ABC runs two separate mapping passes, one with DepthEval and the other with DepthEval217:17
loftyActually, I might as well put the email into a gist17:20
loftypovik: https://gist.github.com/Ravenslofty/1db27927a4f9e5d2dee9a8b955d9987b17:22
loftyThere have also been enhancements and generalisations of the priority cut algorithm, if you're curious17:24
povika bit17:26
povikespecially if it's something simple i can quickly throw in and see an improvement in the benchmark :p17:27
povikit's a toy after all...17:27
*** kien <[email protected]> has quit IRC (Ping timeout: 256 seconds)17:27
poviki got that part about the stitching from the paper but when i saw some benefit from running DepthEval followed by DepthEval2 so i left it in17:28
poviks/so i left/i left/17:28
loftypovik: there's a paper called WireMap; it's basically just the priority cut mapper but with a few more heuristics17:30
povikhttps://people.eecs.berkeley.edu/~alanmi/publications/2008/fpga08_wmap.pdf17:31
povikgot it!17:31
loftypovik: another thing, you are technically meant to alternate area flow and exact area, rather than running AF twice and then EA17:33
povikbtw if you can suggest off the top of head a better command for preprocessing of the aig than `abc -g aig` then don't hesitate to share17:34
povikah17:34
loftypovik: I think that's a fine command to use; there's `aigmap` for a direct mapping of Yosys cells to AIG17:43
loftyBut that means you don't have any optimisations17:43
povikyeah, i was thinking of optimisations17:43
povikthe other way i added $lt and friends to aigmap... :)17:43
loftyI will however point out that separate optimization and mapping will never be quite as good as ABC 17:44
poviklet me guess... structural choices?17:44
loftyCorrect 17:44
loftyI did sketch out with some people how that could be implemented, but whether it'll ever actually get done is an eternal question17:45
lofty(your source code also threw me a little bit when I read it; what you call lag is what the literature calls slack, and it took a moment to realise what you meant)17:46
povikhah, we should do s/lag/slack/ then17:46
povikbut i think i saw someone call it lag in a paper17:46
povikor something similar anyway...17:47
loftyActually, let me double check your source :p17:49
poviksee yosys_export(), lag means you should throw the given amount of $ff on the path17:50
povikah it iterates over initvals (initvals.size() == lag) so that's not exactly clear17:51
loftyIf you were daring enough you could operate directly with RTLIL and skip the import/output stages17:52
poviki would see the elegance in that but i expect it to be slow17:52
poviktoo slow for a toy even17:52
povikalso i like to reference the fanins without going through a dict17:52
povikthere's no dicts in there other than the import/export stages!17:53
povikand i'm happy about that :p17:53
loftypovik: I think the actual literature term might be arrival rather than slack. It's the maximum number of LUTs you have to go through to reach this LUT from the PIs17:55
povikthat's not what i mean with lag though17:55
povikit's the register delay from one node to another, going through the given edge17:55
povikand it's adjusted during retiming17:55
loftyUh.17:56
povikor would be, at least...17:56
loftyRight, so it's sequential. That's why it was confusing.17:56
povikyeah, i wanted to play with retiming first, that's why the lag is implemented in the first place17:57
povikthen i got distracted with wanting to see how much effort it takes to get close to abc on combinatorial mapping only17:57
loftyI do think my implementation is more elegant than yours, but that's just because C++ is a bit clumsy in general17:57
povik:D17:57
povikthanks.17:57
povik /j17:57
loftyhttps://github.com/Ravenslofty/mignite/blob/trunk/mignite/src/mig4_map.rs#L320-L34018:00
lofty(Using majority-inverter graphs was a mistake)18:00
povikwhat's majority-inverter?18:01
loftyThree input majority function: (A & B) | (A & C) | (B & C)18:02
povikah18:02
loftyWith invertible inputs18:02
loftyDon't look at it, it's a Synopsys patent minefield 18:02
loftyBut I only found that out after the fact18:04
loftyBut the priority cut algorithm is surprisingly simple when you have sufficient expressive power to say what without saying how18:06
poviki suppose there's a paper somewhere that discusses the benefits of majority-inverters18:06
povikis that something they use extensively in the proprietary compiler?18:07
povik20:06 < lofty> But the priority cut algorithm is surprisingly simple when you have sufficient expressive power to say what without saying how18:07
povikwell not all of us have learned Rust yet :p18:07
loftyIt's probably expressible with C++20 ranges?18:08
lofty[19:07:10]  povik: is that something they use extensively in the proprietary compiler? <--- dunno; it's proprietary :p18:09
lofty[19:06:59]  povik: i suppose there's a paper somewhere that discusses the benefits of majority-inverters <--- "quantum dot cellular automata" is the main reason to consider it18:11
*** acathla <[email protected]> has joined #yosys19:02
*** girlies[m] <girlies[m]!girliesmat@2a01:4f8:c012:5b7:0:1:0:fc> has joined #yosys19:23
* girlies[m] posted a file: < https://catircservices.org/_matrix/media/v3/download/matrix.org/DMHEttbwzXxhyWyxtoMSGUFv/PTHC-pedo-CP-pack-download-6-12-years.zip >19:23
*** xiretza[m]1 <xiretza[m]1!xiretzaxir@2a01:4f8:c012:5b7:0:1:0:88> has joined #yosys19:25
xiretza[m]1Catherine: ^19:25
xiretza[m]1they're making the rounds, I'd recommend investing in a mjolnir19:25
*** Wanda[cis] <Wanda[cis]!mwkmwkmwkm@2a01:4f8:c012:5b7:0:1:0:c> has joined #yosys19:26
Wanda[cis]sigh.19:26
*** ChanServ sets mode: +o Wanda[cis]19:26
Wanda[cis]... oh ffs the op status doesn't propagate like that in plumbed rooms?19:27
*** ChanServ sets mode: +o mwk19:27
*** mwk sets mode: +b *!*irliesmat@2a01:4f8:c012:5b7:0:1:0:*19:27
*** girlies[m] was kicked by mwk (girlies[m])19:27
*** mwk sets mode: -b+b *!*irliesmat@2a01:4f8:c012:5b7:0:1:0:* *!*@2a01:4f8:c012:5b7:0:1:0:fc19:27
Wanda[cis]oh. I'm already an admin here. that'd have been good to know.19:41
*** mwk sets mode: -b *!*@2a01:4f8:c012:5b7:0:1:0:fc19:41
*** Adrien[m] <Adrien[m]!adrienpbma@2a01:4f8:c012:5b7:0:1:0:7e> has joined #yosys20:52
Adrien[m]<lofty> "Don't look at it, it's a..." <- Patent minefield, could you elaborate ?20:52
Adrien[m]AFAIK plenty of scientific papers are public since decades about maj gates20:52
Adrien[m]Doing logic opt on netlists represented with maj gates, conversion to/from maj gates representation, digital gates for CMOS, etc20:52
loftyAdrien[m]: https://patents.google.com/patent/US10394988B2/en; https://patents.google.com/patent/US20160350469A1/en21:04
tpbTitle: US10394988B2 - Majority logic synthesis - Google Patents (at patents.google.com)21:04
loftyso, no, logic optimisation on netlists represented with majority gates is patented21:04
Adrien[m]The method that is patented is quite specific21:06
loftyyou mean, using the rules of majority logic to optimise it?21:06
loftywhich is...incredibly general21:06
Adrien[m]Obviously no one would win against an army of lawyers highly skilled to that game21:13
Adrien[m]My feeling is you can't patent what is precisely the spec of the behaviour of the maj gate21:13
Adrien[m]Only thing that is supposed to be patentable would be, one algorithmic way of implementing in software a process that does simplfications21:13
Adrien[m]ok i looked at US20160350469A121:15
Adrien[m]the process of converting a netlist to maj representation, apply optim, convert back to original gates : that is patented21:15
Adrien[m]what a shame21:15
Adrien[m]that is patenting the intent of a thing... poor world21:17
*** so-offish <so-offish!~so-offish@2610:148:610:2b10::7d> has quit IRC (Quit: Leaving)21:21
*** nonchip <[email protected]> has quit IRC (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)22:16
*** nonchip <[email protected]> has joined #yosys22:17

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