Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[trace] output the command line used to generate the trace file
authorschnorr <Lucas.Schnorr@imag.fr>
Wed, 17 Oct 2012 13:53:11 +0000 (15:53 +0200)
committerschnorr <Lucas.Schnorr@imag.fr>
Wed, 17 Oct 2012 13:58:58 +0000 (15:58 +0200)
src/instr/instr_paje_trace.c

index 7b5568d..04110ab 100644 (file)
@@ -178,6 +178,13 @@ void TRACE_paje_start(void)
 
   /* output generator version */
   fprintf (tracing_file, "#This file was generated using SimGrid-%d.%d.%d\n", SIMGRID_VERSION_MAJOR, SIMGRID_VERSION_MINOR, SIMGRID_VERSION_PATCH);
+  fprintf (tracing_file, "#[");
+  unsigned int cpt;
+  char *str;
+  xbt_dynar_foreach (sg_cmdline, cpt, str){
+    fprintf(tracing_file, "%s ",str);
+  }
+  fprintf (tracing_file, "]\n");
 
   /* output one line comment */
   dump_comment (TRACE_get_comment());