Beispiel #1
0
    def options(self, nprocs, timeout=None):
        if (self.mpi == 'impi' or self.mpi == 'mpich'):
            if (self.mpi == 'impi'):
                mpiroot = ci_site_config.impi_root
            else:
                mpiroot = '{}/mpich'.format(self.ci_middlewares_path)
            if (self.util_prov):
                prov = '\"{};{}\"'.format(self.core_prov, self.util_prov)
            else:
                prov = self.core_prov

            if (timeout != None):
                os.environ['MPIEXEC_TIMEOUT'] = timeout

            opts = "-n {np} ".format(np=nprocs)
            opts += "-hosts {s},{c} ".format(s=common.get_node_name(\
                                             self.server, self.nw_interface), \
                                             c=common.get_node_name(\
                                             self.client, self.nw_interface))
            opts += "-mpi_root={mpiroot} ".format(mpiroot=mpiroot)
            opts += "-libfabric_path={installpath}/lib " \
                    .format(installpath=self.libfab_installpath)
            opts += "-prov {provider} ".format(provider=prov)

        elif (self.mpi == 'ompi'):
            print(self.mpi)

        return opts
Beispiel #2
0
    def options(self):
        opts = "-T 300 -vvv -p {} -S ".format(self.fabtestpath)
        if (self.core_prov != 'shm' and self.nw_interface):
            opts = "{} -s {} ".format(
                opts,
                common.get_node_name(self.server,
                                     self.nw_interface))  # include common.py
            opts = "{} -c {} ".format(opts,
                                      common.get_node_name(
                                          self.client,
                                          self.nw_interface))  # from common.py

        if (self.core_prov == 'shm'):
            opts = "{} -s {} ".format(opts, self.server)
            opts = "{} -c {} ".format(opts, self.client)
            opts += "-N "

        if (self.ofi_build_mode == 'dl'):
            opts = "{} -t short ".format(opts)
        else:
            opts = "{} -t all ".format(opts)

        if (self.core_prov == 'sockets' and self.ofi_build_mode == 'reg'):
            complex_test_file = '{}/share/fabtests/test_configs/{}/quick.test' \
                                .format(self.libfab_installpath,
                                self.core_prov)
            if (os.path.isfile(complex_test_file)):
                opts = "{} -u {} ".format(opts, complex_test_file)
            else:
                print("{} Complex test file not found".format(self.core_prov))

        if (self.ofi_build_mode != 'reg' or self.core_prov == 'udp'):
            opts = "{} -e \'ubertest,multinode\'".format(opts)

        efile = self.get_exclude_file()
        if efile:
            opts = "{} -R ".format(opts)
            opts = "{} -f {} ".format(opts, efile)

        for key, val in self.env:
            opts = "{options} -E {key}={value} ".format(options=opts,
                                                        key=key,
                                                        value=val)

        if self.util_prov:
            opts = "{options} {core};{util} ".format(options=opts,
                                                     core=self.core_prov,
                                                     util=self.util_prov)
        else:
            opts = "{options} {core} ".format(options=opts,
                                              core=self.core_prov)

        if (self.core_prov == 'shm'):
            opts += "{} {} ".format(self.server, self.server)
        else:
            opts += "{} {} ".format(self.server, self.client)

        return opts
Beispiel #3
0
    def options(self):
        opts = []
        if (self.mpi == 'impi' or self.mpi == 'mpich'):
            opts = "-n {} ".format(self.n)
            opts += "-ppn {} ".format(self.ppn)
            opts += "-hosts {},{} ".format(
                common.get_node_name(self.server, self.nw_interface),
                common.get_node_name(self.client, self.nw_interface))

            if (self.mpi == 'impi'):
                opts = "{} -mpi_root={} ".format(opts,
                                                 ci_site_config.impi_root)
            else:
                opts = "{} -mpi_root={}/mpich".format(opts,
                                                      self.ci_middlewares_path)

            opts = "{} -libfabric_path={}/lib ".format(opts,
                                                       self.libfab_installpath)

            if self.util_prov:
                opts = "{options} -prov {core};{util} ".format(
                    options=opts, core=self.core_prov, util=self.util_prov)
            else:
                opts = "{} -prov {} ".format(opts, self.core_prov)

            for key, val in self.env:
                opts = "{} -genv {} {} ".format(opts, key, val)

        elif (self.mpi == 'ompi'):
            opts = "-np {} ".format(self.n)
            hosts = ','.join([':'.join([common.get_node_name(host, \
                             self.nw_interface), str(self.ppn)]) \
                    for host in self.hosts])

            opts = "{} --host {} ".format(opts, hosts)

            if self.util_prov:
                opts = "{} --mca mtl_ofi_provider_include {};{} ".format(
                    opts, self.core_prov, self.util_prov)
            else:
                opts = "{} --mca mtl_ofi_provider_include {} ".format(
                    opts, self.core_prov)

            opts += "--mca orte_base_help_aggregate 0 "
            opts += "--mca mtl ofi --mca pml cm -tag-output "
            for key, val in self.env:
                opts = "{} -x {}={} ".format(opts, key, val)
        return opts
Beispiel #4
0
    def options(self):
        opts = "-vvv -p {} -S ".format(self.fabtestpath)
        if (self.core_prov == "verbs" and self.nw_interface):
            opts = "{} -s {} ".format(
                opts,
                common.get_node_name(self.server,
                                     self.nw_interface))  # include common.py
            opts = "{} -c {} ".format(opts,
                                      common.get_node_name(
                                          self.client,
                                          self.nw_interface))  # from common.py

        if (self.core_prov == "shm"):
            opts = "{} -s {} ".format(opts, self.server)
            opts = "{} -c {} ".format(opts, self.client)
            opts += "-N "

        if not re.match(".*sockets|udp|tcp.*", self.core_prov):
            opts = "{} -t all ".format(opts)

        efile = self.get_exclude_file()
        if efile:
            opts = "{} -R ".format(opts)
            opts = "{} -f {} ".format(opts, efile)

        for key, val in self.env:
            opts = "{options} -E {key}={value} ".format(options=opts,
                                                        key=key,
                                                        value=val)

        if self.util_prov:
            opts = "{options} {core};{util} ".format(options=opts,
                                                     core=self.core_prov,
                                                     util=self.util_prov)
        else:
            opts = "{options} {core} ".format(options=opts,
                                              core=self.core_prov)

        if (self.core_prov == "shm"):
            opts += "{} {} ".format(self.client, self.server)
        else:
            opts += "{} {} ".format(self.server, self.client)

        return opts
Beispiel #5
0
    def options(self):
        opts = f"-np {self.n} "
        hosts = '\',\''.join([':'.join([common.get_node_name(host, \
                         self.nw_interface), str(self.ppn)]) \
                for host in self.hosts])
        opts += f"--host \'{hosts}\' "
        if self.util_prov:
            opts += f"--mca mtl_ofi_provider_include {self.core_prov}\\;"\
                    f"{self.util_prov} "
            opts += f"--mca btl_ofi_provider_include {self.core_prov}\\;"\
                    f"{self.util_prov} "
        else:
            opts += f"--mca mtl_ofi_provider_include {self.core_prov} "
            opts += f"--mca btl_ofi_provider_include {self.core_prov} "
        opts += "--mca orte_base_help_aggregate 0 "
        opts += "--mca mtl ofi "
        opts += "--mca pml cm -tag-output "
        for key, val in self.environ:
            opts += f"-x {key}={val} "

        return opts