viff

changeset 1329:c4803511dbf8

apps/aes: Adapted program counters.
author Marcel Keller <mkeller@cs.au.dk>
date Fri, 23 Oct 2009 15:03:30 +0200
parents 444954db1fc9
children 6f02ecfa60e1
files apps/aes.py
diffstat 1 files changed, 8 insertions(+), 8 deletions(-) [+]
line diff
     1.1 --- a/apps/aes.py	Fri Oct 23 14:59:34 2009 +0200
     1.2 +++ b/apps/aes.py	Fri Oct 23 15:03:30 2009 +0200
     1.3 @@ -129,30 +129,30 @@
     1.4              js = [3 + i * 23 + j for i in range(20)
     1.5                    for j in range(0, 14, 2) + [15]]
     1.6          elif options.exponentiation == 0 or options.exponentiation == 3:
     1.7 -            max = 561
     1.8 -            js = [1 + i * 28 + j * 2 for i in range(20) for j in range(13)]
     1.9 +            max = 821
    1.10 +            js = [1 + i * 41 + j * 3 for i in range(20) for j in range(13)]
    1.11          elif options.exponentiation == 1 or options.exponentiation == 2:
    1.12 -            max = 481
    1.13 -            js = [1 + i * 24 + j * 2 for i in range(20) for j in range(11)]
    1.14 +            max = 701
    1.15 +            js = [1 + i * 35 + j * 3 for i in range(20) for j in range(11)]
    1.16  
    1.17          if options.exponentiation == 4:
    1.18 -            pcs = [(2, 1 + i, 2 + 2 * j)
    1.19 +            pcs = [(2, 1 + i, 2 + 3 * j)
    1.20                     for i in range(10 * options.count)
    1.21                     for j in range(140)] + \
    1.22 -                  [(3, 17, k) + (121,) * i + (4 + 6 * j, 1 + 2 * l)
    1.23 +                  [(3, 18, k) + (121,) * i + (4 + 6 * j, 1 + 3 * l)
    1.24                     for k in range(1, options.count + 1)
    1.25                     for i in range(10)
    1.26                     for j in range(20)
    1.27                     for l in range(6)]
    1.28          else:
    1.29 -            pcs = [(2, 17, k) + (max,) * i + (j,)
    1.30 +            pcs = [(2, 18, k) + (max,) * i + (j,)
    1.31                     for k in range(1, options.count + 1)
    1.32                     for i in range(10)
    1.33                     for j in js]
    1.34          program_desc[("generate_triples", (GF256,))] = pcs
    1.35  
    1.36      if options.exponentiation == 4:
    1.37 -        pcs = [(3, 17, k) + (121,) * i + (1 + j * 6,)
    1.38 +        pcs = [(3, 18, k) + (121,) * i + (1 + j * 6,)
    1.39                 for k in range(1, options.count + 1)
    1.40                 for i in range(10)
    1.41                 for j in range(20)]