make precision correct when calling conversion between LttTime and double
[lttv.git] / ltt / branches / poly / ltt / convert / convert.c
index ccec523fc029da3683718b65adfa8660eacc0f1d..d57403cad339cbf0cdcd9fd225e30efb4c692c84 100644 (file)
@@ -13,7 +13,8 @@
 #define PROCESS_EXIT_ID     21
 
 #define INFO_ENTRY          9
-#define OVERFLOW_FIGURE     4294967296
+#define OVERFLOW_FIGURE     0x100000000
+//#define OVERFLOW_FIGURE     0xffffffff
 
 typedef struct _new_process
 {
@@ -137,7 +138,8 @@ int main(int argc, char ** argv){
   new_process process;
 
   if(argc < 4){
-    printf("Not enough parameters\n");
+    printf("Usage : ./convert processfile_name number_of_cpu tracefile1 tracefile2 ... trace_creation_directory\n");
+               printf("For more details, see README.\n");
     exit(1);
   }
 
@@ -618,22 +620,22 @@ int main(int argc, char ** argv){
 
 
   //write to system.xml
-  fprintf(fp,"<system\n");
-  fprintf(fp,"node_name=\"%s\"\n", node_name);
-  fprintf(fp,"domainname=\"%s\"\n", domainname);
-  fprintf(fp,"cpu=%d\n", cpu);
-  fprintf(fp,"arch_size=\"%s\"\n", arch_size);
-  fprintf(fp,"endian=\"%s\"\n",endian);
-  fprintf(fp,"kernel_name=\"%s\"\n",kernel_name);
-  fprintf(fp,"kernel_release=\"%s\"\n",kernel_release);
-  fprintf(fp,"kernel_version=\"%s\"\n",kernel_version);
-  fprintf(fp,"machine=\"%s\"\n",machine);
-  fprintf(fp,"processor=\"%s\"\n",processor);
-  fprintf(fp,"hardware_platform=\"%s\"\n",hardware_platform);
-  fprintf(fp,"operating_system=\"%s\"\n",operating_system);
-  fprintf(fp,"ltt_major_version=%d\n",ltt_major_version);
-  fprintf(fp,"ltt_minor_version=%d\n",ltt_minor_version);
-  fprintf(fp,"ltt_block_size=%d\n",ltt_block_size);
+  fprintf(fp,"<system \n");
+  fprintf(fp,"node_name=\"%s\" \n", node_name);
+  fprintf(fp,"domainname=\"%s\" \n", domainname);
+  fprintf(fp,"cpu=\"%d\" \n", cpu);
+  fprintf(fp,"arch_size=\"%s\" \n", arch_size);
+  fprintf(fp,"endian=\"%s\" \n",endian);
+  fprintf(fp,"kernel_name=\"%s\" \n",kernel_name);
+  fprintf(fp,"kernel_release=\"%s\" \n",kernel_release);
+  fprintf(fp,"kernel_version=\"%s\" \n",kernel_version);
+  fprintf(fp,"machine=\"%s\" \n",machine);
+  fprintf(fp,"processor=\"%s\" \n",processor);
+  fprintf(fp,"hardware_platform=\"%s\" \n",hardware_platform);
+  fprintf(fp,"operating_system=\"%s\" \n",operating_system);
+  fprintf(fp,"ltt_major_version=\"%d\" \n",ltt_major_version);
+  fprintf(fp,"ltt_minor_version=\"%d\" \n",ltt_minor_version);
+  fprintf(fp,"ltt_block_size=\"%d\" \n",ltt_block_size);
   fprintf(fp,">\n");
   fprintf(fp,"This is just a test\n");
   fprintf(fp,"</system>\n");
This page took 0.035209 seconds and 4 git commands to generate.