lkcl | ghostmansd[m], yep it grew from "oh whoops i need a quick way to do this by hand" | 08:28 |
---|---|---|
lkcl | ghostmansd[m], preeetty much everything in https://git.libre-soc.org/?p=openpower-isa.git;a=tree;f=src/openpower/decoder/isa;hb=HEAD | 08:30 |
lkcl | starting with test_caller_*.py | 08:30 |
lkcl | holy cow that looks like a lot of work | 08:32 |
lkcl | python3 decoder/isa/test_caller_bitmanip_av.py >& /tmp/f good | 08:39 |
lkcl | python3 decoder/isa/test_caller_setvl.py >& /tmp/f not so much, investigating | 08:43 |
lkcl | hilarious. the comment for svshape was out-of-date from the last re-shuffle of OPC 22 | 08:46 |
lkcl | found it | 08:58 |
lkcl | * setvl RT,RA,SVi,vf,vs,ms | 08:58 |
lkcl | - (RT, RA, SVi, ms, vs, vf) = fields | 08:58 |
lkcl | + (RT, RA, SVi, vf, vs, ms) = fields | 08:58 |
lkcl | and svstep uses only 3 fields | 08:59 |
lkcl | * svstep RT,SVi,vf | 08:59 |
lkcl | python3 decoder/isa/test_caller_setvl.py >& /tmp/f good | 09:01 |
lkcl | i say good, the inner loop fns are barfing... | 09:02 |
lkcl | ahh svremap | 09:05 |
lkcl | SVRM-Form updated a few days back | 09:05 |
ghostmansd[m] | I haven't checked forms | 09:05 |
ghostmansd[m] | For now I concentrated on the code | 09:05 |
lkcl | i had to shuffle some of them | 09:06 |
lkcl | i'm on it | 09:06 |
ghostmansd[m] | Only obvious errors were fixed :-) | 09:06 |
lkcl | svremap: | 09:06 |
lkcl | # 1.6.34 SVRM-FORM from fields.txt | 09:06 |
lkcl | # |0 |6 |11 |13 |15 |17 |19 |21 |22 |26 |31 | | 09:06 |
lkcl | # |PO | SVme |mi0 | mi1 | mi2 | mo0 | mo1 |pst |/// | XO | / | | 09:06 |
lkcl | is out-of-date | 09:06 |
lkcl | actual fields.txt | 09:06 |
lkcl | # 1.6.34 SVRM-FORM | 09:06 |
lkcl | |0 |6 |11 |13 |15 |17 |19 |21 |22 |26 |31 | | 09:06 |
lkcl | | PO | SVme |mi0 | mi1 | mi2 | mo0 | mo1 |pst |/// | XO | | 09:06 |
lkcl | and master svp64.py | 09:06 |
lkcl | insn |= fields[6] << (31-21) # pst , bit 21 | 09:06 |
lkcl | insn |= 0b111001 << (31-31) # XO , bits 26..31 | 09:06 |
lkcl | branch: | 09:07 |
lkcl | (XO , 26, 30), | 09:07 |
lkcl | (0 , 31, 31), | 09:07 |
lkcl | ) | 09:07 |
lkcl | which is wrong | 09:07 |
ghostmansd[m] | It might have been a copy&paste, I admit :-) | 09:07 |
lkcl | i.e. you fitted to the old cut/paste out-of-date copy of fields.txt entry | 09:07 |
ghostmansd[m] | Aaaag | 09:07 |
ghostmansd[m] | Yeah makes sense | 09:07 |
lkcl | no, actually, you did an excellent and perfect job of conforming to out-of-date copies of fields.txt :) | 09:08 |
ghostmansd[m] | I've been looking at fields.txt entries :-) | 09:08 |
ghostmansd[m] | Yeah | 09:08 |
ghostmansd[m] | You know, this is one of the reasons I'm confident that we must generate these | 09:08 |
lkcl | yehyeh | 09:08 |
lkcl | i mean it's precisely what i'd been advocating "oh yeah we do all auto-generated to avoid mistakes" | 09:09 |
lkcl | wark-wark | 09:09 |
ghostmansd[m] | Yeah couldn't agree more | 09:10 |
ghostmansd[m] | BTW could you please split any findings in separate commits if possible? | 09:11 |
programmerjake | luke...soo many emails....i'll need an hour or more to read them all...:) | 09:11 |
ghostmansd[m] | I'll revisit binutils then | 09:11 |
lkcl | programmerjake, i know - last year i simply switched off SMTP delivery (!) | 09:11 |
lkcl | they're pretty much all RFP-related | 09:12 |
lkcl | but they're things that have been delayed and delayed and delayed and delayed | 09:13 |
lkcl | ghostmansd[m], will try, drat, i just put svshape and svstep in the same commit | 09:13 |
lkcl | svremap fixed | 09:14 |
* lkcl frickin monster headache | 09:16 | |
lkcl | ow | 09:16 |
lkcl | python3 decoder/isa/test_caller_setvl.py >& /tmp/f | 09:16 |
lkcl | pass, hooray | 09:16 |
lkcl | python3 decoder/isa/test_caller_transcendentals.py >& /tmp/f good | 09:20 |
lkcl | svp64 fft one underway, go go go go | 09:21 |
lkcl | come ooon you can do it... :) | 09:22 |
lkcl | errr that's odd | 09:23 |
lkcl | ha, one too many arguments :) | 09:23 |
lkcl | python3 decoder/isa/test_caller_transcendentals.py >& /tmp/f gooood | 09:24 |
lkcl | which is a relief because that's a frickin complex test | 09:25 |
lkcl | dct.py... | 09:25 |
lkcl | i think these will all be probably ok from now on, after getting test_caller_svp64_setvl.py to work | 09:26 |
ghostmansd[m] | I have an impression this deserves some task already :-) | 09:27 |
lkcl | mhmm | 09:27 |
ghostmansd[m] | But I think this is just a temporary hack | 09:27 |
ghostmansd[m] | And the real task is generating these | 09:27 |
lkcl | well it's kinda covered by... well it's kinda along the right lines | 09:27 |
ghostmansd[m] | The only reason for task is how much time was spent :-) | 09:27 |
* lkcl taking a look | 09:28 | |
lkcl | https://bugs.libre-soc.org/show_bug.cgi?id=838 | 09:28 |
lkcl | ok there's EUR 1425 available in https://bugs.libre-soc.org/show_bug.cgi?id=577 | 09:29 |
lkcl | what i'll do is shuffle some of that to 838 | 09:29 |
lkcl | EUR 500? | 09:29 |
* lkcl same cut/paste issue with svp64_dct.py svremap (8 args when 7 are needed), sorted... | 09:34 | |
lkcl | this is good, you check the length of the fields, that wouldn't have been caught | 09:35 |
ghostmansd[m] | We actually should do more and check whether they overlap | 09:37 |
ghostmansd[m] | But I'll leave it to generator :-) | 09:37 |
ghostmansd[m] | By the way, is it possible we switch to some other format? :-) | 09:38 |
ghostmansd[m] | I wouldn't call fields.txt particularly readable | 09:38 |
lkcl | mmmm... unfortunately it's machine-read | 09:40 |
lkcl | the columns "|" actually line up in a machine-readable way | 09:40 |
lkcl | and it comes directly from the Power ISA Spec | 09:41 |
lkcl | so changes are a lot more work than it first seems | 09:41 |
lkcl | python3 decoder/isa/test_caller_svp64_dct.py >& /tmp/f gooood | 09:42 |
* lkcl test_caller_fp.py next... | 09:42 | |
lkcl | https://git.libre-soc.org/?p=openpower-isa.git;a=blob;f=src/openpower/decoder/power_fields.py;hb=HEAD | 09:44 |
lkcl | test_caller_fp.py good svp64_fp.py good svp64_matrix.py corrected good | 09:47 |
lkcl | oink. the "open" source podcast announced by the linuxfoundation requests DRM to play it | 10:21 |
lkcl | what the hell | 10:22 |
lkcl | ghostmansd[m], i'm good with the tests. all happy with the new dict-thing svp64.py | 10:28 |
programmerjake | lkcl: re-expanded top comment: https://bugs.libre-soc.org/show_bug.cgi?id=868#c0 | 10:38 |
lkcl | programmerjake, now it's off of the critical path under time-pressure it looks great | 11:03 |
programmerjake | :) | 11:04 |
ghostmansd[m] | Many thanks lkcl! | 11:07 |
ghostmansd[m] | Do you like the new approach? I'm thinking of using some similar stuff in task 838. | 11:08 |
ghostmansd[m] | Not exactly this, I think; rather a dataclass or a namedtuple. | 11:08 |
lkcl | ghostmansd[m], yes it's much better | 11:18 |
lkcl | just bear in mind, power_decoder.py the damn XO fields are hard-coded into the function | 11:18 |
lkcl | it *should* be possible to extract them by tree-walking the list-of-namedtuples | 11:19 |
lkcl | btw can i leave it with you to rebase pysvp64asm branch onto master? i don't do that often enough to remember how to do it | 11:20 |
ghostmansd[m] | Yeah sure | 11:24 |
ghostmansd[m] | I'll complete this later today | 11:24 |
lkcl | star. no rush. | 11:30 |
octavius | good afternoon lkcl, so what should I focus on doing next? pypowersim bug #758? | 15:35 |
ghostmansd | lkcl, I kinda lost how many fields should svremap have :-D | 15:53 |
ghostmansd | Luke I've re-based the branch and integrated the changes. I've changed the wording for some commits a bit so that it's apt to subsystem and follows the wording done before. Many thanks for this work, especially for tests. | 16:03 |
ghostmansd | It seems we've been somewhat out-of-sync. I'll update binutils part respectively; it's been long enough since I published the previous revision. :-) | 16:04 |
ghostmansd | I'm also going to include svindex as well in a new revision, if you don't object. | 16:04 |
ghostmansd | After that I think I'll finally be able to continue with operands parsing. :-) | 16:05 |
ghostmansd[m] | lkcl, I think there's an error with fsins/fcoss. It should be either have FRT,FRA,FRB operands, or FRT,FRB. Judging from svfparith.mdwn, this is the former. But the X-form which you added mentions FRA as well. Am I missing something? | 16:39 |
ghostmansd | lkcl, I think this is the correct form | 16:41 |
ghostmansd | | PO | FRT | /// | FRB | XO |Rc | | 16:41 |
ghostmansd | I've updated pysvp64.asm; this is a comment anyway, so this shouldn't break anything. It matches svfparith.mdwn count of operands, the operands position which I took from the original code, so I think we're safe to assume this is the correct form. Anyway, please let me know whether it is indeed. | 16:43 |
ghostmansd | That'd be great if SVM-form used a different name for operand SVRM, since we already have a form with the same name. | 17:01 |
ghostmansd | For now I call this operand SVRMf, f stands for field. | 17:02 |
ghostmansd | I'm kinda dubious on what we should do with the ignored fields. The current code code marks these, for example, (0, 22, 25) designates "a field which is set to 0 and spans through bits 22-25". | 17:11 |
ghostmansd | On one hand, it makes it easier to keep track, and is explicit. We could also check that all bits are mentioned and not a single bit is forgotten (we don't check for it now, but we really could). | 17:13 |
ghostmansd | On the other hand... well, it actually does nothing other than being explicit and perhaps leaving a room for checks in the future. | 17:13 |
ghostmansd | So, thoughts? I'm inclined to think that the current approach is better. Perhaps we could even have a special data type for an ignored field when we get to the generator. | 17:18 |
lkcl | ghostmansd[m], ah whoops - have a look at Power ISA 3.0, p148, "fneg" instruction | 18:13 |
lkcl | Floating Negate X-form | 18:13 |
lkcl | fneg FRT,FRB (Rc=0) | 18:13 |
lkcl | fneg. FRT,FRB (Rc=1) | 18:13 |
lkcl | fcoss and fsins follow that pattern | 18:13 |
lkcl | so, sorry, you'll have to put those back to FRB :) | 18:14 |
ghostmansd[m] | Yes, and they don't have FRA | 18:14 |
lkcl | correct. | 18:14 |
ghostmansd[m] | FRB is still there :-) | 18:14 |
lkcl | again it'll probably be something down to that trick i described with RS/shift/ldst | 18:14 |
ghostmansd | git show 956dc17c4e10ae57bbd4bb07d9348054353bbd79 | 18:15 |
ghostmansd[m] | Isn't it correct? | 18:15 |
lkcl | ahhh... yes! that's correct | 18:15 |
ghostmansd[m] | We shouldn't list FRA amongst registers | 18:15 |
ghostmansd[m] | Well :-) | 18:15 |
lkcl | sorry you'd spotted something i'd got wrong | 18:15 |
ghostmansd[m] | That's all I did | 18:15 |
* lkcl just woke up | 18:16 | |
lkcl | ah brilliant | 18:16 |
ghostmansd[m] | I also pushed more commits there | 18:16 |
ghostmansd[m] | Re-visiting binutils and comparing both assemblers was a good idea | 18:16 |
ghostmansd[m] | OK it looks like these are finally synced | 18:17 |
ghostmansd[m] | So I'll publish a new series of patches soon | 18:17 |
lkcl | cool. let me think about SVM-Form for a bit | 18:18 |
lkcl | # 1.6.33 SVM-FORM | 18:19 |
lkcl | |0 |6 |11 |16 |21 |25 |26 |31 | | 18:19 |
lkcl | | PO | SVxd | SVyd | SVzd | SVRM |vf | XO | | 18:19 |
lkcl | should really be.... | 18:19 |
lkcl | | PO | SVme | SVxd | SVyd | SVzd |vf | XO | | 18:19 |
lkcl | | PO | SVme | SVxd | SVyd | SVzd |vf | XO | | 18:19 |
lkcl | hmmm... no, it's not the same field | 18:21 |
lkcl | ok it can just be lower-cased SVrm | 18:21 |
lkcl | | PO | SVxd | SVyd | SVzd | SVrm |vf | XO | | 18:21 |
ghostmansd[m] | Ah yeah, good idea! | 18:32 |
ghostmansd[m] | Makes perfect sense | 18:32 |
ghostmansd[m] | Thanks Luke! I see you already updated openpower-isa. | 18:33 |
ghostmansd[m] | I'll update binutils. | 18:33 |
lkcl | ghostmansd[m], yes updated. awesome | 18:56 |
lkcl | btw about the "ignored" fields, these are effectively already dealt with | 18:56 |
lkcl | from power_fields.py and the markdown-pseudocode-parser-class (can't remember its name straight away, something daft like "ISA") | 18:57 |
lkcl | the markdown is already parsed so the opcode arguments obtained | 18:58 |
lkcl | +* svshape SVxd,SVyd,SVzd,SVrm,vf | 18:58 |
lkcl | and the Form obtained as well | 18:58 |
lkcl | SVM-Form | 18:58 |
lkcl | therefore, a dictionary-of-dictionaries (actually, attributes-of-attributes) is created | 18:59 |
lkcl | by FormName.FieldName | 18:59 |
lkcl | and it's a near-trivial job to walk those and obtain the bit-locations | 18:59 |
lkcl | "ignoring" fields doesn't even come into the picture because it's inherently and automatically done by virtue of walking the list of field names and using those as key-lookups into PowerFields[FormName][fieldname] | 19:00 |
lkcl | all of these: | 19:01 |
lkcl | @@ -141,7 +141,7 @@ def svshape(fields): | 19:01 |
lkcl | (SVxd, 6 , 10), | 19:01 |
lkcl | (SVyd, 11, 15), | 19:01 |
lkcl | should be obtainable from PowerFIelds with a single function call instead of manual | 19:01 |
lkcl | bottom line there's an incremental path here, keeping things going without huge disruption or unnecessary "full replacement" code being written | 19:06 |
ghostmansd | lkcl, I've submitted svindex along with its test, plus also refreshed patches (links, renamed SVRMf to SVrm, etc.) | 20:06 |
ghostmansd | I'm wondering if we could generate parts of an RFP via budget-sync, or a similar script. Because, well, some parts can be done in an automatic fashion. | 20:11 |
ghostmansd | Anyway, Luke, I've just sent the template for 867. Both binutils and pysvp64asm can handle svindex successfully. | 20:13 |
lkcl | ghostmansd, brilliant | 20:18 |
lkcl | yes, i know - it's been on the TODO list for a loooong time | 20:18 |
lkcl | yes i saw. you got the project name wrong, it should be "LibreSOC Formal" (i sent it in email) | 20:19 |
lkcl | the rest is good | 20:19 |
lkcl | oh btw, you'll love this: i actually have a bugzilla-automated-poster which manages attachments for patch-sets, somewhere! | 20:20 |
lkcl | i forgot about it. | 20:20 |
ghostmansd | Mmm, I'm missing what you mean. Which kind of attachments? | 20:21 |
lkcl | basically what this program did was, it analysed a series of commits and automatically uploaded them as attachments to a bugreport | 20:23 |
lkcl | including revising them | 20:23 |
lkcl | i wrote it for managing a series of 30 patches to webkit | 20:23 |
lkcl | it relied however on some specific database augmentation that they'd done | 20:24 |
ghostmansd | I kinda have an impression we might need that. I still have no reply from FSF, and perhaps this whole upstream merging might take a while. | 20:36 |
ghostmansd | Well, at least most of the code is decoupled into the separate file. | 20:37 |
programmerjake | technically, our project name is Libre-SOC, not LibreSOC. (we picked that to match the available domain name). | 20:49 |
Generated by irclog2html.py 2.17.1 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!