Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of git+ssh://scm.gforge.inria.fr//gitroot/simgrid/simgrid
authorFrederic Suter <frederic.suter@cc.in2p3.fr>
Fri, 27 May 2016 13:50:58 +0000 (15:50 +0200)
committerFrederic Suter <frederic.suter@cc.in2p3.fr>
Fri, 27 May 2016 13:50:58 +0000 (15:50 +0200)
examples/smpi/CMakeLists.txt
examples/smpi/trace_call_location/smpi_trace_call_location
src/simix/ContextRaw.cpp
src/simix/ContextUnix.cpp
src/simix/popping_private.h
src/simix/smx_context.cpp
src/simix/smx_global.cpp
src/simix/smx_network_private.h
src/simix/smx_process_private.h

index b8d676d..e1847b2 100644 (file)
@@ -1,9 +1,5 @@
 if(enable_smpi)
-  if(WIN32)
-    set(CMAKE_C_FLAGS "-include ${CMAKE_HOME_DIRECTORY}/include/smpi/smpi_main.h")
-  else()
-    set(CMAKE_C_COMPILER "${CMAKE_BINARY_DIR}/smpi_script/bin/smpicc")
-  endif()
+  set(CMAKE_C_COMPILER "${CMAKE_BINARY_DIR}/smpi_script/bin/smpicc")
   include_directories(BEFORE "${CMAKE_HOME_DIRECTORY}/include/smpi")
 
   file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/mc/")
index 9ddb4ef..5eb6324 100755 (executable)
Binary files a/examples/smpi/trace_call_location/smpi_trace_call_location and b/examples/smpi/trace_call_location/smpi_trace_call_location differ
index 10330cb..4a34afa 100644 (file)
@@ -61,7 +61,7 @@ public:
   RawContextFactory();
   ~RawContextFactory() override;
   RawContext* create_context(std::function<void()> code,
-    void_pfn_smxprocess_t, smx_process_t process) override;
+    void_pfn_smxprocess_t cleanup, smx_process_t process) override;
   void run_all() override;
 private:
   void run_all_adaptative();
index ebdd9b0..922631f 100644 (file)
@@ -116,7 +116,7 @@ public:
   UContextFactory();
   ~UContextFactory() override;
   Context* create_context(std::function<void()> code,
-    void_pfn_smxprocess_t, smx_process_t process) override;
+    void_pfn_smxprocess_t cleanup, smx_process_t process) override;
   void run_all() override;
 };
 
index 93f0bfe..e8e76b7 100644 (file)
@@ -55,9 +55,9 @@ typedef struct s_smx_simcall {
 
 /******************************** General *************************************/
 
-XBT_PRIVATE void SIMIX_simcall_answer(smx_simcall_t);
-XBT_PRIVATE void SIMIX_simcall_handle(smx_simcall_t, int);
-XBT_PRIVATE void SIMIX_simcall_exit(smx_synchro_t);
+XBT_PRIVATE void SIMIX_simcall_answer(smx_simcall_t simcall);
+XBT_PRIVATE void SIMIX_simcall_handle(smx_simcall_t simcall, int value);
+XBT_PRIVATE void SIMIX_simcall_exit(smx_synchro_t synchro);
 XBT_PRIVATE const char *SIMIX_simcall_name(e_smx_simcall_t kind);
 XBT_PRIVATE void SIMIX_run_kernel(std::function<void()> const* code);
 
index 84da193..3e46ece 100644 (file)
@@ -42,16 +42,16 @@ XBT_LOG_NEW_DEFAULT_SUBCATEGORY(simix_context, simix, "Context switching mechani
 
 static std::pair<const char*, simgrid::simix::ContextFactoryInitializer> context_factories[] = {
 #if HAVE_RAW_CONTEXTS
-  { "raw", simgrid::simix::raw_factory },
+  { "raw", &simgrid::simix::raw_factory },
 #endif
 #if HAVE_UCONTEXT_CONTEXTS
-  { "ucontext", simgrid::simix::sysv_factory },
+  { "ucontext", &simgrid::simix::sysv_factory },
 #endif
 #if HAVE_BOOST_CONTEXTS
-  { "boost", simgrid::simix::boost_factory },
+  { "boost", &simgrid::simix::boost_factory },
 #endif
 #if HAVE_THREAD_CONTEXTS
-  { "thread", simgrid::simix::thread_factory },
+  { "thread", &simgrid::simix::thread_factory },
 #endif
 };
 
index bc31f71..3001ca0 100644 (file)
@@ -131,7 +131,7 @@ static void install_segvhandler(void)
   }
 
   struct sigaction action, old_action;
-  action.sa_sigaction = segvhandler;
+  action.sa_sigaction = &segvhandler;
   action.sa_flags = SA_ONSTACK | SA_RESETHAND | SA_SIGINFO;
   sigemptyset(&action.sa_mask);
 
@@ -205,9 +205,9 @@ void SIMIX_global_init(int *argc, char **argv)
     simix_global->maestro_process = NULL;
     simix_global->registered_functions = xbt_dict_new_homogeneous(NULL);
 
-    simix_global->create_process_function = SIMIX_process_create;
-    simix_global->kill_process_function = kill_process;
-    simix_global->cleanup_process_function = SIMIX_process_cleanup;
+    simix_global->create_process_function = &SIMIX_process_create;
+    simix_global->kill_process_function = &kill_process;
+    simix_global->cleanup_process_function = &SIMIX_process_cleanup;
     simix_global->mutex = xbt_os_mutex_init();
 
     surf_init(argc, argv);      /* Initialize SURF structures */
@@ -218,8 +218,8 @@ void SIMIX_global_init(int *argc, char **argv)
     simgrid::simix::create_maestro(maestro_code);
 
     /* context exception handlers */
-    __xbt_running_ctx_fetch = SIMIX_process_get_running_context;
-    __xbt_ex_terminate = SIMIX_process_exception_terminate;
+    __xbt_running_ctx_fetch = &SIMIX_process_get_running_context;
+    __xbt_ex_terminate = &SIMIX_process_exception_terminate;
 
     /* Prepare to display some more info when dying on Ctrl-C pressing */
     signal(SIGINT, inthandler);
index 55fc699..6eaa039 100644 (file)
@@ -30,7 +30,7 @@ XBT_PRIVATE void SIMIX_mbox_remove(smx_mailbox_t mbox, smx_synchro_t comm);
 XBT_PRIVATE void SIMIX_mbox_set_receiver(smx_mailbox_t mbox, smx_process_t proc);
 XBT_PRIVATE smx_synchro_t SIMIX_comm_irecv(smx_process_t dst_proc, smx_mailbox_t mbox,
                               void *dst_buff, size_t *dst_buff_size,
-                              int (*)(void *, void *, smx_synchro_t),
+                              int (*match_fun)(void *, void *, smx_synchro_t),
                               void (*copy_data_fun)(smx_synchro_t, void*, size_t),
                               void *data, double rate);
 XBT_PRIVATE smx_synchro_t SIMIX_comm_iprobe(smx_process_t dst_proc, smx_mailbox_t mbox, int type, int src,
index 7f6172d..da6cf69 100644 (file)
@@ -119,8 +119,8 @@ XBT_PRIVATE void SIMIX_process_sleep_destroy(smx_synchro_t synchro);
 XBT_PRIVATE void SIMIX_process_auto_restart_set(smx_process_t process, int auto_restart);
 XBT_PRIVATE smx_process_t SIMIX_process_restart(smx_process_t process, smx_process_t issuer);
 
-void SIMIX_segment_index_set(smx_process_t, int);
-extern void (*SMPI_switch_data_segment)(int);
+void SIMIX_segment_index_set(smx_process_t process, int segment_index);
+extern void (*SMPI_switch_data_segment)(int dest);
 
 SG_END_DECL()