Monday, 2022-06-06

Veera[m]Hi09:54
Veera[m]ghostmansd[m]: lkcl: Bug 838, What has to be done. I cannot make it out?09:57
programmerjakehi, though since i'm going to sleep, bye!09:58
ghostmansd[m]lkcl, does anything uses sv/trans/svp64.py as usual script?19:55
ghostmansd[m]I see it can be used under name pysvp64asm19:55
ghostmansd[m]I'd like to teach it to convert the code from stdin to stdout on-the-fly19:55
ghostmansdconsidering this code...19:59
ghostmansdsv.fcoss. 20.v, 0.v # coco19:59
ghostmansd# jumbo19:59
ghostmansd...19:59
ghostmansdI'd expected this output20:01
ghostmansd.long 0x0540240020:01
ghostmansd.long 0xeca0045d20:01
*** ghostmansd <ghostmansd!~ghostmans@broadband-188-32-220-29.ip.moscow.rt.ru> has left #libre-soc20:01
ghostmansdor, better, considering this...20:02
ghostmansdsv.add. 5.v, 2.v, 1.v # coco20:02
ghostmansd# jumbo20:02
ghostmansd...20:02
ghostmansdI'd have expected this:20:02
ghostmansd.long 0x05402ea020:02
ghostmansdadd. 1, 0, 020:02
ghostmansdinstead I see unchanged sv. insns20:03
ghostmansdsv.add. 5.v, 2.v, 1.v # coco20:04
ghostmansd# jumbo20:04
ghostmansdpotential = ls[1].strip()20:25
ghostmansdif not potential.startswith("sv."):20:26
ghostmansdthis is clearly strange, because `ls` might be result of `line.split("#")`20:26
ghostmansdand, for case like 'sv.add. 5.v, 2.v, 1.v # coco\n', this will check stuff after the comment; this is clearly wrong20:27
ghostmansdhowever, if I replace `potential = ls[1].strip()` with `potential = ls[1].strip()`, it works20:28
ghostmansdprogrammerjake, this is your code, any particular thoughts?... src/openpower/sv/trans/svp64.py20:28
ghostmansdI've pushed the changes I did for now; they're trivial to rollback, should the rollback be required20:31
ghostmansdwhat I did is: 1) replaced prints with logger; 2) simplified stdin/stdout processing; 3) fixed (o'rly?) the "potential" assignment20:32
ghostmansdthe only part which can break stuff is 3)20:32
ghostmansdping me if it breaks anything20:32
ghostmansdI need this for 838 and for checking binutils asm when I'll write binutils-exclusive tests20:33
programmerjakei don't recall writing that, your changes look fine to me20:52
Veera[m]ghostmansd: Bug 838. Hey can you tell me where to start!21:10
lkclghostmansd, go for it.21:11
lkcllong story, for pysvp64asm you have to put "# sv.xxxx" not "sv.xxxx"21:12
lkclVeera[m], there's an easier one to start with https://bugs.libre-soc.org/show_bug.cgi?id=83921:14
lkclthe diagrams from here https://libre-soc.org/openpower/sv/SimpleV_rationale/21:15
lkcli need to add a couple more21:15
lkclbut there are 2 to get started21:15
Veera[m]lkcl: https://libre-soc.org/openpower/sv/500xNx2022-05-14_11-55.jpg.pagespeed.ic.2ekfSI7s4m.webp: is this also to be converted to SVG21:20
lkclno i think that one can stay21:21
Veera[m]ok21:30
lkclghostmansd, please do not alter the behaviour of "# sv." search pattern unless also modifying the assembler programs that rely on that.21:41
lkclthey're in the media/ directory21:41
lkclthe reason for adding the copy of the instruction verbatim afterwards is so that re-running pysvp64asm on the same program *after* it's been run will *re*-substitute the altered comment21:43
lkclotherwise you end up with a one-way process that *destroys* the assembler due to the substitution ".long xxx; v3.0op"21:43

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