Need to have the event thread running during init/finalize, but we still have a problem with cleanup - so comment out the event_base_free for now.
This commit was SVN r27738.
Этот коммит содержится в:
родитель
c65de32218
Коммит
81a8e21939
@ -63,6 +63,15 @@ int orte_finalize(void)
|
||||
/* set the flag indicating we are finalizing */
|
||||
orte_finalizing = true;
|
||||
|
||||
/* close the orte_show_help system */
|
||||
orte_show_help_finalize();
|
||||
|
||||
/* call the finalize function for this environment */
|
||||
orte_ess.finalize();
|
||||
|
||||
/* close the ess itself */
|
||||
orte_ess_base_close();
|
||||
|
||||
#if ORTE_ENABLE_PROGRESS_THREADS
|
||||
/* stop the progress thread */
|
||||
orte_event_base_active = false;
|
||||
@ -72,18 +81,9 @@ int orte_finalize(void)
|
||||
opal_thread_join(&orte_progress_thread, NULL);
|
||||
OBJ_DESTRUCT(&orte_progress_thread);
|
||||
/* release the event base */
|
||||
opal_event_base_free(orte_event_base);
|
||||
/* opal_event_base_free(orte_event_base); */
|
||||
#endif
|
||||
|
||||
/* close the orte_show_help system */
|
||||
orte_show_help_finalize();
|
||||
|
||||
/* call the finalize function for this environment */
|
||||
orte_ess.finalize();
|
||||
|
||||
/* close the ess itself */
|
||||
orte_ess_base_close();
|
||||
|
||||
/* cleanup the process info */
|
||||
orte_proc_info_finalize();
|
||||
|
||||
|
@ -141,6 +141,14 @@ int orte_init(int* pargc, char*** pargv, orte_proc_type_t flags)
|
||||
#if OPAL_EVENT_HAVE_THREAD_SUPPORT
|
||||
/* get a separate orte event base */
|
||||
orte_event_base = opal_event_base_create();
|
||||
/* construct the thread object */
|
||||
OBJ_CONSTRUCT(&orte_progress_thread, opal_thread_t);
|
||||
/* fork off a thread to progress it */
|
||||
orte_progress_thread.t_run = orte_progress_thread_engine;
|
||||
if (OPAL_SUCCESS != (ret = opal_thread_start(&orte_progress_thread))) {
|
||||
error = "orte progress thread start";
|
||||
goto error;
|
||||
}
|
||||
#else
|
||||
error = "event thread support is not configured";
|
||||
ret = ORTE_ERROR;
|
||||
@ -157,18 +165,6 @@ int orte_init(int* pargc, char*** pargv, orte_proc_type_t flags)
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* start the event thread, if required */
|
||||
#if ORTE_ENABLE_PROGRESS_THREADS
|
||||
/* construct the thread object */
|
||||
OBJ_CONSTRUCT(&orte_progress_thread, opal_thread_t);
|
||||
/* fork off a thread to progress it */
|
||||
orte_progress_thread.t_run = orte_progress_thread_engine;
|
||||
if (OPAL_SUCCESS != (ret = opal_thread_start(&orte_progress_thread))) {
|
||||
error = "orte progress thread start";
|
||||
goto error;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* All done */
|
||||
return ORTE_SUCCESS;
|
||||
|
||||
|
Загрузка…
Ссылка в новой задаче
Block a user