[Libre-soc-bugs] [Bug 1159] poly1305 unit tests

bugzilla-daemon at libre-soc.org bugzilla-daemon at libre-soc.org
Wed Sep 20 18:59:34 BST 2023


https://bugs.libre-soc.org/show_bug.cgi?id=1159

--- Comment #2 from Luke Kenneth Casson Leighton <lkcl at lkcl.net> ---
(In reply to Sadoon Albader from comment #1)
> Rough brainstorming:
> 
> To implement comprehensive unit tests we need to understand what we're
> testing, figure out the normal cases, edge cases, and additional behavior
> that is specifically related to SVP64.

so just like in the Test API, there are actually *three* things
to test (all with the same data). actually 4 when it comes to it.
no, 5! no 6!

1. python Poly1305 class instance
2. python Poly1305Donna class instance
3. SVP64 assembler (in test_caller_xxxyyy.py)
4. HDL (when it is able to run REMAP and elwidth overrides)
5. pypowersim (this is "optional" for you as it is extra work)
   running the poly1305-donna.h program compiled to *SFFS* which
   you would be converting slowly using (3) to...
6. pypowersim running svp64.

but i would suggest stopping at (3), i will happily sign-off the entire
RFP up to there :)

nice thing is, you can actually write the unit tests *right now* for 1 and 2
but please do also write some "mini" intermediary unit tests for each
group of 3-6 lines (a group doing h0+= h1 += h2 +=) so that you are
*truly* confident that each group does the job; then when you come to
plug all those "bits" together you will go "pffh, i *know* this should
work"

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


More information about the libre-soc-bugs mailing list