Browse Source

fixing bandwidth names in traces (so MemManager and MPI bandwidths have different aliases)

Luka Stanisic 8 years ago
parent
commit
39c66ea330
3 changed files with 28 additions and 28 deletions
  1. 8 8
      src/debug/traces/starpu_fxt.c
  2. 12 12
      src/debug/traces/starpu_fxt_mpi.c
  3. 8 8
      src/debug/traces/starpu_paje.c

+ 8 - 8
src/debug/traces/starpu_fxt.c

@@ -850,12 +850,12 @@ static void handle_new_mem_node(struct fxt_ev_64 *ev, struct starpu_fxt_options
 		{
 #ifdef STARPU_HAVE_POTI
 			poti_SetVariable(get_event_time_stamp(ev, options), new_memmanager_container_alias, "use", 0.0);
-			poti_SetVariable(get_event_time_stamp(ev, options), new_memmanager_container_alias, "bwi", 0.0);
-			poti_SetVariable(get_event_time_stamp(ev, options), new_memmanager_container_alias, "bwo", 0.0);
+			poti_SetVariable(get_event_time_stamp(ev, options), new_memmanager_container_alias, "bwi_mm", 0.0);
+			poti_SetVariable(get_event_time_stamp(ev, options), new_memmanager_container_alias, "bwo_mm", 0.0);
 #else
 			fprintf(out_paje_file, "13	%.9f	%smm%"PRIu64"	use	0.0\n", get_event_time_stamp(ev, options), prefix, ev->param[0]);
-			fprintf(out_paje_file, "13	%.9f	%smm%"PRIu64"	bwi	0.0\n", get_event_time_stamp(ev, options), prefix, ev->param[0]);
-			fprintf(out_paje_file, "13	%.9f	%smm%"PRIu64"	bwo	0.0\n", get_event_time_stamp(ev, options), prefix, ev->param[0]);
+			fprintf(out_paje_file, "13	%.9f	%smm%"PRIu64"	bwi_mm	0.0\n", get_event_time_stamp(ev, options), prefix, ev->param[0]);
+			fprintf(out_paje_file, "13	%.9f	%smm%"PRIu64"	bwo_mm	0.0\n", get_event_time_stamp(ev, options), prefix, ev->param[0]);
 #endif
 		}
 	}
@@ -2488,9 +2488,9 @@ void _starpu_fxt_display_bandwidth(struct starpu_fxt_options *options)
 #ifdef STARPU_HAVE_POTI
 			char src_memnode_container[STARPU_POTI_STR_LEN];
 			memmanager_container_alias(src_memnode_container, STARPU_POTI_STR_LEN, prefix, itor->src_node);
-			poti_SetVariable(itor->comm_start, src_memnode_container, "bwo", current_bandwidth_out_per_node[itor->src_node]);
+			poti_SetVariable(itor->comm_start, src_memnode_container, "bwo_mm", current_bandwidth_out_per_node[itor->src_node]);
 #else
-			fprintf(out_paje_file, "13	%.9f	%smm%u	bwo	%f\n",
+			fprintf(out_paje_file, "13	%.9f	%smm%u	bwo_mm	%f\n",
 				itor->comm_start, prefix, itor->src_node, current_bandwidth_out_per_node[itor->src_node]);
 #endif
 		}
@@ -2501,9 +2501,9 @@ void _starpu_fxt_display_bandwidth(struct starpu_fxt_options *options)
 #ifdef STARPU_HAVE_POTI
 			char dst_memnode_container[STARPU_POTI_STR_LEN];
 			memmanager_container_alias(dst_memnode_container, STARPU_POTI_STR_LEN, prefix, itor->dst_node);
-			poti_SetVariable(itor->comm_start, dst_memnode_container, "bwi", current_bandwidth_in_per_node[itor->dst_node]);
+			poti_SetVariable(itor->comm_start, dst_memnode_container, "bwi_mm", current_bandwidth_in_per_node[itor->dst_node]);
 #else
-			fprintf(out_paje_file, "13	%.9f	%smm%u	bwi	%f\n",
+			fprintf(out_paje_file, "13	%.9f	%smm%u	bwi_mm	%f\n",
 				itor->comm_start, prefix, itor->dst_node, current_bandwidth_in_per_node[itor->dst_node]);
 #endif
 		}

+ 12 - 12
src/debug/traces/starpu_fxt_mpi.c

@@ -229,11 +229,11 @@ static void display_all_transfers_from_trace(FILE *out_paje_file, unsigned n)
 	{
 #ifdef STARPU_HAVE_POTI
 		snprintf(mpi_container, sizeof(mpi_container), "%u_mpict", node);
-		poti_SetVariable(0., mpi_container, "bwi", 0.);
-		poti_SetVariable(0., mpi_container, "bwo", 0.);
+		poti_SetVariable(0., mpi_container, "bwi_mpi", 0.);
+		poti_SetVariable(0., mpi_container, "bwo_mpi", 0.);
 #else
-		fprintf(out_paje_file, "13	%.9f	%u_mpict	bwi	%f\n", 0., node, 0.);
-		fprintf(out_paje_file, "13	%.9f	%u_mpict	bwo	%f\n", 0., node, 0.);
+		fprintf(out_paje_file, "13	%.9f	%u_mpict	bwi_mpi	%f\n", 0., node, 0.);
+		fprintf(out_paje_file, "13	%.9f	%u_mpict	bwo_mpi	%f\n", 0., node, 0.);
 #endif
 	}
 
@@ -272,12 +272,12 @@ static void display_all_transfers_from_trace(FILE *out_paje_file, unsigned n)
 			current_in_bandwidth[match->dst] -= match->bandwidth;
 #ifdef STARPU_HAVE_POTI
 			snprintf(mpi_container, sizeof(mpi_container), "%d_mpict", match->src);
-			poti_SetVariable(match->date, mpi_container, "bwo", current_out_bandwidth[match->src]);
+			poti_SetVariable(match->date, mpi_container, "bwo_mpi", current_out_bandwidth[match->src]);
 			snprintf(mpi_container, sizeof(mpi_container), "%d_mpict", match->dst);
-			poti_SetVariable(match->date, mpi_container, "bwi", current_in_bandwidth[match->dst]);
+			poti_SetVariable(match->date, mpi_container, "bwi_mpi", current_in_bandwidth[match->dst]);
 #else
-			fprintf(out_paje_file, "13	%.9f	%d_mpict	bwo	%f\n", match->date, match->src, current_out_bandwidth[match->src]);
-			fprintf(out_paje_file, "13	%.9f	%d_mpict	bwi	%f\n", match->date, match->dst, current_in_bandwidth[match->dst]);
+			fprintf(out_paje_file, "13	%.9f	%d_mpict	bwo_mpi	%f\n", match->date, match->src, current_out_bandwidth[match->src]);
+			fprintf(out_paje_file, "13	%.9f	%d_mpict	bwi_mpi	%f\n", match->date, match->dst, current_in_bandwidth[match->dst]);
 #endif
 			continue;
 		}
@@ -324,15 +324,15 @@ static void display_all_transfers_from_trace(FILE *out_paje_file, unsigned n)
 			snprintf(paje_key, STARPU_POTI_STR_LEN, "mpicom_%lu", id);
 			snprintf(mpi_container, sizeof(mpi_container), "%d_mpict", src);
 			poti_StartLink(start_date, "MPICt", "MPIL", mpi_container, paje_value, paje_key);
-			poti_SetVariable(start_date, mpi_container, "bwo", current_out_bandwidth[src]);
+			poti_SetVariable(start_date, mpi_container, "bwo_mpi", current_out_bandwidth[src]);
 			snprintf(mpi_container, sizeof(mpi_container), "%d_mpict", dst);
 			poti_EndLink(end_date, "MPICt", "MPIL", mpi_container, paje_value, paje_key);
-			poti_SetVariable(start_date, mpi_container, "bwo", current_in_bandwidth[dst]);
+			poti_SetVariable(start_date, mpi_container, "bwo_mpi", current_in_bandwidth[dst]);
 #else
 			fprintf(out_paje_file, "18	%.9f	MPIL	MPIroot	%lu	%d_mpict	mpicom_%lu\n", start_date, (unsigned long)size, src, id);
 			fprintf(out_paje_file, "19	%.9f	MPIL	MPIroot	%lu	%d_mpict	mpicom_%lu\n", end_date, (unsigned long)size, dst, id);
-			fprintf(out_paje_file, "13	%.9f	%d_mpict	bwo	%f\n", start_date, src, current_out_bandwidth[src]);
-			fprintf(out_paje_file, "13	%.9f	%d_mpict	bwi	%f\n", start_date, dst, current_in_bandwidth[dst]);
+			fprintf(out_paje_file, "13	%.9f	%d_mpict	bwo_mpi	%f\n", start_date, src, current_out_bandwidth[src]);
+			fprintf(out_paje_file, "13	%.9f	%d_mpict	bwi_mpi	%f\n", start_date, dst, current_in_bandwidth[dst]);
 #endif
 		}
 		else

+ 8 - 8
src/debug/traces/starpu_paje.c

@@ -161,8 +161,8 @@ void _starpu_fxt_write_paje_header(FILE *file STARPU_ATTRIBUTE_UNUSED)
 	/* Types for the memory node */
 	poti_DefineEventType("invalidate", "Mm", "data invalidation");
 	poti_DefineVariableType("use", "Mm", "Used (MB)", "0 0 0");
-	poti_DefineVariableType("bwi", "Mm", "Bandwidth In (MB/s)", "0 0 0");
-	poti_DefineVariableType("bwo", "Mm", "Bandwidth Out (MB/s)", "0 0 0");
+	poti_DefineVariableType("bwi_mm", "Mm", "Bandwidth In (MB/s)", "0 0 0");
+	poti_DefineVariableType("bwo_mm", "Mm", "Bandwidth Out (MB/s)", "0 0 0");
 	poti_DefineStateType("MS", "Mm", "Memory Node State");
 	poti_DefineEntityValue("A", "MS", "Allocating", ".4 .1 .0");
 	poti_DefineEntityValue("Ar", "MS", "AllocatingReuse", ".1 .1 .8");
@@ -216,8 +216,8 @@ void _starpu_fxt_write_paje_header(FILE *file STARPU_ATTRIBUTE_UNUSED)
 
 	/* Types for the MPI Communication Thread of the Memory Node */
 	poti_DefineEventType("MPIev", "MPICt", "MPI event type");
-	poti_DefineVariableType("bwi", "MPICt", "Bandwidth In (MB/s)", "0 0 0");
-	poti_DefineVariableType("bwo", "MPICt", "Bandwidth Out (MB/s)", "0 0 0");
+	poti_DefineVariableType("bwi_mpi", "MPICt", "Bandwidth In (MB/s)", "0 0 0");
+	poti_DefineVariableType("bwo_mpi", "MPICt", "Bandwidth Out (MB/s)", "0 0 0");
 	poti_DefineStateType("CtS", "MPICt", "Communication Thread State");
 	poti_DefineEntityValue("P", "CtS", "Processing", "0 0 0");
 	poti_DefineEntityValue("Sl", "CtS", "Sleeping", ".9 .1 .0");
@@ -305,10 +305,10 @@ void _starpu_fxt_write_paje_header(FILE *file STARPU_ATTRIBUTE_UNUSED)
 4       nsubmitted    Sc       \"Number of Submitted Uncompleted Tasks\"                        \n\
 4       nready    Sc       \"Number of Ready Tasks\"                        \n\
 4       use     Mm       \"Used (MB)\"                        \n\
-4       bwi     Mm       \"Bandwidth In (MB/s)\"                        \n\
-4       bwo     Mm       \"Bandwidth Out (MB/s)\"                        \n\
-4       bwi     MPICt       \"Bandwidth In (MB/s)\"                        \n\
-4       bwo     MPICt       \"Bandwidth Out (MB/s)\"                        \n\
+4       bwi_mm     Mm       \"Bandwidth In (MB/s)\"                        \n\
+4       bwo_mm     Mm       \"Bandwidth Out (MB/s)\"                        \n\
+4       bwi_mpi     MPICt       \"Bandwidth In (MB/s)\"                        \n\
+4       bwo_mpi     MPICt       \"Bandwidth Out (MB/s)\"                        \n\
 4       gf      T       \"GFlops\"                        \n\
 6       I       S       Idle         \".9 .1 .0\"		\n\
 6       In       S      Initializing       \"0.0 .7 1.0\"            \n\