adding sort to performance checking
This commit is contained in:
@@ -86,7 +86,8 @@ int main (int argc, char *argv[])
|
|||||||
|
|
||||||
tISPC1 += get_elapsed_mcycles();
|
tISPC1 += get_elapsed_mcycles();
|
||||||
|
|
||||||
progressbar (i, m);
|
if (argc != 3)
|
||||||
|
progressbar (i, m);
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("[sort ispc]:\t[%.3f] million cycles\n", tISPC1);
|
printf("[sort ispc]:\t[%.3f] million cycles\n", tISPC1);
|
||||||
@@ -103,10 +104,11 @@ int main (int argc, char *argv[])
|
|||||||
|
|
||||||
tISPC2 += get_elapsed_mcycles();
|
tISPC2 += get_elapsed_mcycles();
|
||||||
|
|
||||||
progressbar (i, m);
|
if (argc != 3)
|
||||||
|
progressbar (i, m);
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("[sort ispc+tasks]:\t[%.3f] million cycles\n", tISPC2);
|
printf("[sort ispc + tasks]:\t[%.3f] million cycles\n", tISPC2);
|
||||||
|
|
||||||
srand (0);
|
srand (0);
|
||||||
|
|
||||||
@@ -120,13 +122,13 @@ int main (int argc, char *argv[])
|
|||||||
|
|
||||||
tSerial += get_elapsed_mcycles();
|
tSerial += get_elapsed_mcycles();
|
||||||
|
|
||||||
progressbar (i, m);
|
if (argc != 3)
|
||||||
|
progressbar (i, m);
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("[sort serial]:\t\t[%.3f] million cycles\n", tSerial);
|
printf("[sort serial]:\t\t[%.3f] million cycles\n", tSerial);
|
||||||
|
|
||||||
printf("\t\t\t\t(%.2fx speedup from ISPC serial)\n", tSerial/tISPC1);
|
printf("\t\t\t\t(%.2fx speedup from ISPC, %.2fx speedup from ISPC + tasks)\n", tSerial/tISPC1, tSerial/tISPC2);
|
||||||
printf("\t\t\t\t(%.2fx speedup from ISPC with tasks)\n", tSerial/tISPC2);
|
|
||||||
|
|
||||||
delete code;
|
delete code;
|
||||||
delete order;
|
delete order;
|
||||||
|
|||||||
Reference in New Issue
Block a user