mirror of https://github.com/orefkov/simstr.git
938 lines
139 KiB
Plaintext
938 lines
139 KiB
Plaintext
Benchmarks of simstr, version 1.6.5
|
|
Sources: https://github.com/orefkov/simstr
|
|
Results: https://orefkov.github.io/simstr/results.html
|
|
|
|
2026-02-08T13:13:26+03:00
|
|
Running benchStr.exe
|
|
Run on (32 X 2494 MHz CPU s)
|
|
CPU Caches:
|
|
L1 Data 32 KiB (x16)
|
|
L1 Instruction 32 KiB (x16)
|
|
L2 Unified 256 KiB (x16)
|
|
L3 Unified 40960 KiB (x1)
|
|
--------------------------------------------------------------------------------------------------------------------------------------------------------
|
|
Benchmark Time CPU Iterations
|
|
--------------------------------------------------------------------------------------------------------------------------------------------------------
|
|
----- Concatenate string + Number + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat std::string and number by std to std::string_mean 269 ns 270 ns 4
|
|
Concat std::string and number by std to std::string_median 269 ns 270 ns 4
|
|
Concat std::string and number by std to std::string_stddev 0.596 ns 3.42 ns 4
|
|
Concat std::string and number by std to std::string_cv 0.22 % 1.27 % 4
|
|
Concat std::string and number by StrExpr to std::string_mean 155 ns 154 ns 4
|
|
Concat std::string and number by StrExpr to std::string_median 156 ns 153 ns 4
|
|
Concat std::string and number by StrExpr to std::string_stddev 4.29 ns 5.75 ns 4
|
|
Concat std::string and number by StrExpr to std::string_cv 2.77 % 3.73 % 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_mean 70.3 ns 70.5 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_median 70.4 ns 70.5 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_stddev 1.02 ns 1.80 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_cv 1.45 % 2.56 % 4
|
|
Concat stringa and number by e_concat to simstr::stringa_mean 74.8 ns 75.0 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_median 74.9 ns 75.9 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_stddev 1.83 ns 2.47 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_cv 2.45 % 3.29 % 4
|
|
----- Concatenate string + Hex Number + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat std::string and format hex number and literal to std::string_mean 720 ns 722 ns 4
|
|
Concat std::string and format hex number and literal to std::string_median 722 ns 718 ns 4
|
|
Concat std::string and format hex number and literal to std::string_stddev 16.2 ns 13.4 ns 4
|
|
Concat std::string and format hex number and literal to std::string_cv 2.25 % 1.85 % 4
|
|
std::format std::string and hex number by literal to std::string_mean 1498 ns 1491 ns 4
|
|
std::format std::string and hex number by literal to std::string_median 1496 ns 1491 ns 4
|
|
std::format std::string and hex number by literal to std::string_stddev 7.36 ns 18.1 ns 4
|
|
std::format std::string and hex number by literal to std::string_cv 0.49 % 1.22 % 4
|
|
Concat std::string and std::to_chars and string to std::string_mean 196 ns 197 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_median 196 ns 197 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_stddev 4.66 ns 3.42 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_cv 2.38 % 1.74 % 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_mean 81.1 ns 81.1 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_median 81.0 ns 80.6 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_stddev 2.07 ns 2.00 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_cv 2.55 % 2.47 % 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 72.6 ns 71.9 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 72.5 ns 71.5 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 0.774 ns 0.872 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 1.07 % 1.21 % 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 81.6 ns 81.1 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_median 81.3 ns 81.1 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 1.44 ns 2.25 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 1.76 % 2.78 % 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_mean 150 ns 149 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_median 150 ns 146 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 4.28 ns 5.23 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_cv 2.85 % 3.51 % 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 299 ns 300 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 300 ns 298 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 6.13 ns 6.01 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 2.05 % 2.01 % 4
|
|
---- format/vformat and subst/vsubst octal number to 32 symbols result ----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_mean 663 ns 658 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 667 ns 663 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 15.7 ns 21.9 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 2.37 % 3.33 % 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 745 ns 746 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 742 ns 741 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 17.1 ns 16.7 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 2.30 % 2.24 % 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_mean 1095 ns 1086 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_median 1097 ns 1086 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_stddev 13.9 ns 31.5 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_cv 1.27 % 2.90 % 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 1399 ns 1397 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 1401 ns 1397 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 28.6 ns 18.1 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 2.04 % 1.30 % 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 1377 ns 1365 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 1357 ns 1350 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 42.8 ns 31.4 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 3.11 % 2.30 % 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1590 ns 1593 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_median 1589 ns 1585 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 22.9 ns 30.1 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.44 % 1.89 % 4
|
|
std::vformat(pattern, std::make_format_args(i))_mean 1604 ns 1604 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_median 1602 ns 1604 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_stddev 23.3 ns 28.5 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_cv 1.45 % 1.77 % 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 6560 ns 6557 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 6517 ns 6487 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 164 ns 197 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 2.49 % 3.01 % 4
|
|
----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat std::string by std to std::string_mean 39.5 ns 39.5 ns 4
|
|
Concat std::string by std to std::string_median 39.7 ns 39.7 ns 4
|
|
Concat std::string by std to std::string_stddev 1.28 ns 1.49 ns 4
|
|
Concat std::string by std to std::string_cv 3.24 % 3.77 % 4
|
|
Concat std::string by StrExpr to std::string_mean 38.7 ns 38.1 ns 4
|
|
Concat std::string by StrExpr to std::string_median 38.6 ns 38.4 ns 4
|
|
Concat std::string by StrExpr to std::string_stddev 0.331 ns 0.436 ns 4
|
|
Concat std::string by StrExpr to std::string_cv 0.86 % 1.14 % 4
|
|
Concat stringa by StrExpr to stringa_mean 29.5 ns 29.3 ns 4
|
|
Concat stringa by StrExpr to stringa_median 29.7 ns 29.8 ns 4
|
|
Concat stringa by StrExpr to stringa_stddev 0.968 ns 0.994 ns 4
|
|
Concat stringa by StrExpr to stringa_cv 3.28 % 3.39 % 4
|
|
----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Find concat three std::string_mean 208 ns 206 ns 4
|
|
Find concat three std::string_median 208 ns 205 ns 4
|
|
Find concat three std::string_stddev 2.39 ns 2.44 ns 4
|
|
Find concat three std::string_cv 1.15 % 1.18 % 4
|
|
Find concat three strexpr_mean 123 ns 123 ns 4
|
|
Find concat three strexpr_median 123 ns 123 ns 4
|
|
Find concat three strexpr_stddev 2.07 ns 1.40 ns 4
|
|
Find concat three strexpr_cv 1.68 % 1.13 % 4
|
|
Find concat three simstr_mean 28.0 ns 27.9 ns 4
|
|
Find concat three simstr_median 28.1 ns 27.9 ns 4
|
|
Find concat three simstr_stddev 0.559 ns 0.810 ns 4
|
|
Find concat three simstr_cv 2.00 % 2.90 % 4
|
|
----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
BuildTypeNameStr 0/0_mean 8.30 ns 8.11 ns 4
|
|
BuildTypeNameStr 0/0_median 8.28 ns 8.11 ns 4
|
|
BuildTypeNameStr 0/0_stddev 0.303 ns 0.225 ns 4
|
|
BuildTypeNameStr 0/0_cv 3.65 % 2.78 % 4
|
|
BuildTypeNameExp 0/0_mean 7.64 ns 7.63 ns 4
|
|
BuildTypeNameExp 0/0_median 7.63 ns 7.59 ns 4
|
|
BuildTypeNameExp 0/0_stddev 0.147 ns 0.167 ns 4
|
|
BuildTypeNameExp 0/0_cv 1.92 % 2.19 % 4
|
|
BuildTypeNameSim 0/0_mean 8.09 ns 8.02 ns 4
|
|
BuildTypeNameSim 0/0_median 8.15 ns 8.02 ns 4
|
|
BuildTypeNameSim 0/0_stddev 0.148 ns 0.142 ns 4
|
|
BuildTypeNameSim 0/0_cv 1.83 % 1.77 % 4
|
|
BuildTypeNameStr 10/10_mean 61.1 ns 60.7 ns 4
|
|
BuildTypeNameStr 10/10_median 60.5 ns 60.0 ns 4
|
|
BuildTypeNameStr 10/10_stddev 1.55 ns 1.40 ns 4
|
|
BuildTypeNameStr 10/10_cv 2.54 % 2.30 % 4
|
|
BuildTypeNameExp 10/10_mean 32.4 ns 32.4 ns 4
|
|
BuildTypeNameExp 10/10_median 32.4 ns 32.6 ns 4
|
|
BuildTypeNameExp 10/10_stddev 1.26 ns 1.31 ns 4
|
|
BuildTypeNameExp 10/10_cv 3.87 % 4.04 % 4
|
|
BuildTypeNameSim 10/10_mean 25.4 ns 25.3 ns 4
|
|
BuildTypeNameSim 10/10_median 25.3 ns 25.1 ns 4
|
|
BuildTypeNameSim 10/10_stddev 0.365 ns 0.702 ns 4
|
|
BuildTypeNameSim 10/10_cv 1.44 % 2.78 % 4
|
|
----- Replace string by copy -----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat with replace str_mean 317 ns 316 ns 4
|
|
Concat with replace str_median 315 ns 314 ns 4
|
|
Concat with replace str_stddev 6.51 ns 3.49 ns 4
|
|
Concat with replace str_cv 2.05 % 1.10 % 4
|
|
Concat with replace exp_mean 218 ns 213 ns 4
|
|
Concat with replace exp_median 218 ns 213 ns 4
|
|
Concat with replace exp_stddev 8.70 ns 3.70 ns 4
|
|
Concat with replace exp_cv 4.00 % 1.74 % 4
|
|
----- Create Empty Str ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e;_mean 1.11 ns 1.10 ns 4
|
|
std::string e;_median 1.11 ns 1.10 ns 4
|
|
std::string e;_stddev 0.015 ns 0.037 ns 4
|
|
std::string e;_cv 1.37 % 3.31 % 4
|
|
std::string_view e;_mean 0.369 ns 0.368 ns 4
|
|
std::string_view e;_median 0.371 ns 0.368 ns 4
|
|
std::string_view e;_stddev 0.004 ns 0.007 ns 4
|
|
std::string_view e;_cv 1.18 % 1.86 % 4
|
|
ssa e;_mean 0.365 ns 0.365 ns 4
|
|
ssa e;_median 0.364 ns 0.365 ns 4
|
|
ssa e;_stddev 0.006 ns 0.005 ns 4
|
|
ssa e;_cv 1.57 % 1.27 % 4
|
|
stringa e;_mean 0.738 ns 0.737 ns 4
|
|
stringa e;_median 0.733 ns 0.732 ns 4
|
|
stringa e;_stddev 0.018 ns 0.022 ns 4
|
|
stringa e;_cv 2.43 % 2.98 % 4
|
|
lstringa<20> e;_mean 1.11 ns 1.12 ns 4
|
|
lstringa<20> e;_median 1.12 ns 1.12 ns 4
|
|
lstringa<20> e;_stddev 0.021 ns 0.031 ns 4
|
|
lstringa<20> e;_cv 1.88 % 2.75 % 4
|
|
lstringa<40> e;_mean 1.13 ns 1.14 ns 4
|
|
lstringa<40> e;_median 1.14 ns 1.14 ns 4
|
|
lstringa<40> e;_stddev 0.018 ns 0.020 ns 4
|
|
lstringa<40> e;_cv 1.57 % 1.76 % 4
|
|
----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "Test text";_mean 1.86 ns 1.84 ns 4
|
|
std::string e = "Test text";_median 1.86 ns 1.84 ns 4
|
|
std::string e = "Test text";_stddev 0.022 ns 0.000 ns 4
|
|
std::string e = "Test text";_cv 1.16 % 0.00 % 4
|
|
std::string_view e = "Test text";_mean 0.735 ns 0.732 ns 4
|
|
std::string_view e = "Test text";_median 0.735 ns 0.732 ns 4
|
|
std::string_view e = "Test text";_stddev 0.009 ns 0.000 ns 4
|
|
std::string_view e = "Test text";_cv 1.22 % 0.00 % 4
|
|
ssa e = "Test text";_mean 0.371 ns 0.370 ns 4
|
|
ssa e = "Test text";_median 0.370 ns 0.368 ns 4
|
|
ssa e = "Test text";_stddev 0.002 ns 0.004 ns 4
|
|
ssa e = "Test text";_cv 0.54 % 1.13 % 4
|
|
stringa e = "Test text";_mean 1.09 ns 1.09 ns 4
|
|
stringa e = "Test text";_median 1.09 ns 1.09 ns 4
|
|
stringa e = "Test text";_stddev 0.014 ns 0.023 ns 4
|
|
stringa e = "Test text";_cv 1.30 % 2.14 % 4
|
|
lstringa<20> e = "Test text";_mean 1.87 ns 1.86 ns 4
|
|
lstringa<20> e = "Test text";_median 1.88 ns 1.88 ns 4
|
|
lstringa<20> e = "Test text";_stddev 0.045 ns 0.038 ns 4
|
|
lstringa<20> e = "Test text";_cv 2.42 % 2.06 % 4
|
|
lstringa<40> e = "Test text";_mean 1.90 ns 1.88 ns 4
|
|
lstringa<40> e = "Test text";_median 1.90 ns 1.88 ns 4
|
|
lstringa<40> e = "Test text";_stddev 0.013 ns 0.034 ns 4
|
|
lstringa<40> e = "Test text";_cv 0.66 % 1.81 % 4
|
|
----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "123456789012345678901234567890";_mean 75.9 ns 75.7 ns 4
|
|
std::string e = "123456789012345678901234567890";_median 76.0 ns 75.3 ns 4
|
|
std::string e = "123456789012345678901234567890";_stddev 0.516 ns 0.698 ns 4
|
|
std::string e = "123456789012345678901234567890";_cv 0.68 % 0.92 % 4
|
|
std::string_view e = "123456789012345678901234567890";_mean 0.746 ns 0.737 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_median 0.747 ns 0.732 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_stddev 0.015 ns 0.022 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_cv 2.02 % 2.98 % 4
|
|
ssa e = "123456789012345678901234567890";_mean 0.365 ns 0.364 ns 4
|
|
ssa e = "123456789012345678901234567890";_median 0.363 ns 0.364 ns 4
|
|
ssa e = "123456789012345678901234567890";_stddev 0.008 ns 0.010 ns 4
|
|
ssa e = "123456789012345678901234567890";_cv 2.27 % 2.72 % 4
|
|
stringa e = "123456789012345678901234567890";_mean 1.11 ns 1.10 ns 4
|
|
stringa e = "123456789012345678901234567890";_median 1.11 ns 1.12 ns 4
|
|
stringa e = "123456789012345678901234567890";_stddev 0.025 ns 0.028 ns 4
|
|
stringa e = "123456789012345678901234567890";_cv 2.24 % 2.53 % 4
|
|
lstringa<20> e = "123456789012345678901234567890";_mean 74.9 ns 75.0 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_median 74.7 ns 74.6 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_stddev 1.49 ns 1.34 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_cv 1.99 % 1.78 % 4
|
|
lstringa<40> e = "123456789012345678901234567890";_mean 2.58 ns 2.57 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_median 2.56 ns 2.57 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_stddev 0.054 ns 0.046 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_cv 2.08 % 1.77 % 4
|
|
----- Create copy of Str with 9 symbols ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "Test text"; auto c{e};_mean 1.89 ns 1.88 ns 4
|
|
std::string e = "Test text"; auto c{e};_median 1.89 ns 1.88 ns 4
|
|
std::string e = "Test text"; auto c{e};_stddev 0.026 ns 0.031 ns 4
|
|
std::string e = "Test text"; auto c{e};_cv 1.39 % 1.67 % 4
|
|
std::string_view e = "Test text"; auto c{e};_mean 0.375 ns 0.369 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_median 0.371 ns 0.365 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_stddev 0.014 ns 0.011 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_cv 3.65 % 3.07 % 4
|
|
ssa e = "Test text"; auto c{e};_mean 0.374 ns 0.375 ns 4
|
|
ssa e = "Test text"; auto c{e};_median 0.376 ns 0.377 ns 4
|
|
ssa e = "Test text"; auto c{e};_stddev 0.008 ns 0.004 ns 4
|
|
ssa e = "Test text"; auto c{e};_cv 2.17 % 1.12 % 4
|
|
stringa e = "Test text"; auto c{e};_mean 1.33 ns 1.32 ns 4
|
|
stringa e = "Test text"; auto c{e};_median 1.33 ns 1.33 ns 4
|
|
stringa e = "Test text"; auto c{e};_stddev 0.043 ns 0.048 ns 4
|
|
stringa e = "Test text"; auto c{e};_cv 3.21 % 3.61 % 4
|
|
lstringa<20> e = "Test text"; auto c{e};_mean 5.31 ns 5.20 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_median 5.28 ns 5.16 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_stddev 0.150 ns 0.070 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_cv 2.82 % 1.34 % 4
|
|
lstringa<40> e = "Test text"; auto c{e};_mean 5.19 ns 5.20 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_median 5.19 ns 5.23 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_stddev 0.079 ns 0.150 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_cv 1.52 % 2.88 % 4
|
|
----- Create copy of Str with 30 symbols ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_mean 74.0 ns 74.1 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_median 73.8 ns 74.1 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_stddev 1.93 ns 2.25 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_cv 2.61 % 3.04 % 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.748 ns 0.741 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.750 ns 0.741 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.014 ns 0.010 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 1.90 % 1.36 % 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.369 ns 0.370 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_median 0.368 ns 0.368 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.003 ns 0.004 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_cv 0.76 % 1.13 % 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.85 ns 1.85 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_median 1.85 ns 1.86 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.009 ns 0.037 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_cv 0.50 % 1.98 % 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 76.8 ns 76.3 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 76.3 ns 76.7 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 1.51 ns 0.872 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 1.97 % 1.14 % 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.90 ns 4.89 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.92 ns 4.92 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.046 ns 0.104 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 0.93 % 2.12 % 4
|
|
----- Find 9 symbols text in end of 99 symbols text ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string::find;_mean 39.7 ns 39.6 ns 4
|
|
std::string::find;_median 39.7 ns 39.8 ns 4
|
|
std::string::find;_stddev 0.363 ns 0.801 ns 4
|
|
std::string::find;_cv 0.92 % 2.03 % 4
|
|
std::string_view::find;_mean 39.5 ns 39.1 ns 4
|
|
std::string_view::find;_median 39.3 ns 38.9 ns 4
|
|
std::string_view::find;_stddev 1.01 ns 0.801 ns 4
|
|
std::string_view::find;_cv 2.56 % 2.05 % 4
|
|
ssa::find;_mean 18.0 ns 17.8 ns 4
|
|
ssa::find;_median 17.9 ns 18.0 ns 4
|
|
ssa::find;_stddev 0.557 ns 0.419 ns 4
|
|
ssa::find;_cv 3.10 % 2.35 % 4
|
|
stringa::find;_mean 18.8 ns 18.6 ns 4
|
|
stringa::find;_median 18.9 ns 18.4 ns 4
|
|
stringa::find;_stddev 0.417 ns 0.419 ns 4
|
|
stringa::find;_cv 2.21 % 2.25 % 4
|
|
lstringa<20>::find;_mean 17.9 ns 17.8 ns 4
|
|
lstringa<20>::find;_median 17.8 ns 17.6 ns 4
|
|
lstringa<20>::find;_stddev 0.181 ns 0.384 ns 4
|
|
lstringa<20>::find;_cv 1.01 % 2.15 % 4
|
|
lstringa<40>::find;_mean 17.7 ns 17.8 ns 4
|
|
lstringa<40>::find;_median 17.6 ns 17.6 ns 4
|
|
lstringa<40>::find;_stddev 0.482 ns 0.419 ns 4
|
|
lstringa<40>::find;_cv 2.72 % 2.35 % 4
|
|
------- Copy not literal Str with N symbols ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string copy{str_with_len_N};/15_mean 1.86 ns 1.86 ns 4
|
|
std::string copy{str_with_len_N};/15_median 1.86 ns 1.86 ns 4
|
|
std::string copy{str_with_len_N};/15_stddev 0.028 ns 0.022 ns 4
|
|
std::string copy{str_with_len_N};/15_cv 1.49 % 1.19 % 4
|
|
std::string copy{str_with_len_N};/16_mean 76.9 ns 76.3 ns 4
|
|
std::string copy{str_with_len_N};/16_median 76.6 ns 76.7 ns 4
|
|
std::string copy{str_with_len_N};/16_stddev 1.04 ns 0.872 ns 4
|
|
std::string copy{str_with_len_N};/16_cv 1.35 % 1.14 % 4
|
|
std::string copy{str_with_len_N};/23_mean 76.5 ns 76.3 ns 4
|
|
std::string copy{str_with_len_N};/23_median 76.6 ns 76.7 ns 4
|
|
std::string copy{str_with_len_N};/23_stddev 1.16 ns 0.872 ns 4
|
|
std::string copy{str_with_len_N};/23_cv 1.51 % 1.14 % 4
|
|
std::string copy{str_with_len_N};/24_mean 77.5 ns 77.2 ns 4
|
|
std::string copy{str_with_len_N};/24_median 77.6 ns 76.7 ns 4
|
|
std::string copy{str_with_len_N};/24_stddev 0.844 ns 0.872 ns 4
|
|
std::string copy{str_with_len_N};/24_cv 1.09 % 1.13 % 4
|
|
std::string copy{str_with_len_N};/32_mean 85.7 ns 85.3 ns 4
|
|
std::string copy{str_with_len_N};/32_median 84.9 ns 84.8 ns 4
|
|
std::string copy{str_with_len_N};/32_stddev 3.60 ns 3.57 ns 4
|
|
std::string copy{str_with_len_N};/32_cv 4.20 % 4.19 % 4
|
|
std::string copy{str_with_len_N};/64_mean 80.1 ns 79.8 ns 4
|
|
std::string copy{str_with_len_N};/64_median 79.8 ns 80.2 ns 4
|
|
std::string copy{str_with_len_N};/64_stddev 2.69 ns 2.62 ns 4
|
|
std::string copy{str_with_len_N};/64_cv 3.36 % 3.28 % 4
|
|
std::string copy{str_with_len_N};/128_mean 82.7 ns 82.4 ns 4
|
|
std::string copy{str_with_len_N};/128_median 82.6 ns 82.0 ns 4
|
|
std::string copy{str_with_len_N};/128_stddev 1.26 ns 0.872 ns 4
|
|
std::string copy{str_with_len_N};/128_cv 1.52 % 1.06 % 4
|
|
std::string copy{str_with_len_N};/256_mean 86.8 ns 84.8 ns 4
|
|
std::string copy{str_with_len_N};/256_median 86.5 ns 83.7 ns 4
|
|
std::string copy{str_with_len_N};/256_stddev 2.19 ns 2.09 ns 4
|
|
std::string copy{str_with_len_N};/256_cv 2.53 % 2.47 % 4
|
|
std::string copy{str_with_len_N};/512_mean 88.4 ns 87.9 ns 4
|
|
std::string copy{str_with_len_N};/512_median 89.1 ns 87.9 ns 4
|
|
std::string copy{str_with_len_N};/512_stddev 3.84 ns 3.82 ns 4
|
|
std::string copy{str_with_len_N};/512_cv 4.34 % 4.35 % 4
|
|
std::string copy{str_with_len_N};/1024_mean 97.2 ns 96.4 ns 4
|
|
std::string copy{str_with_len_N};/1024_median 96.1 ns 95.2 ns 4
|
|
std::string copy{str_with_len_N};/1024_stddev 3.67 ns 4.23 ns 4
|
|
std::string copy{str_with_len_N};/1024_cv 3.77 % 4.38 % 4
|
|
std::string copy{str_with_len_N};/2048_mean 131 ns 130 ns 4
|
|
std::string copy{str_with_len_N};/2048_median 126 ns 126 ns 4
|
|
std::string copy{str_with_len_N};/2048_stddev 12.3 ns 11.9 ns 4
|
|
std::string copy{str_with_len_N};/2048_cv 9.36 % 9.14 % 4
|
|
std::string copy{str_with_len_N};/4096_mean 179 ns 177 ns 4
|
|
std::string copy{str_with_len_N};/4096_median 180 ns 178 ns 4
|
|
std::string copy{str_with_len_N};/4096_stddev 6.42 ns 6.55 ns 4
|
|
std::string copy{str_with_len_N};/4096_cv 3.59 % 3.69 % 4
|
|
stringa copy{str_with_len_N};/15_mean 1.33 ns 1.33 ns 4
|
|
stringa copy{str_with_len_N};/15_median 1.32 ns 1.33 ns 4
|
|
stringa copy{str_with_len_N};/15_stddev 0.019 ns 0.016 ns 4
|
|
stringa copy{str_with_len_N};/15_cv 1.44 % 1.22 % 4
|
|
stringa copy{str_with_len_N};/16_mean 1.32 ns 1.30 ns 4
|
|
stringa copy{str_with_len_N};/16_median 1.33 ns 1.30 ns 4
|
|
stringa copy{str_with_len_N};/16_stddev 0.038 ns 0.018 ns 4
|
|
stringa copy{str_with_len_N};/16_cv 2.91 % 1.39 % 4
|
|
stringa copy{str_with_len_N};/23_mean 1.31 ns 1.31 ns 4
|
|
stringa copy{str_with_len_N};/23_median 1.31 ns 1.31 ns 4
|
|
stringa copy{str_with_len_N};/23_stddev 0.011 ns 0.023 ns 4
|
|
stringa copy{str_with_len_N};/23_cv 0.82 % 1.74 % 4
|
|
stringa copy{str_with_len_N};/24_mean 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/24_median 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/24_stddev 0.163 ns 0.000 ns 4
|
|
stringa copy{str_with_len_N};/24_cv 1.01 % 0.00 % 4
|
|
stringa copy{str_with_len_N};/32_mean 16.2 ns 16.2 ns 4
|
|
stringa copy{str_with_len_N};/32_median 16.2 ns 16.1 ns 4
|
|
stringa copy{str_with_len_N};/32_stddev 0.182 ns 0.192 ns 4
|
|
stringa copy{str_with_len_N};/32_cv 1.13 % 1.18 % 4
|
|
stringa copy{str_with_len_N};/64_mean 16.0 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/64_median 15.9 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/64_stddev 0.120 ns 0.201 ns 4
|
|
stringa copy{str_with_len_N};/64_cv 0.75 % 1.27 % 4
|
|
stringa copy{str_with_len_N};/128_mean 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/128_median 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/128_stddev 0.082 ns 0.285 ns 4
|
|
stringa copy{str_with_len_N};/128_cv 0.51 % 1.77 % 4
|
|
stringa copy{str_with_len_N};/256_mean 16.1 ns 16.1 ns 4
|
|
stringa copy{str_with_len_N};/256_median 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/256_stddev 0.102 ns 0.174 ns 4
|
|
stringa copy{str_with_len_N};/256_cv 0.63 % 1.08 % 4
|
|
stringa copy{str_with_len_N};/512_mean 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/512_median 16.2 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/512_stddev 0.133 ns 0.285 ns 4
|
|
stringa copy{str_with_len_N};/512_cv 0.83 % 1.77 % 4
|
|
stringa copy{str_with_len_N};/1024_mean 16.3 ns 16.1 ns 4
|
|
stringa copy{str_with_len_N};/1024_median 16.2 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/1024_stddev 0.280 ns 0.174 ns 4
|
|
stringa copy{str_with_len_N};/1024_cv 1.72 % 1.08 % 4
|
|
stringa copy{str_with_len_N};/2048_mean 16.1 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/2048_median 16.2 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/2048_stddev 0.147 ns 0.222 ns 4
|
|
stringa copy{str_with_len_N};/2048_cv 0.91 % 1.39 % 4
|
|
stringa copy{str_with_len_N};/4096_mean 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/4096_median 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/4096_stddev 0.121 ns 0.285 ns 4
|
|
stringa copy{str_with_len_N};/4096_cv 0.75 % 1.77 % 4
|
|
lstringa<16> copy{str_with_len_N};/15_mean 4.96 ns 4.88 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_median 4.97 ns 4.92 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_stddev 0.072 ns 0.150 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_cv 1.44 % 3.06 % 4
|
|
lstringa<16> copy{str_with_len_N};/16_mean 4.78 ns 4.80 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_median 4.76 ns 4.77 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_stddev 0.095 ns 0.150 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_cv 1.98 % 3.11 % 4
|
|
lstringa<16> copy{str_with_len_N};/23_mean 4.98 ns 4.92 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_median 4.99 ns 4.95 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_stddev 0.110 ns 0.134 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_cv 2.21 % 2.72 % 4
|
|
lstringa<16> copy{str_with_len_N};/24_mean 78.7 ns 78.5 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_median 78.1 ns 78.1 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_stddev 1.52 ns 1.76 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_cv 1.93 % 2.24 % 4
|
|
lstringa<16> copy{str_with_len_N};/32_mean 85.9 ns 85.8 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_median 85.8 ns 85.8 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_stddev 2.23 ns 1.71 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_cv 2.60 % 1.99 % 4
|
|
lstringa<16> copy{str_with_len_N};/64_mean 82.8 ns 82.0 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_median 82.3 ns 82.0 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_stddev 2.16 ns 1.42 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_cv 2.61 % 1.74 % 4
|
|
lstringa<16> copy{str_with_len_N};/128_mean 85.4 ns 85.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_median 84.5 ns 83.7 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_stddev 2.29 ns 3.14 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_cv 2.68 % 3.68 % 4
|
|
lstringa<16> copy{str_with_len_N};/256_mean 87.0 ns 87.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_median 86.7 ns 87.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_stddev 3.32 ns 3.18 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_cv 3.82 % 3.65 % 4
|
|
lstringa<16> copy{str_with_len_N};/512_mean 87.9 ns 88.1 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_median 87.3 ns 88.1 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_stddev 2.43 ns 2.25 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_cv 2.77 % 2.56 % 4
|
|
lstringa<16> copy{str_with_len_N};/1024_mean 93.8 ns 93.7 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_median 94.4 ns 93.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_stddev 1.46 ns 1.67 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_cv 1.55 % 1.78 % 4
|
|
lstringa<16> copy{str_with_len_N};/2048_mean 126 ns 126 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_median 125 ns 126 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_stddev 4.33 ns 5.03 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_cv 3.43 % 3.98 % 4
|
|
lstringa<16> copy{str_with_len_N};/4096_mean 192 ns 188 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_median 191 ns 188 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_stddev 1.95 ns 3.13 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_cv 1.02 % 1.67 % 4
|
|
lstringa<512> copy{str_with_len_N};/15_mean 5.34 ns 5.34 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_median 5.31 ns 5.30 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_stddev 0.179 ns 0.176 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_cv 3.36 % 3.29 % 4
|
|
lstringa<512> copy{str_with_len_N};/16_mean 5.25 ns 5.27 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_median 5.29 ns 5.23 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_stddev 0.141 ns 0.134 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_cv 2.68 % 2.54 % 4
|
|
lstringa<512> copy{str_with_len_N};/23_mean 5.26 ns 5.23 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_median 5.32 ns 5.31 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_stddev 0.185 ns 0.156 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_cv 3.52 % 2.99 % 4
|
|
lstringa<512> copy{str_with_len_N};/24_mean 5.35 ns 5.27 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_median 5.32 ns 5.30 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_stddev 0.120 ns 0.070 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_cv 2.25 % 1.32 % 4
|
|
lstringa<512> copy{str_with_len_N};/32_mean 8.10 ns 8.02 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_median 8.12 ns 8.02 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_stddev 0.114 ns 0.142 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_cv 1.40 % 1.77 % 4
|
|
lstringa<512> copy{str_with_len_N};/64_mean 8.22 ns 8.11 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_median 8.27 ns 8.11 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_stddev 0.140 ns 0.101 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_cv 1.70 % 1.24 % 4
|
|
lstringa<512> copy{str_with_len_N};/128_mean 8.79 ns 8.81 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_median 8.79 ns 8.89 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_stddev 0.164 ns 0.174 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_cv 1.87 % 1.98 % 4
|
|
lstringa<512> copy{str_with_len_N};/256_mean 9.80 ns 9.73 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_median 9.89 ns 9.84 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_stddev 0.323 ns 0.362 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_cv 3.30 % 3.72 % 4
|
|
lstringa<512> copy{str_with_len_N};/512_mean 11.6 ns 11.6 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_median 11.6 ns 11.6 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_stddev 0.153 ns 0.161 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_cv 1.32 % 1.39 % 4
|
|
lstringa<512> copy{str_with_len_N};/1024_mean 96.6 ns 96.8 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_median 96.1 ns 96.3 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_stddev 2.56 ns 2.63 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_cv 2.65 % 2.72 % 4
|
|
lstringa<512> copy{str_with_len_N};/2048_mean 123 ns 123 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_median 123 ns 122 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_stddev 2.81 ns 1.22 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_cv 2.28 % 1.00 % 4
|
|
lstringa<512> copy{str_with_len_N};/4096_mean 194 ns 194 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_median 193 ns 193 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_stddev 4.48 ns 5.27 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_cv 2.31 % 2.72 % 4
|
|
----- Convert to int '1234567' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_mean 31.0 ns 31.0 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 31.0 ns 30.7 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.509 ns 0.698 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 1.64 % 2.25 % 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 13.7 ns 13.6 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 13.7 ns 13.7 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.121 ns 0.301 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 0.88 % 2.21 % 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 14.2 ns 14.1 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_median 14.2 ns 14.1 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.237 ns 0.256 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 1.66 % 1.81 % 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 13.8 ns 13.7 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_median 13.8 ns 13.8 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.073 ns 0.157 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 0.53 % 1.14 % 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 13.7 ns 13.7 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_median 13.7 ns 13.7 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.237 ns 0.140 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 1.73 % 1.02 % 4
|
|
----- Convert to unsigned 'abcDef' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_mean 34.5 ns 34.2 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 34.6 ns 34.4 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 0.558 ns 0.366 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 1.61 % 1.07 % 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 8.45 ns 8.42 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 8.44 ns 8.48 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.143 ns 0.200 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 1.69 % 2.38 % 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 12.8 ns 12.8 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 12.7 ns 12.8 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.211 ns 0.228 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 1.65 % 1.77 % 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 12.3 ns 12.2 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 12.4 ns 12.2 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.187 ns 0.256 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 1.52 % 2.09 % 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 12.0 ns 12.1 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 12.0 ns 11.9 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.238 ns 0.314 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 1.98 % 2.60 % 4
|
|
----- Convert to int ' 1234567' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_mean 43.6 ns 43.5 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 43.6 ns 43.5 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 0.414 ns 0.564 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 0.95 % 1.30 % 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_mean 18.7 ns 18.7 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_median 18.7 ns 18.8 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_stddev 0.244 ns 0.209 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_cv 1.31 % 1.12 % 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_mean 15.5 ns 15.5 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_median 15.5 ns 15.7 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_stddev 0.184 ns 0.349 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_cv 1.18 % 2.25 % 4
|
|
----- Convert to double '1234.567e10' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_mean 103 ns 103 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 102 ns 103 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 2.60 ns 2.63 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 2.53 % 2.55 % 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 59.6 ns 59.3 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 59.9 ns 59.3 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 2.02 ns 1.80 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 3.38 % 3.04 % 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_mean 36.7 ns 36.1 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_median 36.8 ns 36.1 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_stddev 1.06 ns 0.655 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_cv 2.89 % 1.81 % 4
|
|
-- Append const literal of 16 bytes 64 times, 1024 total length --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_mean 4798 ns 4805 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_median 4820 ns 4844 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 96.4 ns 197 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.01 % 4.09 % 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_mean 1101 ns 1093 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_median 1090 ns 1086 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_stddev 25.5 ns 23.4 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_cv 2.32 % 2.14 % 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 756 ns 759 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_median 754 ns 759 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 8.71 ns 10.1 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 1.15 % 1.33 % 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 390 ns 390 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_median 392 ns 390 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 8.15 ns 7.40 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 2.09 % 1.90 % 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 231 ns 231 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_median 232 ns 233 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 4.08 ns 5.01 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 1.77 % 2.16 % 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 146 ns 140 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 140 ns 140 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 14.6 ns 2.28 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 10.00 % 1.63 % 4
|
|
-- Append string of 16 bytes and const literal of 16 bytes 32 times, 1024 total length --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_mean 4654 ns 4627 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 4651 ns 4653 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 62.0 ns 50.6 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 1.33 % 1.09 % 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 3826 ns 3788 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_median 3793 ns 3767 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 119 ns 41.9 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 3.12 % 1.10 % 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 730 ns 732 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 725 ns 724 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 17.2 ns 24.7 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.36 % 3.37 % 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 461 ns 460 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 462 ns 460 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 8.65 ns 12.1 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.87 % 2.62 % 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 304 ns 300 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 306 ns 300 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 8.28 ns 5.98 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.72 % 1.99 % 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 212 ns 212 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 213 ns 215 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 3.71 ns 4.88 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.75 % 2.30 % 4
|
|
-- Append string of 16 bytes and const literal of 16 bytes 2048 times, 65536 total length --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_mean 218672 ns 218506 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 219327 ns 217285 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 4902 ns 4675 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 2.24 % 2.14 % 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 193765 ns 193839 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 193537 ns 192705 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 2124 ns 4341 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.10 % 2.24 % 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 19712 ns 19749 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 19750 ns 19880 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 248 ns 262 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.26 % 1.32 % 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16887 ns 16881 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16737 ns 16689 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 423 ns 543 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.50 % 3.21 % 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16377 ns 16305 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16276 ns 16497 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 567 ns 384 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.46 % 2.35 % 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16381 ns 16392 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16413 ns 16392 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 204 ns 285 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.24 % 1.74 % 4
|
|
-- Append 2 string of 16 bytes 32 times, 1024 total length --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::stringstream str; ... str << str_var1 << str_var2;_mean 4521 ns 4476 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_median 4563 ns 4450 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_stddev 209 ns 209 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_cv 4.62 % 4.66 % 4
|
|
std::string str; ... str += str_var1 + str_var2;_mean 4020 ns 3967 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_median 4025 ns 3945 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_stddev 79.9 ns 86.8 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_cv 1.99 % 2.19 % 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_mean 801 ns 795 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_median 800 ns 795 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_stddev 17.6 ns 17.1 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_cv 2.20 % 2.15 % 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_mean 531 ns 531 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_median 530 ns 531 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_stddev 5.02 ns 0.000 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_cv 0.95 % 0.00 % 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_mean 386 ns 384 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_median 389 ns 384 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_stddev 9.19 ns 7.12 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_cv 2.38 % 1.86 % 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_mean 285 ns 286 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_median 287 ns 289 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 5.16 ns 6.28 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_cv 1.81 % 2.20 % 4
|
|
-- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::stringstream str; str << "test = " << k << " times";_mean 11080 ns 11108 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_median 11069 ns 11108 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_stddev 207 ns 141 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_cv 1.87 % 1.27 % 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_mean 1104 ns 1105 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_median 1096 ns 1111 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_stddev 27.8 ns 23.4 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_cv 2.51 % 2.12 % 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 2849 ns 2809 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 2858 ns 2794 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 48.0 ns 60.1 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 1.68 % 2.14 % 4
|
|
std::string str = std::format("test = {} times", k);_mean 1859 ns 1862 ns 4
|
|
std::string str = std::format("test = {} times", k);_median 1856 ns 1862 ns 4
|
|
std::string str = std::format("test = {} times", k);_stddev 21.3 ns 24.2 ns 4
|
|
std::string str = std::format("test = {} times", k);_cv 1.15 % 1.30 % 4
|
|
lstringa<8> str; str.format("test = {} times", k);_mean 2069 ns 2051 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_median 2055 ns 2051 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_stddev 60.8 ns 79.7 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_cv 2.94 % 3.89 % 4
|
|
lstringa<32> str; str.format("test = {} times", k);_mean 1013 ns 1013 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_median 1016 ns 1013 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_stddev 20.9 ns 14.1 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_cv 2.07 % 1.39 % 4
|
|
lstringa<8> str = "test = " + k + " times";_mean 875 ns 874 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_median 867 ns 868 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_stddev 19.4 ns 20.0 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_cv 2.22 % 2.29 % 4
|
|
lstringa<32> str = "test = " + k + " times";_mean 157 ns 156 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_median 157 ns 157 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_stddev 2.01 ns 1.57 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_cv 1.28 % 1.01 % 4
|
|
stringa str = "test = " + k + " times";_mean 153 ns 151 ns 4
|
|
stringa str = "test = " + k + " times";_median 153 ns 151 ns 4
|
|
stringa str = "test = " + k + " times";_stddev 3.20 ns 2.56 ns 4
|
|
stringa str = "test = " + k + " times";_cv 2.09 % 1.70 % 4
|
|
-- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string::find + substr + std::strtol_mean 546 ns 547 ns 4
|
|
std::string::find + substr + std::strtol_median 546 ns 547 ns 4
|
|
std::string::find + substr + std::strtol_stddev 5.42 ns 0.000 ns 4
|
|
std::string::find + substr + std::strtol_cv 0.99 % 0.00 % 4
|
|
ssa::splitter + ssa::as_int_mean 166 ns 164 ns 4
|
|
ssa::splitter + ssa::as_int_median 166 ns 164 ns 4
|
|
ssa::splitter + ssa::as_int_stddev 6.43 ns 2.85 ns 4
|
|
ssa::splitter + ssa::as_int_cv 3.88 % 1.74 % 4
|
|
ssa::splitf + functor_mean 193 ns 193 ns 4
|
|
ssa::splitf + functor_median 193 ns 193 ns 4
|
|
ssa::splitf + functor_stddev 2.92 ns 2.62 ns 4
|
|
ssa::splitf + functor_cv 1.51 % 1.36 % 4
|
|
-- Replace symbols in text ~400 symbols --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Naive (and wrong) replace symbols with std::string find + replace_mean 1116 ns 1102 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_median 1114 ns 1116 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_stddev 8.69 ns 27.9 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_cv 0.78 % 2.53 % 4
|
|
replace symbols with std::string find_first_of + replace_mean 2075 ns 2039 ns 4
|
|
replace symbols with std::string find_first_of + replace_median 2077 ns 2002 ns 4
|
|
replace symbols with std::string find_first_of + replace_stddev 46.8 ns 73.2 ns 4
|
|
replace symbols with std::string find_first_of + replace_cv 2.26 % 3.59 % 4
|
|
replace symbols with std::string_view find_first_of + copy_mean 2461 ns 2455 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_median 2446 ns 2455 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_stddev 81.0 ns 91.1 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_cv 3.29 % 3.71 % 4
|
|
replace runtime symbols with string expressions and without remembering all search results_mean 1456 ns 1436 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_median 1460 ns 1444 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_stddev 20.4 ns 39.5 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_cv 1.40 % 2.75 % 4
|
|
replace runtime symbols with simstr and memorization of all search results_mean 1328 ns 1306 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_median 1324 ns 1306 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_stddev 34.7 ns 14.1 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_cv 2.61 % 1.08 % 4
|
|
replace const symbols with string expressions and without remembering all search results_mean 1171 ns 1154 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_median 1166 ns 1160 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_stddev 19.1 ns 41.7 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_cv 1.63 % 3.61 % 4
|
|
replace const symbols with string expressions and memorization of all search results_mean 1215 ns 1214 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_median 1214 ns 1214 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_stddev 22.7 ns 16.1 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_cv 1.87 % 1.33 % 4
|
|
-- Replace symbols in text ~40 symbols --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_mean 320 ns 317 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_median 319 ns 314 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_stddev 6.83 ns 6.98 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_cv 2.13 % 2.20 % 4
|
|
Short replace symbols with std::string find_first_of + replace_mean 382 ns 377 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_median 379 ns 375 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_stddev 13.1 ns 11.0 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_cv 3.44 % 2.91 % 4
|
|
Short replace symbols with std::string_view find_first_of + copy_mean 330 ns 330 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_median 329 ns 331 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_stddev 5.71 ns 6.68 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_cv 1.73 % 2.03 % 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_mean 257 ns 256 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_median 256 ns 258 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_stddev 6.36 ns 5.68 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_cv 2.47 % 2.21 % 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_mean 355 ns 351 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_median 352 ns 349 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_stddev 9.93 ns 11.0 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_cv 2.80 % 3.13 % 4
|
|
Short replace const symbols with string expressions and without remembering all search results_mean 222 ns 221 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_median 223 ns 222 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_stddev 4.02 ns 5.01 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_cv 1.81 % 2.27 % 4
|
|
Short replace const symbols with string expressions and memorization of all search results_mean 309 ns 307 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_median 311 ns 314 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_stddev 7.65 ns 14.0 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_cv 2.48 % 4.55 % 4
|
|
----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
replace bb to ---- in std::string|64_mean 231 ns 228 ns 4
|
|
replace bb to ---- in std::string|64_median 232 ns 229 ns 4
|
|
replace bb to ---- in std::string|64_stddev 2.69 ns 6.14 ns 4
|
|
replace bb to ---- in std::string|64_cv 1.16 % 2.69 % 4
|
|
replace bb to ---- in std::string|256_mean 790 ns 789 ns 4
|
|
replace bb to ---- in std::string|256_median 792 ns 793 ns 4
|
|
replace bb to ---- in std::string|256_stddev 11.5 ns 16.7 ns 4
|
|
replace bb to ---- in std::string|256_cv 1.46 % 2.12 % 4
|
|
replace bb to ---- in std::string|512_mean 1467 ns 1460 ns 4
|
|
replace bb to ---- in std::string|512_median 1478 ns 1460 ns 4
|
|
replace bb to ---- in std::string|512_stddev 26.4 ns 18.1 ns 4
|
|
replace bb to ---- in std::string|512_cv 1.80 % 1.24 % 4
|
|
replace bb to ---- in std::string|1024_mean 3177 ns 3174 ns 4
|
|
replace bb to ---- in std::string|1024_median 3178 ns 3174 ns 4
|
|
replace bb to ---- in std::string|1024_stddev 13.4 ns 40.3 ns 4
|
|
replace bb to ---- in std::string|1024_cv 0.42 % 1.27 % 4
|
|
replace bb to ---- in std::string|2048_mean 8072 ns 8022 ns 4
|
|
replace bb to ---- in std::string|2048_median 8057 ns 8022 ns 4
|
|
replace bb to ---- in std::string|2048_stddev 189 ns 142 ns 4
|
|
replace bb to ---- in std::string|2048_cv 2.34 % 1.77 % 4
|
|
replace bb to ---- in lstringa<8>|64_mean 241 ns 239 ns 4
|
|
replace bb to ---- in lstringa<8>|64_median 240 ns 238 ns 4
|
|
replace bb to ---- in lstringa<8>|64_stddev 4.83 ns 5.01 ns 4
|
|
replace bb to ---- in lstringa<8>|64_cv 2.00 % 2.09 % 4
|
|
replace bb to ---- in lstringa<8>|256_mean 641 ns 638 ns 4
|
|
replace bb to ---- in lstringa<8>|256_median 645 ns 635 ns 4
|
|
replace bb to ---- in lstringa<8>|256_stddev 9.51 ns 13.4 ns 4
|
|
replace bb to ---- in lstringa<8>|256_cv 1.48 % 2.09 % 4
|
|
replace bb to ---- in lstringa<8>|512_mean 1060 ns 1062 ns 4
|
|
replace bb to ---- in lstringa<8>|512_median 1066 ns 1067 ns 4
|
|
replace bb to ---- in lstringa<8>|512_stddev 23.4 ns 31.4 ns 4
|
|
replace bb to ---- in lstringa<8>|512_cv 2.21 % 2.96 % 4
|
|
replace bb to ---- in lstringa<8>|1024_mean 1917 ns 1894 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_median 1917 ns 1883 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_stddev 58.3 ns 20.9 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_cv 3.04 % 1.10 % 4
|
|
replace bb to ---- in lstringa<8>|2048_mean 3571 ns 3568 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_median 3575 ns 3568 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_stddev 27.6 ns 44.3 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_cv 0.77 % 1.24 % 4
|
|
replace bb to ---- by init stringa|64_mean 175 ns 174 ns 4
|
|
replace bb to ---- by init stringa|64_median 175 ns 175 ns 4
|
|
replace bb to ---- by init stringa|64_stddev 1.04 ns 3.67 ns 4
|
|
replace bb to ---- by init stringa|64_cv 0.60 % 2.12 % 4
|
|
replace bb to ---- by init stringa|256_mean 382 ns 377 ns 4
|
|
replace bb to ---- by init stringa|256_median 383 ns 377 ns 4
|
|
replace bb to ---- by init stringa|256_stddev 11.3 ns 9.26 ns 4
|
|
replace bb to ---- by init stringa|256_cv 2.95 % 2.46 % 4
|
|
replace bb to ---- by init stringa|512_mean 830 ns 833 ns 4
|
|
replace bb to ---- by init stringa|512_median 830 ns 837 ns 4
|
|
replace bb to ---- by init stringa|512_stddev 20.3 ns 21.9 ns 4
|
|
replace bb to ---- by init stringa|512_cv 2.45 % 2.64 % 4
|
|
replace bb to ---- by init stringa|1024_mean 1705 ns 1707 ns 4
|
|
replace bb to ---- by init stringa|1024_median 1706 ns 1707 ns 4
|
|
replace bb to ---- by init stringa|1024_stddev 15.9 ns 22.2 ns 4
|
|
replace bb to ---- by init stringa|1024_cv 0.93 % 1.30 % 4
|
|
replace bb to ---- by init stringa|2048_mean 3170 ns 3174 ns 4
|
|
replace bb to ---- by init stringa|2048_median 3166 ns 3174 ns 4
|
|
replace bb to ---- by init stringa|2048_stddev 77.6 ns 90.1 ns 4
|
|
replace bb to ---- by init stringa|2048_cv 2.45 % 2.84 % 4
|
|
----- Replace All Str To Same Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
replace bb to -- in std::string|64_mean 195 ns 193 ns 4
|
|
replace bb to -- in std::string|64_median 194 ns 193 ns 4
|
|
replace bb to -- in std::string|64_stddev 4.52 ns 0.000 ns 4
|
|
replace bb to -- in std::string|64_cv 2.31 % 0.00 % 4
|
|
replace bb to -- in std::string|256_mean 502 ns 500 ns 4
|
|
replace bb to -- in std::string|256_median 506 ns 508 ns 4
|
|
replace bb to -- in std::string|256_stddev 13.9 ns 22.1 ns 4
|
|
replace bb to -- in std::string|256_cv 2.77 % 4.42 % 4
|
|
replace bb to -- in std::string|512_mean 1022 ns 1019 ns 4
|
|
replace bb to -- in std::string|512_median 1009 ns 1001 ns 4
|
|
replace bb to -- in std::string|512_stddev 33.7 ns 36.6 ns 4
|
|
replace bb to -- in std::string|512_cv 3.30 % 3.59 % 4
|
|
replace bb to -- in std::string|1024_mean 1730 ns 1698 ns 4
|
|
replace bb to -- in std::string|1024_median 1734 ns 1707 ns 4
|
|
replace bb to -- in std::string|1024_stddev 41.7 ns 36.7 ns 4
|
|
replace bb to -- in std::string|1024_cv 2.41 % 2.16 % 4
|
|
replace bb to -- in std::string|2048_mean 3149 ns 3156 ns 4
|
|
replace bb to -- in std::string|2048_median 3127 ns 3139 ns 4
|
|
replace bb to -- in std::string|2048_stddev 92.0 ns 87.8 ns 4
|
|
replace bb to -- in std::string|2048_cv 2.92 % 2.78 % 4
|
|
replace bb to -- in lstringa<8>|64_mean 185 ns 184 ns 4
|
|
replace bb to -- in lstringa<8>|64_median 184 ns 184 ns 4
|
|
replace bb to -- in lstringa<8>|64_stddev 4.39 ns 3.42 ns 4
|
|
replace bb to -- in lstringa<8>|64_cv 2.38 % 1.86 % 4
|
|
replace bb to -- in lstringa<8>|256_mean 454 ns 450 ns 4
|
|
replace bb to -- in lstringa<8>|256_median 453 ns 450 ns 4
|
|
replace bb to -- in lstringa<8>|256_stddev 10.3 ns 5.84 ns 4
|
|
replace bb to -- in lstringa<8>|256_cv 2.27 % 1.30 % 4
|
|
replace bb to -- in lstringa<8>|512_mean 783 ns 785 ns 4
|
|
replace bb to -- in lstringa<8>|512_median 792 ns 785 ns 4
|
|
replace bb to -- in lstringa<8>|512_stddev 17.3 ns 14.2 ns 4
|
|
replace bb to -- in lstringa<8>|512_cv 2.20 % 1.81 % 4
|
|
replace bb to -- in lstringa<8>|1024_mean 1485 ns 1491 ns 4
|
|
replace bb to -- in lstringa<8>|1024_median 1484 ns 1507 ns 4
|
|
replace bb to -- in lstringa<8>|1024_stddev 25.8 ns 31.4 ns 4
|
|
replace bb to -- in lstringa<8>|1024_cv 1.74 % 2.11 % 4
|
|
replace bb to -- in lstringa<8>|2048_mean 2845 ns 2816 ns 4
|
|
replace bb to -- in lstringa<8>|2048_median 2832 ns 2816 ns 4
|
|
replace bb to -- in lstringa<8>|2048_stddev 44.1 ns 38.3 ns 4
|
|
replace bb to -- in lstringa<8>|2048_cv 1.55 % 1.36 % 4
|
|
replace bb to -- by init stringa|64_mean 162 ns 160 ns 4
|
|
replace bb to -- by init stringa|64_median 164 ns 160 ns 4
|
|
replace bb to -- by init stringa|64_stddev 5.47 ns 5.70 ns 4
|
|
replace bb to -- by init stringa|64_cv 3.37 % 3.55 % 4
|
|
replace bb to -- by init stringa|256_mean 362 ns 359 ns 4
|
|
replace bb to -- by init stringa|256_median 361 ns 361 ns 4
|
|
replace bb to -- by init stringa|256_stddev 3.41 ns 3.84 ns 4
|
|
replace bb to -- by init stringa|256_cv 0.94 % 1.07 % 4
|
|
replace bb to -- by init stringa|512_mean 605 ns 598 ns 4
|
|
replace bb to -- by init stringa|512_median 603 ns 594 ns 4
|
|
replace bb to -- by init stringa|512_stddev 13.4 ns 7.81 ns 4
|
|
replace bb to -- by init stringa|512_cv 2.21 % 1.31 % 4
|
|
replace bb to -- by init stringa|1024_mean 1070 ns 1059 ns 4
|
|
replace bb to -- by init stringa|1024_median 1062 ns 1052 ns 4
|
|
replace bb to -- by init stringa|1024_stddev 27.5 ns 30.1 ns 4
|
|
replace bb to -- by init stringa|1024_cv 2.57 % 2.84 % 4
|
|
replace bb to -- by init stringa|2048_mean 2042 ns 2051 ns 4
|
|
replace bb to -- by init stringa|2048_median 2050 ns 2051 ns 4
|
|
replace bb to -- by init stringa|2048_stddev 38.9 ns 34.2 ns 4
|
|
replace bb to -- by init stringa|2048_cv 1.90 % 1.67 % 4
|
|
----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
hashStrMapA<size_t> emplace & find stringa;_mean 3994959 ns 3989806 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_median 3978794 ns 3968917 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_stddev 80406 ns 79999 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_cv 2.01 % 2.01 % 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_mean 5594557 ns 5580357 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_median 5531872 ns 5510603 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_stddev 191789 ns 197295 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_cv 3.43 % 3.54 % 4
|
|
hashStrMapA<size_t> emplace & find ssa;_mean 3503253 ns 3504136 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_median 3514522 ns 3523284 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_stddev 59974 ns 38297 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_cv 1.71 % 1.09 % 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_mean 6252759 ns 6250000 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_median 6251412 ns 6250000 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_stddev 124886 ns 141753 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_cv 2.00 % 2.27 % 4
|
|
----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Build func full name std::string;_mean 1567 ns 1569 ns 4
|
|
Build func full name std::string;_median 1550 ns 1554 ns 4
|
|
Build func full name std::string;_stddev 48.2 ns 44.4 ns 4
|
|
Build func full name std::string;_cv 3.07 % 2.83 % 4
|
|
Build func full name std::string 1;_mean 1586 ns 1587 ns 4
|
|
Build func full name std::string 1;_median 1584 ns 1587 ns 4
|
|
Build func full name std::string 1;_stddev 20.0 ns 20.1 ns 4
|
|
Build func full name std::string 1;_cv 1.26 % 1.27 % 4
|
|
Build func full name std::stream;_mean 8328 ns 8196 ns 4
|
|
Build func full name std::stream;_median 8351 ns 8196 ns 4
|
|
Build func full name std::stream;_stddev 138 ns 142 ns 4
|
|
Build func full name std::stream;_cv 1.66 % 1.74 % 4
|
|
Build func full name stringa;_mean 825 ns 827 ns 4
|
|
Build func full name stringa;_median 819 ns 827 ns 4
|
|
Build func full name stringa;_stddev 20.1 ns 27.0 ns 4
|
|
Build func full name stringa;_cv 2.44 % 3.27 % 4
|
|
Build func full name stringa 1;_mean 935 ns 921 ns 4
|
|
Build func full name stringa 1;_median 933 ns 910 ns 4
|
|
Build func full name stringa 1;_stddev 29.6 ns 29.6 ns 4
|
|
Build func full name stringa 1;_cv 3.17 % 3.21 % 4
|