- /* FIXME: a global variable would be less expensive to consult than a call to xbt_cfg_get_double() right on the critical path */
- if (duration >= sg_cfg_get_double("smpi/cpu_threshold")) {
- XBT_DEBUG("Sleep for %f to handle real computation time", duration);
- smpi_execute_flops(duration *
- sg_cfg_get_double("smpi/running_power"));
+ if (duration >= smpi_cpu_threshold) {
+ XBT_DEBUG("Sleep for %g to handle real computation time", duration);
+ double flops = duration * smpi_running_power;
+#ifdef HAVE_TRACING
+ int rank = smpi_process_index();
+ instr_extra_data extra = xbt_new0(s_instr_extra_data_t,1);
+ extra->type=TRACING_COMPUTING;
+ extra->comp_size=flops;
+ TRACE_smpi_computing_in(rank, extra);
+#endif
+ smpi_execute_flops(flops);
+
+#ifdef HAVE_TRACING
+ TRACE_smpi_computing_out(rank);
+#endif
+