Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
model-checker : fix number and address of blocks in heap comparison algorithm
[simgrid.git] / src / simix / smx_smurf.c
index df7fb25..ab94a65 100644 (file)
@@ -13,7 +13,8 @@ XBT_INLINE smx_simcall_t SIMIX_simcall_mine()
 
 /**
  * \brief Makes the current process do a simcall to the kernel and yields
- * until completion.
+ * until completion. If the current thread is maestro, we don't yield and
+ * execute the simcall directly.
  * \param self the current process
  */
 void SIMIX_simcall_push(smx_process_t self)
@@ -33,10 +34,12 @@ void SIMIX_simcall_answer(smx_simcall_t simcall)
     XBT_DEBUG("Answer simcall %s (%d) issued by %s (%p)", SIMIX_simcall_name(simcall->call), (int)simcall->call,
         simcall->issuer->name, simcall->issuer);
     simcall->issuer->simcall.call = SIMCALL_NONE;
-    if(!xbt_dynar_member(simix_global->process_to_run, &(simcall->issuer)))
-      xbt_dynar_push_as(simix_global->process_to_run, smx_process_t, simcall->issuer);
-    else
-      DIE_IMPOSSIBLE;
+/*    This check should be useless and slows everyone. Reactivate if you see something
+ *    weird in process scheduling.
+ */
+/*    if(!xbt_dynar_member(simix_global->process_to_run, &(simcall->issuer))) */
+    xbt_dynar_push_as(simix_global->process_to_run, smx_process_t, simcall->issuer);
+/*    else DIE_IMPOSSIBLE; */
   }
 }
 
@@ -306,6 +309,7 @@ void SIMIX_simcall_pre(smx_simcall_t simcall, int value)
          simcall->process_create.code,
          simcall->process_create.data,
          simcall->process_create.hostname,
+         simcall->process_create.kill_time,
          simcall->process_create.argc,
          simcall->process_create.argv,
          simcall->process_create.properties);