mirror of https://github.com/orefkov/simstr.git
940 lines
139 KiB
Plaintext
940 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-10T22:53:39+03:00
|
|
Running ./benchStr
|
|
Run on (32 X 2494.22 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)
|
|
Load Average: 0.05, 0.01, 0.00
|
|
***WARNING*** ASLR is enabled, the results may have unreproducible noise in them.
|
|
--------------------------------------------------------------------------------------------------------------------------------------------------------
|
|
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 197 ns 197 ns 4
|
|
Concat std::string and number by std to std::string_median 195 ns 195 ns 4
|
|
Concat std::string and number by std to std::string_stddev 3.28 ns 3.29 ns 4
|
|
Concat std::string and number by std to std::string_cv 1.67 % 1.67 % 4
|
|
Concat std::string and number by StrExpr to std::string_mean 101 ns 101 ns 4
|
|
Concat std::string and number by StrExpr to std::string_median 98.1 ns 98.1 ns 4
|
|
Concat std::string and number by StrExpr to std::string_stddev 6.44 ns 6.44 ns 4
|
|
Concat std::string and number by StrExpr to std::string_cv 6.37 % 6.37 % 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_mean 68.9 ns 68.9 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_median 68.5 ns 68.5 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_stddev 1.31 ns 1.31 ns 4
|
|
Concat stringa and number by StrExpr to simstr::stringa_cv 1.90 % 1.90 % 4
|
|
Concat stringa and number by e_concat to simstr::stringa_mean 74.0 ns 74.0 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_median 73.6 ns 73.6 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_stddev 1.11 ns 1.11 ns 4
|
|
Concat stringa and number by e_concat to simstr::stringa_cv 1.49 % 1.49 % 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 628 ns 628 ns 4
|
|
Concat std::string and format hex number and literal to std::string_median 622 ns 622 ns 4
|
|
Concat std::string and format hex number and literal to std::string_stddev 17.5 ns 17.5 ns 4
|
|
Concat std::string and format hex number and literal to std::string_cv 2.78 % 2.78 % 4
|
|
std::format std::string and hex number by literal to std::string_mean 889 ns 889 ns 4
|
|
std::format std::string and hex number by literal to std::string_median 879 ns 879 ns 4
|
|
std::format std::string and hex number by literal to std::string_stddev 31.8 ns 31.8 ns 4
|
|
std::format std::string and hex number by literal to std::string_cv 3.57 % 3.57 % 4
|
|
Concat std::string and std::to_chars and string to std::string_mean 180 ns 180 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_median 176 ns 176 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_stddev 13.1 ns 13.1 ns 4
|
|
Concat std::string and std::to_chars and string to std::string_cv 7.28 % 7.28 % 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_mean 120 ns 120 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_median 120 ns 120 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_stddev 0.450 ns 0.450 ns 4
|
|
Concat std::string and hex number and literal by StrExpr to std::string_cv 0.37 % 0.37 % 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 119 ns 119 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 118 ns 118 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 4.30 ns 4.30 ns 4
|
|
Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 3.60 % 3.60 % 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 124 ns 124 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_median 125 ns 125 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 1.38 ns 1.38 ns 4
|
|
Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 1.11 % 1.11 % 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_mean 172 ns 172 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_median 170 ns 170 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 4.48 ns 4.48 ns 4
|
|
Subst stringa and hex number by e_subst literal to simstr::stringa_cv 2.61 % 2.61 % 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 317 ns 317 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 308 ns 308 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 24.4 ns 24.4 ns 4
|
|
Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 7.69 % 7.69 % 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 249 ns 249 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 247 ns 247 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 4.68 ns 4.68 ns 4
|
|
"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 1.88 % 1.88 % 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 323 ns 323 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 316 ns 316 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 19.4 ns 19.4 ns 4
|
|
e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 6.01 % 6.01 % 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_mean 577 ns 577 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_median 573 ns 573 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_stddev 15.3 ns 15.3 ns 4
|
|
e_vsubst(pattern, i / 0x8a010_fmt)_cv 2.65 % 2.65 % 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 703 ns 703 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 703 ns 703 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 7.53 ns 7.53 ns 4
|
|
fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 1.07 % 1.07 % 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 788 ns 788 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 763 ns 763 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 56.5 ns 56.5 ns 4
|
|
fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 7.17 % 7.17 % 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1198 ns 1198 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_median 1191 ns 1191 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 29.9 ns 29.9 ns 4
|
|
std::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.49 % 2.49 % 4
|
|
std::vformat(pattern, std::make_format_args(i))_mean 1065 ns 1065 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_median 1063 ns 1063 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_stddev 6.96 ns 6.96 ns 4
|
|
std::vformat(pattern, std::make_format_args(i))_cv 0.65 % 0.65 % 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 2059 ns 2059 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 2053 ns 2053 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 24.2 ns 24.2 ns 4
|
|
strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 1.17 % 1.17 % 4
|
|
----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat std::string by std to std::string_mean 48.0 ns 48.0 ns 4
|
|
Concat std::string by std to std::string_median 47.8 ns 47.8 ns 4
|
|
Concat std::string by std to std::string_stddev 0.538 ns 0.538 ns 4
|
|
Concat std::string by std to std::string_cv 1.12 % 1.12 % 4
|
|
Concat std::string by StrExpr to std::string_mean 29.4 ns 29.4 ns 4
|
|
Concat std::string by StrExpr to std::string_median 28.7 ns 28.7 ns 4
|
|
Concat std::string by StrExpr to std::string_stddev 1.63 ns 1.63 ns 4
|
|
Concat std::string by StrExpr to std::string_cv 5.55 % 5.55 % 4
|
|
Concat stringa by StrExpr to stringa_mean 26.1 ns 26.1 ns 4
|
|
Concat stringa by StrExpr to stringa_median 26.1 ns 26.1 ns 4
|
|
Concat stringa by StrExpr to stringa_stddev 0.261 ns 0.262 ns 4
|
|
Concat stringa by StrExpr to stringa_cv 1.00 % 1.00 % 4
|
|
----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Find concat three std::string_mean 122 ns 122 ns 4
|
|
Find concat three std::string_median 122 ns 122 ns 4
|
|
Find concat three std::string_stddev 0.875 ns 0.875 ns 4
|
|
Find concat three std::string_cv 0.72 % 0.72 % 4
|
|
Find concat three strexpr_mean 40.2 ns 40.2 ns 4
|
|
Find concat three strexpr_median 39.5 ns 39.5 ns 4
|
|
Find concat three strexpr_stddev 2.76 ns 2.76 ns 4
|
|
Find concat three strexpr_cv 6.87 % 6.87 % 4
|
|
Find concat three simstr_mean 19.2 ns 19.2 ns 4
|
|
Find concat three simstr_median 19.1 ns 19.1 ns 4
|
|
Find concat three simstr_stddev 0.337 ns 0.337 ns 4
|
|
Find concat three simstr_cv 1.76 % 1.76 % 4
|
|
----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
BuildTypeNameStr 0/0_mean 9.86 ns 9.86 ns 4
|
|
BuildTypeNameStr 0/0_median 9.87 ns 9.87 ns 4
|
|
BuildTypeNameStr 0/0_stddev 0.153 ns 0.153 ns 4
|
|
BuildTypeNameStr 0/0_cv 1.55 % 1.55 % 4
|
|
BuildTypeNameExp 0/0_mean 6.52 ns 6.52 ns 4
|
|
BuildTypeNameExp 0/0_median 6.53 ns 6.53 ns 4
|
|
BuildTypeNameExp 0/0_stddev 0.127 ns 0.127 ns 4
|
|
BuildTypeNameExp 0/0_cv 1.96 % 1.96 % 4
|
|
BuildTypeNameSim 0/0_mean 4.76 ns 4.76 ns 4
|
|
BuildTypeNameSim 0/0_median 4.77 ns 4.77 ns 4
|
|
BuildTypeNameSim 0/0_stddev 0.035 ns 0.035 ns 4
|
|
BuildTypeNameSim 0/0_cv 0.74 % 0.74 % 4
|
|
BuildTypeNameStr 10/10_mean 79.6 ns 79.6 ns 4
|
|
BuildTypeNameStr 10/10_median 79.5 ns 79.5 ns 4
|
|
BuildTypeNameStr 10/10_stddev 0.607 ns 0.607 ns 4
|
|
BuildTypeNameStr 10/10_cv 0.76 % 0.76 % 4
|
|
BuildTypeNameExp 10/10_mean 23.7 ns 23.7 ns 4
|
|
BuildTypeNameExp 10/10_median 23.7 ns 23.7 ns 4
|
|
BuildTypeNameExp 10/10_stddev 0.139 ns 0.139 ns 4
|
|
BuildTypeNameExp 10/10_cv 0.59 % 0.59 % 4
|
|
BuildTypeNameSim 10/10_mean 21.0 ns 21.0 ns 4
|
|
BuildTypeNameSim 10/10_median 21.0 ns 21.0 ns 4
|
|
BuildTypeNameSim 10/10_stddev 0.102 ns 0.102 ns 4
|
|
BuildTypeNameSim 10/10_cv 0.49 % 0.49 % 4
|
|
----- Replace string by copy -----/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Concat with replace str_mean 225 ns 225 ns 4
|
|
Concat with replace str_median 227 ns 227 ns 4
|
|
Concat with replace str_stddev 9.49 ns 9.49 ns 4
|
|
Concat with replace str_cv 4.22 % 4.22 % 4
|
|
Concat with replace exp_mean 133 ns 133 ns 4
|
|
Concat with replace exp_median 133 ns 133 ns 4
|
|
Concat with replace exp_stddev 1.95 ns 1.95 ns 4
|
|
Concat with replace exp_cv 1.47 % 1.47 % 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.08 ns 1.08 ns 4
|
|
std::string e;_stddev 0.010 ns 0.010 ns 4
|
|
std::string e;_cv 0.91 % 0.91 % 4
|
|
std::string_view e;_mean 0.731 ns 0.731 ns 4
|
|
std::string_view e;_median 0.726 ns 0.726 ns 4
|
|
std::string_view e;_stddev 0.012 ns 0.012 ns 4
|
|
std::string_view e;_cv 1.69 % 1.69 % 4
|
|
ssa e;_mean 0.180 ns 0.180 ns 4
|
|
ssa e;_median 0.179 ns 0.179 ns 4
|
|
ssa e;_stddev 0.001 ns 0.001 ns 4
|
|
ssa e;_cv 0.75 % 0.75 % 4
|
|
stringa e;_mean 0.732 ns 0.732 ns 4
|
|
stringa e;_median 0.731 ns 0.731 ns 4
|
|
stringa e;_stddev 0.007 ns 0.007 ns 4
|
|
stringa e;_cv 0.98 % 0.98 % 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.015 ns 0.015 ns 4
|
|
lstringa<20> e;_cv 1.37 % 1.37 % 4
|
|
lstringa<40> e;_mean 1.12 ns 1.12 ns 4
|
|
lstringa<40> e;_median 1.08 ns 1.08 ns 4
|
|
lstringa<40> e;_stddev 0.088 ns 0.088 ns 4
|
|
lstringa<40> e;_cv 7.82 % 7.82 % 4
|
|
----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "Test text";_mean 1.85 ns 1.85 ns 4
|
|
std::string e = "Test text";_median 1.84 ns 1.84 ns 4
|
|
std::string e = "Test text";_stddev 0.034 ns 0.034 ns 4
|
|
std::string e = "Test text";_cv 1.85 % 1.85 % 4
|
|
std::string_view e = "Test text";_mean 0.732 ns 0.732 ns 4
|
|
std::string_view e = "Test text";_median 0.731 ns 0.731 ns 4
|
|
std::string_view e = "Test text";_stddev 0.017 ns 0.017 ns 4
|
|
std::string_view e = "Test text";_cv 2.34 % 2.34 % 4
|
|
ssa e = "Test text";_mean 0.722 ns 0.722 ns 4
|
|
ssa e = "Test text";_median 0.721 ns 0.721 ns 4
|
|
ssa e = "Test text";_stddev 0.004 ns 0.004 ns 4
|
|
ssa e = "Test text";_cv 0.52 % 0.52 % 4
|
|
stringa e = "Test text";_mean 1.12 ns 1.12 ns 4
|
|
stringa e = "Test text";_median 1.10 ns 1.10 ns 4
|
|
stringa e = "Test text";_stddev 0.059 ns 0.059 ns 4
|
|
stringa e = "Test text";_cv 5.29 % 5.29 % 4
|
|
lstringa<20> e = "Test text";_mean 1.80 ns 1.80 ns 4
|
|
lstringa<20> e = "Test text";_median 1.81 ns 1.81 ns 4
|
|
lstringa<20> e = "Test text";_stddev 0.006 ns 0.006 ns 4
|
|
lstringa<20> e = "Test text";_cv 0.33 % 0.33 % 4
|
|
lstringa<40> e = "Test text";_mean 1.86 ns 1.86 ns 4
|
|
lstringa<40> e = "Test text";_median 1.84 ns 1.84 ns 4
|
|
lstringa<40> e = "Test text";_stddev 0.076 ns 0.076 ns 4
|
|
lstringa<40> e = "Test text";_cv 4.08 % 4.08 % 4
|
|
----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string e = "123456789012345678901234567890";_mean 19.7 ns 19.7 ns 4
|
|
std::string e = "123456789012345678901234567890";_median 19.5 ns 19.5 ns 4
|
|
std::string e = "123456789012345678901234567890";_stddev 0.560 ns 0.560 ns 4
|
|
std::string e = "123456789012345678901234567890";_cv 2.84 % 2.84 % 4
|
|
std::string_view e = "123456789012345678901234567890";_mean 0.727 ns 0.727 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_median 0.726 ns 0.726 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_stddev 0.020 ns 0.020 ns 4
|
|
std::string_view e = "123456789012345678901234567890";_cv 2.76 % 2.76 % 4
|
|
ssa e = "123456789012345678901234567890";_mean 0.718 ns 0.718 ns 4
|
|
ssa e = "123456789012345678901234567890";_median 0.719 ns 0.719 ns 4
|
|
ssa e = "123456789012345678901234567890";_stddev 0.003 ns 0.003 ns 4
|
|
ssa e = "123456789012345678901234567890";_cv 0.46 % 0.46 % 4
|
|
stringa e = "123456789012345678901234567890";_mean 1.11 ns 1.11 ns 4
|
|
stringa e = "123456789012345678901234567890";_median 1.10 ns 1.10 ns 4
|
|
stringa e = "123456789012345678901234567890";_stddev 0.025 ns 0.025 ns 4
|
|
stringa e = "123456789012345678901234567890";_cv 2.27 % 2.27 % 4
|
|
lstringa<20> e = "123456789012345678901234567890";_mean 20.4 ns 20.4 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_median 20.0 ns 20.0 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_stddev 1.26 ns 1.26 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890";_cv 6.16 % 6.16 % 4
|
|
lstringa<40> e = "123456789012345678901234567890";_mean 1.82 ns 1.82 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_median 1.82 ns 1.82 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_stddev 0.009 ns 0.009 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890";_cv 0.52 % 0.52 % 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 5.55 ns 5.55 ns 4
|
|
std::string e = "Test text"; auto c{e};_median 5.48 ns 5.48 ns 4
|
|
std::string e = "Test text"; auto c{e};_stddev 0.156 ns 0.156 ns 4
|
|
std::string e = "Test text"; auto c{e};_cv 2.81 % 2.81 % 4
|
|
std::string_view e = "Test text"; auto c{e};_mean 0.367 ns 0.367 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_median 0.367 ns 0.367 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_stddev 0.003 ns 0.003 ns 4
|
|
std::string_view e = "Test text"; auto c{e};_cv 0.88 % 0.88 % 4
|
|
ssa e = "Test text"; auto c{e};_mean 0.374 ns 0.374 ns 4
|
|
ssa e = "Test text"; auto c{e};_median 0.369 ns 0.369 ns 4
|
|
ssa e = "Test text"; auto c{e};_stddev 0.016 ns 0.016 ns 4
|
|
ssa e = "Test text"; auto c{e};_cv 4.40 % 4.40 % 4
|
|
stringa e = "Test text"; auto c{e};_mean 1.27 ns 1.27 ns 4
|
|
stringa e = "Test text"; auto c{e};_median 1.28 ns 1.28 ns 4
|
|
stringa e = "Test text"; auto c{e};_stddev 0.011 ns 0.011 ns 4
|
|
stringa e = "Test text"; auto c{e};_cv 0.88 % 0.88 % 4
|
|
lstringa<20> e = "Test text"; auto c{e};_mean 1.46 ns 1.46 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_median 1.45 ns 1.45 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_stddev 0.026 ns 0.026 ns 4
|
|
lstringa<20> e = "Test text"; auto c{e};_cv 1.75 % 1.75 % 4
|
|
lstringa<40> e = "Test text"; auto c{e};_mean 1.47 ns 1.47 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_median 1.45 ns 1.45 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_stddev 0.055 ns 0.055 ns 4
|
|
lstringa<40> e = "Test text"; auto c{e};_cv 3.76 % 3.76 % 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 23.1 ns 23.1 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_median 23.1 ns 23.1 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_stddev 0.115 ns 0.115 ns 4
|
|
std::string e = "123456789012345678901234567890"; auto c{e};_cv 0.50 % 0.50 % 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.730 ns 0.730 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.731 ns 0.731 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.010 ns 0.010 ns 4
|
|
std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 1.39 % 1.39 % 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.730 ns 0.730 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_median 0.730 ns 0.730 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.007 ns 0.007 ns 4
|
|
ssa e = "123456789012345678901234567890"; auto c{e};_cv 1.00 % 1.00 % 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.08 ns 1.08 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_median 1.08 ns 1.08 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.005 ns 0.005 ns 4
|
|
stringa e = "123456789012345678901234567890"; auto c{e};_cv 0.45 % 0.45 % 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 19.5 ns 19.5 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 19.3 ns 19.3 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 0.426 ns 0.426 ns 4
|
|
lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 2.18 % 2.18 % 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 5.61 ns 5.61 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 5.58 ns 5.58 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.075 ns 0.075 ns 4
|
|
lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 1.34 % 1.34 % 4
|
|
----- Find 9 symbols text in end of 99 symbols text ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string::find;_mean 6.56 ns 6.56 ns 4
|
|
std::string::find;_median 6.56 ns 6.56 ns 4
|
|
std::string::find;_stddev 0.053 ns 0.053 ns 4
|
|
std::string::find;_cv 0.81 % 0.81 % 4
|
|
std::string_view::find;_mean 6.70 ns 6.70 ns 4
|
|
std::string_view::find;_median 6.69 ns 6.69 ns 4
|
|
std::string_view::find;_stddev 0.187 ns 0.187 ns 4
|
|
std::string_view::find;_cv 2.78 % 2.78 % 4
|
|
ssa::find;_mean 6.24 ns 6.24 ns 4
|
|
ssa::find;_median 6.24 ns 6.24 ns 4
|
|
ssa::find;_stddev 0.052 ns 0.052 ns 4
|
|
ssa::find;_cv 0.84 % 0.84 % 4
|
|
stringa::find;_mean 6.57 ns 6.57 ns 4
|
|
stringa::find;_median 6.55 ns 6.55 ns 4
|
|
stringa::find;_stddev 0.125 ns 0.125 ns 4
|
|
stringa::find;_cv 1.91 % 1.91 % 4
|
|
lstringa<20>::find;_mean 6.29 ns 6.29 ns 4
|
|
lstringa<20>::find;_median 6.28 ns 6.28 ns 4
|
|
lstringa<20>::find;_stddev 0.159 ns 0.159 ns 4
|
|
lstringa<20>::find;_cv 2.53 % 2.53 % 4
|
|
lstringa<40>::find;_mean 6.24 ns 6.24 ns 4
|
|
lstringa<40>::find;_median 6.22 ns 6.22 ns 4
|
|
lstringa<40>::find;_stddev 0.097 ns 0.097 ns 4
|
|
lstringa<40>::find;_cv 1.55 % 1.55 % 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 5.56 ns 5.56 ns 4
|
|
std::string copy{str_with_len_N};/15_median 5.59 ns 5.59 ns 4
|
|
std::string copy{str_with_len_N};/15_stddev 0.078 ns 0.078 ns 4
|
|
std::string copy{str_with_len_N};/15_cv 1.40 % 1.40 % 4
|
|
std::string copy{str_with_len_N};/16_mean 23.7 ns 23.7 ns 4
|
|
std::string copy{str_with_len_N};/16_median 23.7 ns 23.7 ns 4
|
|
std::string copy{str_with_len_N};/16_stddev 0.134 ns 0.134 ns 4
|
|
std::string copy{str_with_len_N};/16_cv 0.56 % 0.56 % 4
|
|
std::string copy{str_with_len_N};/23_mean 23.3 ns 23.3 ns 4
|
|
std::string copy{str_with_len_N};/23_median 23.3 ns 23.3 ns 4
|
|
std::string copy{str_with_len_N};/23_stddev 0.083 ns 0.083 ns 4
|
|
std::string copy{str_with_len_N};/23_cv 0.35 % 0.35 % 4
|
|
std::string copy{str_with_len_N};/24_mean 23.5 ns 23.5 ns 4
|
|
std::string copy{str_with_len_N};/24_median 23.5 ns 23.5 ns 4
|
|
std::string copy{str_with_len_N};/24_stddev 0.226 ns 0.226 ns 4
|
|
std::string copy{str_with_len_N};/24_cv 0.96 % 0.96 % 4
|
|
std::string copy{str_with_len_N};/32_mean 23.0 ns 23.0 ns 4
|
|
std::string copy{str_with_len_N};/32_median 23.0 ns 23.0 ns 4
|
|
std::string copy{str_with_len_N};/32_stddev 0.227 ns 0.227 ns 4
|
|
std::string copy{str_with_len_N};/32_cv 0.99 % 0.99 % 4
|
|
std::string copy{str_with_len_N};/64_mean 23.6 ns 23.6 ns 4
|
|
std::string copy{str_with_len_N};/64_median 23.7 ns 23.7 ns 4
|
|
std::string copy{str_with_len_N};/64_stddev 0.453 ns 0.453 ns 4
|
|
std::string copy{str_with_len_N};/64_cv 1.92 % 1.92 % 4
|
|
std::string copy{str_with_len_N};/128_mean 24.7 ns 24.7 ns 4
|
|
std::string copy{str_with_len_N};/128_median 24.7 ns 24.7 ns 4
|
|
std::string copy{str_with_len_N};/128_stddev 0.199 ns 0.199 ns 4
|
|
std::string copy{str_with_len_N};/128_cv 0.81 % 0.81 % 4
|
|
std::string copy{str_with_len_N};/256_mean 25.0 ns 25.0 ns 4
|
|
std::string copy{str_with_len_N};/256_median 25.0 ns 25.0 ns 4
|
|
std::string copy{str_with_len_N};/256_stddev 0.089 ns 0.089 ns 4
|
|
std::string copy{str_with_len_N};/256_cv 0.36 % 0.36 % 4
|
|
std::string copy{str_with_len_N};/512_mean 30.2 ns 30.2 ns 4
|
|
std::string copy{str_with_len_N};/512_median 29.1 ns 29.1 ns 4
|
|
std::string copy{str_with_len_N};/512_stddev 2.53 ns 2.53 ns 4
|
|
std::string copy{str_with_len_N};/512_cv 8.40 % 8.40 % 4
|
|
std::string copy{str_with_len_N};/1024_mean 48.2 ns 48.2 ns 4
|
|
std::string copy{str_with_len_N};/1024_median 48.2 ns 48.2 ns 4
|
|
std::string copy{str_with_len_N};/1024_stddev 0.401 ns 0.401 ns 4
|
|
std::string copy{str_with_len_N};/1024_cv 0.83 % 0.83 % 4
|
|
std::string copy{str_with_len_N};/2048_mean 126 ns 126 ns 4
|
|
std::string copy{str_with_len_N};/2048_median 126 ns 126 ns 4
|
|
std::string copy{str_with_len_N};/2048_stddev 5.51 ns 5.51 ns 4
|
|
std::string copy{str_with_len_N};/2048_cv 4.38 % 4.38 % 4
|
|
std::string copy{str_with_len_N};/4096_mean 155 ns 155 ns 4
|
|
std::string copy{str_with_len_N};/4096_median 155 ns 155 ns 4
|
|
std::string copy{str_with_len_N};/4096_stddev 5.49 ns 5.49 ns 4
|
|
std::string copy{str_with_len_N};/4096_cv 3.55 % 3.55 % 4
|
|
stringa copy{str_with_len_N};/15_mean 1.47 ns 1.47 ns 4
|
|
stringa copy{str_with_len_N};/15_median 1.46 ns 1.46 ns 4
|
|
stringa copy{str_with_len_N};/15_stddev 0.028 ns 0.028 ns 4
|
|
stringa copy{str_with_len_N};/15_cv 1.91 % 1.91 % 4
|
|
stringa copy{str_with_len_N};/16_mean 1.42 ns 1.42 ns 4
|
|
stringa copy{str_with_len_N};/16_median 1.46 ns 1.46 ns 4
|
|
stringa copy{str_with_len_N};/16_stddev 0.078 ns 0.078 ns 4
|
|
stringa copy{str_with_len_N};/16_cv 5.46 % 5.46 % 4
|
|
stringa copy{str_with_len_N};/23_mean 1.42 ns 1.42 ns 4
|
|
stringa copy{str_with_len_N};/23_median 1.43 ns 1.43 ns 4
|
|
stringa copy{str_with_len_N};/23_stddev 0.044 ns 0.044 ns 4
|
|
stringa copy{str_with_len_N};/23_cv 3.11 % 3.11 % 4
|
|
stringa copy{str_with_len_N};/24_mean 16.5 ns 16.5 ns 4
|
|
stringa copy{str_with_len_N};/24_median 16.5 ns 16.5 ns 4
|
|
stringa copy{str_with_len_N};/24_stddev 0.156 ns 0.156 ns 4
|
|
stringa copy{str_with_len_N};/24_cv 0.94 % 0.94 % 4
|
|
stringa copy{str_with_len_N};/32_mean 16.6 ns 16.6 ns 4
|
|
stringa copy{str_with_len_N};/32_median 16.6 ns 16.6 ns 4
|
|
stringa copy{str_with_len_N};/32_stddev 0.148 ns 0.148 ns 4
|
|
stringa copy{str_with_len_N};/32_cv 0.89 % 0.89 % 4
|
|
stringa copy{str_with_len_N};/64_mean 16.6 ns 16.6 ns 4
|
|
stringa copy{str_with_len_N};/64_median 16.6 ns 16.6 ns 4
|
|
stringa copy{str_with_len_N};/64_stddev 0.111 ns 0.111 ns 4
|
|
stringa copy{str_with_len_N};/64_cv 0.67 % 0.67 % 4
|
|
stringa copy{str_with_len_N};/128_mean 16.5 ns 16.5 ns 4
|
|
stringa copy{str_with_len_N};/128_median 16.6 ns 16.6 ns 4
|
|
stringa copy{str_with_len_N};/128_stddev 0.315 ns 0.315 ns 4
|
|
stringa copy{str_with_len_N};/128_cv 1.91 % 1.91 % 4
|
|
stringa copy{str_with_len_N};/256_mean 16.6 ns 16.6 ns 4
|
|
stringa copy{str_with_len_N};/256_median 16.6 ns 16.6 ns 4
|
|
stringa copy{str_with_len_N};/256_stddev 0.056 ns 0.056 ns 4
|
|
stringa copy{str_with_len_N};/256_cv 0.34 % 0.34 % 4
|
|
stringa copy{str_with_len_N};/512_mean 16.3 ns 16.3 ns 4
|
|
stringa copy{str_with_len_N};/512_median 16.4 ns 16.4 ns 4
|
|
stringa copy{str_with_len_N};/512_stddev 0.215 ns 0.215 ns 4
|
|
stringa copy{str_with_len_N};/512_cv 1.32 % 1.32 % 4
|
|
stringa copy{str_with_len_N};/1024_mean 16.7 ns 16.7 ns 4
|
|
stringa copy{str_with_len_N};/1024_median 16.7 ns 16.7 ns 4
|
|
stringa copy{str_with_len_N};/1024_stddev 0.287 ns 0.287 ns 4
|
|
stringa copy{str_with_len_N};/1024_cv 1.72 % 1.72 % 4
|
|
stringa copy{str_with_len_N};/2048_mean 16.5 ns 16.5 ns 4
|
|
stringa copy{str_with_len_N};/2048_median 16.5 ns 16.5 ns 4
|
|
stringa copy{str_with_len_N};/2048_stddev 0.085 ns 0.085 ns 4
|
|
stringa copy{str_with_len_N};/2048_cv 0.52 % 0.52 % 4
|
|
stringa copy{str_with_len_N};/4096_mean 16.5 ns 16.5 ns 4
|
|
stringa copy{str_with_len_N};/4096_median 16.5 ns 16.5 ns 4
|
|
stringa copy{str_with_len_N};/4096_stddev 0.117 ns 0.117 ns 4
|
|
stringa copy{str_with_len_N};/4096_cv 0.71 % 0.71 % 4
|
|
lstringa<16> copy{str_with_len_N};/15_mean 1.58 ns 1.58 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_median 1.60 ns 1.60 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_stddev 0.102 ns 0.102 ns 4
|
|
lstringa<16> copy{str_with_len_N};/15_cv 6.45 % 6.45 % 4
|
|
lstringa<16> copy{str_with_len_N};/16_mean 6.31 ns 6.31 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_median 6.14 ns 6.14 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_stddev 0.504 ns 0.504 ns 4
|
|
lstringa<16> copy{str_with_len_N};/16_cv 7.99 % 7.99 % 4
|
|
lstringa<16> copy{str_with_len_N};/23_mean 6.37 ns 6.37 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_median 6.30 ns 6.30 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_stddev 0.412 ns 0.412 ns 4
|
|
lstringa<16> copy{str_with_len_N};/23_cv 6.46 % 6.46 % 4
|
|
lstringa<16> copy{str_with_len_N};/24_mean 26.6 ns 26.6 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_median 27.2 ns 27.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_stddev 1.66 ns 1.66 ns 4
|
|
lstringa<16> copy{str_with_len_N};/24_cv 6.23 % 6.23 % 4
|
|
lstringa<16> copy{str_with_len_N};/32_mean 26.9 ns 26.9 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_median 26.9 ns 26.9 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_stddev 0.696 ns 0.696 ns 4
|
|
lstringa<16> copy{str_with_len_N};/32_cv 2.58 % 2.58 % 4
|
|
lstringa<16> copy{str_with_len_N};/64_mean 27.9 ns 27.9 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_median 28.2 ns 28.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_stddev 1.53 ns 1.53 ns 4
|
|
lstringa<16> copy{str_with_len_N};/64_cv 5.46 % 5.46 % 4
|
|
lstringa<16> copy{str_with_len_N};/128_mean 29.1 ns 29.1 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_median 29.2 ns 29.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_stddev 0.627 ns 0.627 ns 4
|
|
lstringa<16> copy{str_with_len_N};/128_cv 2.15 % 2.15 % 4
|
|
lstringa<16> copy{str_with_len_N};/256_mean 31.4 ns 31.4 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_median 31.2 ns 31.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_stddev 0.942 ns 0.942 ns 4
|
|
lstringa<16> copy{str_with_len_N};/256_cv 3.00 % 3.00 % 4
|
|
lstringa<16> copy{str_with_len_N};/512_mean 33.8 ns 33.8 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_median 33.2 ns 33.2 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_stddev 1.85 ns 1.85 ns 4
|
|
lstringa<16> copy{str_with_len_N};/512_cv 5.47 % 5.47 % 4
|
|
lstringa<16> copy{str_with_len_N};/1024_mean 124 ns 124 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_median 123 ns 123 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_stddev 7.96 ns 7.96 ns 4
|
|
lstringa<16> copy{str_with_len_N};/1024_cv 6.42 % 6.42 % 4
|
|
lstringa<16> copy{str_with_len_N};/2048_mean 135 ns 135 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_median 133 ns 133 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_stddev 4.33 ns 4.33 ns 4
|
|
lstringa<16> copy{str_with_len_N};/2048_cv 3.22 % 3.22 % 4
|
|
lstringa<16> copy{str_with_len_N};/4096_mean 149 ns 149 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_median 147 ns 147 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_stddev 10.9 ns 10.9 ns 4
|
|
lstringa<16> copy{str_with_len_N};/4096_cv 7.31 % 7.31 % 4
|
|
lstringa<512> copy{str_with_len_N};/15_mean 1.57 ns 1.57 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_median 1.59 ns 1.59 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_stddev 0.068 ns 0.068 ns 4
|
|
lstringa<512> copy{str_with_len_N};/15_cv 4.34 % 4.34 % 4
|
|
lstringa<512> copy{str_with_len_N};/16_mean 6.26 ns 6.26 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_median 6.28 ns 6.28 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_stddev 0.105 ns 0.105 ns 4
|
|
lstringa<512> copy{str_with_len_N};/16_cv 1.68 % 1.68 % 4
|
|
lstringa<512> copy{str_with_len_N};/23_mean 6.14 ns 6.14 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_median 6.14 ns 6.14 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_stddev 0.230 ns 0.230 ns 4
|
|
lstringa<512> copy{str_with_len_N};/23_cv 3.75 % 3.75 % 4
|
|
lstringa<512> copy{str_with_len_N};/24_mean 6.76 ns 6.76 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_median 6.62 ns 6.62 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_stddev 0.375 ns 0.375 ns 4
|
|
lstringa<512> copy{str_with_len_N};/24_cv 5.54 % 5.54 % 4
|
|
lstringa<512> copy{str_with_len_N};/32_mean 6.53 ns 6.53 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_median 6.33 ns 6.33 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_stddev 0.559 ns 0.559 ns 4
|
|
lstringa<512> copy{str_with_len_N};/32_cv 8.57 % 8.57 % 4
|
|
lstringa<512> copy{str_with_len_N};/64_mean 8.18 ns 8.18 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_median 8.15 ns 8.15 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_stddev 0.132 ns 0.132 ns 4
|
|
lstringa<512> copy{str_with_len_N};/64_cv 1.61 % 1.61 % 4
|
|
lstringa<512> copy{str_with_len_N};/128_mean 7.95 ns 7.95 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_median 7.94 ns 7.94 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_stddev 0.413 ns 0.413 ns 4
|
|
lstringa<512> copy{str_with_len_N};/128_cv 5.20 % 5.20 % 4
|
|
lstringa<512> copy{str_with_len_N};/256_mean 9.18 ns 9.18 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_median 9.04 ns 9.04 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_stddev 0.594 ns 0.594 ns 4
|
|
lstringa<512> copy{str_with_len_N};/256_cv 6.48 % 6.48 % 4
|
|
lstringa<512> copy{str_with_len_N};/512_mean 12.8 ns 12.8 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_median 12.9 ns 12.9 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_stddev 0.595 ns 0.595 ns 4
|
|
lstringa<512> copy{str_with_len_N};/512_cv 4.66 % 4.66 % 4
|
|
lstringa<512> copy{str_with_len_N};/1024_mean 125 ns 125 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_median 125 ns 125 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_stddev 4.34 ns 4.34 ns 4
|
|
lstringa<512> copy{str_with_len_N};/1024_cv 3.47 % 3.47 % 4
|
|
lstringa<512> copy{str_with_len_N};/2048_mean 135 ns 135 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_median 132 ns 132 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_stddev 10.8 ns 10.8 ns 4
|
|
lstringa<512> copy{str_with_len_N};/2048_cv 7.98 % 7.98 % 4
|
|
lstringa<512> copy{str_with_len_N};/4096_mean 152 ns 152 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_median 151 ns 151 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_stddev 7.29 ns 7.29 ns 4
|
|
lstringa<512> copy{str_with_len_N};/4096_cv 4.81 % 4.81 % 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 30.4 ns 30.4 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 30.3 ns 30.3 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 1.11 ns 1.11 ns 4
|
|
std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 3.64 % 3.64 % 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 12.5 ns 12.5 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 12.6 ns 12.6 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.473 ns 0.473 ns 4
|
|
std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 3.80 % 3.80 % 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 8.44 ns 8.44 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_median 8.57 ns 8.57 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.328 ns 0.328 ns 4
|
|
stringa s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 3.89 % 3.89 % 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 8.12 ns 8.12 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_median 8.22 ns 8.22 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.456 ns 0.456 ns 4
|
|
ssa s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 5.61 % 5.61 % 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_mean 8.81 ns 8.81 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_median 8.85 ns 8.85 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_stddev 0.387 ns 0.387 ns 4
|
|
lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>_cv 4.39 % 4.39 % 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 25.0 ns 25.0 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 25.3 ns 25.3 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 1.63 ns 1.63 ns 4
|
|
std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 6.54 % 6.54 % 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 10.6 ns 10.6 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 10.6 ns 10.6 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.026 ns 0.026 ns 4
|
|
std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 0.25 % 0.25 % 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 9.06 ns 9.06 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 9.07 ns 9.07 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.169 ns 0.169 ns 4
|
|
stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 1.87 % 1.87 % 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 8.03 ns 8.03 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 7.90 ns 7.90 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.468 ns 0.468 ns 4
|
|
ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 5.83 % 5.83 % 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_mean 8.60 ns 8.60 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_median 8.70 ns 8.70 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_stddev 0.374 ns 0.374 ns 4
|
|
lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>_cv 4.34 % 4.34 % 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 30.0 ns 30.0 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 28.7 ns 28.7 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 3.67 ns 3.67 ns 4
|
|
std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 12.25 % 12.25 % 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_mean 15.4 ns 15.4 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_median 15.5 ns 15.5 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_stddev 0.256 ns 0.256 ns 4
|
|
stringa s = " 123456789"; int res = s.to_int<int>; // Check overflow_cv 1.66 % 1.66 % 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_mean 15.1 ns 15.1 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_median 15.2 ns 15.2 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_stddev 0.342 ns 0.342 ns 4
|
|
ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflow_cv 2.26 % 2.26 % 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 72.4 ns 72.4 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 73.6 ns 73.6 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 4.42 ns 4.42 ns 4
|
|
std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 6.10 % 6.10 % 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 26.4 ns 26.4 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 26.2 ns 26.2 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 0.701 ns 0.701 ns 4
|
|
std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 2.66 % 2.66 % 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_mean 26.8 ns 26.8 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_median 26.6 ns 26.6 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.968 ns 0.968 ns 4
|
|
ssa s = "1234.567e10"; double res = *s.to_double()_cv 3.61 % 3.61 % 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 1533 ns 1533 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_median 1529 ns 1529 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 58.6 ns 58.6 ns 4
|
|
std::stringstream str; ... str << "abbaabbaabbaabba";_cv 3.82 % 3.82 % 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_mean 431 ns 431 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_median 426 ns 426 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_stddev 28.8 ns 28.8 ns 4
|
|
std::string str; ... str += "abbaabbaabbaabba";_cv 6.68 % 6.68 % 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 479 ns 479 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_median 473 ns 473 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 18.9 ns 18.9 ns 4
|
|
lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 3.95 % 3.95 % 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 319 ns 319 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_median 319 ns 319 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 19.0 ns 19.0 ns 4
|
|
lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 5.95 % 5.95 % 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 285 ns 285 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_median 293 ns 293 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 20.7 ns 20.7 ns 4
|
|
lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 7.27 % 7.27 % 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 146 ns 146 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 147 ns 147 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 4.19 ns 4.19 ns 4
|
|
lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 2.87 % 2.87 % 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 1500 ns 1500 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 1492 ns 1492 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 72.2 ns 72.2 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 4.81 % 4.81 % 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 1394 ns 1394 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_median 1415 ns 1415 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 69.4 ns 69.4 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 4.98 % 4.98 % 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 499 ns 499 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 500 ns 500 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 18.5 ns 18.5 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 3.70 % 3.70 % 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 434 ns 434 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 441 ns 441 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 58.6 ns 58.6 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 13.50 % 13.50 % 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 381 ns 381 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 387 ns 387 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 23.3 ns 23.3 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 6.10 % 6.10 % 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 269 ns 269 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 271 ns 271 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 13.6 ns 13.6 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 5.06 % 5.06 % 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 89645 ns 89646 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 88242 ns 88242 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 5804 ns 5804 ns 4
|
|
std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 6.47 % 6.47 % 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 91376 ns 91376 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 90959 ns 90959 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 2510 ns 2510 ns 4
|
|
std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.75 % 2.75 % 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 24896 ns 24896 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 24419 ns 24419 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 2547 ns 2547 ns 4
|
|
lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 10.23 % 10.23 % 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 21157 ns 21157 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 21111 ns 21111 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 629 ns 629 ns 4
|
|
lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.97 % 2.97 % 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 20898 ns 20898 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 21205 ns 21205 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1808 ns 1808 ns 4
|
|
lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 8.65 % 8.65 % 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 21053 ns 21053 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 21315 ns 21315 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1735 ns 1735 ns 4
|
|
lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 8.24 % 8.24 % 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 1457 ns 1457 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_median 1459 ns 1459 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_stddev 98.3 ns 98.3 ns 4
|
|
std::stringstream str; ... str << str_var1 << str_var2;_cv 6.75 % 6.75 % 4
|
|
std::string str; ... str += str_var1 + str_var2;_mean 1597 ns 1597 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_median 1605 ns 1605 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_stddev 52.9 ns 52.9 ns 4
|
|
std::string str; ... str += str_var1 + str_var2;_cv 3.31 % 3.31 % 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_mean 581 ns 581 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_median 584 ns 584 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_stddev 46.8 ns 46.8 ns 4
|
|
lstringa<16> str; ... str += str_var1 + str_var2;_cv 8.06 % 8.06 % 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_mean 488 ns 488 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_median 486 ns 486 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_stddev 47.1 ns 47.1 ns 4
|
|
lstringa<128> str; ... str += str_var1 + str_var2;_cv 9.66 % 9.66 % 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_mean 455 ns 455 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_median 468 ns 468 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_stddev 29.2 ns 29.2 ns 4
|
|
lstringa<512> str; ... str += str_var1 + str_var2;_cv 6.40 % 6.40 % 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_mean 347 ns 347 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_median 347 ns 347 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 13.7 ns 13.7 ns 4
|
|
lstringa<1024> str; ... str += str_var1 + str_var2;_cv 3.94 % 3.94 % 4
|
|
-- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::stringstream str; str << "test = " << k << " times";_mean 3363 ns 3363 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_median 3465 ns 3465 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_stddev 239 ns 239 ns 4
|
|
std::stringstream str; str << "test = " << k << " times";_cv 7.12 % 7.12 % 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_mean 489 ns 489 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_median 496 ns 496 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_stddev 25.6 ns 25.6 ns 4
|
|
std::string str = "test = " + std::to_string(k) + " times";_cv 5.23 % 5.23 % 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 1726 ns 1726 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 1719 ns 1719 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 34.7 ns 34.7 ns 4
|
|
char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 2.01 % 2.01 % 4
|
|
std::string str = std::format("test = {} times", k);_mean 1476 ns 1476 ns 4
|
|
std::string str = std::format("test = {} times", k);_median 1468 ns 1468 ns 4
|
|
std::string str = std::format("test = {} times", k);_stddev 38.6 ns 38.6 ns 4
|
|
std::string str = std::format("test = {} times", k);_cv 2.62 % 2.62 % 4
|
|
lstringa<8> str; str.format("test = {} times", k);_mean 1877 ns 1877 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_median 1904 ns 1904 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_stddev 121 ns 121 ns 4
|
|
lstringa<8> str; str.format("test = {} times", k);_cv 6.46 % 6.46 % 4
|
|
lstringa<32> str; str.format("test = {} times", k);_mean 1239 ns 1239 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_median 1215 ns 1215 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_stddev 58.2 ns 58.2 ns 4
|
|
lstringa<32> str; str.format("test = {} times", k);_cv 4.70 % 4.70 % 4
|
|
lstringa<8> str = "test = " + k + " times";_mean 353 ns 353 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_median 352 ns 352 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_stddev 6.76 ns 6.76 ns 4
|
|
lstringa<8> str = "test = " + k + " times";_cv 1.92 % 1.92 % 4
|
|
lstringa<32> str = "test = " + k + " times";_mean 188 ns 188 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_median 189 ns 189 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_stddev 5.16 ns 5.16 ns 4
|
|
lstringa<32> str = "test = " + k + " times";_cv 2.75 % 2.75 % 4
|
|
stringa str = "test = " + k + " times";_mean 180 ns 180 ns 4
|
|
stringa str = "test = " + k + " times";_median 180 ns 180 ns 4
|
|
stringa str = "test = " + k + " times";_stddev 4.59 ns 4.59 ns 4
|
|
stringa str = "test = " + k + " times";_cv 2.55 % 2.55 % 4
|
|
-- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
std::string::find + substr + std::strtol_mean 317 ns 317 ns 4
|
|
std::string::find + substr + std::strtol_median 316 ns 316 ns 4
|
|
std::string::find + substr + std::strtol_stddev 18.1 ns 18.1 ns 4
|
|
std::string::find + substr + std::strtol_cv 5.71 % 5.71 % 4
|
|
ssa::splitter + ssa::as_int_mean 143 ns 143 ns 4
|
|
ssa::splitter + ssa::as_int_median 141 ns 141 ns 4
|
|
ssa::splitter + ssa::as_int_stddev 3.55 ns 3.55 ns 4
|
|
ssa::splitter + ssa::as_int_cv 2.48 % 2.48 % 4
|
|
ssa::splitf + functor_mean 145 ns 145 ns 4
|
|
ssa::splitf + functor_median 144 ns 144 ns 4
|
|
ssa::splitf + functor_stddev 5.94 ns 5.94 ns 4
|
|
ssa::splitf + functor_cv 4.10 % 4.10 % 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 924 ns 924 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_median 922 ns 922 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_stddev 12.7 ns 12.7 ns 4
|
|
Naive (and wrong) replace symbols with std::string find + replace_cv 1.38 % 1.38 % 4
|
|
replace symbols with std::string find_first_of + replace_mean 2915 ns 2915 ns 4
|
|
replace symbols with std::string find_first_of + replace_median 2785 ns 2785 ns 4
|
|
replace symbols with std::string find_first_of + replace_stddev 303 ns 303 ns 4
|
|
replace symbols with std::string find_first_of + replace_cv 10.41 % 10.41 % 4
|
|
replace symbols with std::string_view find_first_of + copy_mean 1097 ns 1097 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_median 1114 ns 1114 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_stddev 50.9 ns 50.9 ns 4
|
|
replace symbols with std::string_view find_first_of + copy_cv 4.64 % 4.64 % 4
|
|
replace runtime symbols with string expressions and without remembering all search results_mean 1593 ns 1593 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_median 1584 ns 1584 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_stddev 84.2 ns 84.2 ns 4
|
|
replace runtime symbols with string expressions and without remembering all search results_cv 5.29 % 5.29 % 4
|
|
replace runtime symbols with simstr and memorization of all search results_mean 1176 ns 1176 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_median 1179 ns 1179 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_stddev 17.2 ns 17.2 ns 4
|
|
replace runtime symbols with simstr and memorization of all search results_cv 1.46 % 1.46 % 4
|
|
replace const symbols with string expressions and without remembering all search results_mean 1365 ns 1365 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_median 1365 ns 1365 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_stddev 34.9 ns 34.9 ns 4
|
|
replace const symbols with string expressions and without remembering all search results_cv 2.55 % 2.55 % 4
|
|
replace const symbols with string expressions and memorization of all search results_mean 988 ns 988 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_median 983 ns 983 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_stddev 29.9 ns 29.9 ns 4
|
|
replace const symbols with string expressions and memorization of all search results_cv 3.03 % 3.03 % 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 182 ns 182 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_median 178 ns 178 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_stddev 11.8 ns 11.8 ns 4
|
|
Short Naive (and wrong) replace symbols with std::string find + replace_cv 6.49 % 6.49 % 4
|
|
Short replace symbols with std::string find_first_of + replace_mean 332 ns 332 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_median 328 ns 328 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_stddev 13.9 ns 13.9 ns 4
|
|
Short replace symbols with std::string find_first_of + replace_cv 4.19 % 4.19 % 4
|
|
Short replace symbols with std::string_view find_first_of + copy_mean 189 ns 189 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_median 188 ns 188 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_stddev 8.75 ns 8.75 ns 4
|
|
Short replace symbols with std::string_view find_first_of + copy_cv 4.62 % 4.62 % 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_mean 214 ns 214 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_median 215 ns 215 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_stddev 6.43 ns 6.43 ns 4
|
|
Short replace runtime symbols with string expressions and without remembering all search results_cv 3.01 % 3.01 % 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_mean 214 ns 214 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_median 218 ns 218 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_stddev 8.01 ns 8.01 ns 4
|
|
Short replace runtime symbols with simstr and memorization of all search results_cv 3.73 % 3.73 % 4
|
|
Short replace const symbols with string expressions and without remembering all search results_mean 177 ns 177 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_median 179 ns 179 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_stddev 7.11 ns 7.11 ns 4
|
|
Short replace const symbols with string expressions and without remembering all search results_cv 4.02 % 4.02 % 4
|
|
Short replace const symbols with string expressions and memorization of all search results_mean 175 ns 175 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_median 176 ns 176 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_stddev 5.54 ns 5.54 ns 4
|
|
Short replace const symbols with string expressions and memorization of all search results_cv 3.17 % 3.17 % 4
|
|
----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
replace bb to ---- in std::string|64_mean 207 ns 207 ns 4
|
|
replace bb to ---- in std::string|64_median 209 ns 209 ns 4
|
|
replace bb to ---- in std::string|64_stddev 4.32 ns 4.32 ns 4
|
|
replace bb to ---- in std::string|64_cv 2.09 % 2.09 % 4
|
|
replace bb to ---- in std::string|256_mean 587 ns 587 ns 4
|
|
replace bb to ---- in std::string|256_median 579 ns 579 ns 4
|
|
replace bb to ---- in std::string|256_stddev 34.7 ns 34.7 ns 4
|
|
replace bb to ---- in std::string|256_cv 5.92 % 5.92 % 4
|
|
replace bb to ---- in std::string|512_mean 1121 ns 1121 ns 4
|
|
replace bb to ---- in std::string|512_median 1121 ns 1121 ns 4
|
|
replace bb to ---- in std::string|512_stddev 36.6 ns 36.6 ns 4
|
|
replace bb to ---- in std::string|512_cv 3.26 % 3.26 % 4
|
|
replace bb to ---- in std::string|1024_mean 2606 ns 2606 ns 4
|
|
replace bb to ---- in std::string|1024_median 2550 ns 2550 ns 4
|
|
replace bb to ---- in std::string|1024_stddev 181 ns 181 ns 4
|
|
replace bb to ---- in std::string|1024_cv 6.95 % 6.95 % 4
|
|
replace bb to ---- in std::string|2048_mean 6608 ns 6608 ns 4
|
|
replace bb to ---- in std::string|2048_median 6423 ns 6423 ns 4
|
|
replace bb to ---- in std::string|2048_stddev 576 ns 576 ns 4
|
|
replace bb to ---- in std::string|2048_cv 8.72 % 8.72 % 4
|
|
replace bb to ---- in lstringa<8>|64_mean 167 ns 167 ns 4
|
|
replace bb to ---- in lstringa<8>|64_median 169 ns 169 ns 4
|
|
replace bb to ---- in lstringa<8>|64_stddev 9.34 ns 9.34 ns 4
|
|
replace bb to ---- in lstringa<8>|64_cv 5.59 % 5.59 % 4
|
|
replace bb to ---- in lstringa<8>|256_mean 555 ns 555 ns 4
|
|
replace bb to ---- in lstringa<8>|256_median 557 ns 557 ns 4
|
|
replace bb to ---- in lstringa<8>|256_stddev 43.0 ns 43.0 ns 4
|
|
replace bb to ---- in lstringa<8>|256_cv 7.75 % 7.75 % 4
|
|
replace bb to ---- in lstringa<8>|512_mean 1029 ns 1029 ns 4
|
|
replace bb to ---- in lstringa<8>|512_median 1034 ns 1034 ns 4
|
|
replace bb to ---- in lstringa<8>|512_stddev 35.4 ns 35.4 ns 4
|
|
replace bb to ---- in lstringa<8>|512_cv 3.44 % 3.44 % 4
|
|
replace bb to ---- in lstringa<8>|1024_mean 2079 ns 2079 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_median 2094 ns 2094 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_stddev 77.7 ns 77.7 ns 4
|
|
replace bb to ---- in lstringa<8>|1024_cv 3.74 % 3.74 % 4
|
|
replace bb to ---- in lstringa<8>|2048_mean 3960 ns 3960 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_median 3982 ns 3982 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_stddev 132 ns 132 ns 4
|
|
replace bb to ---- in lstringa<8>|2048_cv 3.32 % 3.32 % 4
|
|
replace bb to ---- by init stringa|64_mean 116 ns 116 ns 4
|
|
replace bb to ---- by init stringa|64_median 117 ns 117 ns 4
|
|
replace bb to ---- by init stringa|64_stddev 3.42 ns 3.42 ns 4
|
|
replace bb to ---- by init stringa|64_cv 2.95 % 2.95 % 4
|
|
replace bb to ---- by init stringa|256_mean 334 ns 334 ns 4
|
|
replace bb to ---- by init stringa|256_median 338 ns 338 ns 4
|
|
replace bb to ---- by init stringa|256_stddev 8.35 ns 8.35 ns 4
|
|
replace bb to ---- by init stringa|256_cv 2.50 % 2.50 % 4
|
|
replace bb to ---- by init stringa|512_mean 826 ns 826 ns 4
|
|
replace bb to ---- by init stringa|512_median 825 ns 825 ns 4
|
|
replace bb to ---- by init stringa|512_stddev 17.6 ns 17.6 ns 4
|
|
replace bb to ---- by init stringa|512_cv 2.13 % 2.13 % 4
|
|
replace bb to ---- by init stringa|1024_mean 1816 ns 1816 ns 4
|
|
replace bb to ---- by init stringa|1024_median 1829 ns 1829 ns 4
|
|
replace bb to ---- by init stringa|1024_stddev 35.0 ns 35.0 ns 4
|
|
replace bb to ---- by init stringa|1024_cv 1.93 % 1.93 % 4
|
|
replace bb to ---- by init stringa|2048_mean 3707 ns 3707 ns 4
|
|
replace bb to ---- by init stringa|2048_median 3712 ns 3712 ns 4
|
|
replace bb to ---- by init stringa|2048_stddev 113 ns 113 ns 4
|
|
replace bb to ---- by init stringa|2048_cv 3.05 % 3.05 % 4
|
|
----- Replace All Str To Same Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
replace bb to -- in std::string|64_mean 144 ns 144 ns 4
|
|
replace bb to -- in std::string|64_median 144 ns 144 ns 4
|
|
replace bb to -- in std::string|64_stddev 4.80 ns 4.80 ns 4
|
|
replace bb to -- in std::string|64_cv 3.34 % 3.34 % 4
|
|
replace bb to -- in std::string|256_mean 458 ns 458 ns 4
|
|
replace bb to -- in std::string|256_median 455 ns 455 ns 4
|
|
replace bb to -- in std::string|256_stddev 17.5 ns 17.5 ns 4
|
|
replace bb to -- in std::string|256_cv 3.82 % 3.82 % 4
|
|
replace bb to -- in std::string|512_mean 803 ns 803 ns 4
|
|
replace bb to -- in std::string|512_median 793 ns 793 ns 4
|
|
replace bb to -- in std::string|512_stddev 22.7 ns 22.7 ns 4
|
|
replace bb to -- in std::string|512_cv 2.83 % 2.83 % 4
|
|
replace bb to -- in std::string|1024_mean 1544 ns 1544 ns 4
|
|
replace bb to -- in std::string|1024_median 1536 ns 1536 ns 4
|
|
replace bb to -- in std::string|1024_stddev 25.9 ns 25.9 ns 4
|
|
replace bb to -- in std::string|1024_cv 1.67 % 1.68 % 4
|
|
replace bb to -- in std::string|2048_mean 3265 ns 3265 ns 4
|
|
replace bb to -- in std::string|2048_median 3271 ns 3271 ns 4
|
|
replace bb to -- in std::string|2048_stddev 102 ns 102 ns 4
|
|
replace bb to -- in std::string|2048_cv 3.14 % 3.14 % 4
|
|
replace bb to -- in lstringa<8>|64_mean 116 ns 116 ns 4
|
|
replace bb to -- in lstringa<8>|64_median 114 ns 114 ns 4
|
|
replace bb to -- in lstringa<8>|64_stddev 8.03 ns 8.03 ns 4
|
|
replace bb to -- in lstringa<8>|64_cv 6.95 % 6.95 % 4
|
|
replace bb to -- in lstringa<8>|256_mean 328 ns 328 ns 4
|
|
replace bb to -- in lstringa<8>|256_median 327 ns 327 ns 4
|
|
replace bb to -- in lstringa<8>|256_stddev 6.32 ns 6.32 ns 4
|
|
replace bb to -- in lstringa<8>|256_cv 1.92 % 1.92 % 4
|
|
replace bb to -- in lstringa<8>|512_mean 643 ns 643 ns 4
|
|
replace bb to -- in lstringa<8>|512_median 636 ns 636 ns 4
|
|
replace bb to -- in lstringa<8>|512_stddev 31.2 ns 31.2 ns 4
|
|
replace bb to -- in lstringa<8>|512_cv 4.85 % 4.85 % 4
|
|
replace bb to -- in lstringa<8>|1024_mean 1242 ns 1242 ns 4
|
|
replace bb to -- in lstringa<8>|1024_median 1227 ns 1227 ns 4
|
|
replace bb to -- in lstringa<8>|1024_stddev 50.7 ns 50.7 ns 4
|
|
replace bb to -- in lstringa<8>|1024_cv 4.08 % 4.08 % 4
|
|
replace bb to -- in lstringa<8>|2048_mean 2353 ns 2354 ns 4
|
|
replace bb to -- in lstringa<8>|2048_median 2368 ns 2368 ns 4
|
|
replace bb to -- in lstringa<8>|2048_stddev 146 ns 146 ns 4
|
|
replace bb to -- in lstringa<8>|2048_cv 6.22 % 6.22 % 4
|
|
replace bb to -- by init stringa|64_mean 110 ns 110 ns 4
|
|
replace bb to -- by init stringa|64_median 110 ns 110 ns 4
|
|
replace bb to -- by init stringa|64_stddev 2.36 ns 2.36 ns 4
|
|
replace bb to -- by init stringa|64_cv 2.15 % 2.15 % 4
|
|
replace bb to -- by init stringa|256_mean 295 ns 295 ns 4
|
|
replace bb to -- by init stringa|256_median 293 ns 293 ns 4
|
|
replace bb to -- by init stringa|256_stddev 10.0 ns 10.0 ns 4
|
|
replace bb to -- by init stringa|256_cv 3.41 % 3.41 % 4
|
|
replace bb to -- by init stringa|512_mean 558 ns 558 ns 4
|
|
replace bb to -- by init stringa|512_median 558 ns 558 ns 4
|
|
replace bb to -- by init stringa|512_stddev 16.2 ns 16.2 ns 4
|
|
replace bb to -- by init stringa|512_cv 2.90 % 2.90 % 4
|
|
replace bb to -- by init stringa|1024_mean 1142 ns 1142 ns 4
|
|
replace bb to -- by init stringa|1024_median 1136 ns 1136 ns 4
|
|
replace bb to -- by init stringa|1024_stddev 68.1 ns 68.1 ns 4
|
|
replace bb to -- by init stringa|1024_cv 5.97 % 5.97 % 4
|
|
replace bb to -- by init stringa|2048_mean 2076 ns 2076 ns 4
|
|
replace bb to -- by init stringa|2048_median 2076 ns 2076 ns 4
|
|
replace bb to -- by init stringa|2048_stddev 26.9 ns 26.9 ns 4
|
|
replace bb to -- by init stringa|2048_cv 1.29 % 1.29 % 4
|
|
----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
hashStrMapA<size_t> emplace & find stringa;_mean 4503107 ns 4503124 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_median 4514039 ns 4514052 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_stddev 252332 ns 252334 ns 4
|
|
hashStrMapA<size_t> emplace & find stringa;_cv 5.60 % 5.60 % 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_mean 4213379 ns 4213391 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_median 4259591 ns 4259601 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_stddev 180301 ns 180299 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string;_cv 4.28 % 4.28 % 4
|
|
hashStrMapA<size_t> emplace & find ssa;_mean 4560080 ns 4560101 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_median 4547786 ns 4547804 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_stddev 215720 ns 215719 ns 4
|
|
hashStrMapA<size_t> emplace & find ssa;_cv 4.73 % 4.73 % 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_mean 5115138 ns 5115158 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_median 5134814 ns 5134833 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_stddev 345313 ns 345308 ns 4
|
|
std::unordered_map<std::string, size_t> emplace & find std::string_view;_cv 6.75 % 6.75 % 4
|
|
----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000
|
|
Build func full name std::string;_mean 1092 ns 1092 ns 4
|
|
Build func full name std::string;_median 1088 ns 1088 ns 4
|
|
Build func full name std::string;_stddev 96.0 ns 96.0 ns 4
|
|
Build func full name std::string;_cv 8.79 % 8.79 % 4
|
|
Build func full name std::string 1;_mean 1171 ns 1171 ns 4
|
|
Build func full name std::string 1;_median 1187 ns 1187 ns 4
|
|
Build func full name std::string 1;_stddev 105 ns 105 ns 4
|
|
Build func full name std::string 1;_cv 8.98 % 8.98 % 4
|
|
Build func full name std::stream;_mean 2921 ns 2921 ns 4
|
|
Build func full name std::stream;_median 2894 ns 2894 ns 4
|
|
Build func full name std::stream;_stddev 222 ns 222 ns 4
|
|
Build func full name std::stream;_cv 7.60 % 7.60 % 4
|
|
Build func full name stringa;_mean 552 ns 552 ns 4
|
|
Build func full name stringa;_median 556 ns 556 ns 4
|
|
Build func full name stringa;_stddev 23.4 ns 23.4 ns 4
|
|
Build func full name stringa;_cv 4.24 % 4.24 % 4
|
|
Build func full name stringa 1;_mean 746 ns 746 ns 4
|
|
Build func full name stringa 1;_median 736 ns 736 ns 4
|
|
Build func full name stringa 1;_stddev 42.7 ns 42.7 ns 4
|
|
Build func full name stringa 1;_cv 5.72 % 5.72 % 4
|