Changeset f4b83cc in mainline
- Timestamp:
- 2017-12-27T18:26:06Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 2e2af3a
- Parents:
- 8e16454
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/tmon/burst_tests.c
r8e16454 rf4b83cc 161 161 // Format the size. 162 162 const double div_size = size / factor; 163 163 164 char *out = NULL; 164 165 asprintf(&out, fmt, div_size, prefix); … … 174 175 printf(INDENT "Number of cycles: %d\n", params->cycles); 175 176 176 char *str_size = format_size(params->size, "% 0.3f %sB");177 char *str_size = format_size(params->size, "%.3f %sB"); 177 178 printf(INDENT "Data size: %s\n", str_size); 178 179 free(str_size); … … 188 189 189 190 const double dur_per_cycle = (double) duration / (double) params->cycles; 190 printf(INDENT "Duration per cycle: % 0.3f ms\n", dur_per_cycle);191 printf(INDENT "Duration per cycle: %.3f ms\n", dur_per_cycle); 191 192 192 193 const size_t total_size = params->size * params->cycles; 193 char *str_total_size = format_size(total_size, "% 0.3f %sB");194 char *str_total_size = format_size(total_size, "%.3f %sB"); 194 195 printf(INDENT "Total size: %s\n", str_total_size); 195 196 free(str_total_size); 196 197 197 198 const double speed = 1000.0 * (double) total_size / (double) duration; 198 char *str_speed = format_size(speed, "% 0.3f %sB/s");199 char *str_speed = format_size(speed, "%.3f %sB/s"); 199 200 printf(INDENT "Average speed: %s\n", str_speed); 200 201 free(str_speed);
Note:
See TracChangeset
for help on using the changeset viewer.