Monday, 2023-05-15

*** ghostmansd[m] <ghostmansd[m]!~ghostmans@176.59.166.180> has quit IRC00:41
*** ghostmansd[m] <ghostmansd[m]!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has joined #libre-soc00:42
lkclghostmansd, you can't ignore the source/destination on extra_idx mappings02:56
lkclif you look at the original code (which you removed) you'll find that the "s:" and "d:" is absolutely critical02:57
lkclhowever now with making "RA" both a source *and* a destination in the same index-spot, the code's not coping03:01
lkclgot it04:28
*** ghostmansd <ghostmansd!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has quit IRC07:29
*** lxo <lxo!~lxo@gateway/tor-sasl/lxo> has quit IRC07:30
*** lxo <lxo!~lxo@gateway/tor-sasl/lxo> has joined #libre-soc07:32
lkclholy cow pointer-chasing works11:49
*** octavius <octavius!~octavius@92.40.168.14.threembb.co.uk> has joined #libre-soc12:07
*** ghostmansd <ghostmansd!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has joined #libre-soc13:13
*** ghostmansd <ghostmansd!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has quit IRC13:21
*** ghostmansd[m] <ghostmansd[m]!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has quit IRC15:46
*** ghostmansd[m] <ghostmansd[m]!~ghostmans@176.59.164.44> has joined #libre-soc15:47
*** ghostmansd[m] <ghostmansd[m]!~ghostmans@176.59.164.44> has quit IRC16:11
*** ghostmansd[m] <ghostmansd[m]!~ghostmans@176.59.164.120> has joined #libre-soc16:11
*** lxo <lxo!~lxo@gateway/tor-sasl/lxo> has quit IRC16:47
*** lxo <lxo!~lxo@gateway/tor-sasl/lxo> has joined #libre-soc16:48
*** ghostmansd[m] <ghostmansd[m]!~ghostmans@176.59.164.120> has quit IRC17:01
*** ghostmansd[m] <ghostmansd[m]!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has joined #libre-soc17:01
programmerjakelkcl: when you changed f"" to % you inadvertently inserted a space in an identifier, likely breaking vhdl output: https://git.libre-soc.org/?p=openpower-isa.git;a=blob;f=src/openpower/sv/sv_analysis.py;h=5b39295e9576f104130d0e1cbc4d3c6a5405e6a1;hb=62c04f760e63c3f98e5ed4a1f20944c9a8f3ea74#l22917:07
ghostmansd[m]Yet another reason to use f-strings?17:26
ghostmansd[m]lkcl, thanks for insndb fix!17:27
*** octavius <octavius!~octavius@92.40.168.14.threembb.co.uk> has quit IRC18:08
*** ghostmansd <ghostmansd!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has joined #libre-soc18:32
*** ghostmansd <ghostmansd!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has quit IRC19:37
*** ghostmansd <ghostmansd!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has joined #libre-soc19:38
*** ghostmansd <ghostmansd!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has quit IRC19:40
*** ghostmansd <ghostmansd!~ghostmans@broadband-109-173-83-100.ip.moscow.rt.ru> has joined #libre-soc19:40
ghostmansdlkcl, 3 tests fail on master: https://salsa.debian.org/Kazan-team/mirrors/openpower-isa/-/jobs/421903219:41
ghostmansdAll three are vli-related19:43
ghostmansdI assume vli is no longer with us?19:44
ghostmansdIs vli in the same room with us right now?...19:45
lkclprogrammerjake, whoops.19:57
lkclghostmansd, no it's just a mistake19:57
lkclthe VHDL is not actually used19:57
lkclghostmansd, yes i know. attempting to track it down.  oh - i put in an extraneous space, doh20:01
lkclthe sv.crand one i am in the middle of. no idea why "/vli" is now missing20:02
lkclwhere the heck's the CROp mode-setting thingy?20:07
lkclgot it20:07
lkclghostmansd, sorted, i had to swap Mode[0] and Mode[1] in CROps, tracked down selector.mode.sel - all good20:19
lkcloh fer god's sake :)20:20
lkclbroke the rest of sv.cmp :)20:20
lkclon it20:36
lkclbut found another one of these - sv.cmp/ff=eq *4,1,*0,120:36
lkcl    BF (vector)20:36
lkcl        0010020:36
lkcl        38, 39, 40, 19, 20, {0}, {0}20:36
lkcl        extra3<generator object ExtendableOperand.extra_idx at 0x7f9b7694b840>20:36
ghostmansdSigh, yes, CRs are always special20:44
ghostmansdSo special that in fact much of the code is copied there20:44
ghostmansdI'll fix it20:44
ghostmansd(not the copy itself, but a bug)20:44
ghostmansd(fixing the copy needs CRs to be less special)20:44
lkclfound it20:47
lkclsorted20:47
lkclnot yet picking up ff mode on sv.cmp, sigh. haven't tracked down if it's disassembly or assembly yet20:52
lkcl        crop: ffirst 3-bit mode20:53
lkcl        RM20:53
lkclit's disassembly20:53
ghostmansdthanks Luke!20:54
ghostmansdI'm dealing with trace files, so there might be delays in replies :-)20:56
ghostmansdbut I see that you can already navigate through insndb :-)20:57
vaino[m]lkcl: I'll send you an e-mail, for the meeting link20:58
ghostmansdfrankly this is surprising, not because I underestimate you, but because sometimes things get real tricky there20:58
lkclghostmansd, just about20:59
lkclvaino[m], great - you should already have it in a pm from me, last week though21:00
lkclalthough stick around in IRC because last week it was hilarious, they have clearly upgraded jitsi and utterly stuffed it up21:00
lkcl(WebRTC sigh)21:00
vaino[m]Ah, I didn't seem to get it, could it be because I'm using Matrix?21:01
lkclghostmansd, i'm used to navigating code like this, but also remember i know the spec21:01
lkclvaino[m], possibly. i don't use it so i don't know how it works (or doesn't work)21:01
lkclalthough ghostmansd sends me messages from it no problem21:02
vaino[m]ah! got your pm now21:02
lkclghostmansd, 5-bit CRops is swapped round with 3-bit CRops21:02
lkclngggggggggggh21:07
lkclslowly bludgeoning my way through this... :)21:07
ghostmansdlkcl, IIRC there was the giant discussion about whether it's swapped or not :-)21:12
ghostmansdthat time you was totally buried with other works, so I had to move on my own...21:12
ghostmansdI'm too lazy to dig it in IRC, but I raised some questions on whether these are swapped or not, perhaps you remember21:13
ghostmansdapparently I got it the wrong way :-D21:13
lkclghostmansd, can't even remember - vaguely21:16
lkclwark-wark21:16
lkclsorting it out... slowly...21:16
lkclghostmansd, if /ff is placed first in the specifiers the assembly results are incorrect21:45
lkclpresumably bit 6 (/zz) is overwritten by later specifiers21:45
lkcl+                    "sv.cmp/zz/ff=gt/m=r3 *4,1,*0,1", # WRONG21:47
lkcli can't cope with that21:47
*** jn <jn!~quassel@user/jn/x-3390946> has quit IRC22:07
*** jn <jn!~quassel@2a02:908:1066:b7c0:20d:b9ff:fe49:15fc> has joined #libre-soc22:22
*** jn <jn!~quassel@2a02:908:1066:b7c0:20d:b9ff:fe49:15fc> has quit IRC22:22
*** jn <jn!~quassel@user/jn/x-3390946> has joined #libre-soc22:22
ghostmansdlkcl, it seems that ff and zz are in conflict, hang on22:24
ghostmansdff: https://git.libre-soc.org/?p=openpower-isa.git;a=blob;f=src/openpower/decoder/power_insn.py;h=1e909669207f0617f40fd850c81e7950b932a8c2;hb=refs/heads/master#l258122:24
ghostmansdecho "sv.cmp/zz/ff=gt/m=r3 *4,1,*0,1" | SILENCELOG=true pysvp64asm | powerpc64le-linux-gnu-as - -o /tmp/elf.o && powerpc64le-linux-gnu-objcopy -Obinary /tmp/elf.o /tmp/bin.o && pysvp64dis -v < /tmp/bin.o22:27
ghostmansdRM.zz is bit 14...22:28
ghostmansdHere's the whole RM via print(insn.rm.__class__)22:34
ghostmansdhttps://pastebin.com/ET23J51822:34
ghostmansdor, better, insn.rm.crop.__class__22:35
ghostmansdhttps://pastebin.com/AFuAuFdL22:35
ghostmansdor, even better, what's "selected" upon insn.select(record=db[insn]).rm.__class__22:38
ghostmansdhttps://pastebin.com/VTAR5Jg922:38
ghostmansdewsrc?22:39
lkclRM.zz is bit 6 in CRops22:45
lkclahh yes.22:45
lkclewsrc is *disabled* in CRops.22:46
lkclField(6, 8, 10, 11, 12, 13, 14,22:46
lkclRM.zz is Field[6] in that22:46
lkclso yes RM.zz is bit 14 (of the 32-bit prefix, not of RM itself)22:47
lkclok so ewsrc - that's the clue i needed22:47
lkclnope - not having any of it.23:23
ghostmansdI'll take a look at it tomorrow.23:24
ghostmansdThe fact that we have ewsrc does not imply we write there... :-)23:24
ghostmansdI'll have to add some debug code.23:24
ghostmansdBTW, you're welcome to check tracefile branch. :-)23:25
ghostmansdhttps://git.libre-soc.org/?p=openpower-isa.git;a=commitdiff;h=d781f80c9b3e0e48b36ac5b5bca760d0f52468a823:26
ghostmansdYeah I know you don't like dataclasses... I had to add one for explicitness. Please let me know if this is a total vomit factor here, and I'll drop it.23:26
ghostmansdI refactored the trace a little bit, but other than that, it's the same.23:27
ghostmansdI tried to keep regexes simple and straightforward, though.23:28
lkclSpecifierFF is somehow overwriting SpecifierZZ23:28
lkclghostmansd, yes please don't use dataclasses.23:29
lkclthis code should be BARE minimum absolute dead simple23:29
lkclsomeone inexperienced in python should be able to look at this and go, "oh, that's really obvious"23:30
lkcldataclasses are therefore a "hard no"23:30
lkcland regexs are borderline23:30
lkclas long as there is adequate comments explaining what they are, they're ok.23:30
lkcli *cannot* read regexs, period.23:31
lkclalso don't bother doing a branch, just shove everything straight into that file - there should be no other imports, no other code used23:32
lkclalso please please stop doing "import x as _x"23:32
lkclit is really irritating and unnecessary.23:32
lkclonce power_insn.py stabilises i will go through it and remove all uses of underscores in front of all imports23:33
lkcli don't care in the least about the imports showing up in the list of module properties23:33
lkclit's just not as important as making for readable code that in peoples' minds, when they "sub-vocalise" a reading of the text23:34
lkclthey are not slowed down by hearing, in their mind, ***UNDERSCORE*** enum23:34
lkclUUUUNNNDERSCOOORRRE re23:34
lkcl**UNDERSCORE** SVP6423:35
lkcletc.23:35
lkcl 307         "rGPR:0.0/64 wGPR:1.0/64 # addi 1, 0, 0x0010",23:37
lkcl 308         "rGPR:0.0/64 wGPR:2.0/64 # addi 2, 0, 0x1234",23:37
lkclthis is great. yes good idea to move the instruction to the end23:37
lkclwhat i'd do - and this ends up literally in like 3 lines of code23:38
lkcl* format is always the same separator: a colon would do23:38
lkclthen you do23:38
lkclspecs, insn = map(string.strip, x.split("#")23:39
lkclfor spec in specs:23:39
lkcl    (reg, num, offs, elwidth) = spec.split(":")23:39
lkclthat's it.23:39
lkcldone.23:39
lkclthree lines.23:40
lkclthose 3 lines replace *almost a hundred* (!)23:40
lkclif you really want to put the data into something with names, use a namedtuple23:42
lkclthat'll be (gosh) a whole two extra lines, shock-horror :)23:43

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