azonenberg changed the topic of #scopehal to: libscopehal, libscopeprotocols, and glscopeclient development and testing | https://github.com/glscopeclient/scopehal-apps | Logs: https://libera.irclog.whitequark.org/scopehal
Degi has quit [Ping timeout: 260 seconds]
Degi has joined #scopehal
<azonenberg> Diff is now 8.5K lines, and I'm up to filters with name starting with E
<azonenberg> lol
<azonenberg> no one file needs that much of an edit. there's just so... many... files
<GenTooMan> azonenberg, be sure not to loose your head .. to bugs.. :D
<azonenberg> i'm all but certain some bugs will creep in when doing a refactoring this enormous
<azonenberg> especially when combined with the renderer rewrite we have coming up next
<azonenberg> We... do not exactly have a great suite of regression tests yet
<GenTooMan> ah testing code is always fun, I remember doing it by memory, and it always sucked how badly it worked (my memory that is).
<GenTooMan> well in any case don't forget fuzz testing to be sure you can handle insanity flogging your functions.
<azonenberg> We're a long ways from needing fuzzing to find bugs :p
<azonenberg> But yes i would love to have regular fuzzing of decodes, regular unit testing
<azonenberg> automated regression testing comparing the normal, vectorized, and GPU versions of each filter
<GenTooMan> well if it was easy it would be done already. :D
<GenTooMan> still I could have sworn there were OS suites for partially automating testing. I remember vaguely pondering the misuse of doxygen to help test stuff.
<GenTooMan> OS = Open Source
<azonenberg> GenTooMan: we have a unit test tool built in already
<azonenberg> the issue is, the majority of the codebase is either drivers or filter blocks
<azonenberg> for drivers, you either need a very detailed simulator of the instrument, bug for bug with the actual firmware
<azonenberg> or you need an actual instrument to test against
<azonenberg> For filters, you need either a procedural tool for generating well-formed (or slightly malformed) input, or a corpus of test data
<azonenberg> plus some way to determine whether the filter output is correct, given the input
<azonenberg> except for the very simple filters like "subtract" this is very nontrivial
<azonenberg> i very much want to do it, and i've got tens of gigabytes of test waveforms that i collected with the intention of potentially using some of them as the basis for a test suite
<azonenberg> but building it would be an engineering project on the same scale as building glscopeclient itself i think
<azonenberg> also woo 43% of the way through a full build of the project from clean, most of the way through decodes starting with E
<azonenberg> "only" 122 more files open that i know i have to work on before libscopeprotocols is fully refactored, then on to glscopeclient lol
<azonenberg> getting it done this weekend may be less likely than i thought...
<GenTooMan> well writing an instrument emulator is almost the same order as writing the code for the instrument so yeah that could be a bit of work.
<GenTooMan> I haven't touched scopehal for a while to be honest about it, I should test it with the latest code and see if my updated scope firmware works correctly.
<azonenberg> exactly. now imagine doing that for the dozens or hundreds of supported models
<azonenberg> Hold off a little bit
<azonenberg> there is some major refactoring in progress and a big renderer rewrite coming in the next few weeks
<azonenberg> things might be a bit flaky until that all stabilizes
<azonenberg> if you have an older build that works well, keep on that until the dust settles
<GenTooMan> so what is the last (somewhat) stable tag then? I can just use that. I assume you haven't tagged the current head and are in the midst of making modifications to it.
<azonenberg> We have not made any tags. The project is still pre 0.1
<azonenberg> we've talked about making a formal 0.1 release at some point but keep finding new major things to do before then lol
<azonenberg> like getting distro packaging straightened out and greatly improving the state of documentation
<azonenberg> and now rewriting the renderer and making major changes to the internal data model
<azonenberg> so the tl;dr is that we have never got it to a point that everyone agreed it was someone stable that we'd want to tag :p
<GenTooMan> mm oh.. that's kind of a scarey thought. I always used tags as if obsessed with them. I guess I can't count as stable to be tagged? :D sorry couldn't resist.
<GenTooMan> well you are using git so ... all commits are hashed and have no order to them. ugh ... oh well nary a thing to do about it.
<azonenberg> and well the big thing is just that there's always been things to do before i considered it release worthy
<GenTooMan> hmm it's all a matter of perspective I guess.
<azonenberg> basically, i try not to intentionally break HEAD
<azonenberg> but there are a large number of open bugs as well as just general stability and documentation improvements i want to work on
<_whitenotifier-7> [scopehal] azonenberg created branch waveform-refactor - https://github.com/glscopeclient/scopehal
<azonenberg> [waveform-refactor f944904] Initial work on data model revamp. See #650. 133 files changed, 2643 insertions(+), 2260 deletions(-)
<azonenberg> ok that's a good start
<azonenberg> still a lot more to go
<GenTooMan> their are always more things to do... such is the life of development.
<azonenberg> Down to 102 files left to refactor in scopeprotocols, all of A-E is done
azonenberg has quit [Ping timeout: 255 seconds]
azonenberg has joined #scopehal
GenTooMan has quit [Ping timeout: 260 seconds]
GenTooMan has joined #scopehal
<azonenberg> And finished F/G and most of H. Slow progress but it's going
<azonenberg> 92 files to go