Skip to content

Instantly share code, notes, and snippets.

@tanakamura
Last active December 27, 2020 04:37
Show Gist options
  • Save tanakamura/f52b40d4c225b5425294495e602e9c1a to your computer and use it in GitHub Desktop.
Save tanakamura/f52b40d4c225b5425294495e602e9c1a to your computer and use it in GitHub Desktop.
ostimer: clock_gettime
userland_timer: rdtscp
perf_counter: yes
AMD Ryzen 7 3700X 8-Core Processor
==== libc ====
| | nsec/call
-----------------------------------
| atoi_99999 | 14.19927
| fflush_stdout | 5.74030
| sscanf_double_99999 | 122.22827
| sscanf_int_99999 | 79.39621
| sprintf_double_99999 | 249.48759
|sprintf_double_033333 | 148.88077
| sprintf_int_99999 | 61.75789
| malloc_free_1byte | 7.54435
| malloc_free_1MiB | 7.50448
| sort1K |42490.40797
| sort4 | 31.88171
| cos1 | 8.86924
| cos0 | 6.56040
| cosPI | 11.57417
| exp | 6.18102
| log | 6.08529
| log10 | 9.95160
| log2 | 8.27471
| rand | 5.46127
| setjmp1 | 4.29575
| va_start_end | 2.11858
| clock | 151.43461
| time | 1.89959
| gmtime | 29.09185
| localtime | 880.01909
| mktime | 907.52831
| asctime | 277.89738
v : test_name
==== libc++ ====
| | nsec/call
-----------------------------------------
| alloc_ostringstream | 170.47141
| ostringstream_int_99999 | 24.31147
| ostringstream_double_99999 | 267.75032
|ostringstream_double_033333 | 214.05605
| alloc_istringstream | 188.86817
| istringstream_int_99999 | 54.85744
| istringstream_double_99999 | 142.19118
| iomanip_set_precision | 2.39403
| alloc_string | 0.69793
| concat_hello_world | 24.66004
| new_delete_1byte | 0.52678
| unique_ptr_reset | 0.52353
| shared_ptr_incdec | 8.71422
| map1M_insert_remove | 105.57936
| map4_insert_remove | 32.99671
| sort1K |11264.93131
| sort4 | 10.58163
| minstd_rand | 3.58733
| mt19937_rand | 6.15603
| default_rand | 3.57820
| stable_sort1K |13082.71145
| stable_sort4 | 38.76924
| steady_clock_now | 22.07232
| system_clock_now | 22.03463
| steady_timepoint_to_sec | 1.03923
| variant_get | 0.91629
| typeid_get | 10.38028
| scoped_lock_unlock | 9.53878
| enter_try | 0.52386
| throw_catch | 894.80539
v : test_name
==== syscall ====
| | nsec/call
----------------------------------
| close_invalid | 78.93923
| open_close | 639.92487
| select_0 | 429.16202
| fork_wait |399002.63067
| gettimeofday1 | 29.78466
| clock_gettime1 | 28.14314
| stat1 | 331.27418
| fstat1 | 149.46046
| pipe_close | 1095.08065
| mmap_unmap | 635.81915
| thread_create_join | 10108.44840
|write_devnull_1byte | 111.79698
v : test_name
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment