mirror of https://github.com/orefkov/simstr.git
938 lines
139 KiB
Plaintext
938 lines
139 KiB
Plaintext
Benchmarks of simstr, version 1.6.7
|
|
Sources: https://github.com/orefkov/simstr
|
|
Results: https://orefkov.github.io/simstr/results.html
|
|
|
|
2026-02-12T15:02:25+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 272 ns 270 ns 4
|
|
Concat std::string and number by std to std::string_median 269 ns 267 ns 4
|
|
Concat std::string and number by std to std::string_stddev 14.5 ns 11.4 ns 4
|
|
Concat std::string and number by std to std::string_cv 5.32 % 4.21 % 4
|
|
Concat std::string and number by StrExpr to std::string_mean 154 ns 154 ns 4
|
|
Concat std::string and number by StrExpr to std::string_median 154 ns 154 ns 4
|
|
Concat std::string and number by StrExpr to std::string_stddev 2.69 ns 2.56 ns 4
|
|
Concat std::string and number by StrExpr to std::string_cv 1.74 % 1.67 % 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_mean 68.4 ns 68.4 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_median 68.7 ns 69.1 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_stddev 1.22 ns 1.97 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_cv 1.79 % 2.89 % 4
|
|
Concat stringa and number by e_concat to simstr::stringa_mean 73.2 ns 73.2 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_median 72.9 ns 73.2 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_stddev 1.32 ns 1.42 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_cv 1.80 % 1.94 % 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 724 ns 725 ns 4
|
|
Concat std::string and format hex number and literal to std::string_median 713 ns 711 ns 4
|
|
Concat std::string and format hex number and literal to std::string_stddev 25.8 ns 27.9 ns 4
|
|
Concat std::string and format hex number and literal to std::string_cv 3.57 % 3.85 % 4
|
|
std::format std::string and hex number by literal to std::string_mean 1505 ns 1506 ns 4
|
|
std::format std::string and hex number by literal to std::string_median 1502 ns 1496 ns 4
|
|
std::format std::string and hex number by literal to std::string_stddev 28.5 ns 48.3 ns 4
|
|
std::format std::string and hex number by literal to std::string_cv 1.89 % 3.21 % 4
|
|
Concat std::string and std::to_chars and string to std::string_mean 194 ns 191 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_median 194 ns 190 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_stddev 2.21 ns 4.01 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_cv 1.14 % 2.09 % 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_mean 79.4 ns 79.0 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_median 80.3 ns 79.5 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_stddev 2.41 ns 2.63 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_cv 3.04 % 3.33 % 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 73.6 ns 73.8 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 74.1 ns 74.3 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 3.30 ns 3.57 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 4.48 % 4.84 % 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 80.7 ns 81.1 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_median 80.3 ns 80.2 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 2.59 ns 3.34 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 3.21 % 4.12 % 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_mean 148 ns 148 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_median 148 ns 148 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 6.14 ns 5.73 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_cv 4.16 % 3.88 % 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 286 ns 283 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 282 ns 279 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 8.46 ns 8.89 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 2.96 % 3.14 % 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 669 ns 670 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 671 ns 677 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 13.9 ns 19.7 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 2.07 % 2.95 % 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 745 ns 741 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 745 ns 741 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 17.7 ns 10.1 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 2.38 % 1.36 % 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_mean 1036 ns 1038 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_median 1038 ns 1038 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_stddev 15.0 ns 14.1 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_cv 1.45 % 1.36 % 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 1405 ns 1405 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 1395 ns 1397 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 31.2 ns 30.1 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 2.22 % 2.14 % 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 1331 ns 1325 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 1323 ns 1325 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 28.2 ns 16.1 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.12 % 1.22 % 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1540 ns 1535 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_median 1541 ns 1535 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 43.3 ns 57.0 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.81 % 3.71 % 4
|
|
std::vformat(pattern, std::make_format_args(i))_mean 1608 ns 1583 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_median 1578 ns 1573 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_stddev 75.3 ns 19.2 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_cv 4.68 % 1.21 % 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 6435 ns 6383 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 6449 ns 6417 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 82.1 ns 69.8 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 1.28 % 1.09 % 4
|
|
----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat std::string by std to std::string_mean 39.6 ns 39.5 ns 4
|
|
Concat std::string by std to std::string_median 39.9 ns 40.1 ns 4
|
|
Concat std::string by std to std::string_stddev 3.05 ns 2.97 ns 4
|
|
Concat std::string by std to std::string_cv 7.71 % 7.52 % 4
|
|
Concat std::string by StrExpr to std::string_mean 41.1 ns 41.0 ns 4
|
|
Concat std::string by StrExpr to std::string_median 40.9 ns 40.5 ns 4
|
|
Concat std::string by StrExpr to std::string_stddev 1.16 ns 1.23 ns 4
|
|
Concat std::string by StrExpr to std::string_cv 2.83 % 3.01 % 4
|
|
Concat stringa by StrExpr to stringa_mean 28.5 ns 28.4 ns 4
|
|
Concat stringa by StrExpr to stringa_median 28.5 ns 28.6 ns 4
|
|
Concat stringa by StrExpr to stringa_stddev 0.559 ns 0.601 ns 4
|
|
Concat stringa by StrExpr to stringa_cv 1.96 % 2.12 % 4
|
|
----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Find concat three std::string_mean 200 ns 201 ns 4
|
|
Find concat three std::string_median 201 ns 201 ns 4
|
|
Find concat three std::string_stddev 4.02 ns 3.42 ns 4
|
|
Find concat three std::string_cv 2.01 % 1.70 % 4
|
|
Find concat three strexpr_mean 116 ns 116 ns 4
|
|
Find concat three strexpr_median 115 ns 116 ns 4
|
|
Find concat three strexpr_stddev 3.22 ns 3.15 ns 4
|
|
Find concat three strexpr_cv 2.77 % 2.72 % 4
|
|
Find concat three simstr_mean 28.2 ns 28.2 ns 4
|
|
Find concat three simstr_median 27.5 ns 27.3 ns 4
|
|
Find concat three simstr_stddev 1.59 ns 1.78 ns 4
|
|
Find concat three simstr_cv 5.63 % 6.32 % 4
|
|
----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
BuildTypeNameStr 0/0_mean 7.98 ns 7.93 ns 4
|
|
BuildTypeNameStr 0/0_median 7.98 ns 7.93 ns 4
|
|
BuildTypeNameStr 0/0_stddev 0.087 ns 0.101 ns 4
|
|
BuildTypeNameStr 0/0_cv 1.08 % 1.27 % 4
|
|
BuildTypeNameExp 0/0_mean 7.44 ns 7.46 ns 4
|
|
BuildTypeNameExp 0/0_median 7.47 ns 7.50 ns 4
|
|
BuildTypeNameExp 0/0_stddev 0.147 ns 0.087 ns 4
|
|
BuildTypeNameExp 0/0_cv 1.98 % 1.17 % 4
|
|
BuildTypeNameSim 0/0_mean 7.74 ns 7.76 ns 4
|
|
BuildTypeNameSim 0/0_median 7.81 ns 7.76 ns 4
|
|
BuildTypeNameSim 0/0_stddev 0.181 ns 0.225 ns 4
|
|
BuildTypeNameSim 0/0_cv 2.34 % 2.90 % 4
|
|
BuildTypeNameStr 10/10_mean 58.7 ns 58.6 ns 4
|
|
BuildTypeNameStr 10/10_median 58.8 ns 58.6 ns 4
|
|
BuildTypeNameStr 10/10_stddev 0.838 ns 1.14 ns 4
|
|
BuildTypeNameStr 10/10_cv 1.43 % 1.94 % 4
|
|
BuildTypeNameExp 10/10_mean 32.2 ns 32.3 ns 4
|
|
BuildTypeNameExp 10/10_median 32.4 ns 32.4 ns 4
|
|
BuildTypeNameExp 10/10_stddev 0.808 ns 0.668 ns 4
|
|
BuildTypeNameExp 10/10_cv 2.51 % 2.07 % 4
|
|
BuildTypeNameSim 10/10_mean 25.3 ns 25.3 ns 4
|
|
BuildTypeNameSim 10/10_median 25.2 ns 25.1 ns 4
|
|
BuildTypeNameSim 10/10_stddev 0.497 ns 0.279 ns 4
|
|
BuildTypeNameSim 10/10_cv 1.96 % 1.10 % 4
|
|
----- Replace string by copy -----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat with replace str_mean 309 ns 308 ns 4
|
|
Concat with replace str_median 309 ns 308 ns 4
|
|
Concat with replace str_stddev 3.50 ns 8.46 ns 4
|
|
Concat with replace str_cv 1.13 % 2.75 % 4
|
|
Concat with replace exp_mean 214 ns 214 ns 4
|
|
Concat with replace exp_median 215 ns 215 ns 4
|
|
Concat with replace exp_stddev 3.45 ns 2.44 ns 4
|
|
Concat with replace exp_cv 1.61 % 1.14 % 4
|
|
----- Create Empty Str ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e;_mean 1.09 ns 1.09 ns 4
|
|
std::string e;_median 1.08 ns 1.09 ns 4
|
|
std::string e;_stddev 0.023 ns 0.032 ns 4
|
|
std::string e;_cv 2.09 % 2.90 % 4
|
|
std::string_view e;_mean 0.364 ns 0.360 ns 4
|
|
std::string_view e;_median 0.364 ns 0.356 ns 4
|
|
std::string_view e;_stddev 0.009 ns 0.012 ns 4
|
|
std::string_view e;_cv 2.39 % 3.29 % 4
|
|
ssa e;_mean 0.360 ns 0.355 ns 4
|
|
ssa e;_median 0.357 ns 0.353 ns 4
|
|
ssa e;_stddev 0.010 ns 0.004 ns 4
|
|
ssa e;_cv 2.68 % 1.13 % 4
|
|
stringa e;_mean 0.733 ns 0.732 ns 4
|
|
stringa e;_median 0.738 ns 0.732 ns 4
|
|
stringa e;_stddev 0.013 ns 0.014 ns 4
|
|
stringa e;_cv 1.74 % 1.94 % 4
|
|
lstringa<20> e;_mean 1.09 ns 1.09 ns 4
|
|
lstringa<20> e;_median 1.09 ns 1.09 ns 4
|
|
lstringa<20> e;_stddev 0.021 ns 0.023 ns 4
|
|
lstringa<20> e;_cv 1.96 % 2.14 % 4
|
|
lstringa<40> e;_mean 1.10 ns 1.10 ns 4
|
|
lstringa<40> e;_median 1.10 ns 1.10 ns 4
|
|
lstringa<40> e;_stddev 0.006 ns 0.012 ns 4
|
|
lstringa<40> e;_cv 0.56 % 1.10 % 4
|
|
----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "Test text";_mean 1.83 ns 1.83 ns 4
|
|
std::string e = "Test text";_median 1.84 ns 1.84 ns 4
|
|
std::string e = "Test text";_stddev 0.030 ns 0.021 ns 4
|
|
std::string e = "Test text";_cv 1.64 % 1.14 % 4
|
|
std::string_view e = "Test text";_mean 0.753 ns 0.750 ns 4
|
|
std::string_view e = "Test text";_median 0.759 ns 0.750 ns 4
|
|
std::string_view e = "Test text";_stddev 0.034 ns 0.045 ns 4
|
|
std::string_view e = "Test text";_cv 4.51 % 6.00 % 4
|
|
ssa e = "Test text";_mean 0.360 ns 0.359 ns 4
|
|
ssa e = "Test text";_median 0.360 ns 0.357 ns 4
|
|
ssa e = "Test text";_stddev 0.003 ns 0.008 ns 4
|
|
ssa e = "Test text";_cv 0.90 % 2.14 % 4
|
|
stringa e = "Test text";_mean 1.10 ns 1.09 ns 4
|
|
stringa e = "Test text";_median 1.10 ns 1.10 ns 4
|
|
stringa e = "Test text";_stddev 0.016 ns 0.020 ns 4
|
|
stringa e = "Test text";_cv 1.49 % 1.83 % 4
|
|
lstringa<20> e = "Test text";_mean 1.82 ns 1.81 ns 4
|
|
lstringa<20> e = "Test text";_median 1.82 ns 1.80 ns 4
|
|
lstringa<20> e = "Test text";_stddev 0.018 ns 0.019 ns 4
|
|
lstringa<20> e = "Test text";_cv 0.97 % 1.06 % 4
|
|
lstringa<40> e = "Test text";_mean 1.82 ns 1.82 ns 4
|
|
lstringa<40> e = "Test text";_median 1.82 ns 1.82 ns 4
|
|
lstringa<40> e = "Test text";_stddev 0.015 ns 0.022 ns 4
|
|
lstringa<40> e = "Test text";_cv 0.81 % 1.22 % 4
|
|
----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "123456789012345678901234567890";_mean 73.4 ns 73.7 ns 4
|
|
std::string e = "123456789012345678901234567890";_median 73.5 ns 74.1 ns 4
|
|
std::string e = "123456789012345678901234567890";_stddev 1.29 ns 1.67 ns 4
|
|
std::string e = "123456789012345678901234567890";_cv 1.75 % 2.27 % 4
|
|
std::string_view e = "123456789012345678901234567890";_mean 0.729 ns 0.732 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_median 0.731 ns 0.739 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_stddev 0.008 ns 0.014 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_cv 1.10 % 1.90 % 4
|
|
ssa e = "123456789012345678901234567890";_mean 0.364 ns 0.361 ns 4
|
|
ssa e = "123456789012345678901234567890";_median 0.363 ns 0.361 ns 4
|
|
ssa e = "123456789012345678901234567890";_stddev 0.005 ns 0.007 ns 4
|
|
ssa e = "123456789012345678901234567890";_cv 1.28 % 1.81 % 4
|
|
stringa e = "123456789012345678901234567890";_mean 1.08 ns 1.09 ns 4
|
|
stringa e = "123456789012345678901234567890";_median 1.09 ns 1.09 ns 4
|
|
stringa e = "123456789012345678901234567890";_stddev 0.020 ns 0.014 ns 4
|
|
stringa e = "123456789012345678901234567890";_cv 1.80 % 1.30 % 4
|
|
lstringa<20> e = "123456789012345678901234567890";_mean 74.8 ns 74.6 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_median 74.2 ns 74.1 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_stddev 1.24 ns 1.67 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_cv 1.66 % 2.24 % 4
|
|
lstringa<40> e = "123456789012345678901234567890";_mean 2.56 ns 2.55 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_median 2.57 ns 2.55 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_stddev 0.058 ns 0.048 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_cv 2.25 % 1.90 % 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.82 ns 1.81 ns 4
|
|
std::string e = "Test text"; auto c{e};_median 1.81 ns 1.80 ns 4
|
|
std::string e = "Test text"; auto c{e};_stddev 0.027 ns 0.019 ns 4
|
|
std::string e = "Test text"; auto c{e};_cv 1.50 % 1.06 % 4
|
|
std::string_view e = "Test text"; auto c{e};_mean 0.363 ns 0.363 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_median 0.363 ns 0.365 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_stddev 0.004 ns 0.008 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_cv 0.97 % 2.12 % 4
|
|
ssa e = "Test text"; auto c{e};_mean 0.363 ns 0.363 ns 4
|
|
ssa e = "Test text"; auto c{e};_median 0.364 ns 0.361 ns 4
|
|
ssa e = "Test text"; auto c{e};_stddev 0.004 ns 0.004 ns 4
|
|
ssa e = "Test text"; auto c{e};_cv 1.21 % 1.10 % 4
|
|
stringa e = "Test text"; auto c{e};_mean 1.28 ns 1.28 ns 4
|
|
stringa e = "Test text"; auto c{e};_median 1.27 ns 1.28 ns 4
|
|
stringa e = "Test text"; auto c{e};_stddev 0.034 ns 0.032 ns 4
|
|
stringa e = "Test text"; auto c{e};_cv 2.65 % 2.51 % 4
|
|
lstringa<20> e = "Test text"; auto c{e};_mean 1.46 ns 1.45 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_median 1.46 ns 1.46 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_stddev 0.022 ns 0.030 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_cv 1.49 % 2.07 % 4
|
|
lstringa<40> e = "Test text"; auto c{e};_mean 1.46 ns 1.47 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_median 1.47 ns 1.48 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_stddev 0.030 ns 0.047 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_cv 2.03 % 3.21 % 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.7 ns 74.6 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_median 74.6 ns 74.1 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_stddev 0.952 ns 1.67 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_cv 1.27 % 2.24 % 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.732 ns 0.732 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.734 ns 0.732 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.013 ns 0.014 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 1.72 % 1.94 % 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.368 ns 0.366 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_median 0.369 ns 0.368 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.007 ns 0.010 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_cv 1.82 % 2.64 % 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.80 ns 1.79 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_median 1.80 ns 1.80 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.029 ns 0.021 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.61 % 1.17 % 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 73.7 ns 73.7 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 73.7 ns 74.1 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 1.44 ns 1.67 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 1.95 % 2.27 % 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.79 ns 4.81 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.82 ns 4.81 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.097 ns 0.140 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 2.03 % 2.90 % 4
|
|
----- Find 9 symbols text in end of 99 symbols text ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string::find;_mean 38.5 ns 38.1 ns 4
|
|
std::string::find;_median 38.6 ns 38.4 ns 4
|
|
std::string::find;_stddev 0.485 ns 0.436 ns 4
|
|
std::string::find;_cv 1.26 % 1.14 % 4
|
|
std::string_view::find;_mean 37.7 ns 37.7 ns 4
|
|
std::string_view::find;_median 37.7 ns 37.7 ns 4
|
|
std::string_view::find;_stddev 0.142 ns 0.683 ns 4
|
|
std::string_view::find;_cv 0.38 % 1.81 % 4
|
|
ssa::find;_mean 17.5 ns 17.5 ns 4
|
|
ssa::find;_median 17.3 ns 17.3 ns 4
|
|
ssa::find;_stddev 0.518 ns 0.665 ns 4
|
|
ssa::find;_cv 2.97 % 3.81 % 4
|
|
stringa::find;_mean 17.9 ns 17.8 ns 4
|
|
stringa::find;_median 17.9 ns 17.8 ns 4
|
|
stringa::find;_stddev 0.221 ns 0.495 ns 4
|
|
stringa::find;_cv 1.23 % 2.78 % 4
|
|
lstringa<20>::find;_mean 18.2 ns 18.1 ns 4
|
|
lstringa<20>::find;_median 18.1 ns 18.0 ns 4
|
|
lstringa<20>::find;_stddev 0.260 ns 0.209 ns 4
|
|
lstringa<20>::find;_cv 1.43 % 1.16 % 4
|
|
lstringa<40>::find;_mean 17.5 ns 17.5 ns 4
|
|
lstringa<40>::find;_median 17.5 ns 17.5 ns 4
|
|
lstringa<40>::find;_stddev 0.310 ns 0.222 ns 4
|
|
lstringa<40>::find;_cv 1.77 % 1.27 % 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.83 ns 1.83 ns 4
|
|
std::string copy{str_with_len_N};/15_median 1.83 ns 1.84 ns 4
|
|
std::string copy{str_with_len_N};/15_stddev 0.015 ns 0.019 ns 4
|
|
std::string copy{str_with_len_N};/15_cv 0.81 % 1.05 % 4
|
|
std::string copy{str_with_len_N};/16_mean 77.7 ns 77.6 ns 4
|
|
std::string copy{str_with_len_N};/16_median 77.7 ns 77.6 ns 4
|
|
std::string copy{str_with_len_N};/16_stddev 1.33 ns 1.01 ns 4
|
|
std::string copy{str_with_len_N};/16_cv 1.71 % 1.30 % 4
|
|
std::string copy{str_with_len_N};/23_mean 76.4 ns 76.3 ns 4
|
|
std::string copy{str_with_len_N};/23_median 76.3 ns 75.9 ns 4
|
|
std::string copy{str_with_len_N};/23_stddev 1.43 ns 1.67 ns 4
|
|
std::string copy{str_with_len_N};/23_cv 1.88 % 2.19 % 4
|
|
std::string copy{str_with_len_N};/24_mean 77.9 ns 78.1 ns 4
|
|
std::string copy{str_with_len_N};/24_median 78.0 ns 78.1 ns 4
|
|
std::string copy{str_with_len_N};/24_stddev 0.821 ns 1.61 ns 4
|
|
std::string copy{str_with_len_N};/24_cv 1.05 % 2.06 % 4
|
|
std::string copy{str_with_len_N};/32_mean 81.7 ns 81.1 ns 4
|
|
std::string copy{str_with_len_N};/32_median 81.8 ns 82.0 ns 4
|
|
std::string copy{str_with_len_N};/32_stddev 2.01 ns 1.74 ns 4
|
|
std::string copy{str_with_len_N};/32_cv 2.46 % 2.15 % 4
|
|
std::string copy{str_with_len_N};/64_mean 84.6 ns 84.2 ns 4
|
|
std::string copy{str_with_len_N};/64_median 84.8 ns 84.8 ns 4
|
|
std::string copy{str_with_len_N};/64_stddev 1.84 ns 2.00 ns 4
|
|
std::string copy{str_with_len_N};/64_cv 2.18 % 2.38 % 4
|
|
std::string copy{str_with_len_N};/128_mean 85.5 ns 85.4 ns 4
|
|
std::string copy{str_with_len_N};/128_median 85.6 ns 85.4 ns 4
|
|
std::string copy{str_with_len_N};/128_stddev 0.807 ns 1.42 ns 4
|
|
std::string copy{str_with_len_N};/128_cv 0.94 % 1.67 % 4
|
|
std::string copy{str_with_len_N};/256_mean 84.3 ns 84.2 ns 4
|
|
std::string copy{str_with_len_N};/256_median 84.3 ns 84.8 ns 4
|
|
std::string copy{str_with_len_N};/256_stddev 1.94 ns 2.00 ns 4
|
|
std::string copy{str_with_len_N};/256_cv 2.30 % 2.38 % 4
|
|
std::string copy{str_with_len_N};/512_mean 88.0 ns 87.9 ns 4
|
|
std::string copy{str_with_len_N};/512_median 87.7 ns 87.9 ns 4
|
|
std::string copy{str_with_len_N};/512_stddev 2.24 ns 1.71 ns 4
|
|
std::string copy{str_with_len_N};/512_cv 2.54 % 1.94 % 4
|
|
std::string copy{str_with_len_N};/1024_mean 104 ns 104 ns 4
|
|
std::string copy{str_with_len_N};/1024_median 99.8 ns 99.4 ns 4
|
|
std::string copy{str_with_len_N};/1024_stddev 12.3 ns 10.6 ns 4
|
|
std::string copy{str_with_len_N};/1024_cv 11.79 % 10.23 % 4
|
|
std::string copy{str_with_len_N};/2048_mean 131 ns 130 ns 4
|
|
std::string copy{str_with_len_N};/2048_median 132 ns 128 ns 4
|
|
std::string copy{str_with_len_N};/2048_stddev 6.89 ns 6.19 ns 4
|
|
std::string copy{str_with_len_N};/2048_cv 5.24 % 4.74 % 4
|
|
std::string copy{str_with_len_N};/4096_mean 178 ns 177 ns 4
|
|
std::string copy{str_with_len_N};/4096_median 177 ns 178 ns 4
|
|
std::string copy{str_with_len_N};/4096_stddev 4.97 ns 4.01 ns 4
|
|
std::string copy{str_with_len_N};/4096_cv 2.80 % 2.27 % 4
|
|
stringa copy{str_with_len_N};/15_mean 1.27 ns 1.27 ns 4
|
|
stringa copy{str_with_len_N};/15_median 1.27 ns 1.28 ns 4
|
|
stringa copy{str_with_len_N};/15_stddev 0.021 ns 0.028 ns 4
|
|
stringa copy{str_with_len_N};/15_cv 1.61 % 2.20 % 4
|
|
stringa copy{str_with_len_N};/16_mean 1.28 ns 1.28 ns 4
|
|
stringa copy{str_with_len_N};/16_median 1.29 ns 1.28 ns 4
|
|
stringa copy{str_with_len_N};/16_stddev 0.023 ns 0.035 ns 4
|
|
stringa copy{str_with_len_N};/16_cv 1.81 % 2.75 % 4
|
|
stringa copy{str_with_len_N};/23_mean 1.28 ns 1.28 ns 4
|
|
stringa copy{str_with_len_N};/23_median 1.27 ns 1.26 ns 4
|
|
stringa copy{str_with_len_N};/23_stddev 0.034 ns 0.047 ns 4
|
|
stringa copy{str_with_len_N};/23_cv 2.64 % 3.68 % 4
|
|
stringa copy{str_with_len_N};/24_mean 15.8 ns 15.8 ns 4
|
|
stringa copy{str_with_len_N};/24_median 15.8 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/24_stddev 0.109 ns 0.334 ns 4
|
|
stringa copy{str_with_len_N};/24_cv 0.69 % 2.12 % 4
|
|
stringa copy{str_with_len_N};/32_mean 15.8 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/32_median 15.8 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/32_stddev 0.054 ns 0.000 ns 4
|
|
stringa copy{str_with_len_N};/32_cv 0.34 % 0.00 % 4
|
|
stringa copy{str_with_len_N};/64_mean 15.8 ns 15.8 ns 4
|
|
stringa copy{str_with_len_N};/64_median 15.7 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/64_stddev 0.095 ns 0.174 ns 4
|
|
stringa copy{str_with_len_N};/64_cv 0.60 % 1.10 % 4
|
|
stringa copy{str_with_len_N};/128_mean 15.8 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/128_median 15.8 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/128_stddev 0.128 ns 0.201 ns 4
|
|
stringa copy{str_with_len_N};/128_cv 0.81 % 1.27 % 4
|
|
stringa copy{str_with_len_N};/256_mean 15.8 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/256_median 15.8 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/256_stddev 0.130 ns 0.285 ns 4
|
|
stringa copy{str_with_len_N};/256_cv 0.82 % 1.81 % 4
|
|
stringa copy{str_with_len_N};/512_mean 15.8 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/512_median 15.8 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/512_stddev 0.066 ns 0.000 ns 4
|
|
stringa copy{str_with_len_N};/512_cv 0.42 % 0.00 % 4
|
|
stringa copy{str_with_len_N};/1024_mean 15.9 ns 15.8 ns 4
|
|
stringa copy{str_with_len_N};/1024_median 15.9 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/1024_stddev 0.152 ns 0.367 ns 4
|
|
stringa copy{str_with_len_N};/1024_cv 0.96 % 2.32 % 4
|
|
stringa copy{str_with_len_N};/2048_mean 15.8 ns 15.8 ns 4
|
|
stringa copy{str_with_len_N};/2048_median 15.8 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/2048_stddev 0.094 ns 0.174 ns 4
|
|
stringa copy{str_with_len_N};/2048_cv 0.60 % 1.10 % 4
|
|
stringa copy{str_with_len_N};/4096_mean 15.8 ns 15.8 ns 4
|
|
stringa copy{str_with_len_N};/4096_median 15.8 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/4096_stddev 0.113 ns 0.174 ns 4
|
|
stringa copy{str_with_len_N};/4096_cv 0.72 % 1.10 % 4
|
|
lstringa<16> copy{str_with_len_N};/15_mean 1.50 ns 1.51 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_median 1.50 ns 1.51 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_stddev 0.029 ns 0.026 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_cv 1.92 % 1.70 % 4
|
|
lstringa<16> copy{str_with_len_N};/16_mean 5.06 ns 5.08 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_median 4.98 ns 5.00 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_stddev 0.202 ns 0.156 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_cv 3.98 % 3.08 % 4
|
|
lstringa<16> copy{str_with_len_N};/23_mean 5.09 ns 5.12 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_median 5.06 ns 5.16 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_stddev 0.061 ns 0.078 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_cv 1.20 % 1.53 % 4
|
|
lstringa<16> copy{str_with_len_N};/24_mean 75.9 ns 75.9 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_median 76.3 ns 75.9 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_stddev 2.18 ns 2.25 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_cv 2.88 % 2.97 % 4
|
|
lstringa<16> copy{str_with_len_N};/32_mean 78.1 ns 78.1 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_median 78.0 ns 78.1 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_stddev 2.17 ns 2.28 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_cv 2.78 % 2.92 % 4
|
|
lstringa<16> copy{str_with_len_N};/64_mean 80.4 ns 79.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_median 80.7 ns 79.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_stddev 1.99 ns 2.25 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_cv 2.47 % 2.84 % 4
|
|
lstringa<16> copy{str_with_len_N};/128_mean 82.0 ns 81.5 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_median 82.1 ns 81.1 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_stddev 1.74 ns 1.67 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_cv 2.13 % 2.05 % 4
|
|
lstringa<16> copy{str_with_len_N};/256_mean 83.4 ns 83.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_median 83.4 ns 82.8 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_stddev 1.47 ns 1.67 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_cv 1.77 % 2.01 % 4
|
|
lstringa<16> copy{str_with_len_N};/512_mean 84.4 ns 83.7 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_median 84.2 ns 83.7 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_stddev 1.76 ns 3.82 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_cv 2.08 % 4.56 % 4
|
|
lstringa<16> copy{str_with_len_N};/1024_mean 94.4 ns 94.7 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_median 94.2 ns 94.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_stddev 1.29 ns 1.05 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_cv 1.37 % 1.10 % 4
|
|
lstringa<16> copy{str_with_len_N};/2048_mean 127 ns 127 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_median 129 ns 127 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_stddev 4.04 ns 3.60 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_cv 3.19 % 2.84 % 4
|
|
lstringa<16> copy{str_with_len_N};/4096_mean 184 ns 183 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_median 184 ns 184 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_stddev 1.01 ns 5.27 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_cv 0.55 % 2.88 % 4
|
|
lstringa<512> copy{str_with_len_N};/15_mean 1.47 ns 1.47 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_median 1.48 ns 1.48 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_stddev 0.030 ns 0.039 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_cv 2.08 % 2.69 % 4
|
|
lstringa<512> copy{str_with_len_N};/16_mean 5.10 ns 5.12 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_median 5.11 ns 5.16 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_stddev 0.067 ns 0.078 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_cv 1.32 % 1.53 % 4
|
|
lstringa<512> copy{str_with_len_N};/23_mean 5.25 ns 5.27 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_median 5.21 ns 5.23 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_stddev 0.175 ns 0.150 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_cv 3.34 % 2.84 % 4
|
|
lstringa<512> copy{str_with_len_N};/24_mean 5.15 ns 5.13 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_median 5.15 ns 5.16 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_stddev 0.056 ns 0.070 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_cv 1.08 % 1.36 % 4
|
|
lstringa<512> copy{str_with_len_N};/32_mean 8.25 ns 8.24 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_median 8.27 ns 8.28 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_stddev 0.121 ns 0.167 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_cv 1.46 % 2.03 % 4
|
|
lstringa<512> copy{str_with_len_N};/64_mean 8.13 ns 8.11 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_median 8.15 ns 8.16 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_stddev 0.287 ns 0.314 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_cv 3.53 % 3.87 % 4
|
|
lstringa<512> copy{str_with_len_N};/128_mean 8.42 ns 8.37 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_median 8.44 ns 8.37 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_stddev 0.133 ns 0.000 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_cv 1.57 % 0.00 % 4
|
|
lstringa<512> copy{str_with_len_N};/256_mean 10.1 ns 10.1 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_median 10.1 ns 10.1 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_stddev 0.141 ns 0.234 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_cv 1.40 % 2.32 % 4
|
|
lstringa<512> copy{str_with_len_N};/512_mean 11.1 ns 11.0 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_median 11.1 ns 11.0 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_stddev 0.282 ns 0.161 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_cv 2.53 % 1.46 % 4
|
|
lstringa<512> copy{str_with_len_N};/1024_mean 96.6 ns 96.3 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_median 96.4 ns 95.2 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_stddev 2.79 ns 2.96 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_cv 2.89 % 3.07 % 4
|
|
lstringa<512> copy{str_with_len_N};/2048_mean 129 ns 129 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_median 130 ns 131 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_stddev 5.88 ns 6.59 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_cv 4.55 % 5.11 % 4
|
|
lstringa<512> copy{str_with_len_N};/4096_mean 184 ns 184 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_median 183 ns 184 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_stddev 3.25 ns 3.42 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_cv 1.76 % 1.86 % 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 30.8 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 30.9 ns 30.8 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.241 ns 0.383 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 0.77 % 1.24 % 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 13.3 ns 13.3 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 13.3 ns 13.3 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.253 ns 0.301 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 1.90 % 2.27 % 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 13.9 ns 14.0 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_median 14.0 ns 14.0 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.223 ns 0.228 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 1.60 % 1.63 % 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 12.9 ns 12.8 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_median 12.9 ns 12.7 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.171 ns 0.267 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 1.33 % 2.09 % 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 13.3 ns 13.2 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_median 13.3 ns 13.2 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.240 ns 0.495 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 1.80 % 3.74 % 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.4 ns 34.1 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 33.6 ns 33.0 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 1.96 ns 2.30 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 5.69 % 6.74 % 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 8.71 ns 8.63 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 8.50 ns 8.37 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.776 ns 0.826 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 8.91 % 9.57 % 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 12.0 ns 12.0 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 12.0 ns 12.0 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.118 ns 0.228 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 0.98 % 1.90 % 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 11.8 ns 11.8 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 11.9 ns 11.9 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.183 ns 0.267 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 1.54 % 2.27 % 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 12.3 ns 12.3 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 12.2 ns 12.3 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.498 ns 0.456 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 4.06 % 3.71 % 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 44.2 ns 44.2 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 44.4 ns 44.4 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 1.81 ns 1.67 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 4.10 % 3.77 % 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_mean 17.7 ns 17.6 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_median 17.6 ns 17.6 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_stddev 0.270 ns 0.342 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_cv 1.53 % 1.94 % 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_mean 15.9 ns 15.9 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_median 15.9 ns 15.9 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_stddev 0.103 ns 0.201 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_cv 0.65 % 1.27 % 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 102 ns 101 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 102 ns 101 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 2.13 ns 3.15 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 2.09 % 3.11 % 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 58.7 ns 58.6 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 58.5 ns 58.6 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 1.83 ns 1.61 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 3.12 % 2.75 % 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_mean 35.2 ns 35.1 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_median 35.2 ns 35.3 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.374 ns 0.384 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_cv 1.06 % 1.09 % 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 4625 ns 4604 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_median 4624 ns 4604 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 111 ns 161 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.41 % 3.50 % 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_mean 1067 ns 1068 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_median 1068 ns 1062 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_stddev 27.9 ns 23.4 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_cv 2.61 % 2.19 % 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 746 ns 746 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_median 743 ns 739 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 12.5 ns 14.0 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 1.67 % 1.87 % 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 388 ns 389 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_median 387 ns 387 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 4.24 ns 4.20 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 1.09 % 1.08 % 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 227 ns 228 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_median 229 ns 229 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 5.32 ns 4.34 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 2.34 % 1.91 % 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 135 ns 135 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 135 ns 133 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 1.77 ns 4.44 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 1.31 % 3.29 % 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 4517 ns 4517 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 4516 ns 4541 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 83.6 ns 93.5 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 1.85 % 2.07 % 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 3763 ns 3771 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_median 3732 ns 3749 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 92.8 ns 110 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 2.46 % 2.91 % 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 703 ns 702 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 700 ns 698 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 11.2 ns 8.72 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.59 % 1.24 % 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 450 ns 449 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 449 ns 444 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 25.6 ns 28.7 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 5.69 % 6.40 % 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 300 ns 300 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 302 ns 301 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 6.36 ns 7.90 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.12 % 2.64 % 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 209 ns 210 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 209 ns 209 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 0.643 ns 2.27 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 0.31 % 1.08 % 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 221538 ns 221010 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 220176 ns 217087 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 7840 ns 9902 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 3.54 % 4.48 % 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 187478 ns 187038 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 187660 ns 185904 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 7729 ns 6801 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 4.12 % 3.64 % 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 18490 ns 18415 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 18387 ns 18415 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 449 ns 342 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.43 % 1.86 % 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16842 ns 16828 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16953 ns 16915 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 505 ns 596 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.00 % 3.54 % 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16140 ns 16044 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16193 ns 16044 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 362 ns 285 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.25 % 1.77 % 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16187 ns 16131 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16200 ns 16218 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 191 ns 334 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.18 % 2.07 % 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 4542 ns 4544 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_median 4385 ns 4379 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_stddev 429 ns 431 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_cv 9.44 % 9.48 % 4
|
|
std::string str; ... str += str_var1 + str_var2;_mean 3837 ns 3830 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_median 3859 ns 3850 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_stddev 61.7 ns 41.9 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_cv 1.61 % 1.09 % 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_mean 816 ns 811 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_median 817 ns 811 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_stddev 5.69 ns 10.1 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_cv 0.70 % 1.24 % 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_mean 526 ns 520 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_median 529 ns 516 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_stddev 11.8 ns 20.9 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_cv 2.25 % 4.03 % 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_mean 382 ns 381 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_median 375 ns 375 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_stddev 16.1 ns 13.1 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_cv 4.23 % 3.43 % 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_mean 277 ns 278 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_median 276 ns 279 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 5.68 ns 6.01 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_cv 2.05 % 2.16 % 4
|
|
-- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::stringstream str; str << "test = " << k << " times";_mean 10808 ns 10742 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_median 10860 ns 10742 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_stddev 324 ns 399 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_cv 3.00 % 3.71 % 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_mean 1044 ns 1046 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_median 1046 ns 1046 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_stddev 17.5 ns 17.1 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_cv 1.68 % 1.63 % 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 2812 ns 2816 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 2832 ns 2846 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 89.7 ns 114 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 3.19 % 4.03 % 4
|
|
std::string str = std::format("test = {} times", k);_mean 1913 ns 1915 ns 4
|
|
std::string str = std::format("test = {} times", k);_median 1898 ns 1904 ns 4
|
|
std::string str = std::format("test = {} times", k);_stddev 93.7 ns 115 ns 4
|
|
std::string str = std::format("test = {} times", k);_cv 4.90 % 6.02 % 4
|
|
lstringa<8> str; str.format("test = {} times", k);_mean 2071 ns 2061 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_median 2078 ns 2051 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_stddev 39.9 ns 52.7 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_cv 1.92 % 2.55 % 4
|
|
lstringa<32> str; str.format("test = {} times", k);_mean 1006 ns 1007 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_median 997 ns 1001 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_stddev 22.1 ns 30.7 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_cv 2.20 % 3.05 % 4
|
|
lstringa<8> str = "test = " + k + " times";_mean 836 ns 837 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_median 834 ns 837 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_stddev 11.9 ns 14.2 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_cv 1.43 % 1.70 % 4
|
|
lstringa<32> str = "test = " + k + " times";_mean 155 ns 155 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_median 155 ns 155 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_stddev 5.90 ns 6.04 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_cv 3.79 % 3.89 % 4
|
|
stringa str = "test = " + k + " times";_mean 156 ns 156 ns 4
|
|
stringa str = "test = " + k + " times";_median 153 ns 153 ns 4
|
|
stringa str = "test = " + k + " times";_stddev 8.76 ns 7.73 ns 4
|
|
stringa str = "test = " + k + " times";_cv 5.62 % 4.95 % 4
|
|
-- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string::find + substr + std::strtol_mean 541 ns 539 ns 4
|
|
std::string::find + substr + std::strtol_median 540 ns 539 ns 4
|
|
std::string::find + substr + std::strtol_stddev 15.1 ns 9.02 ns 4
|
|
std::string::find + substr + std::strtol_cv 2.79 % 1.67 % 4
|
|
ssa::splitter + ssa::as_int_mean 158 ns 156 ns 4
|
|
ssa::splitter + ssa::as_int_median 157 ns 157 ns 4
|
|
ssa::splitter + ssa::as_int_stddev 2.68 ns 4.39 ns 4
|
|
ssa::splitter + ssa::as_int_cv 1.70 % 2.81 % 4
|
|
ssa::splitf + functor_mean 181 ns 181 ns 4
|
|
ssa::splitf + functor_median 181 ns 180 ns 4
|
|
ssa::splitf + functor_stddev 1.01 ns 1.92 ns 4
|
|
ssa::splitf + functor_cv 0.56 % 1.06 % 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 1171 ns 1169 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_median 1167 ns 1161 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_stddev 29.7 ns 39.5 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_cv 2.54 % 3.38 % 4
|
|
replace symbols with std::string find_first_of + replace_mean 2049 ns 2052 ns 4
|
|
replace symbols with std::string find_first_of + replace_median 2043 ns 2040 ns 4
|
|
replace symbols with std::string find_first_of + replace_stddev 83.1 ns 68.0 ns 4
|
|
replace symbols with std::string find_first_of + replace_cv 4.06 % 3.31 % 4
|
|
replace symbols with std::string_view find_first_of + copy_mean 2357 ns 2341 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_median 2379 ns 2380 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_stddev 56.8 ns 99.0 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_cv 2.41 % 4.23 % 4
|
|
replace runtime symbols with string expressions and without remembering all search results_mean 1451 ns 1452 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_median 1457 ns 1460 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_stddev 29.9 ns 30.1 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_cv 2.06 % 2.07 % 4
|
|
replace runtime symbols with simstr and memorization of all search results_mean 1346 ns 1342 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_median 1341 ns 1334 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_stddev 19.6 ns 30.1 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_cv 1.46 % 2.24 % 4
|
|
replace const symbols with string expressions and without remembering all search results_mean 1228 ns 1221 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_median 1230 ns 1214 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_stddev 12.7 ns 26.7 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_cv 1.03 % 2.19 % 4
|
|
replace const symbols with string expressions and memorization of all search results_mean 1121 ns 1123 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_median 1118 ns 1130 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_stddev 16.2 ns 26.7 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_cv 1.45 % 2.38 % 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 319 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_median 318 ns 317 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_stddev 5.52 ns 6.68 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_cv 1.73 % 2.09 % 4
|
|
Short replace symbols with std::string find_first_of + replace_mean 364 ns 360 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_median 364 ns 360 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_stddev 7.93 ns 6.83 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_cv 2.18 % 1.90 % 4
|
|
Short replace symbols with std::string_view find_first_of + copy_mean 319 ns 317 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_median 319 ns 318 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_stddev 7.88 ns 13.1 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_cv 2.47 % 4.14 % 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_mean 266 ns 267 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_median 265 ns 267 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_stddev 6.04 ns 4.84 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_cv 2.27 % 1.81 % 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_mean 355 ns 355 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_median 355 ns 357 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_stddev 6.73 ns 7.68 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_cv 1.90 % 2.16 % 4
|
|
Short replace const symbols with string expressions and without remembering all search results_mean 225 ns 224 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_median 227 ns 225 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_stddev 6.21 ns 6.58 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_cv 2.76 % 2.94 % 4
|
|
Short replace const symbols with string expressions and memorization of all search results_mean 292 ns 292 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_median 292 ns 292 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_stddev 6.45 ns 7.65 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_cv 2.21 % 2.62 % 4
|
|
----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
replace bb to ---- in std::string|64_mean 224 ns 224 ns 4
|
|
replace bb to ---- in std::string|64_median 224 ns 224 ns 4
|
|
replace bb to ---- in std::string|64_stddev 6.25 ns 5.85 ns 4
|
|
replace bb to ---- in std::string|64_cv 2.79 % 2.61 % 4
|
|
replace bb to ---- in std::string|256_mean 756 ns 753 ns 4
|
|
replace bb to ---- in std::string|256_median 755 ns 753 ns 4
|
|
replace bb to ---- in std::string|256_stddev 11.5 ns 17.1 ns 4
|
|
replace bb to ---- in std::string|256_cv 1.52 % 2.27 % 4
|
|
replace bb to ---- in std::string|512_mean 1431 ns 1436 ns 4
|
|
replace bb to ---- in std::string|512_median 1431 ns 1428 ns 4
|
|
replace bb to ---- in std::string|512_stddev 24.9 ns 30.1 ns 4
|
|
replace bb to ---- in std::string|512_cv 1.74 % 2.09 % 4
|
|
replace bb to ---- in std::string|1024_mean 3112 ns 3108 ns 4
|
|
replace bb to ---- in std::string|1024_median 3080 ns 3108 ns 4
|
|
replace bb to ---- in std::string|1024_stddev 98.9 ns 99.1 ns 4
|
|
replace bb to ---- in std::string|1024_cv 3.18 % 3.19 % 4
|
|
replace bb to ---- in std::string|2048_mean 7873 ns 7847 ns 4
|
|
replace bb to ---- in std::string|2048_median 7859 ns 7847 ns 4
|
|
replace bb to ---- in std::string|2048_stddev 172 ns 142 ns 4
|
|
replace bb to ---- in std::string|2048_cv 2.19 % 1.81 % 4
|
|
replace bb to ---- in lstringa<8>|64_mean 217 ns 217 ns 4
|
|
replace bb to ---- in lstringa<8>|64_median 216 ns 217 ns 4
|
|
replace bb to ---- in lstringa<8>|64_stddev 4.54 ns 6.75 ns 4
|
|
replace bb to ---- in lstringa<8>|64_cv 2.09 % 3.11 % 4
|
|
replace bb to ---- in lstringa<8>|256_mean 622 ns 624 ns 4
|
|
replace bb to ---- in lstringa<8>|256_median 621 ns 621 ns 4
|
|
replace bb to ---- in lstringa<8>|256_stddev 23.6 ns 23.8 ns 4
|
|
replace bb to ---- in lstringa<8>|256_cv 3.79 % 3.82 % 4
|
|
replace bb to ---- in lstringa<8>|512_mean 1050 ns 1050 ns 4
|
|
replace bb to ---- in lstringa<8>|512_median 1044 ns 1038 ns 4
|
|
replace bb to ---- in lstringa<8>|512_stddev 32.8 ns 34.5 ns 4
|
|
replace bb to ---- in lstringa<8>|512_cv 3.12 % 3.29 % 4
|
|
replace bb to ---- in lstringa<8>|1024_mean 1906 ns 1894 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_median 1900 ns 1862 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_stddev 64.8 ns 79.2 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_cv 3.40 % 4.18 % 4
|
|
replace bb to ---- in lstringa<8>|2048_mean 3604 ns 3610 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_median 3604 ns 3610 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_stddev 53.7 ns 0.000 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_cv 1.49 % 0.00 % 4
|
|
replace bb to ---- by init stringa|64_mean 184 ns 181 ns 4
|
|
replace bb to ---- by init stringa|64_median 183 ns 180 ns 4
|
|
replace bb to ---- by init stringa|64_stddev 11.1 ns 8.51 ns 4
|
|
replace bb to ---- by init stringa|64_cv 6.04 % 4.69 % 4
|
|
replace bb to ---- by init stringa|256_mean 373 ns 373 ns 4
|
|
replace bb to ---- by init stringa|256_median 374 ns 373 ns 4
|
|
replace bb to ---- by init stringa|256_stddev 2.79 ns 4.63 ns 4
|
|
replace bb to ---- by init stringa|256_cv 0.75 % 1.24 % 4
|
|
replace bb to ---- by init stringa|512_mean 814 ns 811 ns 4
|
|
replace bb to ---- by init stringa|512_median 825 ns 820 ns 4
|
|
replace bb to ---- by init stringa|512_stddev 22.9 ns 30.2 ns 4
|
|
replace bb to ---- by init stringa|512_cv 2.81 % 3.72 % 4
|
|
replace bb to ---- by init stringa|1024_mean 1629 ns 1622 ns 4
|
|
replace bb to ---- by init stringa|1024_median 1637 ns 1639 ns 4
|
|
replace bb to ---- by init stringa|1024_stddev 20.2 ns 34.9 ns 4
|
|
replace bb to ---- by init stringa|1024_cv 1.24 % 2.15 % 4
|
|
replace bb to ---- by init stringa|2048_mean 3029 ns 3015 ns 4
|
|
replace bb to ---- by init stringa|2048_median 3032 ns 3015 ns 4
|
|
replace bb to ---- by init stringa|2048_stddev 14.6 ns 38.3 ns 4
|
|
replace bb to ---- by init stringa|2048_cv 0.48 % 1.27 % 4
|
|
----- Replace All Str To Same Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
replace bb to -- in std::string|64_mean 193 ns 193 ns 4
|
|
replace bb to -- in std::string|64_median 192 ns 190 ns 4
|
|
replace bb to -- in std::string|64_stddev 3.96 ns 5.92 ns 4
|
|
replace bb to -- in std::string|64_cv 2.06 % 3.07 % 4
|
|
replace bb to -- in std::string|256_mean 561 ns 562 ns 4
|
|
replace bb to -- in std::string|256_median 559 ns 558 ns 4
|
|
replace bb to -- in std::string|256_stddev 6.54 ns 6.98 ns 4
|
|
replace bb to -- in std::string|256_cv 1.17 % 1.24 % 4
|
|
replace bb to -- in std::string|512_mean 1022 ns 1020 ns 4
|
|
replace bb to -- in std::string|512_median 1022 ns 1015 ns 4
|
|
replace bb to -- in std::string|512_stddev 12.6 ns 20.0 ns 4
|
|
replace bb to -- in std::string|512_cv 1.24 % 1.96 % 4
|
|
replace bb to -- in std::string|1024_mean 1596 ns 1593 ns 4
|
|
replace bb to -- in std::string|1024_median 1600 ns 1585 ns 4
|
|
replace bb to -- in std::string|1024_stddev 17.4 ns 30.1 ns 4
|
|
replace bb to -- in std::string|1024_cv 1.09 % 1.89 % 4
|
|
replace bb to -- in std::string|2048_mean 3489 ns 3479 ns 4
|
|
replace bb to -- in std::string|2048_median 3489 ns 3442 ns 4
|
|
replace bb to -- in std::string|2048_stddev 168 ns 140 ns 4
|
|
replace bb to -- in std::string|2048_cv 4.83 % 4.03 % 4
|
|
replace bb to -- in lstringa<8>|64_mean 184 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 6.48 ns 7.00 ns 4
|
|
replace bb to -- in lstringa<8>|64_cv 3.52 % 3.80 % 4
|
|
replace bb to -- in lstringa<8>|256_mean 435 ns 432 ns 4
|
|
replace bb to -- in lstringa<8>|256_median 439 ns 435 ns 4
|
|
replace bb to -- in lstringa<8>|256_stddev 7.63 ns 9.35 ns 4
|
|
replace bb to -- in lstringa<8>|256_cv 1.75 % 2.16 % 4
|
|
replace bb to -- in lstringa<8>|512_mean 746 ns 746 ns 4
|
|
replace bb to -- in lstringa<8>|512_median 741 ns 746 ns 4
|
|
replace bb to -- in lstringa<8>|512_stddev 21.0 ns 18.0 ns 4
|
|
replace bb to -- in lstringa<8>|512_cv 2.81 % 2.41 % 4
|
|
replace bb to -- in lstringa<8>|1024_mean 1361 ns 1350 ns 4
|
|
replace bb to -- in lstringa<8>|1024_median 1351 ns 1350 ns 4
|
|
replace bb to -- in lstringa<8>|1024_stddev 28.5 ns 25.6 ns 4
|
|
replace bb to -- in lstringa<8>|1024_cv 2.09 % 1.90 % 4
|
|
replace bb to -- in lstringa<8>|2048_mean 2648 ns 2653 ns 4
|
|
replace bb to -- in lstringa<8>|2048_median 2624 ns 2638 ns 4
|
|
replace bb to -- in lstringa<8>|2048_stddev 65.0 ns 56.8 ns 4
|
|
replace bb to -- in lstringa<8>|2048_cv 2.45 % 2.14 % 4
|
|
replace bb to -- by init stringa|64_mean 155 ns 154 ns 4
|
|
replace bb to -- by init stringa|64_median 155 ns 153 ns 4
|
|
replace bb to -- by init stringa|64_stddev 3.36 ns 1.74 ns 4
|
|
replace bb to -- by init stringa|64_cv 2.17 % 1.13 % 4
|
|
replace bb to -- by init stringa|256_mean 349 ns 349 ns 4
|
|
replace bb to -- by init stringa|256_median 344 ns 345 ns 4
|
|
replace bb to -- by init stringa|256_stddev 11.0 ns 13.9 ns 4
|
|
replace bb to -- by init stringa|256_cv 3.16 % 3.98 % 4
|
|
replace bb to -- by init stringa|512_mean 599 ns 596 ns 4
|
|
replace bb to -- by init stringa|512_median 598 ns 600 ns 4
|
|
replace bb to -- by init stringa|512_stddev 6.95 ns 6.98 ns 4
|
|
replace bb to -- by init stringa|512_cv 1.16 % 1.17 % 4
|
|
replace bb to -- by init stringa|1024_mean 1056 ns 1053 ns 4
|
|
replace bb to -- by init stringa|1024_median 1058 ns 1060 ns 4
|
|
replace bb to -- by init stringa|1024_stddev 10.7 ns 14.0 ns 4
|
|
replace bb to -- by init stringa|1024_cv 1.01 % 1.32 % 4
|
|
replace bb to -- by init stringa|2048_mean 2024 ns 2018 ns 4
|
|
replace bb to -- by init stringa|2048_median 2031 ns 1995 ns 4
|
|
replace bb to -- by init stringa|2048_stddev 23.0 ns 45.3 ns 4
|
|
replace bb to -- by init stringa|2048_cv 1.14 % 2.25 % 4
|
|
----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
hashStrMapA<size_t> emplace & find stringa;_mean 3990260 ns 3974382 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_median 3979718 ns 3951672 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_stddev 92066 ns 86976 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_cv 2.31 % 2.19 % 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_mean 5696770 ns 5650112 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_median 5747354 ns 5719866 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_stddev 277872 ns 267139 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_cv 4.88 % 4.73 % 4
|
|
hashStrMapA<size_t> emplace & find ssa;_mean 3453562 ns 3466109 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_median 3446008 ns 3447770 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_stddev 53499 ns 36678 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_cv 1.55 % 1.06 % 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_mean 6293665 ns 6312779 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_median 6269807 ns 6347656 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_stddev 106013 ns 133570 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_cv 1.68 % 2.12 % 4
|
|
----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Build func full name std::string;_mean 1593 ns 1592 ns 4
|
|
Build func full name std::string;_median 1591 ns 1592 ns 4
|
|
Build func full name std::string;_stddev 37.9 ns 49.5 ns 4
|
|
Build func full name std::string;_cv 2.38 % 3.11 % 4
|
|
Build func full name std::string 1;_mean 1585 ns 1578 ns 4
|
|
Build func full name std::string 1;_median 1576 ns 1569 ns 4
|
|
Build func full name std::string 1;_stddev 49.6 ns 71.9 ns 4
|
|
Build func full name std::string 1;_cv 3.13 % 4.56 % 4
|
|
Build func full name std::stream;_mean 8042 ns 8022 ns 4
|
|
Build func full name std::stream;_median 8091 ns 8022 ns 4
|
|
Build func full name std::stream;_stddev 125 ns 142 ns 4
|
|
Build func full name std::stream;_cv 1.56 % 1.77 % 4
|
|
Build func full name stringa;_mean 807 ns 807 ns 4
|
|
Build func full name stringa;_median 803 ns 802 ns 4
|
|
Build func full name stringa;_stddev 25.5 ns 26.2 ns 4
|
|
Build func full name stringa;_cv 3.16 % 3.24 % 4
|
|
Build func full name stringa 1;_mean 900 ns 900 ns 4
|
|
Build func full name stringa 1;_median 894 ns 900 ns 4
|
|
Build func full name stringa 1;_stddev 21.9 ns 17.1 ns 4
|
|
Build func full name stringa 1;_cv 2.44 % 1.90 % 4
|