diff --git a/performance.md b/performance.md new file mode 100644 --- /dev/null +++ b/performance.md @@ -0,0 +1,27 @@ +# Performance comparison # +## The base case ## + +Let's assume we have a secret of length _m_. The splitting takes _n_ evaluations of a polynomial of order _k_ (over Galois field 256) for each byte, leading to _O(n\*k\*m)_ finite field multiplications. Reconstruction of the constant parameters during joining first precomputes parts of the Lagrange polynomial and then reuses them for each byte, taking _O(k\*k + k\*m)_ multiplications. + +Benchmark results. The times for split and join mean _seconds per byte_ of the secret length: + + + + + + + + + + + + + + + + + + + + +
RevisionFeaturesk / n parametersSplitJoin
a47ae3e113cc-2 / 35.02e-064.12e-05
254 / 2540.01250.00175
\ No newline at end of file diff --git a/readme.md b/readme.md --- a/readme.md +++ b/readme.md @@ -26,8 +26,8 @@ Benchmark results, all values mean _seco 2 / 3 (a laptop) - 8.7e-06 - 7.17e-05 + 5.02e-06 + 4.12e-05 254 / 254 (a Raspberry Pi 3) @@ -36,8 +36,8 @@ Benchmark results, all values mean _seco 254 / 254 (a laptop) - 0.0209 - 0.00347 + 0.0125 + 0.00175