Wednesday, 2021-08-18

VeeraLuke ping...15:52
*** Veera_ is now known as Veera15:59
lkclVeera: hi16:15
lkclnicely done with the SVG images btw16:15
lkcli'm just doing a screenshot of some corrections, each line "in" (including its colour) has to have a corresponding line out16:24
lkcldon't put actual lines *through* the boxes like i am putting in the screenshot though! :)16:25
lkclthey are just for illustrative purposes16:25
*** Veera_ is now known as Veera16:37
*** Veera_ is now known as Veera16:44
VeeraLuke: Did you read last my post about nlnet milestone entry in Bugzilla17:45
lkclVeera, yes.17:50
VeeraDo those works come under NlNet.Wishbone17:50
lkclyes, under the documentation bug #38417:52
lkclthe budgets are probably not up-to-date now, i have to run the budget-sync program to check them all17:52
lkcli assumed you'd be happy with another EUR 300 task btw :)17:52
lkclquite a lot for you now, almost Eur 1,000 at a guess. which is good because less gets wasted on bank transfer fees17:53
lkclthe symbiflow one was... hell to install, to be honest17:53
lkcltook me a day17:53
lkclbut i did it17:53
VeeraAbout the images I uploaded to website, are they correct after your advise17:54
lkcli will do a "dpkg list" on the chroot i used, and also a list of pip3 pages17:54
lkclyes, they're great17:54
VeeraSorry my net connection is very bad17:57
lkclVeera: no problem, mine is not reliable either.  for IRC, try registering with bnc4you. they maintain a free-access IRC proxy-relay17:59
mikolajwhello again17:59
lkclmikolajw, hi17:59
VeeraI will try17:59
lkclVeera, bnc4you is quite a pain to set up but there is a #bnc4you channel on libera, they are really helpful and responsive18:00
Veeralkcl: what to do with symbiflow?18:00
lkclwrite a dev-env-setup script for it18:01
lkclbut not installing conda18:01
lkcland preeeferably not relying too heavily on pip3.18:01
lkcl_definitely_ not installing conda, but manually installing each dependency18:01
VeeraI want some money now. So will try symbiflow in next round18:02
lkcli'm uploading the list of debian packages that ended up being installed in the schroot i created18:02
lkcland for pip318:02
lkclok that sounds perfectly reasonable.18:02
lkclcan you do the last image of #651 quickly?18:03
lkclthat completes that one 100%18:03
Veerayes definetly18:03
lkclok fantastic.18:03
lkclyes, the symbiflow one is quite complex18:03
Veerathese nlnet donation have a time period. Where to find their deadline?18:04
lkclit's been extended (by at least 2 years)18:04
Veeramean till 202318:05
lkclyes, at least18:08
VeeraIs it good to switch system to Bullseye as it is released?18:10
lkclno it is not.18:10
lkclnot for the chroots, at least18:10
Veeraok (not for chroots)18:10
lkcli don't recommend upgrading in case something breaks18:11
lkclbut, if it does18:11
lkclthen (sigh) you can set up a debian/10 schroot18:11
lkclthen put all the schroots under that (!!)18:11
* lkcl doh18:11
programmerjakeanother alternative to bnc4you is to use matrix (what I use), libera runs a matrix bridge18:11
ghostmansd-pclkcl: I've been looking at execute1.vhdl for quite a while now... do we have an VHDL intro anywhere?18:12
lkclprogrammerjake: except then he's tied to a permanent internet connection18:12
lkclwhich is already very unreliable for him.18:12
lkclghostmansd-pc: honestly i just did google searches and slowly worked it out over time18:12
programmerjakematrix keeps track of chat history, it doesn't need a reliable internet connection18:13
ghostmansd-pcOK, I thought there's some good guide18:13
lkclif it's non-obvious i'd suggest just cheating, and, looking at the output just copy that :)18:13
ghostmansd-pcto me things like `sum_with_carry(64)` are not obvious18:13
lkclbut, if you prefer, do a "better job"18:13
ghostmansd-pcI mean, I know how to do half-adder and full-adder18:13
ghostmansd-pcand, in fact, already did those18:14
lkclthat's equivalent to python "sum_with_carry[64]"18:14
lkclsum_with_carry is a variable created by a function18:14
ghostmansd-pcso that's an index?18:14
lkclthat's the 65th bit18:14
ghostmansd-pcOK, got it18:14
mikolajwis using Debian a formal requirement? I personally would like not to use it18:15
ghostmansd-pcand a_in(x) and b_in(y) correspond to "take bit X from a" and "bit Y from b"?18:15
Veeralkcl: Bug 654; I will start learning how to do.18:15
ghostmansd-pc> is using Debian a formal requirement?18:16
ghostmansd-pcit's not, but the current environment assumes debian18:16
mikolajwnice, thanks18:16
programmerjakeVeera you can connect to libre-soc over matrix:
lkclghostmansd-pc, mikolajw, effectively, yes.18:16
lkclmikolajw, there are two reasons:18:16
lkcl1) we don't need the hassle of supporting windows macosx mint {insert-arbitrary-OS-here}18:17
lkcl2) in VLSI ASIC design you ABSOLUTELY have to have a reproduceable build18:17
lkclcan you imagine, you are about to drop USD 8 million on 7nm masks to a Foundry18:18
Veeraprogrammerjake: ok. I will try. I am using hexchat18:18
lkcland two or more of your developers produce totally different GDS-II files?18:18
mikolajwthat's a major obstacle to me then18:19
lkclmikolajw, what do you have?18:19
mikolajwArch Linux18:19
lkclsome people are running ubuntu18:19
lkclahh yes, we had someone try that, using debootstrap.18:19
lkclit mostly worked.  there was one minor gotcha that they solved when trying to run GUI binaries18:20
lkclpacman -S debootstrap18:20
mikolajwoh, I've never heard of that before18:20
lkcland from there you can run the debian schroots either manually or just see how it goes18:20
lkclmikolajw, you should read this manually an arch-i-fy it;a=blob;f=mk-deb-chroot;hb=HEAD18:21
lkclif you are really really lucky it might actually work as-is18:21
lkclbecause most of the commands are inside the debootstrap chroot itself18:22
lkcl  24 apt install -y debootstrap schroot18:22
lkclnope.  that would need to be "pacman -S debootstrap schroot"18:22
ghostmansdanother option is using some sort of VM18:24
lkclif you reaaally want to, i'd be fine with a patch that detects if /etc/debian_version exists (at line 24) and optionally does that apt-get, then does something similar for archlinux18:24
ghostmansdPerhaps $(cat /etc/*release*) with some grep magic?18:25
lkclmikolajw, yeah, ghostmansd is using qemu, right? and recently tried qemu-in-qemu which, wark-wark :)18:25
ghostmansdThat was what I used to see in such cases18:25
mikolajwthat would be a good starter patch18:25
ghostmansdNope, it's still virtualbox. Shitty, but works to some degree.18:25
mikolajw(for me)18:25
lkcl$ ls /etc/*release*18:25
ghostmansdHm, I usually do cat with grep filter on it, but I guess both work18:26
ghostmansdI mean, it depends on what you want :-)18:26
lkclmikolajw, btw have you reviewed the charter? i'd welcome some extra dilbert cartoons :)
lkclif you're happy with it then i'm happy to add your ssh key to the git repos18:27
mikolajwI did, except for the cartoons (going to read the cartoons now then)18:27
VeeraBye fellows. Quiting.18:28
lkclthey're basically the total antithesis of the chater18:28
lkclk Veera18:28
mikolajwoh, not too fast, I need to get things working and introduce myself on the mailing lists first :)18:28
lkclok lol18:28
* lkcl afk. walk. coffeeee18:29
ghostmansd-pcI've pushed the sketch for addg6s test. It's needlessly complex, awfully written, it might even make anyone here vomit, but this is at least something to use as a playground. What do we have here?21:08
ghostmansd-pc1. We have half-adder and full-adder, atop of which we build full_adder64 (which allows to add two 64-bit numbers and yield the carry). I really hope there's an easier way to do it, I'm not sure how to do it in Python, so I did it in a generic way.21:09
ghostmansd-pc2. We have a generator which might generate all possible 64-bit BCD numbers. I'm not sure how to adopt it to generate some BCD numbers in range, though.21:11
ghostmansd-pc3. We have yet another openpower.simulator.program.Program instance, and it's capable of running addg6s code. That said, there's no batch mode yet.21:13
ghostmansd-pcAny ideas and suggestions are welcome. I don't feel like this code is good, the approach is viable, so take this with a grain of salt.21:13
programmerjakeif you want to calculate carry-out from adding 2 N-bit nmigen signals, all you need is to convert to two N+1 bit signals, add them using the `+` operator, then extract the MSB21:15
programmerjakeno need to build it up from full-adders21:16
ghostmansd-pcI'll think how to make it work as we want. I'd like this: 1) drop the adders, there for sure must be a simpler way (that said, I don't want to copy&paste what the pseudocode generated, this is literally a cheat); 2) I'd like to take some random BCD number pairs, in some _valid_ range, to check; 3) the batch mode is a must.21:16
ghostmansd-pcI'm using a pure Python there, in that test.21:16
ghostmansd-pcOr, well, at least I have no idea of nmigen. I understand how it works (this is exactly the same logic as with adders), but I'm not sure how to implement it in Python (and basically anywhere except of asm where I can access carry flag directly).21:18
programmerjakeusing nmigen's `+` operator also allows yosys to optimize addition, such as by using the special carry propagation logic in some FPGAs, or by building carry look-ahead networks, or etc.21:18
ghostmansd-pcprogrammerjake: do you mean something like a pair of nmigen.Signal(64)?21:19
programmerjakea pair of Signal(65) since you want the space for carry out21:20
ghostmansdI'll take a look at Signal, thank you!21:21
ghostmansdSorry if these questions are dumb. I'm a philologist, after all, not an engineering genius...21:21
programmerjakefor Python, for adding 2 8-bit numbers and getting the carry out, just do `(a + b) >> 8`21:22
ghostmansdSo this will work, due to use of big ints?21:30
ghostmansdIf so, that's really good news. I can drop these adders at all.21:30
ghostmansdI kinda feel ashamed granted that the solution is so obvious, compared to the stuff I implemented.21:31
programmerjakein Python it'll work since it uses big ints, in nmigen you need to use signals 1-bit wider21:32
ghostmansdOk, will cut this thing tomorrow21:33
ghostmansdThank you for your help!21:33
ghostmansdAt least I managed to recall adders, which, granted my background, is already useful, lol21:34
programmerjakeactually --- check nmigen's docs, the `+` operator may produce an output 1-bit wider than the inputs avoiding the need for 65-bit input signals21:34
lkclprogrammerjake, sorry, no, using nmigen Signal here is a major red herring21:34
lkclif anything SelectableInt(value, 65) should be used because it does the arithmetic at the exact bitwidth21:35
lkclbut the same thing can be done in straight python, just & manually with a mask ((1<<66)-1)21:35
ghostmansdThe reason why I don't want to use SelectableInt is that I'd like to avoid using pieces of code from codegen21:36
lkclor, to get the required carry bit, & with (1<<bit_required)21:36
lkclok then do it in straight python.21:36
ghostmansdI mean, by that point, we could've copied the code literally21:36
programmerjakewell, if you want to produce output HDL, you'll need to use nmigen somehow...21:36
lkclPaul Mackerras is a brilliant engineer, he analysed carry-bit production and came up with an elegant algorithm21:37
ghostmansdAnd that's not OK, since we're checking exactly this code21:37
lkclprogrammerjake: this is the simulator.  we do not want to involve HDL - at all - as a critical dependency for the *simulator*21:37
lkclthe goal here is to write something that's blindingly obvious21:37
programmerjakeah, missed that...21:37
lkclto use something that we "trust" as a canonical source21:37
ghostmansdYep, that'd be the best option21:38
lkclwhere, because we are testing the pseudocode, the pseudocode is "off the list of options to trust"21:38
ghostmansdLike we did with BCD conversions21:38
ghostmansdThese tables were great21:38
programmerjakewell, if the inputs are unsigned, `(a + b) >> 64` works21:38
lkclyes, that would do21:38
lkclwhat i suggest is, because the VHDL is not easy for you to read, completely ignore it.21:39
programmerjakeif their signed, they probably need masking first21:39
lkclwork from first principles of the definition21:39
lkclthe version - in python - that you create, ghostmansd, should be as brain-dead-obvious and simple in pure python as you can possibly make it21:40
ghostmansdOk, will do21:40
lkclat that webpage, it says (in words), "Adds source1 to source2 and produces 16 carry bits, one for each carry out of decimal position n (bit position 4xn)."21:41
ghostmansdI simply wanted to make something that can be used as a playground21:41
lkclwhich, now that i look at it, is exactly what's in the spec. v3.0B, p11121:41
lkcl(in words)21:41
ghostmansd(a playground that's literally a mine field, I know)21:41
lkclyeh, sigh21:42
programmerjake...i'd go from the isa spec rather than the aix compiler docs...21:42
ghostmansdBoth literally speak the same language in this case21:42
ghostmansdI mean, I get what it does21:42
* lkcl going to see if power-gem5 has addg6s21:43
ghostmansdStill having a reference values would have been much better21:43
programmerjakeyou can test against real power9 hw...21:43
ghostmansdIf only I had it, lol21:44
lkclof course21:44
lkclghostmansd: 1 sec21:44
lkclssh -p922 in about 5 mins21:44
lkclok try it now21:46
lkclwe're sponsored by Raptor Engineering with access to a veeeery nice TALOS-II workstation :)21:47
lkclplease don't use it for bitcoin mining21:47
ghostmansdYou caught me21:47
ghostmansdThat was literally the first option, lol21:47
lkclor monero21:48
ghostmansdThat was the second21:48
programmerjakebitcoin -- optimal for wasting cpu power without making any money from it!21:48
ghostmansdOk, managed to log in21:49
lkclcan you do me a favour, try that now, it's 10pm here and i'm winding down... excellent21:49
ghostmansdboo :-)21:49
lkclok so you should be able to use ssh-agent pass-thru to git clone the openpower-isa repo on there21:49
lkcldrop some experiments in c/assembler into the openpower-isa repo21:50
lkclhey there should actually be an addg6s intrinsic somewhere, if not, inline asm should do it21:50
lkcli leave you to it.21:50
programmerjakeyou can use power-instruction-analyzer to run tests like I explained yesterday...21:50
ghostmansdIt looks like I'll need to copy my public key21:51
ghostmansdTo be able to clone gitolite3 openpower-isa repo21:52
programmerjakessh can forward ssh-agent access21:52
programmerjakeso you keep your private key on your computer21:52
programmerjakeand the talos server will ask your computer to do the auth21:52
programmerjakeuse ssh -A21:54
ghostmansdStill permission denied upon cloning the repo21:54
ghostmansd(if you mean ssh -A upon entering Talos)21:54
ghostmansdAlso tried using `Host ForwardAgent yes` in ssh/config for talos1.libre-soc.org21:55
programmerjakeyou run ssh-agent on your local computer, then run ssh -A when connecting to talos121:56
ghostmansd-pc$ eval $(ssh-agent)21:59
ghostmansd-pcAgent pid 3084221:59
ghostmansd-pc(libresoc)ghostmansd@3mdeb:~$ ssh -A ghostmansd@talos1.libre-soc.org21:59
ghostmansd-pcLinux 75-224-155-23 5.6.0-1-powerpc64le #1 SMP Debian 5.6.7-1 (2020-04-29) ppc64le21:59
ghostmansd-pc$ git clone
ghostmansd-pcCloning into 'openpower-isa'...21:59 Permission denied (publickey).21:59
ghostmansd-pc(I cut some parts of the output, let me know if you need it)21:59
ghostmansd-pcOK, let's check tomorrow22:00
ghostmansdOr, should I say, today :-)22:02
programmerjakehmm, idk. lkcl should be able to help...22:04
mikolajwlkcl: I think it would be better if mk-deb-chroot asked before modifying /etc/fstab22:42
mikolajwnow I'm going to play softbrick roulette when I reboot, lol22:43
programmerjakeiirc schroot automounts those bind mounts, no fstab modifications necessary22:48
mikolajwfortunately no softbricking occured22:54
mikolajw/bin/bash: line 10: /etc/sudoers.d/deb: No such file or directory23:01
mikolajwoh, it fails to fetch the packages23:02
mikolajwcan't resolve ftp.debian.org23:02
mikolajw(nah, it's something else)23:04

Generated by 2.17.1 by Marius Gedminas - find it at!