Skip to content
Snippets Groups Projects
Commit 7bda5403 authored by tewk's avatar tewk
Browse files

Fork deadlock fix

parent d30d7f54
No related branches found
No related tags found
No related merge requests found
......@@ -13,7 +13,9 @@ process_lib = libthreaded.la
io_lib = libthreaded_io.la
endif
#sbin_PROGRAMS = slurmd slurmd_nbio slurmd_elan
sbin_PROGRAMS = slurmd slurmd_nbio
noinst_LTLIBRARIES = libelan_interconnect.la \
libno_interconnect.la \
libforked_io.la \
......@@ -25,13 +27,12 @@ noinst_LTLIBRARIES = libelan_interconnect.la \
LDADD = $(top_srcdir)/src/common/libcommon.la \
$(top_srcdir)/src/common/libdaemonize.la \
$(top_srcdir)/src/common/libcred.la \
$(interconnect_lib) \
$(SSL_LIBS)
slurmd_LDADD = $(process_lib) $(io_lib) $(LDADD)
slurmd_nbio_LDADD = $(process_lib) libnb_io.la $(LDADD)
slurmd_LDADD = $(process_lib) $(io_lib) $(LDADD) $(interconnect_lib)
slurmd_nbio_LDADD = $(process_lib) libnb_io.la $(LDADD) $(interconnect_lib)
slurmd_SOURCES = slurmd.c \
common_sources = slurmd.c \
get_mach_stat.c \
read_proc.c \
task_mgr.c \
......@@ -40,14 +41,12 @@ slurmd_SOURCES = slurmd.c \
pipes.c \
locks.c
slurmd_nbio_SOURCES = slurmd.c \
get_mach_stat.c \
read_proc.c \
task_mgr.c \
shmem_struct.c \
circular_buffer.c \
pipes.c \
locks.c
slurmd_SOURCES = $(common_sources)
slurmd_nbio_SOURCES = $(common_sources)
#slurmd_elan_LDADD = libforked.la libforked_io.la $(LDADD) libelan_interconnect.la
#slurmd_elan_SOURCES = $(common_sources)
libforked_la_SOURCES = forked_ctrl.c
libthreaded_la_SOURCES = threaded_ctrl.c
......
......@@ -83,7 +83,11 @@ int fan_out_task_launch ( launch_tasks_request_msg_t * launch_msg )
task_start[i] -> io_streams_dest = launch_msg -> streams ;
if ( launch_task ( task_start[i] ) )
{
info ( "launch_task error " ) ;
goto kill_tasks_label ;
}
info ( "task %i launched" , i ) ;
}
/* wait for all the launched threads to finish */
......@@ -194,16 +198,11 @@ void * task_exec_thread ( void * arg )
/* ask me how I know :) */
/* think once, twice, 10^100000000 times before changeing the below */
/*1*/setup_parent_pipes ( task_start->pipes ) ;
info ( "before waitpid ") ;
/*2*/waitpid ( cpid , & task_return_code , 0 ) ;
info ( "taskid: %i before wait_on_io_threads " , cpid ) ;
/*3*/wait_on_io_threads ( task_start ) ;
info ( "before cleanup_parent_pipes " ) ;
/*4*/cleanup_parent_pipes ( task_start->pipes ) ;
info ( "before end_task_exit_msg" ) ;
send_task_exit_msg ( task_return_code , task_start ) ;
info ( "task_exec_thread done" ) ;
break;
}
return ( void * ) SLURM_SUCCESS ;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment