Forráskód Böngészése

profiling: always display the total power consumption when STARPU_IDLE_POWER is set

Samuel Pitoiset 9 éve
szülő
commit
572224c0cd
1 módosított fájl, 2 hozzáadás és 3 törlés
  1. 2 3
      src/profiling/profiling_helpers.c

+ 2 - 3
src/profiling/profiling_helpers.c

@@ -105,9 +105,8 @@ void starpu_profiling_worker_helper_display_summary(void)
 			double idle_consumption = idle_power * overall_time / 1000.; /* J */
 			double idle_consumption = idle_power * overall_time / 1000.; /* J */
 
 
 			fprintf(stderr, "Idle consumption: %.2lf J\n", idle_consumption);
 			fprintf(stderr, "Idle consumption: %.2lf J\n", idle_consumption);
-			sum_consumed += idle_consumption;
+			fprintf(stderr, "Total consumption: %.2lf J\n",
+				sum_consumed + idle_consumption);
 		}
 		}
 	}
 	}
-	if (profiling && sum_consumed)
-		fprintf(stderr, "Total consumption: %.2lf J\n", sum_consumed);
 }
 }