Changeset 778 for branches


Ignore:
Timestamp:
Aug 27, 2014, 6:13:01 PM (10 years ago)
Author:
cfuguet
Message:

reconfiguration/tsar_generic_iob: fixing python version incompatibility issues

Location:
branches/reconfiguration/platforms/tsar_generic_iob
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/reconfiguration/platforms/tsar_generic_iob/scripts/faultyprocs.py

    r775 r778  
    1414
    1515    for x, y, l in faulty:
    16         content.append("    ({} << 6) | ({} << 2) | {},\n".format(x, y, l))
     16        content.append("    ({0} << 6) | ({1} << 2) | {2},\n".format(x, y, l))
    1717
    1818    content.append( "};\n"
  • branches/reconfiguration/platforms/tsar_generic_iob/scripts/run.py

    r776 r778  
    2424# translate the relative path (if needed) into an absolute path
    2525basedir = os.path.abspath(sys.argv[1])
    26 print "[ run.py ] platform base directory: {}".format(basedir)
     26print "[ run.py ] platform base directory: {0}".format(basedir)
    2727
    2828# repeat while configurations is not empty
    2929for faulty in faultylist:
    3030    for x,y in configs:
    31         confdir = "{}/conf/config_{}c".format(basedir, x*y)
    32         print "[ run.py ] generating files for {}".format(confdir)
     31        confdir = "{0}/conf/config_{1}c".format(basedir, x*y)
     32        print "[ run.py ] generating files for {0}".format(confdir)
    3333
    3434        # 1. generate configuration and ouput directories
     
    6464        os.environ["DISTRIBUTED_BOOT"] = "1"
    6565        os.environ["SOCLIB_TTY"] = "FILES"
    66         with open(confdir + "/log", "w") as log_file:
     66
     67        if x*y <= 4: ompthreads = x*y
     68        else:        ompthreads = 4
     69        with open(confdir + "/log", "w") as logfile:
     70            print "executing simul.x"
    6771            subprocess.call([basedir + "/simul.x",
    6872                "-SOFT"   , basedir + "/soft/build/soft.elf",
    6973                "-DISK"   , "/dev/null",
    70                 "-NCYCLES", "10000000"],
    71                 stdout=log_file,
    72                 stderr=log_file,
     74                "-THREADS", str(ompthreads),
     75                "-NCYCLES", "1000000"],
     76                stdout=logfile,
     77                stderr=logfile,
    7378                )
    7479
  • branches/reconfiguration/platforms/tsar_generic_iob/top.cpp

    r769 r778  
    150150//               Parallelisation
    151151///////////////////////////////////////////////////
    152 #define USE_OPENMP               0
    153 
    154152#if USE_OPENMP
    155153#include <omp.h>
Note: See TracChangeset for help on using the changeset viewer.