Bläddra i källkod

starpu_perfmodel_plot: Use a different output name for power graphs

Samuel Thibault 4 år sedan
förälder
incheckning
a3a738657a
1 ändrade filer med 5 tillägg och 2 borttagningar
  1. 5 2
      tools/starpu_perfmodel_plot.c

+ 5 - 2
tools/starpu_perfmodel_plot.c

@@ -495,7 +495,7 @@ static void display_selected_models(FILE *gnuplot_file, struct starpu_perfmodel
 	fprintf(gnuplot_file, "#!/usr/bin/gnuplot -persist\n");
 	fprintf(gnuplot_file, "\n");
 	fprintf(gnuplot_file, "set term postscript eps enhanced color\n");
-	fprintf(gnuplot_file, "set output \"starpu_%s.eps\"\n", options->symbol);
+	fprintf(gnuplot_file, "set output \"starpu_%s%s.eps\"\n", options->energy_symbol?"power_":"", options->symbol);
 	fprintf(gnuplot_file, "set title \"Model for codelet %s\"\n", symbol);
 	fprintf(gnuplot_file, "set xlabel \"Total data size\"\n");
 	if (options->gflops)
@@ -597,7 +597,10 @@ int main(int argc, char **argv)
 			}
 #endif
 
-			snprintf(gnuplot_file_name, sizeof(gnuplot_file_name), "starpu_%s.gp", options.symbol);
+			if (options.energy_symbol)
+				snprintf(gnuplot_file_name, sizeof(gnuplot_file_name), "starpu_power_%s.gp", options.symbol);
+			else
+				snprintf(gnuplot_file_name, sizeof(gnuplot_file_name), "starpu_%s.gp", options.symbol);
 			snprintf(options.avg_file_name, sizeof(options.avg_file_name), "starpu_%s_avg.data", options.symbol);
 
 			FILE *gnuplot_file = fopen(gnuplot_file_name, "w+");