[Libre-soc-bugs] [Bug 550] binutils support needed for svp64

bugzilla-daemon at libre-soc.org bugzilla-daemon at libre-soc.org
Sat Nov 27 21:06:34 GMT 2021


--- Comment #27 from Luke Kenneth Casson Leighton <lkcl at lkcl.net> ---
(In reply to dmitry.selyutin from comment #26)
> Pushed a pair of smallish commits into sv_analysis.py so that it'll be
> capable of generating code for binutils. These are mostly preparations, but
> I think it's inevitable: I have neither desire nor time to copy&paste
> sv_analysis.py customizations (all these if/else branches, continues in
> loops and so on). I intend to decouple the format-specific parts into, well,
> format-specific entities. It'd be great if you could take a look and tell me
> if it's OK or not on the early stage. :-)

yyeah go for it.  try not to go too overboard (a la jinja2) it's just
not worth it.  see how it goes: if there turns out to be a hell of a lot
of "if format == " statements then some sort of *really small* API would
be worth considering, i do tend to find however that the readability of
such APIs is absolutely awful and after about the 5th one you deeply
regret having created them, and go back to code-duplication, where at
least the damn code is linear, shorter, and bleedin obvious.

see how you get on.  this could be short enough to work out okay: it's
only 50 lines within the cvs.svp64.items() loop.

what might be handy would be to drop in some namedtuples. or perhaps
if i'd put in comment it would help, ehn?

You are receiving this mail because:
You are on the CC list for the bug.

More information about the libre-soc-bugs mailing list