1
1

ompi_proc_complete_init_single: make the subroutine public

and accept a proc from a different job
Этот коммит содержится в:
Gilles Gouaillardet 2016-02-19 09:30:18 +09:00
родитель 1df4457af2
Коммит a4aa4c9571
2 изменённых файлов: 15 добавлений и 2 удалений

Просмотреть файл

@ -129,14 +129,15 @@ static int ompi_proc_allocate (ompi_jobid_t jobid, ompi_vpid_t vpid, ompi_proc_t
* retrieving the hostname (if below the modex cutoff), determining the
* remote architecture, and calculating the locality of the process.
*/
static int ompi_proc_complete_init_single (ompi_proc_t *proc)
int ompi_proc_complete_init_single (ompi_proc_t *proc)
{
uint16_t u16, *u16ptr;
int ret;
u16ptr = &u16;
if (OMPI_CAST_RTE_NAME(&proc->super.proc_name)->vpid == OMPI_PROC_MY_NAME->vpid) {
if ((OMPI_CAST_RTE_NAME(&proc->super.proc_name)->jobid == OMPI_PROC_MY_NAME->jobid) &&
(OMPI_CAST_RTE_NAME(&proc->super.proc_name)->vpid == OMPI_PROC_MY_NAME->vpid)) {
/* nothing else to do */
return OMPI_SUCCESS;
}

Просмотреть файл

@ -122,6 +122,18 @@ OMPI_DECLSPEC int ompi_proc_init(void);
*/
OMPI_DECLSPEC int ompi_proc_complete_init(void);
/**
* Complete filling up the proc information (arch, name and locality) for
* a given proc. This function is to be called only after the modex exchange
* has been completed.
*
* @param[in] proc the proc whose information will be filled up
*
* @retval OMPI_SUCCESS All information correctly set.
* @retval OMPI_ERROR Some info could not be initialized.
*/
OMPI_DECLSPEC int ompi_proc_complete_init_single(ompi_proc_t* proc);
/**
* Finalize the OMPI Process subsystem
*