Browse Source

src: disable handler signal when generating trace

Nathalie Furmento 3 years ago
parent
commit
0cabc92c53
2 changed files with 4 additions and 0 deletions
  1. 2 0
      src/common/fxt.c
  2. 2 0
      src/core/workers.h

+ 2 - 0
src/common/fxt.c

@@ -20,6 +20,7 @@
 #include <core/simgrid.h>
 #include <starpu_util.h>
 #include <starpu_profiling.h>
+#include <core/workers.h>
 
 /* we need to identify each task to generate the DAG. */
 unsigned long _starpu_job_cnt = 0;
@@ -318,6 +319,7 @@ void _starpu_stop_fxt_profiling(void)
 		int generate_trace = starpu_get_env_number("STARPU_GENERATE_TRACE");
 		if (generate_trace == 1)
 		{
+			_starpu_set_catch_signals(0);
 			char *fxt_prefix = starpu_getenv("STARPU_FXT_PREFIX");
 			_starpu_generate_paje_trace(_starpu_prof_file_user, "paje.trace", fxt_prefix);
 		}

+ 2 - 0
src/core/workers.h

@@ -434,6 +434,8 @@ extern int _starpu_keys_initialized;
 extern starpu_pthread_key_t _starpu_worker_key;
 extern starpu_pthread_key_t _starpu_worker_set_key;
 
+void _starpu_set_catch_signals(int do_catch_signal);
+
 /** Three functions to manage argv, argc */
 void _starpu_set_argc_argv(int *argc, char ***argv);
 int *_starpu_get_argc();