add benchmark to app. TODO: test benchmark.

This commit is contained in:
TXuian 2022-12-07 17:44:26 +08:00
parent 86d5d6be59
commit 8aed85d59a
1 changed files with 1 additions and 3 deletions

View File

@ -87,8 +87,6 @@ void organize_result(const benchmark_handle *handle) {
while (bmh_list[i].handle != NULL) { while (bmh_list[i].handle != NULL) {
if (bmh_list[i].handle == handle) { if (bmh_list[i].handle == handle) {
bmh_list[i].time = tmp_diff; bmh_list[i].time = tmp_diff;
printf("[BENCHMARK] Time Cost: %-15s %.4f\n", bmh_list[i].name,
bmh_list[i].time);
break; break;
} }
i++; i++;
@ -136,7 +134,7 @@ void *run_benchmark(void *args) {
cur_handle = cur_handle->next; cur_handle = cur_handle->next;
} }
// print_result(); print_result();
printf("[BENCHMARK] Global Time Diff: %f\n", global_diff); printf("[BENCHMARK] Global Time Diff: %f\n", global_diff);
return NULL; return NULL;
} }