X-Git-Url: https://git.distorted.org.uk/u/mdw/catacomb/blobdiff_plain/83c017f3fb115a67734e94dca02095b62cae5e80..e01981257b33a7eac8ff08e97b801c033a2d38f3:/tests/mpx diff --git a/tests/mpx b/tests/mpx index eee85b6..e8aabac 100644 --- a/tests/mpx +++ b/tests/mpx @@ -1,6 +1,6 @@ # Test vectors for low-level MP functions # -# $Id: mpx,v 1.5 2000/06/17 12:11:39 mdw Exp $ +# $Id: mpx,v 1.8 2002/10/06 22:52:50 mdw Exp $ # --- Load-store tests --- # @@ -20,10 +20,31 @@ load-store { 522f8b1de257972a25ec49c9ff56340e2684e847ef2fa4d5714d7c8d454e90f6; } +# --- Two's complement tests --- + +2cb { + "" ""; + 00 00; + 000000 00000000000000000000; + 01 ff; + 0123456789abcdef fedcba9876543211; + 0123456789abcdef fffffffedcba9876543211; + 0100000000 ffffff00000000; +} + +2cl { + "" ""; + 00 00; + 000000 00000000000000000000; + 01 ff; + efcdab8967452301 1132547698badcfe; + efcdab8967452301 1132547698badcfeffffffff; + 0000000001 00000000ffffffff; +} + # --- Shift tests --- lsl { - # --- Simple sanity checks --- 01 2 04; @@ -108,7 +129,6 @@ lsl { } lsr { - # --- Simple sanity checks --- 04 2 01; @@ -760,4 +780,11 @@ udiv { 620d87bb63872a40fc2092b0ed7d3ec4b648be41 0155177e99a8a5113226ff8270 2ea2205327e66d75990cc999fc2380883ee4591a; + + # --- Bugs --- + + 1a923b3406cbe81b093ce418f6a73107f504502b2e3d1b200762fcf6062723de405cab0aea00000000000000000000000000000000 + 184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000 + 0117d3db34ad005954459be9abedd0e5deb4ea0000000000000000 + 00; }