X-Git-Url: https://git.cryptolib.org/avr-crypto-lib.git?a=blobdiff_plain;f=host%2Fperformance2wiki.rb;h=cfdc3cefbed050d8242fd9b06794682385f6bd7f;hb=c9c11514d91b8c19f77d65ac051b998bd99048b0;hp=a60cde153a0eb29f517586347d7743ebb0988f35;hpb=96e930bbd293d62d8a9d2b011eb958aee6840c42;p=avr-crypto-lib.git diff --git a/host/performance2wiki.rb b/host/performance2wiki.rb index a60cde1..cfdc3ce 100644 --- a/host/performance2wiki.rb +++ b/host/performance2wiki.rb @@ -56,10 +56,26 @@ def process_hashfunction(fin, name) lb = fin.readline() m = lb.match(/ctx2hash \(cycles\):[\s]*([\d]*)/) convtime = m[1].to_i() + begin + lb = fin.readline() + end until m = lb.match(/init \(bytes\):[\s]*([\d]*)/) + initstack = m[1].to_i() + lb = fin.readline() + m = lb.match(/nextBlock \(bytes\):[\s]*([\d]*)/) + nextblockstack = m[1].to_i() + lb = fin.readline() + m = lb.match(/lastBlock \(bytes\):[\s]*([\d]*)/) + lastblockstack = m[1].to_i() + lb = fin.readline() + m = lb.match(/ctx2hash \(bytes\):[\s]*([\d]*)/) + convstack = m[1].to_i() + s1 = (initstack>nextblockstack)?initstack:nextblockstack + s2 = (lastblockstack>convstack)?lastblockstack:convstack + stack = (s1>s2)?s1:s2 - printf("| %20s || %3s || %3s || || %4d || || %4d || %4d ||" + + printf("| %20s || %3s || %3s || || %4d || %4d || %4d || %4d ||" + " %6d || %6d || %7.2f || %6d || || || \n|-\n" , - name, $lang, $lang ,ctxsize, hashsize, blocksize, + name, $lang, $lang ,ctxsize, stack, hashsize, blocksize, inittime, nextblocktime, nextblocktime.to_f/(blocksize/8), lastblocktime+convtime) end