X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/ea10e88fd41a11386d9e3868d72ab8cb933a4292..09392faf42646e631a4e42553e901410eb3e488e:/teshsuite/smpi/MBI/CollLocalConcurrencyGenerator.py diff --git a/teshsuite/smpi/MBI/CollLocalConcurrencyGenerator.py b/teshsuite/smpi/MBI/CollLocalConcurrencyGenerator.py index 4eccf015c0..2ff3357e8e 100755 --- a/teshsuite/smpi/MBI/CollLocalConcurrencyGenerator.py +++ b/teshsuite/smpi/MBI/CollLocalConcurrencyGenerator.py @@ -1,7 +1,7 @@ #! /usr/bin/python3 import os import sys -from generator_utils import * +import generator_utils as gen template = """// @{generatedby}@ /* ///////////////////////// The MPI Bugs Initiative //////////////////////// @@ -68,23 +68,23 @@ int main(int argc, char **argv) { } """ -for c in icoll + pcoll: +for c in gen.icoll + gen.pcoll: patterns = {} patterns = {'c': c} patterns['generatedby'] = f'DO NOT EDIT: this file was generated by {os.path.basename(sys.argv[0])}. DO NOT EDIT.' - patterns['icollfeature'] = 'Yes' if c in icoll else 'Lacking' - patterns['pcollfeature'] = 'Yes' if c in pcoll else 'Lacking' + patterns['icollfeature'] = 'Yes' if c in gen.icoll else 'Lacking' + patterns['pcollfeature'] = 'Yes' if c in gen.pcoll else 'Lacking' patterns['c'] = c - patterns['init'] = init[c]("1") - patterns['start'] = start[c]("1") - patterns['fini'] = fini[c]("1") - patterns['operation'] = operation[c]("1") - patterns['write'] = write[c]("1") - patterns['free'] = free[c]("1") - - replace = patterns + patterns['init'] = gen.init[c]("1") + patterns['start'] = gen.start[c]("1") + patterns['fini'] = gen.fini[c]("1") + patterns['operation'] = gen.operation[c]("1") + patterns['write'] = gen.write[c]("1") + patterns['free'] = gen.free[c]("1") + + replace = patterns.copy() replace['shortdesc'] = 'Local concurrency with a collective' replace['longdesc'] = f'The buffer in {c} is modified before the call has been completed.' replace['outcome'] = 'ERROR: LocalConcurrency' replace['errormsg'] = 'Local Concurrency with a collective. The buffer in @{c}@ is modified at @{filename}@:@{line:MBIERROR}@ whereas there is no guarantee the call has been completed.' - make_file(template, f'LocalConcurrency_{c}_nok.c', replace) + gen.make_file(template, f'LocalConcurrency_{c}_nok.c', replace)