mirror of https://github.com/orefkov/simstr.git
938 lines
139 KiB
Plaintext
938 lines
139 KiB
Plaintext
Benchmarks of simstr, version 1.6.6
|
|
Sources: https://github.com/orefkov/simstr
|
|
Results: https://orefkov.github.io/simstr/results.html
|
|
|
|
2026-02-10T20:12:30+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 259 ns 257 ns 4
|
|
Concat std::string and number by std to std::string_median 259 ns 257 ns 4
|
|
Concat std::string and number by std to std::string_stddev 5.87 ns 4.56 ns 4
|
|
Concat std::string and number by std to std::string_cv 2.26 % 1.77 % 4
|
|
Concat std::string and number by StrExpr to std::string_mean 157 ns 157 ns 4
|
|
Concat std::string and number by StrExpr to std::string_median 153 ns 153 ns 4
|
|
Concat std::string and number by StrExpr to std::string_stddev 11.6 ns 10.9 ns 4
|
|
Concat std::string and number by StrExpr to std::string_cv 7.39 % 6.90 % 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_mean 66.5 ns 66.3 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_median 66.5 ns 66.3 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_stddev 0.221 ns 0.000 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_cv 0.33 % 0.00 % 4
|
|
Concat stringa and number by e_concat to simstr::stringa_mean 75.8 ns 75.4 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_median 75.9 ns 75.0 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_stddev 1.96 ns 2.62 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_cv 2.58 % 3.47 % 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 692 ns 694 ns 4
|
|
Concat std::string and format hex number and literal to std::string_median 691 ns 698 ns 4
|
|
Concat std::string and format hex number and literal to std::string_stddev 16.4 ns 20.9 ns 4
|
|
Concat std::string and format hex number and literal to std::string_cv 2.37 % 3.02 % 4
|
|
std::format std::string and hex number by literal to std::string_mean 2290 ns 2276 ns 4
|
|
std::format std::string and hex number by literal to std::string_median 2281 ns 2250 ns 4
|
|
std::format std::string and hex number by literal to std::string_stddev 47.9 ns 52.3 ns 4
|
|
std::format std::string and hex number by literal to std::string_cv 2.09 % 2.30 % 4
|
|
Concat std::string and std::to_chars and string to std::string_mean 188 ns 188 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_median 189 ns 188 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_stddev 2.94 ns 2.62 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_cv 1.56 % 1.39 % 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_mean 77.9 ns 78.0 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_median 77.8 ns 78.5 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_stddev 2.24 ns 2.62 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_cv 2.87 % 3.35 % 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 69.8 ns 70.1 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 69.7 ns 70.5 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 1.18 ns 1.34 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 1.69 % 1.91 % 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 92.6 ns 92.2 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_median 92.9 ns 92.8 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 0.884 ns 1.22 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 0.95 % 1.32 % 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_mean 153 ns 151 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_median 148 ns 146 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 13.6 ns 15.1 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_cv 8.90 % 10.06 % 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 274 ns 273 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 273 ns 273 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 2.71 ns 3.62 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 0.99 % 1.33 % 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 639 ns 638 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 640 ns 642 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 7.34 ns 6.98 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 1.15 % 1.09 % 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 743 ns 741 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 724 ns 724 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 46.5 ns 41.5 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 6.26 % 5.60 % 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_mean 1071 ns 1025 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_median 1022 ns 1018 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_stddev 102 ns 26.7 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_cv 9.51 % 2.61 % 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 1380 ns 1381 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 1365 ns 1365 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 35.9 ns 44.4 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 2.60 % 3.21 % 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 1278 ns 1283 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 1281 ns 1283 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 10.9 ns 0.000 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 0.85 % 0.00 % 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1519 ns 1515 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_median 1521 ns 1522 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 25.9 ns 30.1 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.70 % 1.98 % 4
|
|
std::vformat(pattern, std::make_format_args(i))_mean 1511 ns 1500 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_median 1504 ns 1500 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_stddev 29.7 ns 28.5 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_cv 1.97 % 1.90 % 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 6385 ns 6348 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 6338 ns 6348 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 111 ns 80.5 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 1.74 % 1.27 % 4
|
|
----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat std::string by std to std::string_mean 38.4 ns 38.1 ns 4
|
|
Concat std::string by std to std::string_median 38.2 ns 38.1 ns 4
|
|
Concat std::string by std to std::string_stddev 0.983 ns 1.04 ns 4
|
|
Concat std::string by std to std::string_cv 2.56 % 2.72 % 4
|
|
Concat std::string by StrExpr to std::string_mean 37.6 ns 37.5 ns 4
|
|
Concat std::string by StrExpr to std::string_median 37.6 ns 37.7 ns 4
|
|
Concat std::string by StrExpr to std::string_stddev 0.567 ns 1.05 ns 4
|
|
Concat std::string by StrExpr to std::string_cv 1.51 % 2.81 % 4
|
|
Concat stringa by StrExpr to stringa_mean 27.7 ns 27.7 ns 4
|
|
Concat stringa by StrExpr to stringa_median 27.7 ns 27.9 ns 4
|
|
Concat stringa by StrExpr to stringa_stddev 0.254 ns 0.296 ns 4
|
|
Concat stringa by StrExpr to stringa_cv 0.92 % 1.07 % 4
|
|
----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Find concat three std::string_mean 197 ns 196 ns 4
|
|
Find concat three std::string_median 197 ns 197 ns 4
|
|
Find concat three std::string_stddev 3.39 ns 2.09 ns 4
|
|
Find concat three std::string_cv 1.72 % 1.07 % 4
|
|
Find concat three strexpr_mean 114 ns 114 ns 4
|
|
Find concat three strexpr_median 114 ns 114 ns 4
|
|
Find concat three strexpr_stddev 1.17 ns 1.41 ns 4
|
|
Find concat three strexpr_cv 1.03 % 1.24 % 4
|
|
Find concat three simstr_mean 27.5 ns 27.6 ns 4
|
|
Find concat three simstr_median 26.7 ns 27.0 ns 4
|
|
Find concat three simstr_stddev 2.07 ns 1.84 ns 4
|
|
Find concat three simstr_cv 7.54 % 6.69 % 4
|
|
----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
BuildTypeNameStr 0/0_mean 7.71 ns 7.72 ns 4
|
|
BuildTypeNameStr 0/0_median 7.69 ns 7.67 ns 4
|
|
BuildTypeNameStr 0/0_stddev 0.059 ns 0.087 ns 4
|
|
BuildTypeNameStr 0/0_cv 0.76 % 1.13 % 4
|
|
BuildTypeNameExp 0/0_mean 7.28 ns 7.24 ns 4
|
|
BuildTypeNameExp 0/0_median 7.24 ns 7.24 ns 4
|
|
BuildTypeNameExp 0/0_stddev 0.178 ns 0.101 ns 4
|
|
BuildTypeNameExp 0/0_cv 2.44 % 1.39 % 4
|
|
BuildTypeNameSim 0/0_mean 7.40 ns 7.37 ns 4
|
|
BuildTypeNameSim 0/0_median 7.39 ns 7.32 ns 4
|
|
BuildTypeNameSim 0/0_stddev 0.075 ns 0.087 ns 4
|
|
BuildTypeNameSim 0/0_cv 1.01 % 1.18 % 4
|
|
BuildTypeNameStr 10/10_mean 57.1 ns 56.8 ns 4
|
|
BuildTypeNameStr 10/10_median 57.1 ns 57.2 ns 4
|
|
BuildTypeNameStr 10/10_stddev 0.598 ns 0.698 ns 4
|
|
BuildTypeNameStr 10/10_cv 1.05 % 1.23 % 4
|
|
BuildTypeNameExp 10/10_mean 31.5 ns 31.5 ns 4
|
|
BuildTypeNameExp 10/10_median 31.1 ns 31.1 ns 4
|
|
BuildTypeNameExp 10/10_stddev 1.34 ns 1.27 ns 4
|
|
BuildTypeNameExp 10/10_cv 4.24 % 4.03 % 4
|
|
BuildTypeNameSim 10/10_mean 24.3 ns 24.3 ns 4
|
|
BuildTypeNameSim 10/10_median 24.0 ns 24.3 ns 4
|
|
BuildTypeNameSim 10/10_stddev 0.689 ns 0.720 ns 4
|
|
BuildTypeNameSim 10/10_cv 2.84 % 2.97 % 4
|
|
----- Replace string by copy -----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat with replace str_mean 300 ns 300 ns 4
|
|
Concat with replace str_median 300 ns 298 ns 4
|
|
Concat with replace str_stddev 10.7 ns 9.94 ns 4
|
|
Concat with replace str_cv 3.58 % 3.31 % 4
|
|
Concat with replace exp_mean 208 ns 207 ns 4
|
|
Concat with replace exp_median 209 ns 209 ns 4
|
|
Concat with replace exp_stddev 2.10 ns 2.27 ns 4
|
|
Concat with replace exp_cv 1.01 % 1.09 % 4
|
|
----- Create Empty Str ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e;_mean 1.08 ns 1.08 ns 4
|
|
std::string e;_median 1.07 ns 1.06 ns 4
|
|
std::string e;_stddev 0.050 ns 0.062 ns 4
|
|
std::string e;_cv 4.65 % 5.72 % 4
|
|
std::string_view e;_mean 0.352 ns 0.352 ns 4
|
|
std::string_view e;_median 0.350 ns 0.352 ns 4
|
|
std::string_view e;_stddev 0.004 ns 0.007 ns 4
|
|
std::string_view e;_cv 1.27 % 1.94 % 4
|
|
ssa e;_mean 0.346 ns 0.347 ns 4
|
|
ssa e;_median 0.346 ns 0.349 ns 4
|
|
ssa e;_stddev 0.001 ns 0.007 ns 4
|
|
ssa e;_cv 0.21 % 2.12 % 4
|
|
stringa e;_mean 0.723 ns 0.724 ns 4
|
|
stringa e;_median 0.722 ns 0.724 ns 4
|
|
stringa e;_stddev 0.027 ns 0.030 ns 4
|
|
stringa e;_cv 3.67 % 4.17 % 4
|
|
lstringa<20> e;_mean 1.07 ns 1.07 ns 4
|
|
lstringa<20> e;_median 1.07 ns 1.07 ns 4
|
|
lstringa<20> e;_stddev 0.007 ns 0.012 ns 4
|
|
lstringa<20> e;_cv 0.65 % 1.14 % 4
|
|
lstringa<40> e;_mean 1.07 ns 1.06 ns 4
|
|
lstringa<40> e;_median 1.07 ns 1.06 ns 4
|
|
lstringa<40> e;_stddev 0.009 ns 0.020 ns 4
|
|
lstringa<40> e;_cv 0.83 % 1.89 % 4
|
|
----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "Test text";_mean 1.77 ns 1.77 ns 4
|
|
std::string e = "Test text";_median 1.78 ns 1.76 ns 4
|
|
std::string e = "Test text";_stddev 0.010 ns 0.019 ns 4
|
|
std::string e = "Test text";_cv 0.58 % 1.08 % 4
|
|
std::string_view e = "Test text";_mean 0.719 ns 0.718 ns 4
|
|
std::string_view e = "Test text";_median 0.720 ns 0.718 ns 4
|
|
std::string_view e = "Test text";_stddev 0.007 ns 0.008 ns 4
|
|
std::string_view e = "Test text";_cv 0.95 % 1.12 % 4
|
|
ssa e = "Test text";_mean 0.357 ns 0.357 ns 4
|
|
ssa e = "Test text";_median 0.356 ns 0.357 ns 4
|
|
ssa e = "Test text";_stddev 0.004 ns 0.005 ns 4
|
|
ssa e = "Test text";_cv 1.19 % 1.30 % 4
|
|
stringa e = "Test text";_mean 1.07 ns 1.06 ns 4
|
|
stringa e = "Test text";_median 1.07 ns 1.06 ns 4
|
|
stringa e = "Test text";_stddev 0.006 ns 0.014 ns 4
|
|
stringa e = "Test text";_cv 0.55 % 1.33 % 4
|
|
lstringa<20> e = "Test text";_mean 1.81 ns 1.81 ns 4
|
|
lstringa<20> e = "Test text";_median 1.79 ns 1.80 ns 4
|
|
lstringa<20> e = "Test text";_stddev 0.044 ns 0.048 ns 4
|
|
lstringa<20> e = "Test text";_cv 2.43 % 2.66 % 4
|
|
lstringa<40> e = "Test text";_mean 1.81 ns 1.80 ns 4
|
|
lstringa<40> e = "Test text";_median 1.81 ns 1.80 ns 4
|
|
lstringa<40> e = "Test text";_stddev 0.037 ns 0.034 ns 4
|
|
lstringa<40> e = "Test text";_cv 2.02 % 1.90 % 4
|
|
----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "123456789012345678901234567890";_mean 72.2 ns 72.4 ns 4
|
|
std::string e = "123456789012345678901234567890";_median 71.7 ns 72.4 ns 4
|
|
std::string e = "123456789012345678901234567890";_stddev 1.05 ns 1.01 ns 4
|
|
std::string e = "123456789012345678901234567890";_cv 1.46 % 1.39 % 4
|
|
std::string_view e = "123456789012345678901234567890";_mean 0.715 ns 0.715 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_median 0.714 ns 0.718 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_stddev 0.013 ns 0.013 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_cv 1.75 % 1.87 % 4
|
|
ssa e = "123456789012345678901234567890";_mean 0.357 ns 0.355 ns 4
|
|
ssa e = "123456789012345678901234567890";_median 0.360 ns 0.357 ns 4
|
|
ssa e = "123456789012345678901234567890";_stddev 0.007 ns 0.008 ns 4
|
|
ssa e = "123456789012345678901234567890";_cv 2.01 % 2.16 % 4
|
|
stringa e = "123456789012345678901234567890";_mean 1.06 ns 1.06 ns 4
|
|
stringa e = "123456789012345678901234567890";_median 1.05 ns 1.05 ns 4
|
|
stringa e = "123456789012345678901234567890";_stddev 0.017 ns 0.012 ns 4
|
|
stringa e = "123456789012345678901234567890";_cv 1.61 % 1.16 % 4
|
|
lstringa<20> e = "123456789012345678901234567890";_mean 69.8 ns 69.8 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_median 68.5 ns 68.0 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_stddev 3.73 ns 3.49 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_cv 5.34 % 5.00 % 4
|
|
lstringa<40> e = "123456789012345678901234567890";_mean 2.50 ns 2.48 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_median 2.50 ns 2.51 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_stddev 0.029 ns 0.056 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_cv 1.17 % 2.25 % 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.76 ns 1.75 ns 4
|
|
std::string e = "Test text"; auto c{e};_median 1.76 ns 1.76 ns 4
|
|
std::string e = "Test text"; auto c{e};_stddev 0.010 ns 0.021 ns 4
|
|
std::string e = "Test text"; auto c{e};_cv 0.55 % 1.20 % 4
|
|
std::string_view e = "Test text"; auto c{e};_mean 0.357 ns 0.357 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_median 0.358 ns 0.357 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_stddev 0.003 ns 0.004 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_cv 0.95 % 1.24 % 4
|
|
ssa e = "Test text"; auto c{e};_mean 0.354 ns 0.353 ns 4
|
|
ssa e = "Test text"; auto c{e};_median 0.353 ns 0.353 ns 4
|
|
ssa e = "Test text"; auto c{e};_stddev 0.004 ns 0.000 ns 4
|
|
ssa e = "Test text"; auto c{e};_cv 1.03 % 0.00 % 4
|
|
stringa e = "Test text"; auto c{e};_mean 1.24 ns 1.24 ns 4
|
|
stringa e = "Test text"; auto c{e};_median 1.24 ns 1.24 ns 4
|
|
stringa e = "Test text"; auto c{e};_stddev 0.020 ns 0.016 ns 4
|
|
stringa e = "Test text"; auto c{e};_cv 1.63 % 1.30 % 4
|
|
lstringa<20> e = "Test text"; auto c{e};_mean 1.75 ns 1.76 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_median 1.75 ns 1.76 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_stddev 0.009 ns 0.019 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_cv 0.53 % 1.09 % 4
|
|
lstringa<40> e = "Test text"; auto c{e};_mean 1.78 ns 1.78 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_median 1.77 ns 1.76 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_stddev 0.053 ns 0.066 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_cv 2.97 % 3.72 % 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 69.0 ns 69.1 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_median 68.8 ns 68.4 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_stddev 0.963 ns 1.40 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_cv 1.40 % 2.02 % 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.720 ns 0.722 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.719 ns 0.718 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.014 ns 0.013 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 1.94 % 1.85 % 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.360 ns 0.359 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_median 0.360 ns 0.361 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.005 ns 0.010 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_cv 1.28 % 2.81 % 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.79 ns 1.78 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_median 1.78 ns 1.78 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.028 ns 0.022 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.54 % 1.24 % 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 71.2 ns 71.5 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 71.2 ns 71.5 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 0.330 ns 0.000 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 0.46 % 0.00 % 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.72 ns 4.71 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.71 ns 4.71 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.069 ns 0.121 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 1.46 % 2.57 % 4
|
|
----- Find 9 symbols text in end of 99 symbols text ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string::find;_mean 37.9 ns 37.9 ns 4
|
|
std::string::find;_median 38.0 ns 37.7 ns 4
|
|
std::string::find;_stddev 0.260 ns 0.419 ns 4
|
|
std::string::find;_cv 0.69 % 1.10 % 4
|
|
std::string_view::find;_mean 37.9 ns 37.4 ns 4
|
|
std::string_view::find;_median 37.9 ns 37.6 ns 4
|
|
std::string_view::find;_stddev 0.333 ns 0.868 ns 4
|
|
std::string_view::find;_cv 0.88 % 2.32 % 4
|
|
ssa::find;_mean 17.0 ns 17.0 ns 4
|
|
ssa::find;_median 17.1 ns 17.3 ns 4
|
|
ssa::find;_stddev 0.240 ns 0.575 ns 4
|
|
ssa::find;_cv 1.41 % 3.39 % 4
|
|
stringa::find;_mean 18.4 ns 18.2 ns 4
|
|
stringa::find;_median 18.2 ns 17.8 ns 4
|
|
stringa::find;_stddev 0.859 ns 0.996 ns 4
|
|
stringa::find;_cv 4.68 % 5.47 % 4
|
|
lstringa<20>::find;_mean 17.8 ns 17.7 ns 4
|
|
lstringa<20>::find;_median 17.8 ns 17.8 ns 4
|
|
lstringa<20>::find;_stddev 0.380 ns 0.367 ns 4
|
|
lstringa<20>::find;_cv 2.14 % 2.07 % 4
|
|
lstringa<40>::find;_mean 17.4 ns 17.4 ns 4
|
|
lstringa<40>::find;_median 17.3 ns 17.5 ns 4
|
|
lstringa<40>::find;_stddev 0.456 ns 0.655 ns 4
|
|
lstringa<40>::find;_cv 2.61 % 3.77 % 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.77 ns 1.78 ns 4
|
|
std::string copy{str_with_len_N};/15_median 1.78 ns 1.78 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.59 % 1.24 % 4
|
|
std::string copy{str_with_len_N};/16_mean 74.3 ns 73.7 ns 4
|
|
std::string copy{str_with_len_N};/16_median 74.4 ns 73.2 ns 4
|
|
std::string copy{str_with_len_N};/16_stddev 0.747 ns 0.872 ns 4
|
|
std::string copy{str_with_len_N};/16_cv 1.01 % 1.18 % 4
|
|
std::string copy{str_with_len_N};/23_mean 74.7 ns 74.6 ns 4
|
|
std::string copy{str_with_len_N};/23_median 74.1 ns 74.1 ns 4
|
|
std::string copy{str_with_len_N};/23_stddev 2.96 ns 2.98 ns 4
|
|
std::string copy{str_with_len_N};/23_cv 3.96 % 3.99 % 4
|
|
std::string copy{str_with_len_N};/24_mean 74.3 ns 74.1 ns 4
|
|
std::string copy{str_with_len_N};/24_median 74.5 ns 74.1 ns 4
|
|
std::string copy{str_with_len_N};/24_stddev 1.45 ns 1.01 ns 4
|
|
std::string copy{str_with_len_N};/24_cv 1.96 % 1.36 % 4
|
|
std::string copy{str_with_len_N};/32_mean 82.3 ns 82.1 ns 4
|
|
std::string copy{str_with_len_N};/32_median 81.3 ns 81.6 ns 4
|
|
std::string copy{str_with_len_N};/32_stddev 3.17 ns 2.63 ns 4
|
|
std::string copy{str_with_len_N};/32_cv 3.86 % 3.21 % 4
|
|
std::string copy{str_with_len_N};/64_mean 79.0 ns 78.9 ns 4
|
|
std::string copy{str_with_len_N};/64_median 79.0 ns 78.5 ns 4
|
|
std::string copy{str_with_len_N};/64_stddev 1.53 ns 0.872 ns 4
|
|
std::string copy{str_with_len_N};/64_cv 1.94 % 1.10 % 4
|
|
std::string copy{str_with_len_N};/128_mean 82.4 ns 82.7 ns 4
|
|
std::string copy{str_with_len_N};/128_median 80.4 ns 80.6 ns 4
|
|
std::string copy{str_with_len_N};/128_stddev 4.96 ns 4.98 ns 4
|
|
std::string copy{str_with_len_N};/128_cv 6.02 % 6.03 % 4
|
|
std::string copy{str_with_len_N};/256_mean 82.6 ns 82.7 ns 4
|
|
std::string copy{str_with_len_N};/256_median 80.9 ns 80.6 ns 4
|
|
std::string copy{str_with_len_N};/256_stddev 3.82 ns 4.98 ns 4
|
|
std::string copy{str_with_len_N};/256_cv 4.63 % 6.03 % 4
|
|
std::string copy{str_with_len_N};/512_mean 83.4 ns 82.1 ns 4
|
|
std::string copy{str_with_len_N};/512_median 83.1 ns 81.6 ns 4
|
|
std::string copy{str_with_len_N};/512_stddev 1.42 ns 1.05 ns 4
|
|
std::string copy{str_with_len_N};/512_cv 1.70 % 1.27 % 4
|
|
std::string copy{str_with_len_N};/1024_mean 89.9 ns 89.5 ns 4
|
|
std::string copy{str_with_len_N};/1024_median 89.4 ns 88.9 ns 4
|
|
std::string copy{str_with_len_N};/1024_stddev 1.72 ns 2.00 ns 4
|
|
std::string copy{str_with_len_N};/1024_cv 1.91 % 2.24 % 4
|
|
std::string copy{str_with_len_N};/2048_mean 121 ns 121 ns 4
|
|
std::string copy{str_with_len_N};/2048_median 121 ns 121 ns 4
|
|
std::string copy{str_with_len_N};/2048_stddev 4.36 ns 5.44 ns 4
|
|
std::string copy{str_with_len_N};/2048_cv 3.60 % 4.50 % 4
|
|
std::string copy{str_with_len_N};/4096_mean 198 ns 197 ns 4
|
|
std::string copy{str_with_len_N};/4096_median 201 ns 199 ns 4
|
|
std::string copy{str_with_len_N};/4096_stddev 26.2 ns 25.3 ns 4
|
|
std::string copy{str_with_len_N};/4096_cv 13.22 % 12.88 % 4
|
|
stringa copy{str_with_len_N};/15_mean 1.56 ns 1.56 ns 4
|
|
stringa copy{str_with_len_N};/15_median 1.55 ns 1.55 ns 4
|
|
stringa copy{str_with_len_N};/15_stddev 0.043 ns 0.054 ns 4
|
|
stringa copy{str_with_len_N};/15_cv 2.75 % 3.43 % 4
|
|
stringa copy{str_with_len_N};/16_mean 1.54 ns 1.54 ns 4
|
|
stringa copy{str_with_len_N};/16_median 1.54 ns 1.55 ns 4
|
|
stringa copy{str_with_len_N};/16_stddev 0.105 ns 0.112 ns 4
|
|
stringa copy{str_with_len_N};/16_cv 6.83 % 7.26 % 4
|
|
stringa copy{str_with_len_N};/23_mean 1.52 ns 1.52 ns 4
|
|
stringa copy{str_with_len_N};/23_median 1.52 ns 1.52 ns 4
|
|
stringa copy{str_with_len_N};/23_stddev 0.044 ns 0.045 ns 4
|
|
stringa copy{str_with_len_N};/23_cv 2.90 % 2.97 % 4
|
|
stringa copy{str_with_len_N};/24_mean 16.2 ns 16.2 ns 4
|
|
stringa copy{str_with_len_N};/24_median 16.3 ns 16.2 ns 4
|
|
stringa copy{str_with_len_N};/24_stddev 0.148 ns 0.201 ns 4
|
|
stringa copy{str_with_len_N};/24_cv 0.91 % 1.24 % 4
|
|
stringa copy{str_with_len_N};/32_mean 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/32_median 16.1 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/32_stddev 0.258 ns 0.285 ns 4
|
|
stringa copy{str_with_len_N};/32_cv 1.61 % 1.77 % 4
|
|
stringa copy{str_with_len_N};/64_mean 16.2 ns 16.2 ns 4
|
|
stringa copy{str_with_len_N};/64_median 16.2 ns 16.2 ns 4
|
|
stringa copy{str_with_len_N};/64_stddev 0.070 ns 0.201 ns 4
|
|
stringa copy{str_with_len_N};/64_cv 0.43 % 1.24 % 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.101 ns 0.000 ns 4
|
|
stringa copy{str_with_len_N};/128_cv 0.63 % 0.00 % 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.059 ns 0.174 ns 4
|
|
stringa copy{str_with_len_N};/256_cv 0.36 % 1.08 % 4
|
|
stringa copy{str_with_len_N};/512_mean 16.0 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/512_median 16.0 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/512_stddev 0.206 ns 0.222 ns 4
|
|
stringa copy{str_with_len_N};/512_cv 1.29 % 1.39 % 4
|
|
stringa copy{str_with_len_N};/1024_mean 16.0 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/1024_median 16.0 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/1024_stddev 0.209 ns 0.439 ns 4
|
|
stringa copy{str_with_len_N};/1024_cv 1.31 % 2.75 % 4
|
|
stringa copy{str_with_len_N};/2048_mean 16.0 ns 16.0 ns 4
|
|
stringa copy{str_with_len_N};/2048_median 15.9 ns 15.9 ns 4
|
|
stringa copy{str_with_len_N};/2048_stddev 0.099 ns 0.334 ns 4
|
|
stringa copy{str_with_len_N};/2048_cv 0.62 % 2.09 % 4
|
|
stringa copy{str_with_len_N};/4096_mean 15.9 ns 15.8 ns 4
|
|
stringa copy{str_with_len_N};/4096_median 15.9 ns 15.7 ns 4
|
|
stringa copy{str_with_len_N};/4096_stddev 0.171 ns 0.192 ns 4
|
|
stringa copy{str_with_len_N};/4096_cv 1.07 % 1.21 % 4
|
|
lstringa<16> copy{str_with_len_N};/15_mean 1.93 ns 1.94 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_median 1.94 ns 1.95 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_stddev 0.130 ns 0.138 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_cv 6.72 % 7.14 % 4
|
|
lstringa<16> copy{str_with_len_N};/16_mean 6.22 ns 6.25 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_median 6.26 ns 6.33 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_stddev 0.375 ns 0.338 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_cv 6.02 % 5.40 % 4
|
|
lstringa<16> copy{str_with_len_N};/23_mean 6.41 ns 6.42 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_median 6.44 ns 6.42 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_stddev 0.209 ns 0.228 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_cv 3.26 % 3.55 % 4
|
|
lstringa<16> copy{str_with_len_N};/24_mean 83.6 ns 83.7 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_median 84.1 ns 84.1 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_stddev 12.5 ns 13.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_cv 14.89 % 15.77 % 4
|
|
lstringa<16> copy{str_with_len_N};/32_mean 93.3 ns 93.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_median 95.0 ns 95.0 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_stddev 11.3 ns 12.0 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_cv 12.11 % 12.81 % 4
|
|
lstringa<16> copy{str_with_len_N};/64_mean 91.7 ns 91.6 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_median 89.8 ns 90.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_stddev 8.28 ns 9.03 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_cv 9.03 % 9.86 % 4
|
|
lstringa<16> copy{str_with_len_N};/128_mean 92.1 ns 92.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_median 91.4 ns 91.6 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_stddev 3.12 ns 2.34 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_cv 3.39 % 2.54 % 4
|
|
lstringa<16> copy{str_with_len_N};/256_mean 90.9 ns 90.5 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_median 86.1 ns 85.8 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_stddev 13.9 ns 13.9 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_cv 15.28 % 15.38 % 4
|
|
lstringa<16> copy{str_with_len_N};/512_mean 96.1 ns 96.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_median 95.4 ns 95.9 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_stddev 2.62 ns 2.19 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_cv 2.73 % 2.28 % 4
|
|
lstringa<16> copy{str_with_len_N};/1024_mean 108 ns 109 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_median 108 ns 109 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_stddev 4.91 ns 5.08 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_cv 4.54 % 4.68 % 4
|
|
lstringa<16> copy{str_with_len_N};/2048_mean 158 ns 158 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_median 157 ns 159 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_stddev 4.65 ns 6.28 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_cv 2.95 % 3.97 % 4
|
|
lstringa<16> copy{str_with_len_N};/4096_mean 232 ns 232 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_median 232 ns 232 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_stddev 8.30 ns 10.3 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_cv 3.58 % 4.41 % 4
|
|
lstringa<512> copy{str_with_len_N};/15_mean 2.09 ns 2.10 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_median 2.12 ns 2.10 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_stddev 0.083 ns 0.080 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_cv 3.98 % 3.80 % 4
|
|
lstringa<512> copy{str_with_len_N};/16_mean 5.41 ns 5.41 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_median 5.44 ns 5.44 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_stddev 0.176 ns 0.176 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_cv 3.26 % 3.25 % 4
|
|
lstringa<512> copy{str_with_len_N};/23_mean 5.77 ns 5.75 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_median 5.71 ns 5.72 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_stddev 0.384 ns 0.417 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_cv 6.65 % 7.24 % 4
|
|
lstringa<512> copy{str_with_len_N};/24_mean 5.46 ns 5.43 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_median 5.39 ns 5.39 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_stddev 0.202 ns 0.150 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_cv 3.69 % 2.76 % 4
|
|
lstringa<512> copy{str_with_len_N};/32_mean 8.47 ns 8.46 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_median 8.49 ns 8.46 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_stddev 0.286 ns 0.225 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_cv 3.38 % 2.66 % 4
|
|
lstringa<512> copy{str_with_len_N};/64_mean 8.47 ns 8.46 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_median 8.37 ns 8.37 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_stddev 0.314 ns 0.334 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_cv 3.71 % 3.95 % 4
|
|
lstringa<512> copy{str_with_len_N};/128_mean 8.99 ns 8.95 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_median 8.92 ns 8.89 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_stddev 0.283 ns 0.200 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_cv 3.15 % 2.24 % 4
|
|
lstringa<512> copy{str_with_len_N};/256_mean 10.5 ns 10.5 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_median 10.7 ns 10.6 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_stddev 0.556 ns 0.534 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_cv 5.31 % 5.11 % 4
|
|
lstringa<512> copy{str_with_len_N};/512_mean 12.0 ns 12.0 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_median 11.8 ns 11.7 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_stddev 0.732 ns 0.691 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_cv 6.12 % 5.77 % 4
|
|
lstringa<512> copy{str_with_len_N};/1024_mean 108 ns 108 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_median 109 ns 108 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_stddev 5.67 ns 4.36 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_cv 5.24 % 4.04 % 4
|
|
lstringa<512> copy{str_with_len_N};/2048_mean 153 ns 153 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_median 150 ns 150 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_stddev 11.8 ns 13.7 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_cv 7.72 % 8.90 % 4
|
|
lstringa<512> copy{str_with_len_N};/4096_mean 214 ns 214 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_median 213 ns 213 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_stddev 7.77 ns 6.80 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_cv 3.62 % 3.17 % 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 35.0 ns 34.9 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 35.3 ns 35.3 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.856 ns 0.802 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 2.45 % 2.30 % 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 15.7 ns 15.7 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 15.7 ns 15.5 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.496 ns 0.543 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 3.16 % 3.45 % 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 15.3 ns 15.3 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_median 15.2 ns 15.3 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.431 ns 0.483 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 2.81 % 3.17 % 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 14.5 ns 14.4 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_median 14.2 ns 14.3 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.979 ns 0.993 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 6.77 % 6.87 % 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 15.2 ns 15.2 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_median 15.2 ns 15.2 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 1.06 ns 0.976 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 6.95 % 6.41 % 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 37.8 ns 37.7 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 37.1 ns 37.2 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 2.45 ns 2.03 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 6.49 % 5.40 % 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 8.94 ns 8.85 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 8.96 ns 8.81 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.306 ns 0.436 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 3.42 % 4.93 % 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 13.5 ns 13.5 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 13.5 ns 13.7 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.555 ns 0.534 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 4.11 % 3.95 % 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 13.1 ns 13.0 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 13.0 ns 12.9 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.726 ns 0.830 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 5.55 % 6.38 % 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 13.0 ns 13.0 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 13.0 ns 13.1 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.228 ns 0.140 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 1.75 % 1.07 % 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 48.0 ns 47.8 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 47.9 ns 48.1 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 0.904 ns 1.04 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 1.88 % 2.16 % 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_mean 19.5 ns 19.5 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_median 19.4 ns 19.6 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_stddev 0.391 ns 0.483 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_cv 2.01 % 2.48 % 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_mean 17.7 ns 17.6 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_median 17.5 ns 17.6 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_stddev 0.356 ns 0.313 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_cv 2.01 % 1.77 % 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 102 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 104 ns 104 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 5.95 ns 6.42 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 5.82 % 6.30 % 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 70.7 ns 70.6 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 71.2 ns 70.6 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 1.71 ns 2.25 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 2.42 % 3.19 % 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_mean 38.8 ns 38.7 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_median 38.9 ns 38.5 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.252 ns 0.419 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_cv 0.65 % 1.08 % 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 5083 ns 5092 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_median 5076 ns 5022 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 339 ns 351 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_cv 6.67 % 6.89 % 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_mean 1315 ns 1311 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_median 1311 ns 1297 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_stddev 72.6 ns 68.3 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_cv 5.52 % 5.21 % 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 867 ns 868 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_median 872 ns 868 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 41.5 ns 49.8 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 4.78 % 5.74 % 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 450 ns 449 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_median 453 ns 449 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 26.8 ns 25.2 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 5.95 % 5.61 % 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 255 ns 255 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_median 257 ns 257 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 11.0 ns 11.5 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 4.32 % 4.51 % 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 146 ns 145 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 146 ns 144 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 1.24 ns 1.57 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 0.85 % 1.08 % 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 5564 ns 5560 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 5631 ns 5644 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 258 ns 267 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 4.64 % 4.80 % 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 4477 ns 4473 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_median 4575 ns 4567 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 312 ns 293 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 6.98 % 6.55 % 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 769 ns 767 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 775 ns 776 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 54.8 ns 62.1 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 7.13 % 8.09 % 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 549 ns 547 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 550 ns 547 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 5.20 ns 12.8 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 0.95 % 2.33 % 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 333 ns 335 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 332 ns 333 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 17.9 ns 18.3 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 5.37 % 5.46 % 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 215 ns 216 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 209 ns 210 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 18.9 ns 19.7 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 8.76 % 9.11 % 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 212569 ns 212402 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 210125 ns 209961 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 7781 ns 8457 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 3.66 % 3.98 % 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 183368 ns 184168 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 182060 ns 184168 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 3135 ns 3418 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.71 % 1.86 % 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 18492 ns 18415 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 18471 ns 18415 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 219 ns 342 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.18 % 1.86 % 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16512 ns 16479 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16374 ns 16392 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 610 ns 719 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.70 % 4.36 % 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 15660 ns 15695 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 15673 ns 15695 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 87.5 ns 0.000 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 0.56 % 0.00 % 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 15990 ns 15782 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 15654 ns 15520 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 891 ns 1187 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 5.57 % 7.52 % 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 4241 ns 4214 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_median 4214 ns 4238 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_stddev 63.9 ns 47.1 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_cv 1.51 % 1.12 % 4
|
|
std::string str; ... str += str_var1 + str_var2;_mean 3791 ns 3793 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_median 3784 ns 3793 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_stddev 32.4 ns 50.3 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_cv 0.86 % 1.33 % 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_mean 750 ns 750 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_median 750 ns 750 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_stddev 2.14 ns 0.000 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_cv 0.29 % 0.00 % 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_mean 499 ns 500 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_median 499 ns 500 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_stddev 2.85 ns 0.000 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_cv 0.57 % 0.00 % 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_mean 372 ns 372 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_median 363 ns 364 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_stddev 23.4 ns 26.0 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_cv 6.30 % 6.99 % 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_mean 275 ns 275 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_median 276 ns 273 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 2.51 ns 6.01 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_cv 0.91 % 2.19 % 4
|
|
-- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::stringstream str; str << "test = " << k << " times";_mean 10371 ns 10376 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_median 10358 ns 10376 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_stddev 227 ns 315 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_cv 2.19 % 3.04 % 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_mean 1028 ns 1025 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_median 1025 ns 1025 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_stddev 17.2 ns 19.9 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_cv 1.67 % 1.94 % 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 2704 ns 2683 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 2704 ns 2698 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 29.8 ns 56.8 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 1.10 % 2.12 % 4
|
|
std::string str = std::format("test = {} times", k);_mean 1802 ns 1803 ns 4
|
|
std::string str = std::format("test = {} times", k);_median 1795 ns 1803 ns 4
|
|
std::string str = std::format("test = {} times", k);_stddev 20.9 ns 31.3 ns 4
|
|
std::string str = std::format("test = {} times", k);_cv 1.16 % 1.74 % 4
|
|
lstringa<8> str; str.format("test = {} times", k);_mean 2052 ns 2052 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_median 2037 ns 2040 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_stddev 69.4 ns 68.0 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_cv 3.38 % 3.31 % 4
|
|
lstringa<32> str; str.format("test = {} times", k);_mean 1013 ns 1010 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_median 987 ns 984 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_stddev 63.7 ns 52.3 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_cv 6.29 % 5.18 % 4
|
|
lstringa<8> str = "test = " + k + " times";_mean 807 ns 802 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_median 809 ns 811 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_stddev 9.74 ns 24.7 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_cv 1.21 % 3.07 % 4
|
|
lstringa<32> str = "test = " + k + " times";_mean 152 ns 152 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_median 151 ns 151 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_stddev 5.11 ns 5.44 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_cv 3.35 % 3.57 % 4
|
|
stringa str = "test = " + k + " times";_mean 149 ns 149 ns 4
|
|
stringa str = "test = " + k + " times";_median 150 ns 150 ns 4
|
|
stringa str = "test = " + k + " times";_stddev 1.48 ns 1.74 ns 4
|
|
stringa str = "test = " + k + " times";_cv 0.99 % 1.17 % 4
|
|
-- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string::find + substr + std::strtol_mean 518 ns 516 ns 4
|
|
std::string::find + substr + std::strtol_median 518 ns 516 ns 4
|
|
std::string::find + substr + std::strtol_stddev 2.10 ns 0.000 ns 4
|
|
std::string::find + substr + std::strtol_cv 0.41 % 0.00 % 4
|
|
ssa::splitter + ssa::as_int_mean 158 ns 158 ns 4
|
|
ssa::splitter + ssa::as_int_median 153 ns 153 ns 4
|
|
ssa::splitter + ssa::as_int_stddev 9.64 ns 11.2 ns 4
|
|
ssa::splitter + ssa::as_int_cv 6.12 % 7.08 % 4
|
|
ssa::splitf + functor_mean 183 ns 182 ns 4
|
|
ssa::splitf + functor_median 182 ns 182 ns 4
|
|
ssa::splitf + functor_stddev 4.02 ns 5.40 ns 4
|
|
ssa::splitf + functor_cv 2.20 % 2.97 % 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 1164 ns 1151 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_median 1175 ns 1158 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_stddev 31.0 ns 26.7 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_cv 2.67 % 2.32 % 4
|
|
replace symbols with std::string find_first_of + replace_mean 1997 ns 1998 ns 4
|
|
replace symbols with std::string find_first_of + replace_median 2000 ns 2009 ns 4
|
|
replace symbols with std::string find_first_of + replace_stddev 54.7 ns 52.7 ns 4
|
|
replace symbols with std::string find_first_of + replace_cv 2.74 % 2.64 % 4
|
|
replace symbols with std::string_view find_first_of + copy_mean 2301 ns 2307 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_median 2305 ns 2319 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_stddev 28.1 ns 46.7 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_cv 1.22 % 2.03 % 4
|
|
replace runtime symbols with string expressions and without remembering all search results_mean 1421 ns 1413 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_median 1410 ns 1413 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_stddev 24.6 ns 20.1 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_cv 1.73 % 1.43 % 4
|
|
replace runtime symbols with simstr and memorization of all search results_mean 1301 ns 1295 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_median 1302 ns 1303 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_stddev 9.07 ns 30.1 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_cv 0.70 % 2.32 % 4
|
|
replace const symbols with string expressions and without remembering all search results_mean 1201 ns 1200 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_median 1193 ns 1186 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_stddev 34.0 ns 39.5 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_cv 2.83 % 3.29 % 4
|
|
replace const symbols with string expressions and memorization of all search results_mean 1111 ns 1116 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_median 1102 ns 1116 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_stddev 22.3 ns 22.8 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_cv 2.01 % 2.04 % 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 304 ns 303 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_median 305 ns 307 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_stddev 4.53 ns 6.98 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_cv 1.49 % 2.30 % 4
|
|
Short replace symbols with std::string find_first_of + replace_mean 380 ns 377 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_median 375 ns 369 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_stddev 24.0 ns 28.5 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_cv 6.32 % 7.57 % 4
|
|
Short replace symbols with std::string_view find_first_of + copy_mean 314 ns 312 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_median 312 ns 310 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_stddev 8.83 ns 6.68 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_cv 2.81 % 2.14 % 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_mean 259 ns 259 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_median 257 ns 258 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_stddev 4.34 ns 5.68 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_cv 1.68 % 2.19 % 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_mean 336 ns 336 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_median 337 ns 338 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_stddev 1.54 ns 3.84 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_cv 0.46 % 1.14 % 4
|
|
Short replace const symbols with string expressions and without remembering all search results_mean 212 ns 212 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_median 210 ns 211 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_stddev 4.78 ns 4.34 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_cv 2.25 % 2.05 % 4
|
|
Short replace const symbols with string expressions and memorization of all search results_mean 293 ns 293 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_median 293 ns 292 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_stddev 3.39 ns 3.31 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_cv 1.16 % 1.13 % 4
|
|
----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
replace bb to ---- in std::string|64_mean 221 ns 222 ns 4
|
|
replace bb to ---- in std::string|64_median 221 ns 222 ns 4
|
|
replace bb to ---- in std::string|64_stddev 1.42 ns 2.82 ns 4
|
|
replace bb to ---- in std::string|64_cv 0.64 % 1.27 % 4
|
|
replace bb to ---- in std::string|256_mean 732 ns 732 ns 4
|
|
replace bb to ---- in std::string|256_median 728 ns 732 ns 4
|
|
replace bb to ---- in std::string|256_stddev 11.5 ns 14.2 ns 4
|
|
replace bb to ---- in std::string|256_cv 1.57 % 1.94 % 4
|
|
replace bb to ---- in std::string|512_mean 1412 ns 1413 ns 4
|
|
replace bb to ---- in std::string|512_median 1416 ns 1413 ns 4
|
|
replace bb to ---- in std::string|512_stddev 19.5 ns 25.6 ns 4
|
|
replace bb to ---- in std::string|512_cv 1.38 % 1.81 % 4
|
|
replace bb to ---- in std::string|1024_mean 3187 ns 3191 ns 4
|
|
replace bb to ---- in std::string|1024_median 3051 ns 3069 ns 4
|
|
replace bb to ---- in std::string|1024_stddev 288 ns 292 ns 4
|
|
replace bb to ---- in std::string|1024_cv 9.02 % 9.17 % 4
|
|
replace bb to ---- in std::string|2048_mean 7649 ns 7629 ns 4
|
|
replace bb to ---- in std::string|2048_median 7579 ns 7673 ns 4
|
|
replace bb to ---- in std::string|2048_stddev 158 ns 87.2 ns 4
|
|
replace bb to ---- in std::string|2048_cv 2.07 % 1.14 % 4
|
|
replace bb to ---- in lstringa<8>|64_mean 220 ns 220 ns 4
|
|
replace bb to ---- in lstringa<8>|64_median 214 ns 214 ns 4
|
|
replace bb to ---- in lstringa<8>|64_stddev 15.0 ns 14.8 ns 4
|
|
replace bb to ---- in lstringa<8>|64_cv 6.79 % 6.73 % 4
|
|
replace bb to ---- in lstringa<8>|256_mean 590 ns 589 ns 4
|
|
replace bb to ---- in lstringa<8>|256_median 590 ns 593 ns 4
|
|
replace bb to ---- in lstringa<8>|256_stddev 11.2 ns 13.4 ns 4
|
|
replace bb to ---- in lstringa<8>|256_cv 1.91 % 2.27 % 4
|
|
replace bb to ---- in lstringa<8>|512_mean 1038 ns 1038 ns 4
|
|
replace bb to ---- in lstringa<8>|512_median 1031 ns 1038 ns 4
|
|
replace bb to ---- in lstringa<8>|512_stddev 31.0 ns 31.5 ns 4
|
|
replace bb to ---- in lstringa<8>|512_cv 2.99 % 3.04 % 4
|
|
replace bb to ---- in lstringa<8>|1024_mean 1942 ns 1870 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_median 1873 ns 1883 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_stddev 176 ns 26.2 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_cv 9.06 % 1.40 % 4
|
|
replace bb to ---- in lstringa<8>|2048_mean 3514 ns 3516 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_median 3492 ns 3516 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_stddev 57.3 ns 68.3 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_cv 1.63 % 1.94 % 4
|
|
replace bb to ---- by init stringa|64_mean 170 ns 170 ns 4
|
|
replace bb to ---- by init stringa|64_median 170 ns 169 ns 4
|
|
replace bb to ---- by init stringa|64_stddev 2.04 ns 1.92 ns 4
|
|
replace bb to ---- by init stringa|64_cv 1.20 % 1.13 % 4
|
|
replace bb to ---- by init stringa|256_mean 351 ns 351 ns 4
|
|
replace bb to ---- by init stringa|256_median 351 ns 353 ns 4
|
|
replace bb to ---- by init stringa|256_stddev 1.82 ns 4.01 ns 4
|
|
replace bb to ---- by init stringa|256_cv 0.52 % 1.14 % 4
|
|
replace bb to ---- by init stringa|512_mean 791 ns 793 ns 4
|
|
replace bb to ---- by init stringa|512_median 786 ns 785 ns 4
|
|
replace bb to ---- by init stringa|512_stddev 10.7 ns 17.4 ns 4
|
|
replace bb to ---- by init stringa|512_cv 1.36 % 2.20 % 4
|
|
replace bb to ---- by init stringa|1024_mean 1624 ns 1604 ns 4
|
|
replace bb to ---- by init stringa|1024_median 1622 ns 1604 ns 4
|
|
replace bb to ---- by init stringa|1024_stddev 23.6 ns 28.5 ns 4
|
|
replace bb to ---- by init stringa|1024_cv 1.46 % 1.77 % 4
|
|
replace bb to ---- by init stringa|2048_mean 3034 ns 3032 ns 4
|
|
replace bb to ---- by init stringa|2048_median 3032 ns 3048 ns 4
|
|
replace bb to ---- by init stringa|2048_stddev 115 ns 99.4 ns 4
|
|
replace bb to ---- by init stringa|2048_cv 3.78 % 3.28 % 4
|
|
----- Replace All Str To Same Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
replace bb to -- in std::string|64_mean 188 ns 188 ns 4
|
|
replace bb to -- in std::string|64_median 188 ns 188 ns 4
|
|
replace bb to -- in std::string|64_stddev 1.46 ns 0.000 ns 4
|
|
replace bb to -- in std::string|64_cv 0.77 % 0.00 % 4
|
|
replace bb to -- in std::string|256_mean 453 ns 450 ns 4
|
|
replace bb to -- in std::string|256_median 450 ns 446 ns 4
|
|
replace bb to -- in std::string|256_stddev 6.77 ns 6.98 ns 4
|
|
replace bb to -- in std::string|256_cv 1.50 % 1.55 % 4
|
|
replace bb to -- in std::string|512_mean 851 ns 848 ns 4
|
|
replace bb to -- in std::string|512_median 851 ns 837 ns 4
|
|
replace bb to -- in std::string|512_stddev 8.89 ns 20.9 ns 4
|
|
replace bb to -- in std::string|512_cv 1.04 % 2.47 % 4
|
|
replace bb to -- in std::string|1024_mean 1566 ns 1569 ns 4
|
|
replace bb to -- in std::string|1024_median 1567 ns 1569 ns 4
|
|
replace bb to -- in std::string|1024_stddev 21.1 ns 40.3 ns 4
|
|
replace bb to -- in std::string|1024_cv 1.34 % 2.57 % 4
|
|
replace bb to -- in std::string|2048_mean 3199 ns 3191 ns 4
|
|
replace bb to -- in std::string|2048_median 3201 ns 3209 ns 4
|
|
replace bb to -- in std::string|2048_stddev 43.0 ns 34.9 ns 4
|
|
replace bb to -- in std::string|2048_cv 1.35 % 1.09 % 4
|
|
replace bb to -- in lstringa<8>|64_mean 181 ns 181 ns 4
|
|
replace bb to -- in lstringa<8>|64_median 178 ns 178 ns 4
|
|
replace bb to -- in lstringa<8>|64_stddev 6.58 ns 7.26 ns 4
|
|
replace bb to -- in lstringa<8>|64_cv 3.64 % 4.01 % 4
|
|
replace bb to -- in lstringa<8>|256_mean 423 ns 420 ns 4
|
|
replace bb to -- in lstringa<8>|256_median 422 ns 420 ns 4
|
|
replace bb to -- in lstringa<8>|256_stddev 4.24 ns 0.000 ns 4
|
|
replace bb to -- in lstringa<8>|256_cv 1.00 % 0.00 % 4
|
|
replace bb to -- in lstringa<8>|512_mean 736 ns 737 ns 4
|
|
replace bb to -- in lstringa<8>|512_median 735 ns 732 ns 4
|
|
replace bb to -- in lstringa<8>|512_stddev 15.9 ns 26.2 ns 4
|
|
replace bb to -- in lstringa<8>|512_cv 2.16 % 3.55 % 4
|
|
replace bb to -- in lstringa<8>|1024_mean 1346 ns 1342 ns 4
|
|
replace bb to -- in lstringa<8>|1024_median 1338 ns 1334 ns 4
|
|
replace bb to -- in lstringa<8>|1024_stddev 24.2 ns 30.1 ns 4
|
|
replace bb to -- in lstringa<8>|1024_cv 1.80 % 2.24 % 4
|
|
replace bb to -- in lstringa<8>|2048_mean 2605 ns 2609 ns 4
|
|
replace bb to -- in lstringa<8>|2048_median 2603 ns 2623 ns 4
|
|
replace bb to -- in lstringa<8>|2048_stddev 30.6 ns 27.9 ns 4
|
|
replace bb to -- in lstringa<8>|2048_cv 1.17 % 1.07 % 4
|
|
replace bb to -- by init stringa|64_mean 153 ns 152 ns 4
|
|
replace bb to -- by init stringa|64_median 152 ns 152 ns 4
|
|
replace bb to -- by init stringa|64_stddev 3.57 ns 1.81 ns 4
|
|
replace bb to -- by init stringa|64_cv 2.33 % 1.19 % 4
|
|
replace bb to -- by init stringa|256_mean 344 ns 343 ns 4
|
|
replace bb to -- by init stringa|256_median 341 ns 347 ns 4
|
|
replace bb to -- by init stringa|256_stddev 11.3 ns 11.8 ns 4
|
|
replace bb to -- by init stringa|256_cv 3.28 % 3.45 % 4
|
|
replace bb to -- by init stringa|512_mean 605 ns 582 ns 4
|
|
replace bb to -- by init stringa|512_median 589 ns 586 ns 4
|
|
replace bb to -- by init stringa|512_stddev 38.7 ns 6.98 ns 4
|
|
replace bb to -- by init stringa|512_cv 6.41 % 1.20 % 4
|
|
replace bb to -- by init stringa|1024_mean 1034 ns 1036 ns 4
|
|
replace bb to -- by init stringa|1024_median 1035 ns 1036 ns 4
|
|
replace bb to -- by init stringa|1024_stddev 2.50 ns 12.1 ns 4
|
|
replace bb to -- by init stringa|1024_cv 0.24 % 1.17 % 4
|
|
replace bb to -- by init stringa|2048_mean 1982 ns 1988 ns 4
|
|
replace bb to -- by init stringa|2048_median 1964 ns 1967 ns 4
|
|
replace bb to -- by init stringa|2048_stddev 46.0 ns 41.9 ns 4
|
|
replace bb to -- by init stringa|2048_cv 2.32 % 2.11 % 4
|
|
----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
hashStrMapA<size_t> emplace & find stringa;_mean 3860152 ns 3818959 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_median 3852020 ns 3840782 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_stddev 51816 ns 43645 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_cv 1.34 % 1.14 % 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_mean 5751400 ns 5781250 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_median 5754146 ns 5781250 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_stddev 83553 ns 127578 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_cv 1.45 % 2.21 % 4
|
|
hashStrMapA<size_t> emplace & find ssa;_mean 3389482 ns 3385417 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_median 3399206 ns 3365385 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_stddev 36688 ns 40064 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_cv 1.08 % 1.18 % 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_mean 6573724 ns 6556920 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_median 6584297 ns 6556920 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_stddev 33447 ns 0.000 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_cv 0.51 % 0.00 % 4
|
|
----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Build func full name std::string;_mean 1507 ns 1508 ns 4
|
|
Build func full name std::string;_median 1509 ns 1517 ns 4
|
|
Build func full name std::string;_stddev 28.5 ns 33.4 ns 4
|
|
Build func full name std::string;_cv 1.89 % 2.21 % 4
|
|
Build func full name std::string 1;_mean 1502 ns 1500 ns 4
|
|
Build func full name std::string 1;_median 1500 ns 1500 ns 4
|
|
Build func full name std::string 1;_stddev 7.70 ns 0.000 ns 4
|
|
Build func full name std::string 1;_cv 0.51 % 0.00 % 4
|
|
Build func full name std::stream;_mean 7853 ns 7847 ns 4
|
|
Build func full name std::stream;_median 7851 ns 7847 ns 4
|
|
Build func full name std::stream;_stddev 96.0 ns 121 ns 4
|
|
Build func full name std::stream;_cv 1.22 % 1.54 % 4
|
|
Build func full name stringa;_mean 784 ns 785 ns 4
|
|
Build func full name stringa;_median 780 ns 785 ns 4
|
|
Build func full name stringa;_stddev 9.31 ns 14.2 ns 4
|
|
Build func full name stringa;_cv 1.19 % 1.81 % 4
|
|
Build func full name stringa 1;_mean 908 ns 907 ns 4
|
|
Build func full name stringa 1;_median 906 ns 907 ns 4
|
|
Build func full name stringa 1;_stddev 16.5 ns 20.1 ns 4
|
|
Build func full name stringa 1;_cv 1.82 % 2.22 % 4
|