diff --git a/bench/CMakeLists.txt b/bench/CMakeLists.txt index 3e419a6..bedc2fd 100644 --- a/bench/CMakeLists.txt +++ b/bench/CMakeLists.txt @@ -14,7 +14,14 @@ FetchContent_Declare( ) FetchContent_MakeAvailable(fmt) -target_link_libraries(benchStr fmt::fmt) +FetchContent_Declare( + stringzilla + GIT_REPOSITORY https://github.com/ashvardanian/StringZilla.git + GIT_TAG main # or specify a version tag +) +FetchContent_MakeAvailable(stringzilla) + +target_link_libraries(benchStr fmt::fmt stringzilla_header) add_executable(process_result process_result.cpp) target_link_libraries(process_result simstr_simstr) diff --git a/bench/bench_str.cpp b/bench/bench_str.cpp index 2f28968..7eb19e0 100644 --- a/bench/bench_str.cpp +++ b/bench/bench_str.cpp @@ -5,6 +5,8 @@ * (c) Project "SimStr", Aleksandr Orefkov orefkov@gmail.com * Benchmarks */ +#include +#include #include "bench.h" #include @@ -50,9 +52,131 @@ static void DoTeardown(const benchmark::State& state) { #define LONG_TEXT "123456789012345678901234567890" #define TEXT_16 "abbaabbaabbaabba" -#define CHECK_RESULT +//#define CHECK_RESULT void __(benchmark::State& state) { for (auto _: state) {} } +namespace sz = ashvardanian::stringzilla; + +sz::string email_concat_stringzilla_app(sz::string name, sz::string_view domain, sz::string_view tld) { + return name.append("@").append(domain).append(".").append(tld); +} + +//> sz::string email_concat_stringzilla_app(sz::string name, sz::string_view domain, sz::string_view tld) { +void ConcatEmailSzApp(benchmark::State& state) { + sz::string name = "username"; + sz::string_view domain = "verybigdomain", tld = "tld"; + for (auto _: state) { + benchmark::DoNotOptimize(name); + benchmark::DoNotOptimize(domain); + benchmark::DoNotOptimize(tld); + auto email = email_concat_stringzilla_app(name, domain, tld); + benchmark::DoNotOptimize(email); + } +} + +sz::string email_concat_stringzilla_exp(sz::string name, sz::string_view domain, sz::string_view tld) { + return sz::string{name | sz::string_view{"@"} | domain | sz::string_view{"."} | tld}; +} + +//> sz::string email_concat_stringzilla_exp(sz::string name, sz::string_view domain, sz::string_view tld) { +void ConcatEmailSzExp(benchmark::State& state) { + sz::string name = "username"; + sz::string_view domain = "verybigdomain", tld = "tld"; + for (auto _: state) { + benchmark::DoNotOptimize(name); + benchmark::DoNotOptimize(domain); + benchmark::DoNotOptimize(tld); + auto email = email_concat_stringzilla_exp(name, domain, tld); + benchmark::DoNotOptimize(email); + } +} + +std::string email_concat_format(std::string_view name, std::string_view domain, std::string_view tld) { + return std::format("{}@{}.{}", name, domain, tld); +} +//> std::string email_concat_format(std::string_view name, std::string_view domain, std::string_view tld) { +void ConcatEmailFormat(benchmark::State& state) { + std::string_view name = "username", domain = "verybigdomain", tld = "tld"; + for (auto _: state) { + benchmark::DoNotOptimize(name); + benchmark::DoNotOptimize(domain); + benchmark::DoNotOptimize(tld); + auto email = email_concat_format(name, domain, tld); + benchmark::DoNotOptimize(email); + } +} + +std::string email_concat_stream(std::string_view name, std::string_view domain, std::string_view tld) { + std::stringstream s; + s << name << "@" << domain << "." << tld; + return s.str(); +} +//> std::string email_concat_stream(std::string_view name, std::string_view domain, std::string_view tld) { +void ConcatEmailStream(benchmark::State& state) { + std::string_view name = "username", domain = "verybigdomain", tld = "tld"; + for (auto _: state) { + benchmark::DoNotOptimize(name); + benchmark::DoNotOptimize(domain); + benchmark::DoNotOptimize(tld); + auto email = email_concat_stream(name, domain, tld); + benchmark::DoNotOptimize(email); + } +} + +std::string email_concat_std(std::string name, std::string_view domain, std::string_view tld) { + return name.append("@").append(domain).append(".").append(tld); +} +//> std::string email_concat_std(std::string name, std::string_view domain, std::string_view tld) { +void ConcatEmailStd(benchmark::State& state) { + std::string name = "username"; + std::string_view domain = "verybigdomain", tld = "tld"; + for (auto _: state) { + benchmark::DoNotOptimize(name); + benchmark::DoNotOptimize(domain); + benchmark::DoNotOptimize(tld); + auto email = email_concat_std(name, domain, tld); + benchmark::DoNotOptimize(email); + } +} + +std::string email_concat_std_expr(std::string_view name, std::string_view domain, std::string_view tld) { + return +name + "@" + domain + "." + tld; +} +//> std::string email_concat_std_expr(std::string_view name, std::string_view domain, std::string_view tld) { +void ConcatEmailStdExp(benchmark::State& state) { + std::string_view name = "username", domain = "verybigdomain", tld = "tld"; + for (auto _: state) { + benchmark::DoNotOptimize(name); + benchmark::DoNotOptimize(domain); + benchmark::DoNotOptimize(tld); + auto email = email_concat_std_expr(name, domain, tld); + benchmark::DoNotOptimize(email); + } +} + +stringa email_concat_sim_expr(ssa name, ssa domain, ssa tld) { + return name + "@" + domain + "." + tld; +} +//> stringa email_concat_sim_expr(ssa name, ssa domain, ssa tld) { +void ConcatEmailSimExp(benchmark::State& state) { + ssa name = "username", domain = "verybigdomain", tld = "tld"; + for (auto _: state) { + benchmark::DoNotOptimize(name); + benchmark::DoNotOptimize(domain); + benchmark::DoNotOptimize(tld); + auto email = email_concat_sim_expr(name, domain, tld); + benchmark::DoNotOptimize(email); + } +} + +BENCHMARK(__)->Name("----- Concatenate email ---------")->Repetitions(1); +BENCHMARK(ConcatEmailFormat)->Name("Concat email std::format"); +BENCHMARK(ConcatEmailStream)->Name("Concat email std::stringstream"); +BENCHMARK(ConcatEmailSzApp) ->Name("Concat email stringzilla append"); +BENCHMARK(ConcatEmailSzExp) ->Name("Concat email stringzilla concat"); +BENCHMARK(ConcatEmailStd) ->Name("Concat email std::string append"); +BENCHMARK(ConcatEmailStdExp)->Name("Concat email std::string by strexpr"); +BENCHMARK(ConcatEmailSimExp)->Name("Concat email stringa"); void ConcatStdToStd(benchmark::State& state) { std::string s1 = "start "; @@ -355,6 +479,10 @@ size_t find_pos_sim(ssa src, ssa name) { return src.find(lstringa<200>{"\n- " + name + " -\n"}); } +size_t find_pos_sz(sz::string_view src, sz::string_view name) { + return src.find(sz::string{"\n- "}.append(name).append(" -\n")); +} + //> size_t find_pos_str(std::string_view src, std::string_view name) { void FindConcatThreeStr(benchmark::State& state) { std::string_view src = "sdfsdf\n- testtesttesttesttesttesttestte -\nsfrgdgfsg"; @@ -405,11 +533,27 @@ void FindConcatThreeSim(benchmark::State& state) { #endif } } - +//> size_t find_pos_sz(sz::string_view src, sz::string_view name) { +void FindConcatThreeSz(benchmark::State& state) { + sz::string_view src = "sdfsdf\n- testtesttesttesttesttesttestte -\nsfrgdgfsg"; + sz::string_view fnd = "testtesttesttesttesttesttestte"; + for (auto _: state) { + benchmark::DoNotOptimize(src); + benchmark::DoNotOptimize(fnd); + size_t pos = find_pos_sz(src, fnd); + benchmark::DoNotOptimize(pos); + #ifdef CHECK_RESULT + if (pos != 6) { + state.SkipWithError("fail"); + } + #endif + } +} BENCHMARK(__)->Name("----- Find three concatenated string in string_view -----")->Repetitions(1); BENCHMARK(FindConcatThreeStr)->Name("Find concat three std::string"); BENCHMARK(FindConcatThreeExp)->Name("Find concat three strexpr"); BENCHMARK(FindConcatThreeSim)->Name("Find concat three simstr"); +BENCHMARK(FindConcatThreeSz) ->Name("Find concat three stringzilla string"); std::string buildTypeNameStr(std::string_view type_name, size_t prec, size_t scale) { std::string res{type_name}; @@ -631,6 +775,7 @@ void Find(benchmark::State& state) { } } BENCHMARK(__)->Name("----- Find 9 symbols text in end of 99 symbols text ---------")->Repetitions(1); +BENCHMARK(Find)->Name("sz::string::find;"); BENCHMARK(Find) ->Name("std::string::find;"); BENCHMARK(Find) ->Name("std::string_view::find;"); BENCHMARK(Find) ->Name("ssa::find;"); @@ -1811,7 +1956,7 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { lstringa<2048> big_source{Count, source}, big_sample{Count, sample}; for (auto _: state) { - stringa result = e_repl(big_source.to_str(), "bb", "----"); + stringa result = e_repl(big_source, "bb", "----"); #ifdef CHECK_RESULT if (result.to_str() != big_sample) { diff --git a/bench/comments.txt b/bench/comments.txt index 722105e..724d19b 100644 --- a/bench/comments.txt +++ b/bench/comments.txt @@ -8,12 +8,22 @@ holds 23 characters in SSO instead of 15, so at the end of the std::string test, memory has to be allocated, while in stringa , the entire test is included in SSO. +- Concat email stringzilla concat +В stringzilla тоже есть конкатенация строковыми выражениями, но не +так удобна и развита, как в simstr. +Stringzilla also has concatenation by expression templates, +but it's not as convenient or advanced as simstr. + - Find concat three simstr Если результат конкатенации меньше 207 символов, он собирается в буфере на стеке, без аллокации и деалокации. If the concatenation result is less than 207 characters, it is collected in a stack-based buffer, without allocation or deallocation. +- sz::string::find; +stringzilla более заточена на поиск больших строк в больших строках. +stringzilla is more focused on searching large strings within large strings. + - Concat with replace exp В simstr строковое выражение для замены подстрок есть "из коробки". diff --git a/bench/results.html b/bench/results.html index 9a524f1..40b49a3 100644 --- a/bench/results.html +++ b/bench/results.html @@ -275,14 +275,14 @@ L1 Instruction 32 KiB (x16) L2 Unified 256 KiB (x16) L3 Unified 40960 KiB (x1) -Load Average: 0.00, 0.00, 0.00 +Load Average: 0.43, 0.77, 0.52 ***WARNING*** ASLR is enabled, the results may have unreproducible noise in them. Include in charts:
  • Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-1332 X 2494.22 MHz CPU sCPU Caches: L1 Data 32 KiB (x16) L1 Instruction 32 KiB (x16) L2 Unified 256 KiB (x16) L3 Unified 40960 KiB (x1) -Load Average: 0.19, 0.64, 0.48 +Load Average: 0.00, 0.00, 0.00 ***WARNING*** ASLR is enabled, the results may have unreproducible noise in them. Include in charts:
  • Xeon E5-2682 v4, Windows 10, Clang-1932 X 2494 MHz CPU sCPU Caches: L1 Data 32 KiB (x16) @@ -299,9 +299,47 @@ Load Average: 0.19, 0.64, 0.48 -

    # Concatenate string + Number + "Literal"

    +

    # Concatenate email

    - + + + + + + +
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Concat std::string and number by std to std::stringvoid ConcatStdToStd(benchmark::State& state) { +
    Concat email std::formatstd::string email_concat_format(std::string_view name, std::string_view domain, std::string_view tld) { + return std::format("{}@{}.{}", name, domain, tld); +}163177203259964
    Concat email std::stringstreamstd::string email_concat_stream(std::string_view name, std::string_view domain, std::string_view tld) { + std::stringstream s; + s << name << "@" << domain << "." << tld; + return s.str(); +}3223287928982458
    Concat email stringzilla appendsz::string email_concat_stringzilla_app(sz::string name, sz::string_view domain, sz::string_view tld) { + return name.append("@").append(domain).append(".").append(tld); +}133115268282594
    Concat email stringzilla concatsz::string email_concat_stringzilla_exp(sz::string name, sz::string_view domain, sz::string_view tld) { + return sz::string{name | sz::string_view{"@"} | domain | sz::string_view{"."} | tld}; +} >> В stringzilla тоже есть конкатенация строковыми выражениями, но не +так удобна и развита, как в simstr. +Stringzilla also has concatenation by expression templates, +but it's not as convenient or advanced as simstr.54.948.3126131213
    Concat email std::string appendstd::string email_concat_std(std::string name, std::string_view domain, std::string_view tld) { + return name.append("@").append(domain).append(".").append(tld); +}72.196.7189198623
    Concat email std::string by strexprstd::string email_concat_std_expr(std::string_view name, std::string_view domain, std::string_view tld) { + return +name + "@" + domain + "." + tld; +}44.333.5108106158
    Concat email stringastringa email_concat_sim_expr(ssa name, ssa domain, ssa tld) { + return name + "@" + domain + "." + tld; +}39.940.392.7103124
    + +

    # Concatenate string + Number + "Literal"

    + + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Concat std::string and number by std to std::stringvoid ConcatStdToStd(benchmark::State& state) { std::string s1 = "start "; for (auto _: state) { for (int i = 1; i <= 100'000; i *= 10) { @@ -310,8 +348,8 @@ Load Average: 0.19, 0.64, 0.48 benchmark::DoNotOptimize(str); } } -}2112022723191035
    Concat std::string and number by StrExpr to std::stringvoid ConcatSimToStd(benchmark::State& state) { +}2142242733201831
    Concat std::string and number by StrExpr to std::stringvoid ConcatSimToStd(benchmark::State& state) { std::string s1 = "start "; for (auto _: state) { for (int i = 1; i <= 100'000; i *= 10) { @@ -320,8 +358,8 @@ Load Average: 0.19, 0.64, 0.48 benchmark::DoNotOptimize(str); } } -}102101154207505
    Concat stringa and number by StrExpr to simstr::stringavoid ConcatSimToSim(benchmark::State& state) { +}103100152212947
    Concat stringa and number by StrExpr to simstr::stringavoid ConcatSimToSim(benchmark::State& state) { stra s1 = "start "; for (auto _: state) { for (int i = 1; i <= 100'000; i *= 10) { @@ -337,8 +375,8 @@ Load Average: 0.19, 0.64, 0.48 Unlike std::string, stringa holds 23 characters in SSO instead of 15, so at the end of the std::string test, memory has to be allocated, -while in stringa , the entire test is included in SSO.63.172.168.4106224
    Concat stringa and number by e_concat to simstr::stringavoid ConcatSimToSimConcat(benchmark::State& state) { +while in stringa , the entire test is included in SSO.63.072.870.1107354
    Concat stringa and number by e_concat to simstr::stringavoid ConcatSimToSimConcat(benchmark::State& state) { stra s1 = "start "; for (auto _: state) { for (int i = 1; i <= 100'000; i *= 10) { @@ -347,17 +385,17 @@ while in stringa , the entire test is included in SSO.69.575.973.2116224
    -

    # Concatenate string + Hex Number + "Literal"

    +

    # Concatenate string + Hex Number + "Literal"

    - - + - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Concat std::string and format hex number and literal to std::stringvoid ConcatStdToFmtHex(benchmark::State& state) { +
    Concat std::string and format hex number and literal to std::stringvoid ConcatStdToFmtHex(benchmark::State& state) { // We use a short string so that the longest result is 15 characters and fits in the std::string SSO buffer. std::string s1 = "art "; for (auto _: state) { @@ -368,8 +406,8 @@ while in stringa , the entire test is included in SSO.68065172410202034
    std::format std::string and hex number by literal to std::stringvoid ConcatAllFmtToHex(benchmark::State& state) { +}65471270510443883
    std::format std::string and hex number by literal to std::stringvoid ConcatAllFmtToHex(benchmark::State& state) { // We use a short string so that the longest result is 15 characters and fits in the std::string SSO buffer. std::string s1 = "art "; for (auto _: state) { @@ -380,8 +418,8 @@ while in stringa , the entire test is included in SSO.865922150518352519
    Concat std::string and std::to_chars and string to std::stringvoid ConcatStdToCharsHex(benchmark::State& state) { +}874969146218324986
    Concat std::string and std::to_chars and string to std::stringvoid ConcatStdToCharsHex(benchmark::State& state) { // We use a short string so that the longest result is 15 characters and fits in the std::string SSO buffer. std::string s1 = "art "; for (auto _: state) { @@ -394,8 +432,8 @@ while in stringa , the entire test is included in SSO.198176194248617
    Concat std::string and hex number and literal by StrExpr to std::stringvoid ConcatSimToStdHex(benchmark::State& state) { +}1962521892531124
    Concat std::string and hex number and literal by StrExpr to std::stringvoid ConcatSimToStdHex(benchmark::State& state) { // We use a short string so that the longest result is 15 characters and fits in the std::string SSO buffer. std::string s1 = "art "; for (auto _: state) { @@ -406,8 +444,8 @@ while in stringa , the entire test is included in SSO.13112579.4116473
    Concat stringa and hex number and literal by StrExpr to simstr::stringavoid ConcatSimToSimHex(benchmark::State& state) { +}13112487.4115873
    Concat stringa and hex number and literal by StrExpr to simstr::stringavoid ConcatSimToSimHex(benchmark::State& state) { // stringa SSO buffer is 23, but we use a short string to compare under the same conditions stra s1 = "art "; for (auto _: state) { @@ -418,8 +456,8 @@ while in stringa , the entire test is included in SSO.11512073.6101184
    Concat stringa and hex number and literal by e_concat to simstr::stringavoid ConcatSimToSimHexC(benchmark::State& state) { +}11512077.799.3257
    Concat stringa and hex number and literal by e_concat to simstr::stringavoid ConcatSimToSimHexC(benchmark::State& state) { // stringa SSO buffer is 23, but we use a short string to compare under the same conditions stra s1 = "art "; for (auto _: state) { @@ -430,8 +468,8 @@ while in stringa , the entire test is included in SSO.12112480.7106190
    Subst stringa and hex number by e_subst literal to simstr::stringavoid ConcatSimToSimHexS(benchmark::State& state) { +}12212676.3106269
    Subst stringa and hex number by e_subst literal to simstr::stringavoid ConcatSimToSimHexS(benchmark::State& state) { // stringa SSO buffer is 23, but we use a short string to compare under the same conditions stra s1 = "art "; for (auto _: state) { @@ -441,8 +479,8 @@ while in stringa , the entire test is included in SSO.183167148172333
    Subst stringa and hex number by e_vsubst stra to simstr::stringavoid ConcatSimToSimHexVS(benchmark::State& state) { +}180164152171541
    Subst stringa and hex number by e_vsubst stra to simstr::stringavoid ConcatSimToSimHexVS(benchmark::State& state) { // stringa SSO buffer is 23, but we use a short string to compare under the same conditions stra s1 = "art "; for (auto _: state) { @@ -452,37 +490,37 @@ while in stringa , the entire test is included in SSO.308296286355833
    -

    # format/vformat and subst/vsubst octal number to 32 symbols result

    +

    # format/vformat and subst/vsubst octal number to 32 symbols result

    - - + - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    "abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"void ConcatSimToSimOct(benchmark::State& state) { +
    "abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"void ConcatSimToSimOct(benchmark::State& state) { for (auto _: state) { for (unsigned i = 1; i <= 100'000; i *= 10) { stringa str = "abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"; benchmark::DoNotOptimize(str); } } -}276339669681380
    e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)void SubstSimToSimOct(benchmark::State& state) { +}280266660698843
    e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)void SubstSimToSimOct(benchmark::State& state) { for (auto _: state) { for (unsigned i = 1; i <= 100'000; i *= 10) { stringa str = e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt); benchmark::DoNotOptimize(str); } } -}354320745787580
    e_vsubst(pattern, i / 0x8a010_fmt)void VSubstSimToSimOct(benchmark::State& state) { +}3413247788131112
    e_vsubst(pattern, i / 0x8a010_fmt)void VSubstSimToSimOct(benchmark::State& state) { ssa pattern = "abcdefghihklmopqr {} end"; for (auto _: state) { for (unsigned i = 1; i <= 100'000; i *= 10) { @@ -490,16 +528,16 @@ while in stringa , the entire test is included in SSO.618582103611281424
    fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)void FmtFormatComp(benchmark::State& state) { +}599583106111182885
    fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)void FmtFormatComp(benchmark::State& state) { for (auto _: state) { for (unsigned i = 1; i <= 100'000; i *= 10) { std::string str = fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i); benchmark::DoNotOptimize(str); } } -}882727140515762133
    fmt::format("abcdefghihklmopqr {:#010o} end", i)void FmtFormat(benchmark::State& state) { +}676785140415504562
    fmt::format("abcdefghihklmopqr {:#010o} end", i)void FmtFormat(benchmark::State& state) { for (auto _: state) { for (unsigned i = 1; i <= 100'000; i *= 10) { std::string str = fmt::format("abcdefghihklmopqr {:#010o} end", i); @@ -507,16 +545,16 @@ while in stringa , the entire test is included in SSO.819786133114322874
    std::format("abcdefghihklmopqr {:#010o} end", i)void FormatStdToStdOct(benchmark::State& state) { +}832827135514314550
    std::format("abcdefghihklmopqr {:#010o} end", i)void FormatStdToStdOct(benchmark::State& state) { for (auto _: state) { for (unsigned i = 1; i <= 100'000; i *= 10) { std::string str = std::format("abcdefghihklmopqr {:#010o} end", i); benchmark::DoNotOptimize(str); } } -}9521222154019042951
    std::vformat(pattern, std::make_format_args(i))void VFormatStdToStdOct(benchmark::State& state) { +}10071224154219235661
    std::vformat(pattern, std::make_format_args(i))void VFormatStdToStdOct(benchmark::State& state) { std::string_view pattern = "abcdefghihklmopqr {:#010o} end"; for (auto _: state) { for (unsigned i = 1; i <= 100'000; i *= 10) { @@ -524,8 +562,8 @@ while in stringa , the entire test is included in SSO.9571143160819323034
    strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"void StreamStdToStdOct(benchmark::State& state) { +}10011100154919415730
    strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"void StreamStdToStdOct(benchmark::State& state) { for (auto _: state) { for (unsigned i = 1; i <= 100'000; i *= 10) { std::stringstream strm; @@ -534,21 +572,21 @@ while in stringa , the entire test is included in SSO.20192092643576518267
    -

    # Concatenate string + "Literal"

    +

    # Concatenate string + "Literal"

    - - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Concat std::string by std to std::stringvoid ConcatStdToStdS(benchmark::State& state) { +
    Concat std::string by std to std::stringvoid ConcatStdToStdS(benchmark::State& state) { std::string s1 = "start "; for (auto _: state) { for (int i = 1; i <= 100'000; i *= 10) { @@ -557,8 +595,8 @@ while in stringa , the entire test is included in SSO.45.149.839.660.5104
    Concat std::string by StrExpr to std::stringvoid ConcatSimToStdS(benchmark::State& state) { +}49.052.341.555.6143
    Concat std::string by StrExpr to std::stringvoid ConcatSimToStdS(benchmark::State& state) { std::string s1 = "start "; for (auto _: state) { for (int i = 1; i <= 100'000; i *= 10) { @@ -567,8 +605,8 @@ while in stringa , the entire test is included in SSO.34.830.341.179.0119
    Concat stringa by StrExpr to stringavoid ConcatSimToSimS(benchmark::State& state) { +}39.934.138.681.8168
    Concat stringa by StrExpr to stringavoid ConcatSimToSimS(benchmark::State& state) { stra s1 = "start "; for (auto _: state) { for (int i = 1; i <= 100'000; i *= 10) { @@ -577,37 +615,41 @@ while in stringa , the entire test is included in SSO.28.326.628.551.195.1
    -

    # Find three concatenated string in string_view

    +

    # Find three concatenated string in string_view

    - - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Find concat three std::stringsize_t find_pos_str(std::string_view src, std::string_view name) { +
    Find concat three std::stringsize_t find_pos_str(std::string_view src, std::string_view name) { // before C++26 we can not concatenate string and string_view... return src.find("\n- "s + std::string{name} + " -\n"); -}111192200244217
    Find concat three strexprsize_t find_pos_exp(ssa src, ssa name) { +}110137205228542
    Find concat three strexprsize_t find_pos_exp(ssa src, ssa name) { return src.find(std::string{"\n- " + name + " -\n"}); -}49.241.1116121107
    Find concat three simstrsize_t find_pos_sim(ssa src, ssa name) { +}51.538.1118132294
    Find concat three simstrsize_t find_pos_sim(ssa src, ssa name) { return src.find(lstringa<200>{"\n- " + name + " -\n"}); } >> Если результат конкатенации меньше 207 символов, он собирается в буфере на стеке, без аллокации и деалокации. If the concatenation result is less than 207 characters, -it is collected in a stack-based buffer, without allocation or deallocation.19.119.528.229.061.5
    -

    # Build Type Name

    +

    # Build Type Name

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    BuildTypeNameStr 0/0std::string buildTypeNameStr(std::string_view type_name, size_t prec, size_t scale) { +
    BuildTypeNameStr 0/0std::string buildTypeNameStr(std::string_view type_name, size_t prec, size_t scale) { std::string res{type_name}; if (prec) { res += "(" + std::to_string(prec); @@ -617,20 +659,20 @@ it is collected in a stack-based buffer, without allocation or deallocation.7.0210.17.9817.321.3
    BuildTypeNameExp 0/0std::string buildTypeNameExp(ssa type_name, size_t prec, size_t scale) { +}7.6510.18.4818.127.4
    BuildTypeNameExp 0/0std::string buildTypeNameExp(ssa type_name, size_t prec, size_t scale) { if (prec) { return type_name + "(" + prec + e_if(scale, ","_ss + scale) + ")"; } return type_name; -}7.316.627.4413.123.4
    BuildTypeNameSim 0/0stringa buildTypeNameSim(ssa type_name, size_t prec, size_t scale) { +}6.508.757.6414.528.9
    BuildTypeNameSim 0/0stringa buildTypeNameSim(ssa type_name, size_t prec, size_t scale) { if (prec) { return type_name + "(" + prec + e_if(scale, ","_ss + scale) + ")"; } return type_name; -}4.804.897.7415.219.2
    BuildTypeNameStr 10/10std::string buildTypeNameStr(std::string_view type_name, size_t prec, size_t scale) { +}4.144.907.7516.338.4
    BuildTypeNameStr 10/10std::string buildTypeNameStr(std::string_view type_name, size_t prec, size_t scale) { std::string res{type_name}; if (prec) { res += "(" + std::to_string(prec); @@ -640,31 +682,31 @@ it is collected in a stack-based buffer, without allocation or deallocation.54.882.358.781.8374
    BuildTypeNameExp 10/10std::string buildTypeNameExp(ssa type_name, size_t prec, size_t scale) { +}56.984.359.685.7652
    BuildTypeNameExp 10/10std::string buildTypeNameExp(ssa type_name, size_t prec, size_t scale) { if (prec) { return type_name + "(" + prec + e_if(scale, ","_ss + scale) + ")"; } return type_name; -}30.225.332.238.8109
    BuildTypeNameSim 10/10stringa buildTypeNameSim(ssa type_name, size_t prec, size_t scale) { +}29.925.933.340.1196
    BuildTypeNameSim 10/10stringa buildTypeNameSim(ssa type_name, size_t prec, size_t scale) { if (prec) { return type_name + "(" + prec + e_if(scale, ","_ss + scale) + ")"; } return type_name; -}22.521.625.336.463.6
    -

    # Replace string by copy

    +

    # Replace string by copy

    - - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Concat with replace strstd::string make_str_str(std::string_view from, std::string_view pattern, std::string_view repl) { +
    Concat with replace strstd::string make_str_str(std::string_view from, std::string_view pattern, std::string_view repl) { auto str_replace = [](std::string_view from, std::string_view pattern, std::string_view repl) { std::string result; for (size_t offset = 0; ;) { @@ -680,74 +722,74 @@ it is collected in a stack-based buffer, without allocation or deallocation."; -}207225309351495
    Concat with replace expstd::string make_str_exp(std::string_view from, std::string_view pattern, std::string_view repl) { +}2002503083661074
    Concat with replace expstd::string make_str_exp(std::string_view from, std::string_view pattern, std::string_view repl) { return "<" + e_repl(from, pattern, repl) + ">"; } >> В simstr строковое выражение для замены подстрок есть "из коробки". -simstr has a string expression for replacing substrings out of the box.138135214222239
    -

    # Create Empty Str

    +

    # Create Empty Str

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string e;template<typename T> +
    std::string e;template<typename T> void CreateEmpty(benchmark::State& state) { for (auto _: state) { T empty_string; benchmark::DoNotOptimize(empty_string); } } >> Пустые строки, ничего необычного. -Empty lines, nothing unusual.1.101.131.092.862.14
    std::string_view e;template<typename T> +Empty lines, nothing unusual.1.111.091.143.252.60
    std::string_view e;template<typename T> void CreateEmpty(benchmark::State& state) { for (auto _: state) { T empty_string; benchmark::DoNotOptimize(empty_string); } -}0.3720.7390.3641.810.730
    ssa e;template<typename T> +}0.3750.7390.3721.852.15
    ssa e;template<typename T> void CreateEmpty(benchmark::State& state) { for (auto _: state) { T empty_string; benchmark::DoNotOptimize(empty_string); } -}0.3630.1820.3601.500.364
    stringa e;template<typename T> +}0.3610.1830.3591.452.16
    stringa e;template<typename T> void CreateEmpty(benchmark::State& state) { for (auto _: state) { T empty_string; benchmark::DoNotOptimize(empty_string); } -}0.7350.7360.7332.232.17
    lstringa<20> e;template<typename T> +}0.7530.7310.7362.205.52
    lstringa<20> e;template<typename T> void CreateEmpty(benchmark::State& state) { for (auto _: state) { T empty_string; benchmark::DoNotOptimize(empty_string); } -}1.101.111.092.572.18
    lstringa<40> e;template<typename T> +}1.201.111.112.599.16
    lstringa<40> e;template<typename T> void CreateEmpty(benchmark::State& state) { for (auto _: state) { T empty_string; benchmark::DoNotOptimize(empty_string); } -}1.101.101.102.582.26
    -

    # Create Str from short literal (9 symbols)

    +

    # Create Str from short literal (9 symbols)

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string e = "Test text";template<typename T> +
    std::string e = "Test text";template<typename T> void CreateShortLiteral(benchmark::State& state) { for (auto _: state) { T empty_string = TEST_TEXT; @@ -756,8 +798,8 @@ void CreateShortLiteral(benchmark::State& state) { } >> Короткий литерал помещается во внутренний буфер std::string, время тратится только на копирование 10 байтов. The short literal is placed in the internal std::string buffer; -time is spent only copying 10 bytes.1.841.821.832.562.43
    std::string_view e = "Test text";template<typename T> +time is spent only copying 10 bytes.1.811.841.812.6710.4
    std::string_view e = "Test text";template<typename T> void CreateShortLiteral(benchmark::State& state) { for (auto _: state) { T empty_string = TEST_TEXT; @@ -766,15 +808,15 @@ void CreateShortLiteral(benchmark::State& state) { } >> И string_view, и ssa - по сути одно и то же: указатель на текст и его длина. Both string_view and ssa are essentially the same thing: -a pointer to text and its length.0.7390.7420.7531.811.10
    ssa e = "Test text";template<typename T> +a pointer to text and its length.0.7310.7360.7341.842.18
    ssa e = "Test text";template<typename T> void CreateShortLiteral(benchmark::State& state) { for (auto _: state) { T empty_string = TEST_TEXT; benchmark::DoNotOptimize(empty_string); } -}0.3630.7360.3601.820.732
    stringa e = "Test text";template<typename T> +}0.3670.7500.3641.872.17
    stringa e = "Test text";template<typename T> void CreateShortLiteral(benchmark::State& state) { for (auto _: state) { T empty_string = TEST_TEXT; @@ -783,8 +825,8 @@ void CreateShortLiteral(benchmark::State& state) { } >> stringa при инициализации константным литералом так же сохраняет только указатель на текст и его длину. When initialized with a constant literal, stringa also stores -only a pointer to the text and its length.1.111.101.102.842.19
    lstringa<20> e = "Test text";template<typename T> +only a pointer to the text and its length.1.111.111.112.868.30
    lstringa<20> e = "Test text";template<typename T> void CreateShortLiteral(benchmark::State& state) { for (auto _: state) { T empty_string = TEST_TEXT; @@ -793,26 +835,26 @@ void CreateShortLiteral(benchmark::State& state) { } >> Внутреннего буфера хватает для размещения символов, время уходит только на копирование байтов. The internal buffer is sufficient to accommodate characters; -time is spent only on copying bytes.1.871.851.822.562.57
    lstringa<40> e = "Test text";template<typename T> +time is spent only on copying bytes.1.851.841.872.553.89
    lstringa<40> e = "Test text";template<typename T> void CreateShortLiteral(benchmark::State& state) { for (auto _: state) { T empty_string = TEST_TEXT; benchmark::DoNotOptimize(empty_string); } -}1.901.831.822.542.62
    -

    # Create Str from long literal (30 symbols)

    +

    # Create Str from long literal (30 symbols)

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string e = "123456789012345678901234567890";template<typename T> +
    std::string e = "123456789012345678901234567890";template<typename T> void CreateLongLiteral(benchmark::State& state) { for (auto _: state) { T empty_string{LONG_TEXT}; @@ -823,8 +865,8 @@ void CreateLongLiteral(benchmark::State& state) { Но как же отстает аллокация под Windows от Linux'а, 20 vs 70 ns... Here, the literal doesn't fit into the internal buffer, and 30 bytes are allocated and copied. -But how much slower is allocation under Windows than under Linux, 20 ns vs. 70 ns...19.919.573.479.422.4
    std::string_view e = "123456789012345678901234567890";template<typename T> +But how much slower is allocation under Windows than under Linux, 20 ns vs. 70 ns...19.119.273.473.668.6
    std::string_view e = "123456789012345678901234567890";template<typename T> void CreateLongLiteral(benchmark::State& state) { for (auto _: state) { T empty_string{LONG_TEXT}; @@ -833,23 +875,23 @@ void CreateLongLiteral(benchmark::State& state) { } >> string_view и ssa по прежнему ничего не делают, кроме запоминания указателя на текст и его размера. string_view and ssa still do nothing except -remember the pointer to the text and its size.0.7290.7300.7291.821.18
    ssa e = "123456789012345678901234567890";template<typename T> +remember the pointer to the text and its size.0.7620.7520.7501.832.19
    ssa e = "123456789012345678901234567890";template<typename T> void CreateLongLiteral(benchmark::State& state) { for (auto _: state) { T empty_string{LONG_TEXT}; benchmark::DoNotOptimize(empty_string); } -}0.3660.7390.3641.790.778
    stringa e = "123456789012345678901234567890";template<typename T> +}0.3690.7330.3601.812.18
    stringa e = "123456789012345678901234567890";template<typename T> void CreateLongLiteral(benchmark::State& state) { for (auto _: state) { T empty_string{LONG_TEXT}; benchmark::DoNotOptimize(empty_string); } } >> stringa на константных литералах не отстает! -stringa doesn't lag behind on constant literals!1.121.131.082.552.22
    lstringa<20> e = "123456789012345678901234567890";template<typename T> +stringa doesn't lag behind on constant literals!1.091.111.082.548.30
    lstringa<20> e = "123456789012345678901234567890";template<typename T> void CreateLongLiteral(benchmark::State& state) { for (auto _: state) { T empty_string{LONG_TEXT}; @@ -857,8 +899,8 @@ void CreateLongLiteral(benchmark::State& state) { } } >> lstringa<20> может вместить в себя до 23 символов, Очевидно, что для 30-и символов уже нужна аллокация. -Obviously, 30 characters already require allocation.20.319.974.876.324.8
    lstringa<40> e = "123456789012345678901234567890";template<typename T> +Obviously, 30 characters already require allocation.21.020.473.675.168.6
    lstringa<40> e = "123456789012345678901234567890";template<typename T> void CreateLongLiteral(benchmark::State& state) { for (auto _: state) { T empty_string{LONG_TEXT}; @@ -867,19 +909,19 @@ void CreateLongLiteral(benchmark::State& state) { } >> А в lstringa<40> влезает до 47 символов, так что просто копируется 30 байтов. And lstringa<40> can hold up to 47 characters, so 30 -bytes are simply copied.2.541.872.563.253.16
    -

    # Create copy of Str with 9 symbols

    +

    # Create copy of Str with 9 symbols

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string e = "Test text"; auto c{e};template<typename T> +
    std::string e = "Test text"; auto c{e};template<typename T> void CopyShortString(benchmark::State& state) { T x{TEST_TEXT}; for (auto _: state) { @@ -888,8 +930,8 @@ void CopyShortString(benchmark::State& state) { benchmark::DoNotOptimize(x); } } >> Строка в пределах SSO, так что просто копирует байты. -The string is within the SSO, so it just copies the bytes.4.785.761.825.083.86
    std::string_view e = "Test text"; auto c{e};template<typename T> +The string is within the SSO, so it just copies the bytes.5.585.621.825.107.32
    std::string_view e = "Test text"; auto c{e};template<typename T> void CopyShortString(benchmark::State& state) { T x{TEST_TEXT}; for (auto _: state) { @@ -897,8 +939,8 @@ void CopyShortString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}0.3630.4430.3633.791.14
    ssa e = "Test text"; auto c{e};template<typename T> +}0.3700.3650.3633.792.17
    ssa e = "Test text"; auto c{e};template<typename T> void CopyShortString(benchmark::State& state) { T x{TEST_TEXT}; for (auto _: state) { @@ -909,8 +951,8 @@ void CopyShortString(benchmark::State& state) { } >> ssa и string_view не владеют строкой, копируется только информация о строке. ssa and string_view don't own the string; only the -string information is copied.0.3680.3950.3633.761.19
    stringa e = "Test text"; auto c{e};template<typename T> +string information is copied.0.3720.3740.3663.852.18
    stringa e = "Test text"; auto c{e};template<typename T> void CopyShortString(benchmark::State& state) { T x{TEST_TEXT}; for (auto _: state) { @@ -921,8 +963,8 @@ void CopyShortString(benchmark::State& state) { } >> Копирование stringa происходит быстро, особенно если она инициализирована литералом. Copying a stringa is fast, -especially if it is initialized with a literal.1.081.351.284.032.53
    lstringa<20> e = "Test text"; auto c{e};template<typename T> +especially if it is initialized with a literal.1.111.111.284.006.33
    lstringa<20> e = "Test text"; auto c{e};template<typename T> void CopyShortString(benchmark::State& state) { T x{TEST_TEXT}; for (auto _: state) { @@ -931,8 +973,8 @@ void CopyShortString(benchmark::State& state) { benchmark::DoNotOptimize(x); } } >> В обоих случаях хватает внутреннего буфера. -In both cases, the internal buffer is sufficient.1.471.251.464.274.78
    lstringa<40> e = "Test text"; auto c{e};template<typename T> +In both cases, the internal buffer is sufficient.1.491.111.504.387.15
    lstringa<40> e = "Test text"; auto c{e};template<typename T> void CopyShortString(benchmark::State& state) { T x{TEST_TEXT}; for (auto _: state) { @@ -941,19 +983,19 @@ void CopyShortString(benchmark::State& state) { benchmark::DoNotOptimize(x); } } >> Только копируются байты. -Only bytes are copied.1.471.251.464.544.80
    -

    # Create copy of Str with 30 symbols

    +

    # Create copy of Str with 30 symbols

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string e = "123456789012345678901234567890"; auto c{e};template<typename T> +
    std::string e = "123456789012345678901234567890"; auto c{e};template<typename T> void CopyLongString(benchmark::State& state) { T x = LONG_TEXT; for (auto _: state) { @@ -963,24 +1005,24 @@ void CopyLongString(benchmark::State& state) { } >> Копирования длинной строки вызывает аллокацию, SSO уже не хватает. И снова как же отстаёт аллокация под Windows... Copying a long string causes allocations, -SSO is no longer sufficient. And again, how allocation lags under Windows...18.422.874.777.146.7
    std::string_view e = "123456789012345678901234567890"; auto c{e};template<typename T> +SSO is no longer sufficient. And again, how allocation lags under Windows...19.023.875.878.3120
    std::string_view e = "123456789012345678901234567890"; auto c{e};template<typename T> void CopyLongString(benchmark::State& state) { T x = LONG_TEXT; for (auto _: state) { T copy{x}; benchmark::DoNotOptimize(copy); } -}0.7380.7860.7321.821.09
    ssa e = "123456789012345678901234567890"; auto c{e};template<typename T> +}0.7610.7350.7351.852.22
    ssa e = "123456789012345678901234567890"; auto c{e};template<typename T> void CopyLongString(benchmark::State& state) { T x = LONG_TEXT; for (auto _: state) { T copy{x}; benchmark::DoNotOptimize(copy); } -}0.3670.8200.3681.850.737
    stringa e = "123456789012345678901234567890"; auto c{e};template<typename T> +}0.3660.7420.3611.812.16
    stringa e = "123456789012345678901234567890"; auto c{e};template<typename T> void CopyLongString(benchmark::State& state) { T x = LONG_TEXT; for (auto _: state) { @@ -990,8 +1032,8 @@ void CopyLongString(benchmark::State& state) { } >> А вот у stringa копирование литерала не зависит от его длины, сравни с предыдущим бенчмарком. But with stringa, literal copying doesn't depend on its length, -compare with the previous benchmark.1.101.111.802.972.16
    lstringa<20> e = "123456789012345678901234567890"; auto c{e};template<typename T> +compare with the previous benchmark.1.111.301.822.938.35
    lstringa<20> e = "123456789012345678901234567890"; auto c{e};template<typename T> void CopyLongString(benchmark::State& state) { T x = LONG_TEXT; for (auto _: state) { @@ -999,8 +1041,8 @@ void CopyLongString(benchmark::State& state) { benchmark::DoNotOptimize(copy); } } >> Не влезает, аллокация. -Doesn't fit, allocation.19.420.673.777.321.9
    lstringa<40> e = "123456789012345678901234567890"; auto c{e};template<typename T> +Doesn't fit, allocation.21.019.875.182.067.2
    lstringa<40> e = "123456789012345678901234567890"; auto c{e};template<typename T> void CopyLongString(benchmark::State& state) { T x = LONG_TEXT; for (auto _: state) { @@ -1008,19 +1050,35 @@ void CopyLongString(benchmark::State& state) { benchmark::DoNotOptimize(copy); } } >> Уложили во внутренний буфер. -Placed in the internal buffer.4.474.704.797.4015.0
    -

    # Find 9 symbols text in end of 99 symbols text

    +

    # Find 9 symbols text in end of 99 symbols text

    - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string::find;template<typename T> +
    sz::string::find;template<typename T> +void Find(benchmark::State& state) { + T x{LONG_TEXT LONG_TEXT LONG_TEXT TEST_TEXT}; + for (auto _: state) { + int i = (int)x.find(TEST_TEXT); + #ifdef CHECK_RESULT + if (i != 90) { + state.SkipWithError("not find?"); + break; + } + #endif + benchmark::DoNotOptimize(i); + benchmark::DoNotOptimize(x); + } +} >> stringzilla более заточена на поиск больших строк в больших строках. +stringzilla is more focused on searching large strings within large strings.93.493.898.8115227
    std::string::find;template<typename T> void Find(benchmark::State& state) { T x{LONG_TEXT LONG_TEXT LONG_TEXT TEST_TEXT}; for (auto _: state) { @@ -1037,8 +1095,8 @@ void Find(benchmark::State& state) { } >> Здесь "победила дружба", у всех типов по колонке примерно одинаково. Однако, Windows и Linux явно в разных весовых категориях. Here, "friendship wins," with all types scoring roughly equally. -However, Windows and Linux are clearly in different weight classes.6.796.9238.541.343.3
    std::string_view::find;template<typename T> +However, Windows and Linux are clearly in different weight classes.7.547.6739.339.099.1
    std::string_view::find;template<typename T> void Find(benchmark::State& state) { T x{LONG_TEXT LONG_TEXT LONG_TEXT TEST_TEXT}; for (auto _: state) { @@ -1052,8 +1110,8 @@ void Find(benchmark::State& state) { benchmark::DoNotOptimize(i); benchmark::DoNotOptimize(x); } -}7.096.7537.739.245.3
    ssa::find;template<typename T> +}6.707.4852.140.197.5
    ssa::find;template<typename T> void Find(benchmark::State& state) { T x{LONG_TEXT LONG_TEXT LONG_TEXT TEST_TEXT}; for (auto _: state) { @@ -1067,8 +1125,8 @@ void Find(benchmark::State& state) { benchmark::DoNotOptimize(i); benchmark::DoNotOptimize(x); } -}6.796.5217.520.443.4
    stringa::find;template<typename T> +}7.496.7819.521.496.3
    stringa::find;template<typename T> void Find(benchmark::State& state) { T x{LONG_TEXT LONG_TEXT LONG_TEXT TEST_TEXT}; for (auto _: state) { @@ -1082,8 +1140,8 @@ void Find(benchmark::State& state) { benchmark::DoNotOptimize(i); benchmark::DoNotOptimize(x); } -}7.436.6217.929.343.5
    lstringa<20>::find;template<typename T> +}7.847.1718.930.197.2
    lstringa<20>::find;template<typename T> void Find(benchmark::State& state) { T x{LONG_TEXT LONG_TEXT LONG_TEXT TEST_TEXT}; for (auto _: state) { @@ -1097,8 +1155,8 @@ void Find(benchmark::State& state) { benchmark::DoNotOptimize(i); benchmark::DoNotOptimize(x); } -}6.266.3218.220.738.7
    lstringa<40>::find;template<typename T> +}7.386.9617.622.097.6
    lstringa<40>::find;template<typename T> void Find(benchmark::State& state) { T x{LONG_TEXT LONG_TEXT LONG_TEXT TEST_TEXT}; for (auto _: state) { @@ -1112,19 +1170,20 @@ void Find(benchmark::State& state) { benchmark::DoNotOptimize(i); benchmark::DoNotOptimize(x); } -}6.266.3317.522.140.2
    -

    # Copy not literal Str with N symbols

    +

    # Copy not literal Str with N symbols

    - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string copy{str_with_len_N};/15template<typename T> +
    std::string copy{str_with_len_N};/15template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1132,8 +1191,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}4.746.031.834.4249.3
    std::string copy{str_with_len_N};/16template<typename T> +}4.877.911.834.42125
    std::string copy{str_with_len_N};/16template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1146,8 +1205,8 @@ void CopyDynString(benchmark::State& state) { SSO у std::string меньше, 10 символов + 0. The jump where SSO ends and allocation begins is clearly visible. Note that WASM is 32-bit, and the size of the SSO for std::string is -smaller, as far as I remember: 11 characters + 0.22.825.977.782.248.3
    std::string copy{str_with_len_N};/23template<typename T> +smaller, as far as I remember: 11 characters + 0.23.226.580.881.3123
    std::string copy{str_with_len_N};/23template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1156,8 +1215,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(x); } } >> Дальше просто добавляется время на копирование байтов. -Then the time for copying bytes is simply added.22.625.076.483.349.1
    std::string copy{str_with_len_N};/24template<typename T> +Then the time for copying bytes is simply added.23.527.378.378.6128
    std::string copy{str_with_len_N};/24template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1165,8 +1224,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}22.625.377.980.748.1
    std::string copy{str_with_len_N};/32template<typename T> +}22.627.778.579.8120
    std::string copy{str_with_len_N};/32template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1174,8 +1233,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}22.624.281.784.351.5
    std::string copy{str_with_len_N};/64template<typename T> +}22.626.581.883.8128
    std::string copy{str_with_len_N};/64template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1183,8 +1242,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}21.924.184.688.853.0
    std::string copy{str_with_len_N};/128template<typename T> +}22.326.982.881.7131
    std::string copy{str_with_len_N};/128template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1192,8 +1251,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}24.225.685.590.452.6
    std::string copy{str_with_len_N};/256template<typename T> +}23.728.982.687.7132
    std::string copy{str_with_len_N};/256template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1201,8 +1260,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}24.425.884.389.859.2
    std::string copy{str_with_len_N};/512template<typename T> +}24.928.885.088.5161
    std::string copy{str_with_len_N};/512template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1210,8 +1269,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}28.730.488.093.059.5
    std::string copy{str_with_len_N};/1024template<typename T> +}28.533.686.592.7149
    std::string copy{str_with_len_N};/1024template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1219,8 +1278,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}44.747.010410968.5
    std::string copy{str_with_len_N};/2048template<typename T> +}34.844.295.397.1156
    std::string copy{str_with_len_N};/2048template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1228,8 +1287,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}12213113113190.5
    std::string copy{str_with_len_N};/4096template<typename T> +}79.180.3133129206
    std::string copy{str_with_len_N};/4096template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1238,8 +1297,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(x); } } >> Чем длиннее строка, тем дольше создаётся копия. -The longer the string, the longer it takes to create a copy.158159178181133
    stringa copy{str_with_len_N};/15template<typename T> +The longer the string, the longer it takes to create a copy.111115179180271
    stringa copy{str_with_len_N};/15template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1250,8 +1309,8 @@ void CopyDynString(benchmark::State& state) { } >> Здесь stringa инициализируется не литералом, а значит, должна сама хранить символы. Here, stringa is not initialized with a literal, -meaning it must store characters itself.1.111.301.274.042.36
    stringa copy{str_with_len_N};/16template<typename T> +meaning it must store characters itself.1.091.091.294.004.60
    stringa copy{str_with_len_N};/16template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1264,8 +1323,8 @@ void CopyDynString(benchmark::State& state) { инкремент заменён на обычный, судя по времени. Under WASM, stringa has a 15-character SSO. Furthermore, it was built without thread support, so the atomic -increment was replaced with a regular one, judging by the time.1.101.301.284.084.79
    stringa copy{str_with_len_N};/23template<typename T> +increment was replaced with a regular one, judging by the time.1.131.101.324.027.36
    stringa copy{str_with_len_N};/23template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1276,8 +1335,8 @@ void CopyDynString(benchmark::State& state) { } >> SSO в stringa до 23 символов, и даже 23 копируются быстрее, чем 15 в std::string. SSO in stringa is up to 23 characters, and even 23 -copies faster than 15 in std::string.1.091.301.283.964.82
    stringa copy{str_with_len_N};/24template<typename T> +copies faster than 15 in std::string.1.111.101.294.107.39
    stringa copy{str_with_len_N};/24template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1288,8 +1347,8 @@ void CopyDynString(benchmark::State& state) { } >> Всё, не влезаем в SSO, а значит, используем shared буфер. Добавляется время на атомарный инкремент счётчика. That's it, we're not using SSO, so we're using a shared buffer. -Time is added for the atomic counter increment.16.116.115.818.24.79
    stringa copy{str_with_len_N};/32template<typename T> +Time is added for the atomic counter increment.15.916.115.818.47.35
    stringa copy{str_with_len_N};/32template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1297,8 +1356,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}15.916.015.818.24.81
    stringa copy{str_with_len_N};/64template<typename T> +}16.016.015.818.47.33
    stringa copy{str_with_len_N};/64template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1306,8 +1365,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}16.016.015.818.34.83
    stringa copy{str_with_len_N};/128template<typename T> +}16.016.115.818.37.37
    stringa copy{str_with_len_N};/128template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1315,8 +1374,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}16.116.015.818.44.77
    stringa copy{str_with_len_N};/256template<typename T> +}16.016.015.718.47.30
    stringa copy{str_with_len_N};/256template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1324,8 +1383,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}16.216.215.818.34.81
    stringa copy{str_with_len_N};/512template<typename T> +}16.015.915.818.37.33
    stringa copy{str_with_len_N};/512template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1333,8 +1392,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}16.116.215.818.44.77
    stringa copy{str_with_len_N};/1024template<typename T> +}16.016.015.718.27.44
    stringa copy{str_with_len_N};/1024template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1342,8 +1401,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}15.916.115.919.14.83
    stringa copy{str_with_len_N};/2048template<typename T> +}16.016.115.818.27.35
    stringa copy{str_with_len_N};/2048template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1351,8 +1410,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}16.216.215.818.34.82
    stringa copy{str_with_len_N};/4096template<typename T> +}15.916.216.818.37.33
    stringa copy{str_with_len_N};/4096template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1363,8 +1422,8 @@ void CopyDynString(benchmark::State& state) { } >> И как видно, кроме инкремента нет накладных расходов, время копирования не зависит от длины строки. And as you can see, there are no overhead costs other than the -increment; copying time does not depend on the string length.16.016.315.818.44.77
    lstringa<16> copy{str_with_len_N};/15template<typename T> +increment; copying time does not depend on the string length.15.916.015.718.37.36
    lstringa<16> copy{str_with_len_N};/15template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1375,8 +1434,8 @@ void CopyDynString(benchmark::State& state) { } >> lstringa<16> использует SSO до 23 символов. А в WASM 32-битная архитектура, SSO до 19 символов. lstringa<16> uses SSO up to 23 characters. -WASM has a 32-bit architecture, so SSO is up to 19 characters.1.461.111.504.914.05
    lstringa<16> copy{str_with_len_N};/16template<typename T> +WASM has a 32-bit architecture, so SSO is up to 19 characters.1.471.101.504.847.29
    lstringa<16> copy{str_with_len_N};/16template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1384,8 +1443,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}5.215.125.069.0114.5
    lstringa<16> copy{str_with_len_N};/23template<typename T> +}5.225.385.098.9819.3
    lstringa<16> copy{str_with_len_N};/23template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1393,8 +1452,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}5.095.055.099.1535.6
    lstringa<16> copy{str_with_len_N};/24template<typename T> +}5.165.435.369.0885.0
    lstringa<16> copy{str_with_len_N};/24template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1403,8 +1462,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(x); } } >> И после начинает вести себя при копировании, как std::string. -And then it starts to behave like std::string when copied.22.924.475.979.335.4
    lstringa<16> copy{str_with_len_N};/32template<typename T> +And then it starts to behave like std::string when copied.22.623.676.881.285.7
    lstringa<16> copy{str_with_len_N};/32template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1412,8 +1471,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}22.624.778.181.438.4
    lstringa<16> copy{str_with_len_N};/64template<typename T> +}23.023.581.485.093.3
    lstringa<16> copy{str_with_len_N};/64template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1421,8 +1480,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}24.126.380.489.538.3
    lstringa<16> copy{str_with_len_N};/128template<typename T> +}25.525.780.883.792.8
    lstringa<16> copy{str_with_len_N};/128template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1430,8 +1489,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}24.726.582.086.739.6
    lstringa<16> copy{str_with_len_N};/256template<typename T> +}25.725.682.890.095.0
    lstringa<16> copy{str_with_len_N};/256template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1439,8 +1498,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}25.928.483.486.345.5
    lstringa<16> copy{str_with_len_N};/512template<typename T> +}27.128.087.493.2126
    lstringa<16> copy{str_with_len_N};/512template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1448,8 +1507,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}29.231.184.490.044.0
    lstringa<16> copy{str_with_len_N};/1024template<typename T> +}29.829.686.991.0119
    lstringa<16> copy{str_with_len_N};/1024template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1457,8 +1516,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}10210994.499.454.9
    lstringa<16> copy{str_with_len_N};/2048template<typename T> +}51.856.593.498.2120
    lstringa<16> copy{str_with_len_N};/2048template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1466,8 +1525,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}11512012712876.6
    lstringa<16> copy{str_with_len_N};/4096template<typename T> +}65.766.4133130169
    lstringa<16> copy{str_with_len_N};/4096template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1475,8 +1534,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}127128184189122
    lstringa<512> copy{str_with_len_N};/15template<typename T> +}86.487.0189183236
    lstringa<512> copy{str_with_len_N};/15template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1484,8 +1543,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}1.511.141.474.074.44
    lstringa<512> copy{str_with_len_N};/16template<typename T> +}1.491.141.494.037.25
    lstringa<512> copy{str_with_len_N};/16template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1493,8 +1552,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}5.174.925.109.1715.0
    lstringa<512> copy{str_with_len_N};/23template<typename T> +}5.154.465.158.7819.5
    lstringa<512> copy{str_with_len_N};/23template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1502,8 +1561,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}5.165.055.259.3315.0
    lstringa<512> copy{str_with_len_N};/24template<typename T> +}5.254.675.148.8219.9
    lstringa<512> copy{str_with_len_N};/24template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1511,8 +1570,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}4.894.585.159.1115.1
    lstringa<512> copy{str_with_len_N};/32template<typename T> +}5.094.105.128.7419.4
    lstringa<512> copy{str_with_len_N};/32template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1520,8 +1579,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}4.784.738.2512.117.8
    lstringa<512> copy{str_with_len_N};/64template<typename T> +}5.264.208.2511.922.7
    lstringa<512> copy{str_with_len_N};/64template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1529,8 +1588,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}6.276.238.1312.318.4
    lstringa<512> copy{str_with_len_N};/128template<typename T> +}6.395.668.0012.322.4
    lstringa<512> copy{str_with_len_N};/128template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1538,8 +1597,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}6.658.448.4212.518.5
    lstringa<512> copy{str_with_len_N};/256template<typename T> +}6.596.978.4612.423.6
    lstringa<512> copy{str_with_len_N};/256template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1547,8 +1606,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}8.269.0310.113.420.5
    lstringa<512> copy{str_with_len_N};/512template<typename T> +}7.997.999.5813.424.8
    lstringa<512> copy{str_with_len_N};/512template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1559,8 +1618,8 @@ void CopyDynString(benchmark::State& state) { } >> Даже 512 символов копируются быстрее, чем одна аллокация или атомарный инкремент. Even 512 characters are copied faster than a single -allocation or atomic increment.10.512.811.115.323.2
    lstringa<512> copy{str_with_len_N};/1024template<typename T> +allocation or atomic increment.10.510.311.014.728.3
    lstringa<512> copy{str_with_len_N};/1024template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1569,8 +1628,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(x); } } >> А дальше уже как у всех. -And then it's like everyone else.10511096.699.855.2
    lstringa<512> copy{str_with_len_N};/2048template<typename T> +And then it's like everyone else.52.154.294.593.5121
    lstringa<512> copy{str_with_len_N};/2048template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1578,8 +1637,8 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}11611612913676.0
    lstringa<512> copy{str_with_len_N};/4096template<typename T> +}64.966.7134127167
    lstringa<512> copy{str_with_len_N};/4096template<typename T> void CopyDynString(benchmark::State& state) { T x(state.range(0), 'a'); for (auto _: state) { @@ -1587,61 +1646,61 @@ void CopyDynString(benchmark::State& state) { benchmark::DoNotOptimize(copy); benchmark::DoNotOptimize(x); } -}128130184191122
    -

    # Convert to int '1234567'

    +

    # Convert to int '1234567'

    - - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);void ToIntStr10(benchmark::State& state, const std::string& s, int c) { +
    std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);void ToIntStr10(benchmark::State& state, const std::string& s, int c) { for (auto _: state) { int res = std::strtol(s.c_str(), nullptr, 10); #ifdef CHECK_RESULT @@ -1660,8 +1719,8 @@ void CopyDynString(benchmark::State& state) { In simstr, a string fragment is sufficient for conversion to a number; there's no need for null termination. The closest analog to this behavior is "std::from_chars," but unfortunately, it is very limited in its capabilities. -Here, I attempted to run tests that are similar in logic to std::from_chars.26.426.431.031.793.0
    std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);void ToIntFromChars10(benchmark::State& state, const std::string_view& s, int c) { +Here, I attempted to run tests that are similar in logic to std::from_chars.26.927.230.631.5203
    std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);void ToIntFromChars10(benchmark::State& state, const std::string_view& s, int c) { for (auto _: state) { int res = 0; std::from_chars(s.data(), s.data() + s.size(), res, 10); @@ -1676,8 +1735,8 @@ Here, I attempted to run tests that are similar in logic to std::from_chars. >> from_chars требует точного указания основания счисления, не допускает знаков плюс, пробелов, префиксов 0x и т.п. from_chars requires an exact radix specification and does not allow plus -signs, spaces, 0x prefixes, etc.14.911.413.313.626.7
    stringa s = "123456789"; int res = s.to_int<int, true, 10, false>template<typename T> +signs, spaces, 0x prefixes, etc.14.512.013.514.82.18
    stringa s = "123456789"; int res = s.to_int<int, true, 10, false>template<typename T> void ToIntSimStr10(benchmark::State& state, T t, int c) { for (auto _: state) { int res = t. template to_int<int, true, 10, false, false>().value; @@ -1693,8 +1752,8 @@ void ToIntSimStr10(benchmark::State& state, T t, int c) { } >> Здесь для to_int заданы такие же ограничения - проверять переполнение, десятичная система, без лидирующих пробелов и знака плюс Here, to_int has the same restrictions: check for overflow, -decimal system, no leading spaces, and no plus sign.12.68.3613.915.119.1
    ssa s = "123456789"; int res = s.to_int<int, true, 10, false>template<typename T> +decimal system, no leading spaces, and no plus sign.9.628.5413.815.950.4
    ssa s = "123456789"; int res = s.to_int<int, true, 10, false>template<typename T> void ToIntSimStr10(benchmark::State& state, T t, int c) { for (auto _: state) { int res = t. template to_int<int, true, 10, false, false>().value; @@ -1707,8 +1766,8 @@ void ToIntSimStr10(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); benchmark::DoNotOptimize(t); } -}12.37.8312.914.818.6
    lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>template<typename T> +}9.847.799.1715.247.5
    lstringa<20> s = "123456789"; int res = s.to_int<int, true, 10, false>template<typename T> void ToIntSimStr10(benchmark::State& state, T t, int c) { for (auto _: state) { int res = t. template to_int<int, true, 10, false, false>().value; @@ -1721,18 +1780,18 @@ void ToIntSimStr10(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); benchmark::DoNotOptimize(t); } -}12.28.3813.315.018.9
    -

    # Convert to unsigned 'abcDef'

    +

    # Convert to unsigned 'abcDef'

    - - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);void ToIntStr16(benchmark::State& state, const std::string& s, int c) { +
    std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);void ToIntStr16(benchmark::State& state, const std::string& s, int c) { for (auto _: state) { int res = std::strtol(s.c_str(), nullptr, 16); #ifdef CHECK_RESULT @@ -1744,8 +1803,8 @@ void ToIntSimStr10(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); } } >> Всё то же, только для 16ричной системы -Everything is the same, only for the hexadecimal system23.523.534.435.467.9
    std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);void ToIntFromChars16(benchmark::State& state, const std::string_view& s, int c) { +Everything is the same, only for the hexadecimal system22.823.834.234.5151
    std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);void ToIntFromChars16(benchmark::State& state, const std::string_view& s, int c) { for (auto _: state) { int res = 0; std::from_chars(s.data(), s.data() + s.size(), res, 16); @@ -1757,8 +1816,8 @@ Everything is the same, only for the hexadecimal system9.659.898.719.4525.8
    stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>template<typename T> +}9.228.078.119.1653.9
    stringa s = "abcDef"; int res = s.to_int<int, true, 16, false>template<typename T> void ToIntSimStr16(benchmark::State& state, T t, int c) { for (auto _: state) { int res = t. template to_int<int, true, 16, false, false>().value; @@ -1771,8 +1830,8 @@ void ToIntSimStr16(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); benchmark::DoNotOptimize(t); } -}12.58.1912.013.419.2
    ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>template<typename T> +}7.558.4412.713.846.1
    ssa s = "abcDef"; int res = s.to_int<int, true, 16, false>template<typename T> void ToIntSimStr16(benchmark::State& state, T t, int c) { for (auto _: state) { int res = t. template to_int<int, true, 16, false, false>().value; @@ -1785,8 +1844,8 @@ void ToIntSimStr16(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); benchmark::DoNotOptimize(t); } -}13.07.7711.812.519.0
    lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>template<typename T> +}7.556.727.3913.444.8
    lstringa<20> s = "abcDef"; int res = s.to_int<int, true, 16, false>template<typename T> void ToIntSimStr16(benchmark::State& state, T t, int c) { for (auto _: state) { int res = t. template to_int<int, true, 16, false, false>().value; @@ -1799,18 +1858,18 @@ void ToIntSimStr16(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); benchmark::DoNotOptimize(t); } -}12.58.1212.313.819.6
    -

    # Convert to int ' 1234567'

    +

    # Convert to int ' 1234567'

    - - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);void ToIntStr0(benchmark::State& state, const std::string& s, int c) { +
    std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);void ToIntStr0(benchmark::State& state, const std::string& s, int c) { for (auto _: state) { int res = std::strtol(s.c_str(), nullptr, 0); #ifdef CHECK_RESULT @@ -1822,8 +1881,8 @@ void ToIntSimStr16(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); } } >> А здесь уже парсинг произвольного числа. -And here we have parsing of an arbitrary number.28.628.444.244.898.4
    stringa s = " 123456789"; int res = s.to_int<int>; // Check overflowtemplate<typename T> +And here we have parsing of an arbitrary number.28.827.842.844.1219
    stringa s = " 123456789"; int res = s.to_int<int>; // Check overflowtemplate<typename T> void ToIntSimStr0(benchmark::State& state, T t, int c) { for (auto _: state) { int res = t. template to_int<int>().value; @@ -1836,8 +1895,8 @@ void ToIntSimStr0(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); benchmark::DoNotOptimize(t); } -}18.514.917.721.624.4
    ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflowvoid ToIntNoOverflow(benchmark::State& state, ssa t, int c) { +}11.415.318.522.335.2
    ssa s = " 123456789"; int res = s.to_int<int, false>; // No check overflowvoid ToIntNoOverflow(benchmark::State& state, ssa t, int c) { for (auto _: state) { int res = t.to_int<int, false>().value; #ifdef CHECK_RESULT @@ -1849,16 +1908,16 @@ void ToIntSimStr0(benchmark::State& state, T t, int c) { benchmark::DoNotOptimize(res); benchmark::DoNotOptimize(t); } -}15.513.715.916.919.3
    -

    # Convert to double '1234.567e10'

    +

    # Convert to double '1234.567e10'

    - - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);void ToDoubleStr(benchmark::State& state, const std::string& s, double c) { +
    std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);void ToDoubleStr(benchmark::State& state, const std::string& s, double c) { for (auto _: state) { char* ptr = nullptr; double res = std::strtod(s.c_str(), &ptr); @@ -1873,8 +1932,8 @@ void ToIntSimStr0(benchmark::State& state, T t, int c) { #endif benchmark::DoNotOptimize(res); } -}63.766.8102105308
    std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);void ToDoubleFromChars(benchmark::State& state, const std::string_view& s, double c) { +}66.262.897.9103633
    std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);void ToDoubleFromChars(benchmark::State& state, const std::string_view& s, double c) { for (auto _: state) { double res = 0; if (std::from_chars(s.data(), s.data() + s.size(), res).ec != std::errc{}) { @@ -1888,8 +1947,8 @@ void ToIntSimStr0(benchmark::State& state, T t, int c) { #endif benchmark::DoNotOptimize(res); } -}25.025.058.779.8109
    ssa s = "1234.567e10"; double res = *s.to_double()template<typename T> +}23.624.258.477.6279
    ssa s = "1234.567e10"; double res = *s.to_double()template<typename T> void ToDoubleSimStr(benchmark::State& state, T t, double c) { for (auto _: state) { auto r = t.template to_double<false>(); @@ -1906,16 +1965,16 @@ void ToDoubleSimStr(benchmark::State& state, T t, double c) { benchmark::DoNotOptimize(res); benchmark::DoNotOptimize(t); } -}25.425.235.236.242.1
    -

    # Append const literal of 16 bytes 64 times, 1024 total length

    +

    # Append const literal of 16 bytes 64 times, 1024 total length

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::stringstream str; ... str << "abbaabbaabbaabba";void AppendStreamConstLiteral(benchmark::State& state) { +
    std::stringstream str; ... str << "abbaabbaabbaabba";void AppendStreamConstLiteral(benchmark::State& state) { for (auto _: state) { std::string result; std::stringstream str; @@ -1932,8 +1991,8 @@ void ToDoubleSimStr(benchmark::State& state, T t, double c) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(str); } -}13511359462558686617
    std::string str; ... str += "abbaabbaabbaabba";void AppendStdStringConstLiteral(benchmark::State& state) { +}133613454844566915882
    std::string str; ... str += "abbaabbaabbaabba";void AppendStdStringConstLiteral(benchmark::State& state) { for (auto _: state) { std::string result; for (size_t c = 0; c < 64; c++) { @@ -1947,8 +2006,8 @@ void ToDoubleSimStr(benchmark::State& state, T t, double c) { #endif benchmark::DoNotOptimize(result); } -}38338010671286775
    lstringa<8> str; ... str += "abbaabbaabbaabba";template<unsigned N> +}407346104513051402
    lstringa<8> str; ... str += "abbaabbaabbaabba";template<unsigned N> void AppendLstringConstLiteral(benchmark::State& state) { for (auto _: state) { lstringa<N> result; @@ -1963,8 +2022,8 @@ void AppendLstringConstLiteral(benchmark::State& state) { #endif benchmark::DoNotOptimize(result); } -}378435746948700
    lstringa<128> str; ... str += "abbaabbaabbaabba";template<unsigned N> +}3763457829861320
    lstringa<128> str; ... str += "abbaabbaabbaabba";template<unsigned N> void AppendLstringConstLiteral(benchmark::State& state) { for (auto _: state) { lstringa<N> result; @@ -1982,8 +2041,8 @@ void AppendLstringConstLiteral(benchmark::State& state) { } >> Чем больше внутренний буфер, тем меньше раз требуется аллокация, тем быстрее результат. The larger the internal buffer, the fewer allocations are -required, and the faster the result.253280388542574
    lstringa<512> str; ... str += "abbaabbaabbaabba";template<unsigned N> +required, and the faster the result.236239406582889
    lstringa<512> str; ... str += "abbaabbaabbaabba";template<unsigned N> void AppendLstringConstLiteral(benchmark::State& state) { for (auto _: state) { lstringa<N> result; @@ -1998,8 +2057,8 @@ void AppendLstringConstLiteral(benchmark::State& state) { #endif benchmark::DoNotOptimize(result); } -}223255227366519
    lstringa<1024> str; ... str += "abbaabbaabbaabba";template<unsigned N> +}206209268400624
    lstringa<1024> str; ... str += "abbaabbaabbaabba";template<unsigned N> void AppendLstringConstLiteral(benchmark::State& state) { for (auto _: state) { lstringa<N> result; @@ -2014,19 +2073,19 @@ void AppendLstringConstLiteral(benchmark::State& state) { #endif benchmark::DoNotOptimize(result); } -}136141135229420
    -

    # Append string of 16 bytes and const literal of 16 bytes 32 times, 1024 total length

    +

    # Append string of 16 bytes and const literal of 16 bytes 32 times, 1024 total length

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::stringstream str; ... str << str_var << "abbaabbaabbaabba";void AppendStreamStrConstLiteral(benchmark::State& state) { +
    std::stringstream str; ... str << str_var << "abbaabbaabbaabba";void AppendStreamStrConstLiteral(benchmark::State& state) { std::string s1 = TEXT_16; for (auto _: state) { std::string result; @@ -2044,8 +2103,8 @@ void AppendLstringConstLiteral(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(s1); } -}13371357451756217050
    std::string str; ... str += str_var + "abbaabbaabbaabba";void AppendStdStrStrConstLiteral(benchmark::State& state) { +}136213454654594616035
    std::string str; ... str += str_var + "abbaabbaabbaabba";void AppendStdStrStrConstLiteral(benchmark::State& state) { std::string p1 = TEXT_16; for (auto _: state) { std::string result; @@ -2061,8 +2120,8 @@ void AppendLstringConstLiteral(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}12691291376338322182
    lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";template<unsigned N> +}12211298373644204646
    lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";template<unsigned N> void AppendLstringStrConstLiteral(benchmark::State& state) { stringa p1 = TEXT_16; for (auto _: state) { @@ -2079,8 +2138,8 @@ void AppendLstringStrConstLiteral(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}479450703813978
    lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";template<unsigned N> +}3854037139201514
    lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";template<unsigned N> void AppendLstringStrConstLiteral(benchmark::State& state) { stringa p1 = TEXT_16; for (auto _: state) { @@ -2097,8 +2156,8 @@ void AppendLstringStrConstLiteral(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}354373450538838
    lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";template<unsigned N> +}3013424376351209
    lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";template<unsigned N> void AppendLstringStrConstLiteral(benchmark::State& state) { stringa p1 = TEXT_16; for (auto _: state) { @@ -2115,8 +2174,8 @@ void AppendLstringStrConstLiteral(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}329337300385735
    lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";template<unsigned N> +}293299281384986
    lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";template<unsigned N> void AppendLstringStrConstLiteral(benchmark::State& state) { stringa p1 = TEXT_16; for (auto _: state) { @@ -2133,19 +2192,19 @@ void AppendLstringStrConstLiteral(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}236246209269663
    -

    # Append string of 16 bytes and const literal of 16 bytes 2048 times, 65536 total length

    +

    # Append string of 16 bytes and const literal of 16 bytes 2048 times, 65536 total length

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 timesvoid AppendStreamStrConstLiteralBig(benchmark::State& state) { +
    std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 timesvoid AppendStreamStrConstLiteralBig(benchmark::State& state) { std::string s1 = TEXT_16; for (auto _: state) { std::string result; @@ -2163,8 +2222,8 @@ void AppendLstringStrConstLiteral(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(s1); } -}7387776165221538278650346232
    std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 timesvoid AppendStdStrStrConstLiteralBig(benchmark::State& state) { +}111021113874234977272220821457
    std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 timesvoid AppendStdStrStrConstLiteralBig(benchmark::State& state) { std::string p1 = TEXT_16; for (auto _: state) { std::string result; @@ -2180,8 +2239,8 @@ void AppendLstringStrConstLiteral(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}7120374730187478196731119182
    lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 timestemplate<unsigned N> +}6996773347192544203527238655
    lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 timestemplate<unsigned N> void AppendLstringStrConstLiteralBig(benchmark::State& state) { stringa p1 = TEXT_16; for (auto _: state) { @@ -2198,8 +2257,8 @@ void AppendLstringStrConstLiteralBig(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}1865320473184902380350289
    lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 timestemplate<unsigned N> +}4541444770200772430358092
    lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 timestemplate<unsigned N> void AppendLstringStrConstLiteralBig(benchmark::State& state) { stringa p1 = TEXT_16; for (auto _: state) { @@ -2216,8 +2275,8 @@ void AppendLstringStrConstLiteralBig(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}1901817347168422256847056
    lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 timestemplate<unsigned N> +}2303325460164032277056704
    lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 timestemplate<unsigned N> void AppendLstringStrConstLiteralBig(benchmark::State& state) { stringa p1 = TEXT_16; for (auto _: state) { @@ -2234,8 +2293,8 @@ void AppendLstringStrConstLiteralBig(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}1590517337161402162547969
    lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 timestemplate<unsigned N> +}1926718428162372209555779
    lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 timestemplate<unsigned N> void AppendLstringStrConstLiteralBig(benchmark::State& state) { stringa p1 = TEXT_16; for (auto _: state) { @@ -2252,19 +2311,19 @@ void AppendLstringStrConstLiteralBig(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(p1); } -}1572417747161872118247909
    -

    # Append 2 string of 16 bytes 32 times, 1024 total length

    +

    # Append 2 string of 16 bytes 32 times, 1024 total length

    - - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::stringstream str; ... str << str_var1 << str_var2;void AppendStream2String(benchmark::State& state) { +
    std::stringstream str; ... str << str_var1 << str_var2;void AppendStream2String(benchmark::State& state) { std::string s1 = TEXT_16; std::string s2 = TEXT_16; for (auto _: state) { @@ -2284,8 +2343,8 @@ void AppendLstringStrConstLiteralBig(benchmark::State& state) { benchmark::DoNotOptimize(s1); benchmark::DoNotOptimize(s2); } -}13991390454252487139
    std::string str; ... str += str_var1 + str_var2;void AppendStdStr2String(benchmark::State& state) { +}136113524325526516125
    std::string str; ... str += str_var1 + str_var2;void AppendStdStr2String(benchmark::State& state) { std::string s1 = TEXT_16; std::string s2 = TEXT_16; @@ -2304,8 +2363,8 @@ void AppendLstringStrConstLiteralBig(benchmark::State& state) { benchmark::DoNotOptimize(s1); benchmark::DoNotOptimize(s2); } -}13561351383740212572
    lstringa<16> str; ... str += str_var1 + str_var2;template<unsigned N> +}13971422407240345089
    lstringa<16> str; ... str += str_var1 + str_var2;template<unsigned N> void AppendLstring2String(benchmark::State& state) { stra s1 = TEXT_16; stra s2 = TEXT_16; @@ -2324,8 +2383,8 @@ void AppendLstring2String(benchmark::State& state) { benchmark::DoNotOptimize(s1); benchmark::DoNotOptimize(s2); } -}5365478169001204
    lstringa<128> str; ... str += str_var1 + str_var2;template<unsigned N> +}4524657949111846
    lstringa<128> str; ... str += str_var1 + str_var2;template<unsigned N> void AppendLstring2String(benchmark::State& state) { stra s1 = TEXT_16; stra s2 = TEXT_16; @@ -2344,8 +2403,8 @@ void AppendLstring2String(benchmark::State& state) { benchmark::DoNotOptimize(s1); benchmark::DoNotOptimize(s2); } -}4314555266221079
    lstringa<512> str; ... str += str_var1 + str_var2;template<unsigned N> +}4074155126201663
    lstringa<512> str; ... str += str_var1 + str_var2;template<unsigned N> void AppendLstring2String(benchmark::State& state) { stra s1 = TEXT_16; stra s2 = TEXT_16; @@ -2364,8 +2423,8 @@ void AppendLstring2String(benchmark::State& state) { benchmark::DoNotOptimize(s1); benchmark::DoNotOptimize(s2); } -}404428382462993
    lstringa<1024> str; ... str += str_var1 + str_var2;template<unsigned N> +}3513613954691291
    lstringa<1024> str; ... str += str_var1 + str_var2;template<unsigned N> void AppendLstring2String(benchmark::State& state) { stra s1 = TEXT_16; stra s2 = TEXT_16; @@ -2384,19 +2443,19 @@ void AppendLstring2String(benchmark::State& state) { benchmark::DoNotOptimize(s1); benchmark::DoNotOptimize(s2); } -}283318277351947
    -

    # Append text, number, text

    +

    # Append text, number, text

    - - + - + - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::stringstream str; str << "test = " << k << " times";void AppendStreamStrNumStr(benchmark::State& state) { +
    std::stringstream str; str << "test = " << k << " times";void AppendStreamStrNumStr(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { std::stringstream t; @@ -2412,8 +2471,8 @@ void AppendLstring2String(benchmark::State& state) { benchmark::DoNotOptimize(k); } } -}29753118108081162511745
    std::string str = "test = " + std::to_string(k) + " times";void AppendStdStringStrNumStr(benchmark::State& state) { +}30113192108251146725591
    std::string str = "test = " + std::to_string(k) + " times";void AppendStdStringStrNumStr(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { std::string result = "test = " + std::to_string(k) + " times"; @@ -2427,8 +2486,8 @@ void AppendLstring2String(benchmark::State& state) { benchmark::DoNotOptimize(k); } } -}470444104412331627
    char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;void AppendSprintfStrNumStr(benchmark::State& state) { +}434505106611623456
    char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;void AppendSprintfStrNumStr(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { char buf[100]; @@ -2444,8 +2503,8 @@ void AppendLstring2String(benchmark::State& state) { benchmark::DoNotOptimize(k); } } -}13631517281228065392
    std::string str = std::format("test = {} times", k);void AppendFormatStrNumStr(benchmark::State& state) { +}139115442723274310939
    std::string str = std::format("test = {} times", k);void AppendFormatStrNumStr(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { std::string result = std::format("test = {} times", k); @@ -2459,8 +2518,8 @@ void AppendLstring2String(benchmark::State& state) { benchmark::DoNotOptimize(k); } } -}11121221191323672823
    lstringa<8> str; str.format("test = {} times", k);template<typename T> +}11541453184223975707
    lstringa<8> str; str.format("test = {} times", k);template<typename T> void AppendSimStrStrNumStrF(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { @@ -2478,8 +2537,8 @@ void AppendSimStrStrNumStrF(benchmark::State& state) { } } >> В simstr format с первого раза не помещается в такую строку без аллокации. In simstr format, the first time it doesn't fit into such a -string without allocation.13061732207126244756
    lstringa<32> str; str.format("test = {} times", k);template<typename T> +string without allocation.13741547201227128601
    lstringa<32> str; str.format("test = {} times", k);template<typename T> void AppendSimStrStrNumStrF(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { @@ -2496,8 +2555,8 @@ void AppendSimStrStrNumStrF(benchmark::State& state) { } } } >> А в такую помещается. Используйте сразу буфера подходящего размера. -And it fits in this one. Use buffers of the appropriate size right away.9461099100614814212
    lstringa<8> str = "test = " + k + " times";template<typename T> +And it fits in this one. Use buffers of the appropriate size right away.9971083100415217339
    lstringa<8> str = "test = " + k + " times";template<typename T> void AppendSimStrStrNumStr(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { @@ -2513,8 +2572,8 @@ void AppendSimStrStrNumStr(benchmark::State& state) { } } } >> Результат не помещается в SSO, возникает аллокация. -The result does not fit into SSO, an allocation occurs.292299836898565
    lstringa<32> str = "test = " + k + " times";template<typename T> +The result does not fit into SSO, an allocation occurs.2722958218991332
    lstringa<32> str = "test = " + k + " times";template<typename T> void AppendSimStrStrNumStr(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { @@ -2532,8 +2591,8 @@ void AppendSimStrStrNumStr(benchmark::State& state) { } >> А здесь и ниже - результат укладывается в SSO. Ещё раз - используйте сразу буфера подходящего размера. And here and below, the result fits within SSO. -Once again, use appropriately sized buffers from the start.151180155194338
    stringa str = "test = " + k + " times";template<typename T> +Once again, use appropriately sized buffers from the start.124149136177570
    stringa str = "test = " + k + " times";template<typename T> void AppendSimStrStrNumStr(benchmark::State& state) { for (auto _: state) { for (unsigned k = 1; k <= 1'000'000'000; k *= 10) { @@ -2551,22 +2610,22 @@ void AppendSimStrStrNumStr(benchmark::State& state) { } >> Под WASM размер SSO 15 символов, что явно не хватает для размещения результата, отсюда и такое время. Under WASM, the SSO size is 15 characters, which is clearly not -enough to accommodate the result, hence the long time.154189156236564
    -

    # Split text and convert to int

    +

    # Split text and convert to int

    - - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    std::string::find + substr + std::strtolvoid SplitConvertIntStdString(benchmark::State& state) { +
    std::string::find + substr + std::strtolvoid SplitConvertIntStdString(benchmark::State& state) { std::string numbers = NUMBER_LIST; for (auto _: state) { int total = 0; @@ -2588,8 +2647,8 @@ enough to accommodate the result, hence the long time.287290541543693
    ssa::splitter + ssa::as_intvoid SplitConvertIntSimStr(benchmark::State& state) { +}2662755465511483
    ssa::splitter + ssa::as_intvoid SplitConvertIntSimStr(benchmark::State& state) { stra numbers = NUMBER_LIST; for (auto _: state) { int total = 0; @@ -2605,8 +2664,8 @@ enough to accommodate the result, hence the long time.150147158296250
    ssa::splitf + functorvoid SplitConvertIntSplitf(benchmark::State& state) { +}156151165300587
    ssa::splitf + functorvoid SplitConvertIntSplitf(benchmark::State& state) { stra numbers = NUMBER_LIST; for (auto _: state) { int total = 0; @@ -2620,16 +2679,16 @@ enough to accommodate the result, hence the long time.204136181213277
    -

    # Replace symbols in text ~400 symbols

    +

    # Replace symbols in text ~400 symbols

    - - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Naive (and wrong) replace symbols with std::string find + replacevoid ReplaceSymbolsStdStringNaiveWrong(benchmark::State& state) { +
    Naive (and wrong) replace symbols with std::string find + replacevoid ReplaceSymbolsStdStringNaiveWrong(benchmark::State& state) { std::string_view source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" " ksjd-fksjd \"dkjfs-jkhdf dfj ' kdkd \"dkfdkfkdjf" @@ -2686,8 +2745,8 @@ enough to accommodate the result, hence the long time.'b' and 'b'->'a'. But if the substitutions don't conflict, -it works quickly.847925117112503150
    replace symbols with std::string find_first_of + replacevoid ReplaceSymbolsStdStringNaiveRight(benchmark::State& state) { +it works quickly.835834110812244781
    replace symbols with std::string find_first_of + replacevoid ReplaceSymbolsStdStringNaiveRight(benchmark::State& state) { std::string_view source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" " ksjd-fksjd \"dkjfs-jkhdf dfj ' kdkd \"dkfdkfkdjf" @@ -2741,8 +2800,8 @@ it works quickly.847 >> Дальше уже правильные реализации, не зависящие от конфликтующих замен. Further, there are correct implementations that do not depend on -conflicting replacements.24052787204921604982
    replace symbols with std::string_view find_first_of + copyvoid ReplaceSymbolsStdString(benchmark::State& state) { +conflicting replacements.24592603200922648914
    replace symbols with std::string_view find_first_of + copyvoid ReplaceSymbolsStdString(benchmark::State& state) { std::string_view source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" " ksjd-fksjd \"dkjfs-jkhdf dfj ' kdkd \"dkfdkfkdjf" @@ -2793,8 +2852,8 @@ conflicting replacements.240510811082235725593246
    replace runtime symbols with string expressions and without remembering all search resultstemplate<bool UseVector> +}11281037227726624601
    replace runtime symbols with string expressions and without remembering all search resultstemplate<bool UseVector> void ReplaceSymbolsDynPatternSimStr(benchmark::State& state) { stra source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" @@ -2839,8 +2898,8 @@ void ReplaceSymbolsDynPatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(source); benchmark::DoNotOptimize(repl); } -}12341483145115853117
    replace runtime symbols with simstr and memorization of all search resultstemplate<bool UseVector> +}12681542144815824270
    replace runtime symbols with simstr and memorization of all search resultstemplate<bool UseVector> void ReplaceSymbolsDynPatternSimStr(benchmark::State& state) { stra source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" @@ -2885,8 +2944,8 @@ void ReplaceSymbolsDynPatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(source); benchmark::DoNotOptimize(repl); } -}9891047134614232534
    replace const symbols with string expressions and without remembering all search resultstemplate<bool UseVector> +}10101156136313983830
    replace const symbols with string expressions and without remembering all search resultstemplate<bool UseVector> void ReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { stra source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" @@ -2928,8 +2987,8 @@ void ReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}10991228122813062608
    replace const symbols with string expressions and memorization of all search resultstemplate<bool UseVector> +}10611193122912513372
    replace const symbols with string expressions and memorization of all search resultstemplate<bool UseVector> void ReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { stra source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" @@ -2971,20 +3030,20 @@ void ReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}862850112112402259
    -

    # Replace symbols in text ~40 symbols

    +

    # Replace symbols in text ~40 symbols

    - - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Short Naive (and wrong) replace symbols with std::string find + replacevoid ShortReplaceSymbolsStdStringNaiveWrong(benchmark::State& state) { +
    Short Naive (and wrong) replace symbols with std::string find + replacevoid ShortReplaceSymbolsStdStringNaiveWrong(benchmark::State& state) { std::string_view source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" ; @@ -3022,8 +3081,8 @@ void ReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(source); benchmark::DoNotOptimize(repl); } -}163165320327449
    Short replace symbols with std::string find_first_of + replacevoid ShortReplaceSymbolsStdStringNaiveRight(benchmark::State& state) { +}150154305337866
    Short replace symbols with std::string find_first_of + replacevoid ShortReplaceSymbolsStdStringNaiveRight(benchmark::State& state) { std::string_view source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" ; @@ -3061,8 +3120,8 @@ void ReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(source); benchmark::DoNotOptimize(repl); } -}319313364434628
    Short replace symbols with std::string_view find_first_of + copyvoid ShortReplaceSymbolsStdString(benchmark::State& state) { +}3133013564231328
    Short replace symbols with std::string_view find_first_of + copyvoid ShortReplaceSymbolsStdString(benchmark::State& state) { std::string_view source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" ; @@ -3099,8 +3158,8 @@ void ReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}162156319368474
    Short replace runtime symbols with string expressions and without remembering all search resultstemplate<bool UseVector> +}153154307350797
    Short replace runtime symbols with string expressions and without remembering all search resultstemplate<bool UseVector> void ShortReplaceSymbolsDynPatternSimStr(benchmark::State& state) { stra source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" @@ -3131,8 +3190,8 @@ void ShortReplaceSymbolsDynPatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(source); benchmark::DoNotOptimize(repl); } -}175188266306376
    Short replace runtime symbols with simstr and memorization of all search resultstemplate<bool UseVector> +}172178259298656
    Short replace runtime symbols with simstr and memorization of all search resultstemplate<bool UseVector> void ShortReplaceSymbolsDynPatternSimStr(benchmark::State& state) { stra source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" @@ -3163,8 +3222,8 @@ void ShortReplaceSymbolsDynPatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(source); benchmark::DoNotOptimize(repl); } -}180193355409435
    Short replace const symbols with string expressions and without remembering all search resultstemplate<bool UseVector> +}173192355396831
    Short replace const symbols with string expressions and without remembering all search resultstemplate<bool UseVector> void ShortReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { stra source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" @@ -3192,8 +3251,8 @@ void ShortReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}137150225268285
    Short replace const symbols with string expressions and memorization of all search resultstemplate<bool UseVector> +}138149199253438
    Short replace const symbols with string expressions and memorization of all search resultstemplate<bool UseVector> void ShortReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { stra source = "abcdefg124 < jhsfjsh sjdfsh jfhjd && jdjdj >" @@ -3221,20 +3280,20 @@ void ShortReplaceSymbolsCons2PatternSimStr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}142143292346312
    -

    # Replace All Str To Longer Size

    +

    # Replace All Str To Longer Size

    - - + - + - + - + - + - + - + - + - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    replace bb to ---- in std::string|64template<size_t Long> +
    replace bb to ---- in std::string|64template<size_t Long> void ReplaceAllLongerStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3266,8 +3325,8 @@ void ReplaceAllLongerStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}158159224246422
    replace bb to ---- in std::string|256template<size_t Long> +}157152217241754
    replace bb to ---- in std::string|256template<size_t Long> void ReplaceAllLongerStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3299,8 +3358,8 @@ void ReplaceAllLongerStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}5325027567971229
    replace bb to ---- in std::string|512template<size_t Long> +}5274637367912292
    replace bb to ---- in std::string|512template<size_t Long> void ReplaceAllLongerStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3332,8 +3391,8 @@ void ReplaceAllLongerStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}10231124143114842359
    replace bb to ---- in std::string|1024template<size_t Long> +}13321323138514254359
    replace bb to ---- in std::string|1024template<size_t Long> void ReplaceAllLongerStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3365,8 +3424,8 @@ void ReplaceAllLongerStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}23572263311231875079
    replace bb to ---- in std::string|2048template<size_t Long> +}23592217304831308819
    replace bb to ---- in std::string|2048template<size_t Long> void ReplaceAllLongerStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3398,8 +3457,8 @@ void ReplaceAllLongerStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}578958987873826412214
    replace bb to ---- in lstringa<8>|64template<size_t N, size_t Count> +}547958117662795018166
    replace bb to ---- in lstringa<8>|64template<size_t N, size_t Count> void ReplaceAllLongerSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3420,8 +3479,8 @@ void ReplaceAllLongerSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}141163217234311
    replace bb to ---- in lstringa<8>|256template<size_t N, size_t Count> +}137137218234590
    replace bb to ---- in lstringa<8>|256template<size_t N, size_t Count> void ReplaceAllLongerSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3442,8 +3501,8 @@ void ReplaceAllLongerSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}441480622674964
    replace bb to ---- in lstringa<8>|512template<size_t N, size_t Count> +}4264516136621916
    replace bb to ---- in lstringa<8>|512template<size_t N, size_t Count> void ReplaceAllLongerSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3464,8 +3523,8 @@ void ReplaceAllLongerSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}828909105011321801
    replace bb to ---- in lstringa<8>|1024template<size_t N, size_t Count> +}781857105611183332
    replace bb to ---- in lstringa<8>|1024template<size_t N, size_t Count> void ReplaceAllLongerSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3486,8 +3545,8 @@ void ReplaceAllLongerSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}16891860190620703329
    replace bb to ---- in lstringa<8>|2048template<size_t N, size_t Count> +}15741683189419996057
    replace bb to ---- in lstringa<8>|2048template<size_t N, size_t Count> void ReplaceAllLongerSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3508,8 +3567,8 @@ void ReplaceAllLongerSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}31623465360439286478
    replace bb to ---- by init stringa|64template<size_t Count> +}302433863567391411959
    replace bb to ---- by init stringa|64template<size_t Count> void ReplaceAllLongerSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3517,7 +3576,7 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { lstringa<2048> big_source{Count, source}, big_sample{Count, sample}; for (auto _: state) { - stringa result = e_repl(big_source.to_str(), "bb", "----"); + stringa result = e_repl(big_source, "bb", "----"); #ifdef CHECK_RESULT if (result.to_str() != big_sample) { @@ -3529,8 +3588,8 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}95.598.5184204205
    replace bb to ---- by init stringa|256template<size_t Count> +}91.990.1170195403
    replace bb to ---- by init stringa|256template<size_t Count> void ReplaceAllLongerSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3538,7 +3597,7 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { lstringa<2048> big_source{Count, source}, big_sample{Count, sample}; for (auto _: state) { - stringa result = e_repl(big_source.to_str(), "bb", "----"); + stringa result = e_repl(big_source, "bb", "----"); #ifdef CHECK_RESULT if (result.to_str() != big_sample) { @@ -3550,8 +3609,8 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}305302373483620
    replace bb to ---- by init stringa|512template<size_t Count> +}3052943694651149
    replace bb to ---- by init stringa|512template<size_t Count> void ReplaceAllLongerSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3559,7 +3618,7 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { lstringa<2048> big_source{Count, source}, big_sample{Count, sample}; for (auto _: state) { - stringa result = e_repl(big_source.to_str(), "bb", "----"); + stringa result = e_repl(big_source, "bb", "----"); #ifdef CHECK_RESULT if (result.to_str() != big_sample) { @@ -3571,8 +3630,8 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}72972981410601395
    replace bb to ---- by init stringa|1024template<size_t Count> +}70067380610642695
    replace bb to ---- by init stringa|1024template<size_t Count> void ReplaceAllLongerSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3580,7 +3639,7 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { lstringa<2048> big_source{Count, source}, big_sample{Count, sample}; for (auto _: state) { - stringa result = e_repl(big_source.to_str(), "bb", "----"); + stringa result = e_repl(big_source, "bb", "----"); #ifdef CHECK_RESULT if (result.to_str() != big_sample) { @@ -3592,8 +3651,8 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}15021639162922792995
    replace bb to ---- by init stringa|2048template<size_t Count> +}15641470165822185688
    replace bb to ---- by init stringa|2048template<size_t Count> void ReplaceAllLongerSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa----baaaaaaaa--------aaaaabaaaaaaaaaaaaaaaaaaaaa----a"; @@ -3601,7 +3660,7 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { lstringa<2048> big_source{Count, source}, big_sample{Count, sample}; for (auto _: state) { - stringa result = e_repl(big_source.to_str(), "bb", "----"); + stringa result = e_repl(big_source, "bb", "----"); #ifdef CHECK_RESULT if (result.to_str() != big_sample) { @@ -3613,28 +3672,28 @@ void ReplaceAllLongerSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}31503376302945265944
    -

    # Replace All Str To Same Size

    +

    # Replace All Str To Same Size

    - - + - + - + - + - + - + - + - + - + - + - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    replace bb to -- in std::string|64template<size_t Long> +
    replace bb to -- in std::string|64template<size_t Long> void ReplaceAllEqualStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3665,8 +3724,8 @@ void ReplaceAllEqualStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}125117193213282
    replace bb to -- in std::string|256template<size_t Long> +}131113186200556
    replace bb to -- in std::string|256template<size_t Long> void ReplaceAllEqualStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3697,8 +3756,8 @@ void ReplaceAllEqualStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}392392561540853
    replace bb to -- in std::string|512template<size_t Long> +}3673604645271773
    replace bb to -- in std::string|512template<size_t Long> void ReplaceAllEqualStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3729,8 +3788,8 @@ void ReplaceAllEqualStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}75870510229751670
    replace bb to -- in std::string|1024template<size_t Long> +}7227298439253125
    replace bb to -- in std::string|1024template<size_t Long> void ReplaceAllEqualStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3761,8 +3820,8 @@ void ReplaceAllEqualStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}14151346159618123119
    replace bb to -- in std::string|2048template<size_t Long> +}14291303157618496361
    replace bb to -- in std::string|2048template<size_t Long> void ReplaceAllEqualStdString(benchmark::State& state) { std::string_view source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; std::string_view sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3793,8 +3852,8 @@ void ReplaceAllEqualStdString(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}30322835348935626498
    replace bb to -- in lstringa<8>|64template<size_t N, size_t Long> +}280126423142343211893
    replace bb to -- in lstringa<8>|64template<size_t N, size_t Long> void ReplaceAllEqualSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3814,8 +3873,8 @@ void ReplaceAllEqualSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}97.7102184196221
    replace bb to -- in lstringa<8>|256template<size_t N, size_t Long> +}99.693.3185184439
    replace bb to -- in lstringa<8>|256template<size_t N, size_t Long> void ReplaceAllEqualSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3835,8 +3894,8 @@ void ReplaceAllEqualSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}290284435459671
    replace bb to -- in lstringa<8>|512template<size_t N, size_t Long> +}2892844234411355
    replace bb to -- in lstringa<8>|512template<size_t N, size_t Long> void ReplaceAllEqualSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3856,8 +3915,8 @@ void ReplaceAllEqualSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}5515257467911237
    replace bb to -- in lstringa<8>|1024template<size_t N, size_t Long> +}5235177287732540
    replace bb to -- in lstringa<8>|1024template<size_t N, size_t Long> void ReplaceAllEqualSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3877,8 +3936,8 @@ void ReplaceAllEqualSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}11291047136115192398
    replace bb to -- in lstringa<8>|2048template<size_t N, size_t Long> +}10581029140314384650
    replace bb to -- in lstringa<8>|2048template<size_t N, size_t Long> void ReplaceAllEqualSimString(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3898,8 +3957,8 @@ void ReplaceAllEqualSimString(benchmark::State& state) { benchmark::DoNotOptimize(result); benchmark::DoNotOptimize(source); } -}21461993264828884661
    replace bb to -- by init stringa|64template<size_t Count> +}20932035268627979148
    replace bb to -- by init stringa|64template<size_t Count> void ReplaceAllEqualSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3923,8 +3982,8 @@ void ReplaceAllEqualSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}84.593.5155176171
    replace bb to -- by init stringa|256template<size_t Count> +}74.483.5151165309
    replace bb to -- by init stringa|256template<size_t Count> void ReplaceAllEqualSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3948,8 +4007,8 @@ void ReplaceAllEqualSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}239268349389528
    replace bb to -- by init stringa|512template<size_t Count> +}238263320371967
    replace bb to -- by init stringa|512template<size_t Count> void ReplaceAllEqualSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3973,8 +4032,8 @@ void ReplaceAllEqualSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}424506599647881
    replace bb to -- by init stringa|1024template<size_t Count> +}4205165236131774
    replace bb to -- by init stringa|1024template<size_t Count> void ReplaceAllEqualSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -3998,8 +4057,8 @@ void ReplaceAllEqualSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}8961045105612221721
    replace bb to -- by init stringa|2048template<size_t Count> +}86999997811033375
    replace bb to -- by init stringa|2048template<size_t Count> void ReplaceAllEqualSimStringExpr(benchmark::State& state) { ssa source = "aaaaaaaaaaaaaaaaaaabbbaaaaaaaabbbbaaaaabaaaaaaaaaaaaaaaaaaaaabba"; ssa sample = "aaaaaaaaaaaaaaaaaaa--baaaaaaaa----aaaaabaaaaaaaaaaaaaaaaaaaaa--a"; @@ -4023,28 +4082,28 @@ void ReplaceAllEqualSimStringExpr(benchmark::State& state) { benchmark::DoNotOptimize(pattern); benchmark::DoNotOptimize(repl); } -}16852003202422803318
    -

    # Hash Map insert and find

    +

    # Hash Map insert and find

    - - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    hashStrMapA<size_t> emplace & find stringa;void HashMapSimStr(benchmark::State& state) { +
    hashStrMapA<size_t> emplace & find stringa;void HashMapSimStr(benchmark::State& state) { for (auto _: state) { hashStrMapA<size_t> store; for (size_t idx = 0; idx < bs_sim.size(); idx++) { @@ -4069,8 +4128,8 @@ void ReplaceAllEqualSimStringExpr(benchmark::State& state) { } >> Вставляем в hashStrMapA 10000 stringa длиной от 30 до 50 символов, а потом ищем их в ней We insert 10,000 strings of length from 30 to 50 characters into -hashStrMapA, and then search for them in it.35473423717070399026042403703294169
    std::unordered_map<std::string, size_t> emplace & find std::string;void HashMapStdStr(benchmark::State& state) { +hashStrMapA, and then search for them in it.35196143793699392201544048705122075
    std::unordered_map<std::string, size_t> emplace & find std::string;void HashMapStdStr(benchmark::State& state) { for (auto _: state) { std::unordered_map<std::string, size_t> store; for (size_t idx = 0; idx < bs_std.size(); idx++) { @@ -4093,8 +4152,8 @@ hashStrMapA, and then search for them in it. >> То же самое c std::string и std::unordered_map -Same thing with std::string and std::unordered_map35237323567358569677054650213593372
    hashStrMapA<size_t> emplace & find ssa;void HashMapSimSsa(benchmark::State& state) { +Same thing with std::string and std::unordered_map34295633632923558469557212966141653
    hashStrMapA<size_t> emplace & find ssa;void HashMapSimSsa(benchmark::State& state) { for (auto _: state) { hashStrMapA<size_t> store; for (size_t idx = 0; idx < bs_sim.size(); idx++) { @@ -4118,8 +4177,8 @@ Same thing with std::string and std::unordered_map >> Теперь вставляем stringa, а ищем ssa -Now we insert stringa and search for ssa35544033701465345356239256463280453
    std::unordered_map<std::string, size_t> emplace & find std::string_view;void HashMapStdStrView(benchmark::State& state) { +Now we insert stringa and search for ssa35265983697109352321938990025107848
    std::unordered_map<std::string, size_t> emplace & find std::string_view;void HashMapStdStrView(benchmark::State& state) { for (auto _: state) { std::unordered_map<std::string, size_t> store; for (size_t idx = 0; idx < bs_std.size(); idx++) { @@ -4143,17 +4202,17 @@ Now we insert stringa and search for ssa >> Вставляем std::string, а ищем std::string_view -We insert std::string and look for std::string_view39556013941394629366562426933999371
    -

    # Build Full Func Name

    +

    # Build Full Func Name

    - - + - + - + - + -
    Benchmark nameCommentXeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13Xeon E5-2682 v4, Windows 10, Clang-19Xeon E5-2682 v4, Windows 10, MSVC-19Xeon E5-2682 v4, WASM Chrome 143, Clang-21
    Build func full name std::string;std::string build_full_name_std() const { +
    Build func full name std::string;std::string build_full_name_std() const { std::string str{has_ret_type_resolver ? "any"sv : type_names_sv[(unsigned)ret_type]}; str += " "; str += std_name; @@ -4190,8 +4249,8 @@ We insert std::string and look for std::string_view721971159316643564
    Build func full name std::string 1;std::string build_full_name_std1() const { +return values. The algorithm uses std::string.660812150515775362
    Build func full name std::string 1;std::string build_full_name_std1() const { std::string str{has_ret_type_resolver ? "any"sv : type_names_sv[(unsigned)ret_type]}; str += " " + std_name + "("; @@ -4222,8 +4281,8 @@ return values. The algorithm uses std::string. >> Почти тот же алгоритм, но несколько последовательных += к строке заменены на одно += + + +. Almost the same algorithm, but several consecutive -+= to a string are replaced with a single += + + +.8281015158517693650
    Build func full name std::stream;std::string build_full_name_stream() const { ++= to a string are replaced with a single += + + +.758935150116226029
    Build func full name std::stream;std::string build_full_name_stream() const { std::ostringstream str; if (has_ret_type_resolver) { str << "any"; @@ -4256,8 +4315,8 @@ Almost the same algorithm, but several consecutive str << ")"; return str.str(); } >> Строим имя функции через std::ostringstream и << -We construct the function name through std::ostringstream and <<256125698042977812092
    Build func full name stringa;stringa build_full_name() const { +We construct the function name through std::ostringstream and <<255725278093957925412
    Build func full name stringa;stringa build_full_name() const { lstringa<512> str = e_choice(has_ret_type_resolver, "any", type_names[(unsigned)ret_type]) + " " + name + "("; bool add_comma = false; @@ -4274,8 +4333,8 @@ We construct the function name through std::ostringstream and << >> Реализация на simstr строках и строковых выражениях. Инфа о параметрах добавляется в текущую строку Implementation using simstr strings and string expressions. -Parameter information is appended to the current line.5034638078731696
    Build func full name stringa 1;stringa build_full_name1() const { +Parameter information is appended to the current line.4944467478572926
    Build func full name stringa 1;stringa build_full_name1() const { lstringa<512> str = e_choice(has_ret_type_resolver, "any", type_names[(unsigned)ret_type]) + " " + name + "("; bool add_comma = false; @@ -4292,11 +4351,11 @@ Parameter information is appended to the current line.67166490010402029
    \ No newline at end of file diff --git a/bench/results/000-Xeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21.txt b/bench/results/000-Xeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21.txt index 562cb5b..e40988d 100644 --- a/bench/results/000-Xeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21.txt +++ b/bench/results/000-Xeon E5-2682 v4, Ubuntu 22 (WSL), Clang-21.txt @@ -2,7 +2,7 @@ Benchmarks of simstr, version 1.6.7 Sources: https://github.com/orefkov/simstr Results: https://orefkov.github.io/simstr/results.html -2026-02-12T15:14:20+03:00 +2026-02-14T12:00:49+03:00 Running ./benchStr Run on (32 X 2494.22 MHz CPU s) CPU Caches: @@ -10,930 +10,967 @@ CPU Caches: L1 Instruction 32 KiB (x16) L2 Unified 256 KiB (x16) L3 Unified 40960 KiB (x1) -Load Average: 0.00, 0.00, 0.00 +Load Average: 0.43, 0.77, 0.52 ***WARNING*** ASLR is enabled, the results may have unreproducible noise in them. -------------------------------------------------------------------------------------------------------------------------------------------------------- Benchmark Time CPU Iterations -------------------------------------------------------------------------------------------------------------------------------------------------------- +----- Concatenate email ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 +Concat email std::format_mean 163 ns 163 ns 4 +Concat email std::format_median 164 ns 164 ns 4 +Concat email std::format_stddev 4.45 ns 4.45 ns 4 +Concat email std::format_cv 2.73 % 2.73 % 4 +Concat email std::stringstream_mean 322 ns 322 ns 4 +Concat email std::stringstream_median 322 ns 322 ns 4 +Concat email std::stringstream_stddev 4.22 ns 4.22 ns 4 +Concat email std::stringstream_cv 1.31 % 1.31 % 4 +Concat email stringzilla append_mean 133 ns 133 ns 4 +Concat email stringzilla append_median 131 ns 131 ns 4 +Concat email stringzilla append_stddev 5.72 ns 5.72 ns 4 +Concat email stringzilla append_cv 4.31 % 4.31 % 4 +Concat email stringzilla concat_mean 54.9 ns 54.9 ns 4 +Concat email stringzilla concat_median 54.2 ns 54.2 ns 4 +Concat email stringzilla concat_stddev 3.02 ns 3.02 ns 4 +Concat email stringzilla concat_cv 5.50 % 5.50 % 4 +Concat email std::string append_mean 72.1 ns 72.1 ns 4 +Concat email std::string append_median 71.4 ns 71.4 ns 4 +Concat email std::string append_stddev 3.01 ns 3.01 ns 4 +Concat email std::string append_cv 4.18 % 4.18 % 4 +Concat email std::string by strexpr_mean 44.3 ns 44.3 ns 4 +Concat email std::string by strexpr_median 44.4 ns 44.4 ns 4 +Concat email std::string by strexpr_stddev 2.96 ns 2.96 ns 4 +Concat email std::string by strexpr_cv 6.67 % 6.67 % 4 +Concat email stringa_mean 39.9 ns 39.9 ns 4 +Concat email stringa_median 39.3 ns 39.3 ns 4 +Concat email stringa_stddev 2.33 ns 2.33 ns 4 +Concat email stringa_cv 5.85 % 5.85 % 4 ----- Concatenate string + Number + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string and number by std to std::string_mean 211 ns 211 ns 4 -Concat std::string and number by std to std::string_median 211 ns 211 ns 4 -Concat std::string and number by std to std::string_stddev 2.33 ns 2.33 ns 4 -Concat std::string and number by std to std::string_cv 1.10 % 1.10 % 4 -Concat std::string and number by StrExpr to std::string_mean 102 ns 102 ns 4 -Concat std::string and number by StrExpr to std::string_median 102 ns 102 ns 4 -Concat std::string and number by StrExpr to std::string_stddev 1.47 ns 1.47 ns 4 -Concat std::string and number by StrExpr to std::string_cv 1.44 % 1.44 % 4 -Concat stringa and number by StrExpr to simstr::stringa_mean 63.1 ns 63.1 ns 4 +Concat std::string and number by std to std::string_mean 214 ns 214 ns 4 +Concat std::string and number by std to std::string_median 214 ns 214 ns 4 +Concat std::string and number by std to std::string_stddev 3.43 ns 3.43 ns 4 +Concat std::string and number by std to std::string_cv 1.60 % 1.60 % 4 +Concat std::string and number by StrExpr to std::string_mean 103 ns 103 ns 4 +Concat std::string and number by StrExpr to std::string_median 103 ns 103 ns 4 +Concat std::string and number by StrExpr to std::string_stddev 2.19 ns 2.19 ns 4 +Concat std::string and number by StrExpr to std::string_cv 2.13 % 2.13 % 4 +Concat stringa and number by StrExpr to simstr::stringa_mean 63.0 ns 63.0 ns 4 Concat stringa and number by StrExpr to simstr::stringa_median 63.1 ns 63.1 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_stddev 1.98 ns 1.98 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_cv 3.14 % 3.14 % 4 -Concat stringa and number by e_concat to simstr::stringa_mean 69.5 ns 69.5 ns 4 -Concat stringa and number by e_concat to simstr::stringa_median 69.5 ns 69.5 ns 4 -Concat stringa and number by e_concat to simstr::stringa_stddev 1.68 ns 1.68 ns 4 -Concat stringa and number by e_concat to simstr::stringa_cv 2.42 % 2.42 % 4 +Concat stringa and number by StrExpr to simstr::stringa_stddev 1.13 ns 1.13 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_cv 1.80 % 1.80 % 4 +Concat stringa and number by e_concat to simstr::stringa_mean 67.4 ns 67.4 ns 4 +Concat stringa and number by e_concat to simstr::stringa_median 67.4 ns 67.4 ns 4 +Concat stringa and number by e_concat to simstr::stringa_stddev 0.707 ns 0.707 ns 4 +Concat stringa and number by e_concat to simstr::stringa_cv 1.05 % 1.05 % 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 680 ns 680 ns 4 -Concat std::string and format hex number and literal to std::string_median 666 ns 666 ns 4 -Concat std::string and format hex number and literal to std::string_stddev 34.3 ns 34.3 ns 4 -Concat std::string and format hex number and literal to std::string_cv 5.04 % 5.04 % 4 -std::format std::string and hex number by literal to std::string_mean 865 ns 865 ns 4 -std::format std::string and hex number by literal to std::string_median 844 ns 844 ns 4 -std::format std::string and hex number by literal to std::string_stddev 57.6 ns 57.6 ns 4 -std::format std::string and hex number by literal to std::string_cv 6.66 % 6.66 % 4 -Concat std::string and std::to_chars and string to std::string_mean 198 ns 198 ns 4 -Concat std::string and std::to_chars and string to std::string_median 198 ns 198 ns 4 -Concat std::string and std::to_chars and string to std::string_stddev 3.20 ns 3.20 ns 4 -Concat std::string and std::to_chars and string to std::string_cv 1.62 % 1.62 % 4 +Concat std::string and format hex number and literal to std::string_mean 654 ns 654 ns 4 +Concat std::string and format hex number and literal to std::string_median 649 ns 649 ns 4 +Concat std::string and format hex number and literal to std::string_stddev 22.0 ns 22.0 ns 4 +Concat std::string and format hex number and literal to std::string_cv 3.36 % 3.36 % 4 +std::format std::string and hex number by literal to std::string_mean 874 ns 874 ns 4 +std::format std::string and hex number by literal to std::string_median 878 ns 878 ns 4 +std::format std::string and hex number by literal to std::string_stddev 18.7 ns 18.7 ns 4 +std::format std::string and hex number by literal to std::string_cv 2.14 % 2.14 % 4 +Concat std::string and std::to_chars and string to std::string_mean 196 ns 196 ns 4 +Concat std::string and std::to_chars and string to std::string_median 196 ns 196 ns 4 +Concat std::string and std::to_chars and string to std::string_stddev 1.22 ns 1.22 ns 4 +Concat std::string and std::to_chars and string to std::string_cv 0.62 % 0.62 % 4 Concat std::string and hex number and literal by StrExpr to std::string_mean 131 ns 131 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_median 132 ns 132 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_stddev 1.47 ns 1.47 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_cv 1.12 % 1.12 % 4 +Concat std::string and hex number and literal by StrExpr to std::string_median 130 ns 130 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_stddev 2.93 ns 2.93 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_cv 2.24 % 2.24 % 4 Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 115 ns 115 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 114 ns 114 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 1.65 ns 1.65 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 1.44 % 1.44 % 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 121 ns 121 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 115 ns 115 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 0.413 ns 0.413 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 0.36 % 0.36 % 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 122 ns 122 ns 4 Concat stringa and hex number and literal by e_concat to simstr::stringa_median 121 ns 121 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 0.573 ns 0.573 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 0.47 % 0.47 % 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_mean 183 ns 183 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_median 182 ns 182 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 3.80 ns 3.80 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_cv 2.08 % 2.08 % 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 308 ns 308 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 310 ns 310 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 3.99 ns 3.99 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 1.30 % 1.30 % 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 1.88 ns 1.88 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 1.54 % 1.54 % 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_mean 180 ns 180 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_median 180 ns 180 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 1.33 ns 1.33 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_cv 0.74 % 0.74 % 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 313 ns 313 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 313 ns 313 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 2.04 ns 2.04 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 0.65 % 0.65 % 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 276 ns 276 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 273 ns 273 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 10.5 ns 10.5 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 3.80 % 3.80 % 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 354 ns 354 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 349 ns 349 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 11.6 ns 11.6 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 3.27 % 3.27 % 4 -e_vsubst(pattern, i / 0x8a010_fmt)_mean 618 ns 618 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_median 615 ns 615 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_stddev 14.3 ns 14.3 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_cv 2.31 % 2.31 % 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 882 ns 882 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 881 ns 881 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 5.47 ns 5.47 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 0.62 % 0.62 % 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 819 ns 819 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 825 ns 825 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 15.0 ns 15.0 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.83 % 1.83 % 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_mean 952 ns 952 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_median 959 ns 959 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 18.8 ns 18.8 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.97 % 1.97 % 4 -std::vformat(pattern, std::make_format_args(i))_mean 957 ns 957 ns 4 -std::vformat(pattern, std::make_format_args(i))_median 963 ns 963 ns 4 -std::vformat(pattern, std::make_format_args(i))_stddev 34.8 ns 34.8 ns 4 -std::vformat(pattern, std::make_format_args(i))_cv 3.63 % 3.63 % 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 2019 ns 2019 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 2022 ns 2022 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 33.4 ns 33.4 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 1.65 % 1.65 % 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_mean 280 ns 280 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 279 ns 279 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 11.1 ns 11.1 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 3.96 % 3.96 % 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 341 ns 341 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 337 ns 337 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 9.29 ns 9.29 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 2.72 % 2.72 % 4 +e_vsubst(pattern, i / 0x8a010_fmt)_mean 599 ns 599 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_median 595 ns 595 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_stddev 15.5 ns 15.5 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_cv 2.60 % 2.60 % 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 676 ns 676 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 681 ns 681 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 19.9 ns 19.9 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 2.94 % 2.94 % 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 832 ns 832 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 835 ns 835 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 6.79 ns 6.79 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 0.82 % 0.82 % 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1007 ns 1007 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_median 1003 ns 1003 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 28.1 ns 28.1 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.79 % 2.79 % 4 +std::vformat(pattern, std::make_format_args(i))_mean 1001 ns 1001 ns 4 +std::vformat(pattern, std::make_format_args(i))_median 1006 ns 1006 ns 4 +std::vformat(pattern, std::make_format_args(i))_stddev 19.3 ns 19.3 ns 4 +std::vformat(pattern, std::make_format_args(i))_cv 1.93 % 1.93 % 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 2029 ns 2029 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 2021 ns 2021 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 31.4 ns 31.4 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 1.55 % 1.55 % 4 ----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string by std to std::string_mean 45.1 ns 45.1 ns 4 -Concat std::string by std to std::string_median 45.0 ns 45.0 ns 4 -Concat std::string by std to std::string_stddev 0.744 ns 0.744 ns 4 -Concat std::string by std to std::string_cv 1.65 % 1.65 % 4 -Concat std::string by StrExpr to std::string_mean 34.8 ns 34.8 ns 4 -Concat std::string by StrExpr to std::string_median 35.2 ns 35.2 ns 4 -Concat std::string by StrExpr to std::string_stddev 2.56 ns 2.56 ns 4 -Concat std::string by StrExpr to std::string_cv 7.34 % 7.34 % 4 -Concat stringa by StrExpr to stringa_mean 28.3 ns 28.3 ns 4 -Concat stringa by StrExpr to stringa_median 28.2 ns 28.2 ns 4 -Concat stringa by StrExpr to stringa_stddev 0.824 ns 0.824 ns 4 -Concat stringa by StrExpr to stringa_cv 2.92 % 2.92 % 4 +Concat std::string by std to std::string_mean 49.0 ns 49.0 ns 4 +Concat std::string by std to std::string_median 48.8 ns 48.8 ns 4 +Concat std::string by std to std::string_stddev 0.989 ns 0.989 ns 4 +Concat std::string by std to std::string_cv 2.02 % 2.02 % 4 +Concat std::string by StrExpr to std::string_mean 39.9 ns 39.9 ns 4 +Concat std::string by StrExpr to std::string_median 40.2 ns 40.2 ns 4 +Concat std::string by StrExpr to std::string_stddev 0.729 ns 0.729 ns 4 +Concat std::string by StrExpr to std::string_cv 1.83 % 1.83 % 4 +Concat stringa by StrExpr to stringa_mean 27.1 ns 27.1 ns 4 +Concat stringa by StrExpr to stringa_median 27.2 ns 27.2 ns 4 +Concat stringa by StrExpr to stringa_stddev 0.317 ns 0.317 ns 4 +Concat stringa by StrExpr to stringa_cv 1.17 % 1.17 % 4 ----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Find concat three std::string_mean 111 ns 111 ns 4 -Find concat three std::string_median 111 ns 111 ns 4 -Find concat three std::string_stddev 4.64 ns 4.64 ns 4 -Find concat three std::string_cv 4.17 % 4.17 % 4 -Find concat three strexpr_mean 49.2 ns 49.2 ns 4 -Find concat three strexpr_median 48.8 ns 48.8 ns 4 -Find concat three strexpr_stddev 1.41 ns 1.41 ns 4 -Find concat three strexpr_cv 2.87 % 2.87 % 4 -Find concat three simstr_mean 19.1 ns 19.1 ns 4 -Find concat three simstr_median 19.1 ns 19.1 ns 4 -Find concat three simstr_stddev 0.472 ns 0.472 ns 4 -Find concat three simstr_cv 2.47 % 2.47 % 4 +Find concat three std::string_mean 110 ns 110 ns 4 +Find concat three std::string_median 109 ns 109 ns 4 +Find concat three std::string_stddev 2.79 ns 2.79 ns 4 +Find concat three std::string_cv 2.55 % 2.55 % 4 +Find concat three strexpr_mean 51.5 ns 51.5 ns 4 +Find concat three strexpr_median 49.3 ns 49.3 ns 4 +Find concat three strexpr_stddev 5.16 ns 5.16 ns 4 +Find concat three strexpr_cv 10.03 % 10.03 % 4 +Find concat three simstr_mean 19.4 ns 19.4 ns 4 +Find concat three simstr_median 19.3 ns 19.3 ns 4 +Find concat three simstr_stddev 0.414 ns 0.414 ns 4 +Find concat three simstr_cv 2.13 % 2.13 % 4 +Find concat three stringzilla string_mean 146 ns 146 ns 4 +Find concat three stringzilla string_median 147 ns 147 ns 4 +Find concat three stringzilla string_stddev 6.23 ns 6.23 ns 4 +Find concat three stringzilla string_cv 4.27 % 4.27 % 4 ----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -BuildTypeNameStr 0/0_mean 7.02 ns 7.02 ns 4 -BuildTypeNameStr 0/0_median 7.02 ns 7.02 ns 4 -BuildTypeNameStr 0/0_stddev 0.143 ns 0.143 ns 4 -BuildTypeNameStr 0/0_cv 2.04 % 2.04 % 4 -BuildTypeNameExp 0/0_mean 7.31 ns 7.31 ns 4 -BuildTypeNameExp 0/0_median 7.28 ns 7.28 ns 4 -BuildTypeNameExp 0/0_stddev 0.148 ns 0.148 ns 4 -BuildTypeNameExp 0/0_cv 2.02 % 2.02 % 4 -BuildTypeNameSim 0/0_mean 4.80 ns 4.80 ns 4 -BuildTypeNameSim 0/0_median 4.78 ns 4.78 ns 4 -BuildTypeNameSim 0/0_stddev 0.146 ns 0.146 ns 4 -BuildTypeNameSim 0/0_cv 3.03 % 3.03 % 4 -BuildTypeNameStr 10/10_mean 54.8 ns 54.8 ns 4 -BuildTypeNameStr 10/10_median 54.9 ns 54.9 ns 4 -BuildTypeNameStr 10/10_stddev 2.34 ns 2.34 ns 4 -BuildTypeNameStr 10/10_cv 4.28 % 4.28 % 4 -BuildTypeNameExp 10/10_mean 30.2 ns 30.2 ns 4 -BuildTypeNameExp 10/10_median 30.2 ns 30.2 ns 4 -BuildTypeNameExp 10/10_stddev 0.435 ns 0.435 ns 4 -BuildTypeNameExp 10/10_cv 1.44 % 1.44 % 4 -BuildTypeNameSim 10/10_mean 22.5 ns 22.5 ns 4 -BuildTypeNameSim 10/10_median 22.4 ns 22.4 ns 4 -BuildTypeNameSim 10/10_stddev 0.524 ns 0.524 ns 4 -BuildTypeNameSim 10/10_cv 2.33 % 2.33 % 4 +BuildTypeNameStr 0/0_mean 7.65 ns 7.65 ns 4 +BuildTypeNameStr 0/0_median 7.68 ns 7.68 ns 4 +BuildTypeNameStr 0/0_stddev 0.164 ns 0.164 ns 4 +BuildTypeNameStr 0/0_cv 2.15 % 2.15 % 4 +BuildTypeNameExp 0/0_mean 6.50 ns 6.50 ns 4 +BuildTypeNameExp 0/0_median 6.52 ns 6.52 ns 4 +BuildTypeNameExp 0/0_stddev 0.124 ns 0.124 ns 4 +BuildTypeNameExp 0/0_cv 1.90 % 1.90 % 4 +BuildTypeNameSim 0/0_mean 4.14 ns 4.14 ns 4 +BuildTypeNameSim 0/0_median 4.15 ns 4.15 ns 4 +BuildTypeNameSim 0/0_stddev 0.063 ns 0.063 ns 4 +BuildTypeNameSim 0/0_cv 1.53 % 1.53 % 4 +BuildTypeNameStr 10/10_mean 56.9 ns 56.9 ns 4 +BuildTypeNameStr 10/10_median 56.6 ns 56.6 ns 4 +BuildTypeNameStr 10/10_stddev 1.71 ns 1.71 ns 4 +BuildTypeNameStr 10/10_cv 3.01 % 3.01 % 4 +BuildTypeNameExp 10/10_mean 29.9 ns 29.9 ns 4 +BuildTypeNameExp 10/10_median 30.1 ns 30.1 ns 4 +BuildTypeNameExp 10/10_stddev 0.479 ns 0.479 ns 4 +BuildTypeNameExp 10/10_cv 1.60 % 1.60 % 4 +BuildTypeNameSim 10/10_mean 22.9 ns 22.9 ns 4 +BuildTypeNameSim 10/10_median 22.9 ns 22.9 ns 4 +BuildTypeNameSim 10/10_stddev 0.483 ns 0.483 ns 4 +BuildTypeNameSim 10/10_cv 2.11 % 2.11 % 4 ----- Replace string by copy -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat with replace str_mean 207 ns 207 ns 4 -Concat with replace str_median 207 ns 207 ns 4 -Concat with replace str_stddev 3.33 ns 3.33 ns 4 -Concat with replace str_cv 1.61 % 1.61 % 4 -Concat with replace exp_mean 138 ns 138 ns 4 -Concat with replace exp_median 139 ns 139 ns 4 -Concat with replace exp_stddev 1.77 ns 1.77 ns 4 -Concat with replace exp_cv 1.28 % 1.28 % 4 +Concat with replace str_mean 200 ns 200 ns 4 +Concat with replace str_median 201 ns 201 ns 4 +Concat with replace str_stddev 5.79 ns 5.79 ns 4 +Concat with replace str_cv 2.90 % 2.90 % 4 +Concat with replace exp_mean 147 ns 147 ns 4 +Concat with replace exp_median 147 ns 147 ns 4 +Concat with replace exp_stddev 2.55 ns 2.55 ns 4 +Concat with replace exp_cv 1.73 % 1.73 % 4 ----- Create Empty Str ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e;_mean 1.10 ns 1.10 ns 4 -std::string e;_median 1.10 ns 1.10 ns 4 -std::string e;_stddev 0.021 ns 0.021 ns 4 -std::string e;_cv 1.87 % 1.87 % 4 -std::string_view e;_mean 0.372 ns 0.372 ns 4 -std::string_view e;_median 0.369 ns 0.369 ns 4 -std::string_view e;_stddev 0.005 ns 0.005 ns 4 -std::string_view e;_cv 1.42 % 1.42 % 4 -ssa e;_mean 0.363 ns 0.363 ns 4 -ssa e;_median 0.363 ns 0.363 ns 4 -ssa e;_stddev 0.004 ns 0.004 ns 4 -ssa e;_cv 1.23 % 1.23 % 4 -stringa e;_mean 0.735 ns 0.735 ns 4 -stringa e;_median 0.735 ns 0.735 ns 4 -stringa e;_stddev 0.009 ns 0.009 ns 4 -stringa e;_cv 1.16 % 1.16 % 4 -lstringa<20> e;_mean 1.10 ns 1.10 ns 4 -lstringa<20> e;_median 1.10 ns 1.10 ns 4 -lstringa<20> e;_stddev 0.012 ns 0.012 ns 4 -lstringa<20> e;_cv 1.07 % 1.07 % 4 -lstringa<40> e;_mean 1.10 ns 1.10 ns 4 -lstringa<40> e;_median 1.08 ns 1.08 ns 4 -lstringa<40> e;_stddev 0.047 ns 0.047 ns 4 -lstringa<40> e;_cv 4.21 % 4.21 % 4 +std::string e;_mean 1.11 ns 1.11 ns 4 +std::string e;_median 1.11 ns 1.11 ns 4 +std::string e;_stddev 0.017 ns 0.017 ns 4 +std::string e;_cv 1.55 % 1.55 % 4 +std::string_view e;_mean 0.375 ns 0.375 ns 4 +std::string_view e;_median 0.373 ns 0.373 ns 4 +std::string_view e;_stddev 0.007 ns 0.007 ns 4 +std::string_view e;_cv 1.80 % 1.80 % 4 +ssa e;_mean 0.361 ns 0.361 ns 4 +ssa e;_median 0.361 ns 0.361 ns 4 +ssa e;_stddev 0.005 ns 0.005 ns 4 +ssa e;_cv 1.32 % 1.32 % 4 +stringa e;_mean 0.753 ns 0.753 ns 4 +stringa e;_median 0.750 ns 0.750 ns 4 +stringa e;_stddev 0.011 ns 0.011 ns 4 +stringa e;_cv 1.46 % 1.46 % 4 +lstringa<20> e;_mean 1.20 ns 1.20 ns 4 +lstringa<20> e;_median 1.18 ns 1.18 ns 4 +lstringa<20> e;_stddev 0.062 ns 0.062 ns 4 +lstringa<20> e;_cv 5.22 % 5.22 % 4 +lstringa<40> e;_mean 1.13 ns 1.13 ns 4 +lstringa<40> e;_median 1.13 ns 1.13 ns 4 +lstringa<40> e;_stddev 0.007 ns 0.007 ns 4 +lstringa<40> e;_cv 0.65 % 0.65 % 4 ----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "Test text";_mean 1.84 ns 1.84 ns 4 -std::string e = "Test text";_median 1.85 ns 1.85 ns 4 -std::string e = "Test text";_stddev 0.036 ns 0.036 ns 4 -std::string e = "Test text";_cv 1.93 % 1.93 % 4 -std::string_view e = "Test text";_mean 0.739 ns 0.739 ns 4 -std::string_view e = "Test text";_median 0.738 ns 0.738 ns 4 -std::string_view e = "Test text";_stddev 0.009 ns 0.009 ns 4 -std::string_view e = "Test text";_cv 1.24 % 1.24 % 4 -ssa e = "Test text";_mean 0.363 ns 0.363 ns 4 -ssa e = "Test text";_median 0.363 ns 0.363 ns 4 -ssa e = "Test text";_stddev 0.005 ns 0.005 ns 4 -ssa e = "Test text";_cv 1.48 % 1.48 % 4 +std::string e = "Test text";_mean 1.81 ns 1.81 ns 4 +std::string e = "Test text";_median 1.82 ns 1.82 ns 4 +std::string e = "Test text";_stddev 0.020 ns 0.020 ns 4 +std::string e = "Test text";_cv 1.13 % 1.13 % 4 +std::string_view e = "Test text";_mean 0.731 ns 0.731 ns 4 +std::string_view e = "Test text";_median 0.731 ns 0.731 ns 4 +std::string_view e = "Test text";_stddev 0.018 ns 0.018 ns 4 +std::string_view e = "Test text";_cv 2.49 % 2.49 % 4 +ssa e = "Test text";_mean 0.367 ns 0.367 ns 4 +ssa e = "Test text";_median 0.367 ns 0.367 ns 4 +ssa e = "Test text";_stddev 0.007 ns 0.007 ns 4 +ssa e = "Test text";_cv 1.93 % 1.93 % 4 stringa e = "Test text";_mean 1.11 ns 1.11 ns 4 -stringa e = "Test text";_median 1.11 ns 1.11 ns 4 -stringa e = "Test text";_stddev 0.025 ns 0.025 ns 4 -stringa e = "Test text";_cv 2.26 % 2.26 % 4 -lstringa<20> e = "Test text";_mean 1.87 ns 1.87 ns 4 -lstringa<20> e = "Test text";_median 1.87 ns 1.87 ns 4 -lstringa<20> e = "Test text";_stddev 0.047 ns 0.047 ns 4 -lstringa<20> e = "Test text";_cv 2.53 % 2.53 % 4 -lstringa<40> e = "Test text";_mean 1.90 ns 1.90 ns 4 -lstringa<40> e = "Test text";_median 1.90 ns 1.90 ns 4 -lstringa<40> e = "Test text";_stddev 0.076 ns 0.076 ns 4 -lstringa<40> e = "Test text";_cv 3.98 % 3.98 % 4 +stringa e = "Test text";_median 1.12 ns 1.12 ns 4 +stringa e = "Test text";_stddev 0.022 ns 0.022 ns 4 +stringa e = "Test text";_cv 1.99 % 1.99 % 4 +lstringa<20> e = "Test text";_mean 1.85 ns 1.85 ns 4 +lstringa<20> e = "Test text";_median 1.85 ns 1.85 ns 4 +lstringa<20> e = "Test text";_stddev 0.032 ns 0.032 ns 4 +lstringa<20> e = "Test text";_cv 1.74 % 1.74 % 4 +lstringa<40> e = "Test text";_mean 1.88 ns 1.88 ns 4 +lstringa<40> e = "Test text";_median 1.85 ns 1.85 ns 4 +lstringa<40> e = "Test text";_stddev 0.073 ns 0.073 ns 4 +lstringa<40> e = "Test text";_cv 3.86 % 3.86 % 4 ----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "123456789012345678901234567890";_mean 19.9 ns 19.9 ns 4 -std::string e = "123456789012345678901234567890";_median 19.3 ns 19.3 ns 4 -std::string e = "123456789012345678901234567890";_stddev 1.95 ns 1.95 ns 4 -std::string e = "123456789012345678901234567890";_cv 9.82 % 9.82 % 4 -std::string_view e = "123456789012345678901234567890";_mean 0.729 ns 0.729 ns 4 -std::string_view e = "123456789012345678901234567890";_median 0.728 ns 0.728 ns 4 -std::string_view e = "123456789012345678901234567890";_stddev 0.011 ns 0.011 ns 4 -std::string_view e = "123456789012345678901234567890";_cv 1.45 % 1.45 % 4 -ssa e = "123456789012345678901234567890";_mean 0.366 ns 0.366 ns 4 -ssa e = "123456789012345678901234567890";_median 0.365 ns 0.365 ns 4 -ssa e = "123456789012345678901234567890";_stddev 0.008 ns 0.008 ns 4 -ssa e = "123456789012345678901234567890";_cv 2.10 % 2.10 % 4 -stringa e = "123456789012345678901234567890";_mean 1.12 ns 1.12 ns 4 -stringa e = "123456789012345678901234567890";_median 1.12 ns 1.12 ns 4 -stringa e = "123456789012345678901234567890";_stddev 0.022 ns 0.022 ns 4 -stringa e = "123456789012345678901234567890";_cv 1.99 % 1.99 % 4 -lstringa<20> e = "123456789012345678901234567890";_mean 20.3 ns 20.3 ns 4 -lstringa<20> e = "123456789012345678901234567890";_median 20.2 ns 20.2 ns 4 -lstringa<20> e = "123456789012345678901234567890";_stddev 0.533 ns 0.533 ns 4 -lstringa<20> e = "123456789012345678901234567890";_cv 2.63 % 2.63 % 4 +std::string e = "123456789012345678901234567890";_mean 19.1 ns 19.1 ns 4 +std::string e = "123456789012345678901234567890";_median 19.2 ns 19.2 ns 4 +std::string e = "123456789012345678901234567890";_stddev 0.242 ns 0.242 ns 4 +std::string e = "123456789012345678901234567890";_cv 1.26 % 1.26 % 4 +std::string_view e = "123456789012345678901234567890";_mean 0.762 ns 0.762 ns 4 +std::string_view e = "123456789012345678901234567890";_median 0.748 ns 0.748 ns 4 +std::string_view e = "123456789012345678901234567890";_stddev 0.053 ns 0.053 ns 4 +std::string_view e = "123456789012345678901234567890";_cv 6.97 % 6.97 % 4 +ssa e = "123456789012345678901234567890";_mean 0.369 ns 0.369 ns 4 +ssa e = "123456789012345678901234567890";_median 0.366 ns 0.366 ns 4 +ssa e = "123456789012345678901234567890";_stddev 0.012 ns 0.012 ns 4 +ssa e = "123456789012345678901234567890";_cv 3.15 % 3.15 % 4 +stringa e = "123456789012345678901234567890";_mean 1.09 ns 1.09 ns 4 +stringa e = "123456789012345678901234567890";_median 1.09 ns 1.09 ns 4 +stringa e = "123456789012345678901234567890";_stddev 0.007 ns 0.007 ns 4 +stringa e = "123456789012345678901234567890";_cv 0.64 % 0.64 % 4 +lstringa<20> e = "123456789012345678901234567890";_mean 21.0 ns 21.0 ns 4 +lstringa<20> e = "123456789012345678901234567890";_median 20.6 ns 20.6 ns 4 +lstringa<20> e = "123456789012345678901234567890";_stddev 1.49 ns 1.49 ns 4 +lstringa<20> e = "123456789012345678901234567890";_cv 7.10 % 7.10 % 4 lstringa<40> e = "123456789012345678901234567890";_mean 2.54 ns 2.54 ns 4 lstringa<40> e = "123456789012345678901234567890";_median 2.53 ns 2.53 ns 4 -lstringa<40> e = "123456789012345678901234567890";_stddev 0.032 ns 0.032 ns 4 -lstringa<40> e = "123456789012345678901234567890";_cv 1.27 % 1.27 % 4 +lstringa<40> e = "123456789012345678901234567890";_stddev 0.024 ns 0.024 ns 4 +lstringa<40> e = "123456789012345678901234567890";_cv 0.96 % 0.96 % 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 4.78 ns 4.78 ns 4 -std::string e = "Test text"; auto c{e};_median 4.78 ns 4.78 ns 4 -std::string e = "Test text"; auto c{e};_stddev 0.060 ns 0.060 ns 4 -std::string e = "Test text"; auto c{e};_cv 1.25 % 1.25 % 4 -std::string_view e = "Test text"; auto c{e};_mean 0.363 ns 0.363 ns 4 -std::string_view e = "Test text"; auto c{e};_median 0.365 ns 0.365 ns 4 -std::string_view e = "Test text"; auto c{e};_stddev 0.005 ns 0.005 ns 4 -std::string_view e = "Test text"; auto c{e};_cv 1.39 % 1.39 % 4 -ssa e = "Test text"; auto c{e};_mean 0.368 ns 0.368 ns 4 -ssa e = "Test text"; auto c{e};_median 0.368 ns 0.368 ns 4 -ssa e = "Test text"; auto c{e};_stddev 0.004 ns 0.004 ns 4 -ssa e = "Test text"; auto c{e};_cv 0.97 % 0.97 % 4 -stringa e = "Test text"; auto c{e};_mean 1.08 ns 1.08 ns 4 -stringa e = "Test text"; auto c{e};_median 1.08 ns 1.08 ns 4 -stringa e = "Test text"; auto c{e};_stddev 0.009 ns 0.009 ns 4 -stringa e = "Test text"; auto c{e};_cv 0.84 % 0.84 % 4 -lstringa<20> e = "Test text"; auto c{e};_mean 1.47 ns 1.47 ns 4 -lstringa<20> e = "Test text"; auto c{e};_median 1.47 ns 1.47 ns 4 -lstringa<20> e = "Test text"; auto c{e};_stddev 0.033 ns 0.033 ns 4 -lstringa<20> e = "Test text"; auto c{e};_cv 2.24 % 2.24 % 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.47 ns 1.47 ns 4 -lstringa<40> e = "Test text"; auto c{e};_stddev 0.027 ns 0.027 ns 4 -lstringa<40> e = "Test text"; auto c{e};_cv 1.87 % 1.87 % 4 +std::string e = "Test text"; auto c{e};_mean 5.58 ns 5.58 ns 4 +std::string e = "Test text"; auto c{e};_median 5.57 ns 5.57 ns 4 +std::string e = "Test text"; auto c{e};_stddev 0.112 ns 0.112 ns 4 +std::string e = "Test text"; auto c{e};_cv 2.00 % 2.00 % 4 +std::string_view e = "Test text"; auto c{e};_mean 0.370 ns 0.370 ns 4 +std::string_view e = "Test text"; auto c{e};_median 0.366 ns 0.366 ns 4 +std::string_view e = "Test text"; auto c{e};_stddev 0.016 ns 0.016 ns 4 +std::string_view e = "Test text"; auto c{e};_cv 4.44 % 4.44 % 4 +ssa e = "Test text"; auto c{e};_mean 0.372 ns 0.372 ns 4 +ssa e = "Test text"; auto c{e};_median 0.371 ns 0.371 ns 4 +ssa e = "Test text"; auto c{e};_stddev 0.001 ns 0.001 ns 4 +ssa e = "Test text"; auto c{e};_cv 0.29 % 0.29 % 4 +stringa e = "Test text"; auto c{e};_mean 1.11 ns 1.11 ns 4 +stringa e = "Test text"; auto c{e};_median 1.10 ns 1.10 ns 4 +stringa e = "Test text"; auto c{e};_stddev 0.012 ns 0.012 ns 4 +stringa e = "Test text"; auto c{e};_cv 1.07 % 1.07 % 4 +lstringa<20> e = "Test text"; auto c{e};_mean 1.49 ns 1.49 ns 4 +lstringa<20> e = "Test text"; auto c{e};_median 1.48 ns 1.48 ns 4 +lstringa<20> e = "Test text"; auto c{e};_stddev 0.031 ns 0.031 ns 4 +lstringa<20> e = "Test text"; auto c{e};_cv 2.07 % 2.07 % 4 +lstringa<40> e = "Test text"; auto c{e};_mean 1.48 ns 1.48 ns 4 +lstringa<40> e = "Test text"; auto c{e};_median 1.48 ns 1.48 ns 4 +lstringa<40> e = "Test text"; auto c{e};_stddev 0.040 ns 0.040 ns 4 +lstringa<40> e = "Test text"; auto c{e};_cv 2.73 % 2.73 % 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 18.4 ns 18.4 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_median 18.4 ns 18.4 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_stddev 0.458 ns 0.458 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_cv 2.49 % 2.49 % 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.738 ns 0.738 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.738 ns 0.738 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.002 ns 0.002 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 0.29 % 0.29 % 4 -ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.367 ns 0.367 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_median 0.363 ns 0.363 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.009 ns 0.009 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_cv 2.51 % 2.51 % 4 -stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.10 ns 1.10 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_mean 19.0 ns 19.0 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_median 18.8 ns 18.8 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_stddev 0.822 ns 0.822 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_cv 4.32 % 4.32 % 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.761 ns 0.762 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.739 ns 0.739 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.055 ns 0.055 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 7.17 % 7.17 % 4 +ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.366 ns 0.366 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_median 0.365 ns 0.365 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.005 ns 0.005 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_cv 1.44 % 1.44 % 4 +stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.11 ns 1.11 ns 4 stringa e = "123456789012345678901234567890"; auto c{e};_median 1.10 ns 1.10 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.015 ns 0.015 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.34 % 1.34 % 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 19.4 ns 19.4 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 19.5 ns 19.5 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 0.443 ns 0.443 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 2.28 % 2.28 % 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.47 ns 4.47 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.47 ns 4.47 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.083 ns 0.083 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 1.85 % 1.85 % 4 +stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.020 ns 0.020 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.84 % 1.84 % 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 21.0 ns 21.0 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 20.4 ns 20.4 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 1.41 ns 1.41 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 6.74 % 6.74 % 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.83 ns 4.83 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.81 ns 4.81 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.060 ns 0.060 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 1.25 % 1.25 % 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.79 ns 6.79 ns 4 -std::string::find;_median 6.76 ns 6.76 ns 4 -std::string::find;_stddev 0.180 ns 0.180 ns 4 -std::string::find;_cv 2.65 % 2.65 % 4 -std::string_view::find;_mean 7.09 ns 7.09 ns 4 -std::string_view::find;_median 7.11 ns 7.11 ns 4 -std::string_view::find;_stddev 0.163 ns 0.163 ns 4 -std::string_view::find;_cv 2.30 % 2.30 % 4 -ssa::find;_mean 6.79 ns 6.79 ns 4 -ssa::find;_median 6.80 ns 6.80 ns 4 -ssa::find;_stddev 0.088 ns 0.088 ns 4 -ssa::find;_cv 1.30 % 1.30 % 4 -stringa::find;_mean 7.43 ns 7.43 ns 4 -stringa::find;_median 7.33 ns 7.33 ns 4 -stringa::find;_stddev 0.301 ns 0.301 ns 4 -stringa::find;_cv 4.05 % 4.05 % 4 -lstringa<20>::find;_mean 6.26 ns 6.26 ns 4 -lstringa<20>::find;_median 6.31 ns 6.31 ns 4 -lstringa<20>::find;_stddev 0.110 ns 0.110 ns 4 -lstringa<20>::find;_cv 1.75 % 1.75 % 4 -lstringa<40>::find;_mean 6.26 ns 6.26 ns 4 -lstringa<40>::find;_median 6.20 ns 6.20 ns 4 -lstringa<40>::find;_stddev 0.179 ns 0.179 ns 4 -lstringa<40>::find;_cv 2.85 % 2.85 % 4 +sz::string::find;_mean 93.4 ns 93.4 ns 4 +sz::string::find;_median 93.2 ns 93.2 ns 4 +sz::string::find;_stddev 1.53 ns 1.53 ns 4 +sz::string::find;_cv 1.64 % 1.64 % 4 +std::string::find;_mean 7.54 ns 7.54 ns 4 +std::string::find;_median 7.54 ns 7.54 ns 4 +std::string::find;_stddev 0.060 ns 0.060 ns 4 +std::string::find;_cv 0.79 % 0.79 % 4 +std::string_view::find;_mean 6.70 ns 6.70 ns 4 +std::string_view::find;_median 6.67 ns 6.67 ns 4 +std::string_view::find;_stddev 0.222 ns 0.222 ns 4 +std::string_view::find;_cv 3.31 % 3.31 % 4 +ssa::find;_mean 7.49 ns 7.49 ns 4 +ssa::find;_median 7.47 ns 7.47 ns 4 +ssa::find;_stddev 0.278 ns 0.278 ns 4 +ssa::find;_cv 3.71 % 3.71 % 4 +stringa::find;_mean 7.84 ns 7.84 ns 4 +stringa::find;_median 7.83 ns 7.83 ns 4 +stringa::find;_stddev 0.024 ns 0.024 ns 4 +stringa::find;_cv 0.31 % 0.31 % 4 +lstringa<20>::find;_mean 7.38 ns 7.38 ns 4 +lstringa<20>::find;_median 7.27 ns 7.27 ns 4 +lstringa<20>::find;_stddev 0.240 ns 0.240 ns 4 +lstringa<20>::find;_cv 3.25 % 3.25 % 4 +lstringa<40>::find;_mean 7.02 ns 7.02 ns 4 +lstringa<40>::find;_median 7.02 ns 7.02 ns 4 +lstringa<40>::find;_stddev 0.062 ns 0.062 ns 4 +lstringa<40>::find;_cv 0.89 % 0.89 % 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 4.74 ns 4.74 ns 4 -std::string copy{str_with_len_N};/15_median 4.74 ns 4.74 ns 4 -std::string copy{str_with_len_N};/15_stddev 0.123 ns 0.123 ns 4 -std::string copy{str_with_len_N};/15_cv 2.59 % 2.59 % 4 -std::string copy{str_with_len_N};/16_mean 22.8 ns 22.8 ns 4 -std::string copy{str_with_len_N};/16_median 23.0 ns 23.0 ns 4 -std::string copy{str_with_len_N};/16_stddev 0.514 ns 0.514 ns 4 -std::string copy{str_with_len_N};/16_cv 2.25 % 2.25 % 4 -std::string copy{str_with_len_N};/23_mean 22.6 ns 22.6 ns 4 -std::string copy{str_with_len_N};/23_median 22.7 ns 22.7 ns 4 -std::string copy{str_with_len_N};/23_stddev 0.330 ns 0.330 ns 4 -std::string copy{str_with_len_N};/23_cv 1.46 % 1.46 % 4 +std::string copy{str_with_len_N};/15_mean 4.87 ns 4.87 ns 4 +std::string copy{str_with_len_N};/15_median 4.88 ns 4.88 ns 4 +std::string copy{str_with_len_N};/15_stddev 0.072 ns 0.072 ns 4 +std::string copy{str_with_len_N};/15_cv 1.48 % 1.48 % 4 +std::string copy{str_with_len_N};/16_mean 23.2 ns 23.2 ns 4 +std::string copy{str_with_len_N};/16_median 23.2 ns 23.2 ns 4 +std::string copy{str_with_len_N};/16_stddev 0.490 ns 0.490 ns 4 +std::string copy{str_with_len_N};/16_cv 2.11 % 2.11 % 4 +std::string copy{str_with_len_N};/23_mean 23.5 ns 23.5 ns 4 +std::string copy{str_with_len_N};/23_median 22.8 ns 22.8 ns 4 +std::string copy{str_with_len_N};/23_stddev 1.53 ns 1.53 ns 4 +std::string copy{str_with_len_N};/23_cv 6.52 % 6.52 % 4 std::string copy{str_with_len_N};/24_mean 22.6 ns 22.6 ns 4 std::string copy{str_with_len_N};/24_median 22.6 ns 22.6 ns 4 -std::string copy{str_with_len_N};/24_stddev 0.293 ns 0.293 ns 4 -std::string copy{str_with_len_N};/24_cv 1.29 % 1.29 % 4 +std::string copy{str_with_len_N};/24_stddev 0.340 ns 0.340 ns 4 +std::string copy{str_with_len_N};/24_cv 1.51 % 1.51 % 4 std::string copy{str_with_len_N};/32_mean 22.6 ns 22.6 ns 4 std::string copy{str_with_len_N};/32_median 22.6 ns 22.6 ns 4 -std::string copy{str_with_len_N};/32_stddev 0.497 ns 0.497 ns 4 -std::string copy{str_with_len_N};/32_cv 2.20 % 2.20 % 4 -std::string copy{str_with_len_N};/64_mean 21.9 ns 21.9 ns 4 -std::string copy{str_with_len_N};/64_median 22.0 ns 22.0 ns 4 -std::string copy{str_with_len_N};/64_stddev 0.185 ns 0.185 ns 4 -std::string copy{str_with_len_N};/64_cv 0.84 % 0.84 % 4 -std::string copy{str_with_len_N};/128_mean 24.2 ns 24.2 ns 4 -std::string copy{str_with_len_N};/128_median 24.6 ns 24.6 ns 4 -std::string copy{str_with_len_N};/128_stddev 0.689 ns 0.689 ns 4 -std::string copy{str_with_len_N};/128_cv 2.84 % 2.84 % 4 -std::string copy{str_with_len_N};/256_mean 24.4 ns 24.4 ns 4 -std::string copy{str_with_len_N};/256_median 24.3 ns 24.3 ns 4 -std::string copy{str_with_len_N};/256_stddev 0.352 ns 0.352 ns 4 -std::string copy{str_with_len_N};/256_cv 1.44 % 1.45 % 4 -std::string copy{str_with_len_N};/512_mean 28.7 ns 28.7 ns 4 +std::string copy{str_with_len_N};/32_stddev 0.901 ns 0.901 ns 4 +std::string copy{str_with_len_N};/32_cv 3.99 % 3.99 % 4 +std::string copy{str_with_len_N};/64_mean 22.3 ns 22.3 ns 4 +std::string copy{str_with_len_N};/64_median 22.3 ns 22.3 ns 4 +std::string copy{str_with_len_N};/64_stddev 0.426 ns 0.426 ns 4 +std::string copy{str_with_len_N};/64_cv 1.91 % 1.91 % 4 +std::string copy{str_with_len_N};/128_mean 23.7 ns 23.7 ns 4 +std::string copy{str_with_len_N};/128_median 23.6 ns 23.6 ns 4 +std::string copy{str_with_len_N};/128_stddev 0.580 ns 0.580 ns 4 +std::string copy{str_with_len_N};/128_cv 2.45 % 2.45 % 4 +std::string copy{str_with_len_N};/256_mean 24.9 ns 24.9 ns 4 +std::string copy{str_with_len_N};/256_median 24.8 ns 24.8 ns 4 +std::string copy{str_with_len_N};/256_stddev 1.05 ns 1.05 ns 4 +std::string copy{str_with_len_N};/256_cv 4.24 % 4.24 % 4 +std::string copy{str_with_len_N};/512_mean 28.5 ns 28.5 ns 4 std::string copy{str_with_len_N};/512_median 28.6 ns 28.6 ns 4 -std::string copy{str_with_len_N};/512_stddev 0.461 ns 0.461 ns 4 -std::string copy{str_with_len_N};/512_cv 1.61 % 1.61 % 4 -std::string copy{str_with_len_N};/1024_mean 44.7 ns 44.7 ns 4 -std::string copy{str_with_len_N};/1024_median 44.6 ns 44.6 ns 4 -std::string copy{str_with_len_N};/1024_stddev 0.414 ns 0.414 ns 4 -std::string copy{str_with_len_N};/1024_cv 0.93 % 0.93 % 4 -std::string copy{str_with_len_N};/2048_mean 122 ns 122 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 3.03 ns 3.03 ns 4 -std::string copy{str_with_len_N};/2048_cv 2.49 % 2.49 % 4 -std::string copy{str_with_len_N};/4096_mean 158 ns 158 ns 4 -std::string copy{str_with_len_N};/4096_median 158 ns 158 ns 4 -std::string copy{str_with_len_N};/4096_stddev 8.73 ns 8.73 ns 4 -std::string copy{str_with_len_N};/4096_cv 5.52 % 5.52 % 4 -stringa copy{str_with_len_N};/15_mean 1.11 ns 1.11 ns 4 -stringa copy{str_with_len_N};/15_median 1.11 ns 1.11 ns 4 -stringa copy{str_with_len_N};/15_stddev 0.017 ns 0.017 ns 4 -stringa copy{str_with_len_N};/15_cv 1.51 % 1.51 % 4 -stringa copy{str_with_len_N};/16_mean 1.10 ns 1.10 ns 4 -stringa copy{str_with_len_N};/16_median 1.11 ns 1.11 ns 4 -stringa copy{str_with_len_N};/16_stddev 0.023 ns 0.023 ns 4 -stringa copy{str_with_len_N};/16_cv 2.09 % 2.09 % 4 -stringa copy{str_with_len_N};/23_mean 1.09 ns 1.09 ns 4 -stringa copy{str_with_len_N};/23_median 1.09 ns 1.09 ns 4 -stringa copy{str_with_len_N};/23_stddev 0.013 ns 0.013 ns 4 -stringa copy{str_with_len_N};/23_cv 1.17 % 1.17 % 4 -stringa copy{str_with_len_N};/24_mean 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/24_median 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/24_stddev 0.225 ns 0.225 ns 4 -stringa copy{str_with_len_N};/24_cv 1.40 % 1.40 % 4 -stringa copy{str_with_len_N};/32_mean 15.9 ns 15.9 ns 4 -stringa copy{str_with_len_N};/32_median 15.9 ns 15.9 ns 4 -stringa copy{str_with_len_N};/32_stddev 0.043 ns 0.043 ns 4 -stringa copy{str_with_len_N};/32_cv 0.27 % 0.27 % 4 +std::string copy{str_with_len_N};/512_stddev 0.369 ns 0.369 ns 4 +std::string copy{str_with_len_N};/512_cv 1.29 % 1.29 % 4 +std::string copy{str_with_len_N};/1024_mean 34.8 ns 34.8 ns 4 +std::string copy{str_with_len_N};/1024_median 34.9 ns 34.9 ns 4 +std::string copy{str_with_len_N};/1024_stddev 1.77 ns 1.77 ns 4 +std::string copy{str_with_len_N};/1024_cv 5.10 % 5.10 % 4 +std::string copy{str_with_len_N};/2048_mean 79.1 ns 79.1 ns 4 +std::string copy{str_with_len_N};/2048_median 78.6 ns 78.6 ns 4 +std::string copy{str_with_len_N};/2048_stddev 5.40 ns 5.40 ns 4 +std::string copy{str_with_len_N};/2048_cv 6.83 % 6.83 % 4 +std::string copy{str_with_len_N};/4096_mean 111 ns 111 ns 4 +std::string copy{str_with_len_N};/4096_median 111 ns 111 ns 4 +std::string copy{str_with_len_N};/4096_stddev 2.30 ns 2.30 ns 4 +std::string copy{str_with_len_N};/4096_cv 2.08 % 2.08 % 4 +stringa copy{str_with_len_N};/15_mean 1.09 ns 1.09 ns 4 +stringa copy{str_with_len_N};/15_median 1.09 ns 1.09 ns 4 +stringa copy{str_with_len_N};/15_stddev 0.011 ns 0.011 ns 4 +stringa copy{str_with_len_N};/15_cv 1.02 % 1.02 % 4 +stringa copy{str_with_len_N};/16_mean 1.13 ns 1.13 ns 4 +stringa copy{str_with_len_N};/16_median 1.12 ns 1.12 ns 4 +stringa copy{str_with_len_N};/16_stddev 0.032 ns 0.032 ns 4 +stringa copy{str_with_len_N};/16_cv 2.84 % 2.84 % 4 +stringa copy{str_with_len_N};/23_mean 1.11 ns 1.11 ns 4 +stringa copy{str_with_len_N};/23_median 1.11 ns 1.11 ns 4 +stringa copy{str_with_len_N};/23_stddev 0.010 ns 0.010 ns 4 +stringa copy{str_with_len_N};/23_cv 0.88 % 0.88 % 4 +stringa copy{str_with_len_N};/24_mean 15.9 ns 15.9 ns 4 +stringa copy{str_with_len_N};/24_median 15.9 ns 15.9 ns 4 +stringa copy{str_with_len_N};/24_stddev 0.091 ns 0.091 ns 4 +stringa copy{str_with_len_N};/24_cv 0.57 % 0.57 % 4 +stringa copy{str_with_len_N};/32_mean 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/32_median 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/32_stddev 0.111 ns 0.111 ns 4 +stringa copy{str_with_len_N};/32_cv 0.69 % 0.69 % 4 stringa copy{str_with_len_N};/64_mean 16.0 ns 16.0 ns 4 stringa copy{str_with_len_N};/64_median 16.0 ns 16.0 ns 4 -stringa copy{str_with_len_N};/64_stddev 0.096 ns 0.096 ns 4 -stringa copy{str_with_len_N};/64_cv 0.60 % 0.60 % 4 -stringa copy{str_with_len_N};/128_mean 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/128_median 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/128_stddev 0.186 ns 0.186 ns 4 -stringa copy{str_with_len_N};/128_cv 1.16 % 1.16 % 4 -stringa copy{str_with_len_N};/256_mean 16.2 ns 16.2 ns 4 -stringa copy{str_with_len_N};/256_median 16.2 ns 16.2 ns 4 -stringa copy{str_with_len_N};/256_stddev 0.326 ns 0.326 ns 4 -stringa copy{str_with_len_N};/256_cv 2.01 % 2.01 % 4 -stringa copy{str_with_len_N};/512_mean 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/512_median 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/512_stddev 0.085 ns 0.085 ns 4 -stringa copy{str_with_len_N};/512_cv 0.53 % 0.53 % 4 -stringa copy{str_with_len_N};/1024_mean 15.9 ns 15.9 ns 4 -stringa copy{str_with_len_N};/1024_median 15.9 ns 15.9 ns 4 -stringa copy{str_with_len_N};/1024_stddev 0.067 ns 0.067 ns 4 -stringa copy{str_with_len_N};/1024_cv 0.42 % 0.42 % 4 -stringa copy{str_with_len_N};/2048_mean 16.2 ns 16.2 ns 4 -stringa copy{str_with_len_N};/2048_median 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/2048_stddev 0.209 ns 0.209 ns 4 -stringa copy{str_with_len_N};/2048_cv 1.29 % 1.29 % 4 -stringa copy{str_with_len_N};/4096_mean 16.0 ns 16.0 ns 4 -stringa copy{str_with_len_N};/4096_median 16.0 ns 16.0 ns 4 -stringa copy{str_with_len_N};/4096_stddev 0.087 ns 0.087 ns 4 -stringa copy{str_with_len_N};/4096_cv 0.54 % 0.54 % 4 -lstringa<16> copy{str_with_len_N};/15_mean 1.46 ns 1.46 ns 4 -lstringa<16> copy{str_with_len_N};/15_median 1.45 ns 1.45 ns 4 -lstringa<16> copy{str_with_len_N};/15_stddev 0.025 ns 0.025 ns 4 -lstringa<16> copy{str_with_len_N};/15_cv 1.72 % 1.72 % 4 -lstringa<16> copy{str_with_len_N};/16_mean 5.21 ns 5.21 ns 4 -lstringa<16> copy{str_with_len_N};/16_median 5.22 ns 5.22 ns 4 -lstringa<16> copy{str_with_len_N};/16_stddev 0.078 ns 0.078 ns 4 -lstringa<16> copy{str_with_len_N};/16_cv 1.49 % 1.49 % 4 -lstringa<16> copy{str_with_len_N};/23_mean 5.09 ns 5.09 ns 4 -lstringa<16> copy{str_with_len_N};/23_median 5.08 ns 5.08 ns 4 -lstringa<16> copy{str_with_len_N};/23_stddev 0.082 ns 0.082 ns 4 -lstringa<16> copy{str_with_len_N};/23_cv 1.60 % 1.60 % 4 -lstringa<16> copy{str_with_len_N};/24_mean 22.9 ns 22.9 ns 4 -lstringa<16> copy{str_with_len_N};/24_median 22.8 ns 22.8 ns 4 -lstringa<16> copy{str_with_len_N};/24_stddev 0.229 ns 0.229 ns 4 -lstringa<16> copy{str_with_len_N};/24_cv 1.00 % 1.00 % 4 -lstringa<16> copy{str_with_len_N};/32_mean 22.6 ns 22.6 ns 4 -lstringa<16> copy{str_with_len_N};/32_median 22.6 ns 22.6 ns 4 -lstringa<16> copy{str_with_len_N};/32_stddev 0.395 ns 0.395 ns 4 -lstringa<16> copy{str_with_len_N};/32_cv 1.75 % 1.75 % 4 -lstringa<16> copy{str_with_len_N};/64_mean 24.1 ns 24.1 ns 4 -lstringa<16> copy{str_with_len_N};/64_median 24.2 ns 24.2 ns 4 -lstringa<16> copy{str_with_len_N};/64_stddev 0.583 ns 0.583 ns 4 -lstringa<16> copy{str_with_len_N};/64_cv 2.42 % 2.42 % 4 -lstringa<16> copy{str_with_len_N};/128_mean 24.7 ns 24.7 ns 4 -lstringa<16> copy{str_with_len_N};/128_median 24.8 ns 24.8 ns 4 -lstringa<16> copy{str_with_len_N};/128_stddev 0.232 ns 0.232 ns 4 -lstringa<16> copy{str_with_len_N};/128_cv 0.94 % 0.94 % 4 -lstringa<16> copy{str_with_len_N};/256_mean 25.9 ns 25.9 ns 4 -lstringa<16> copy{str_with_len_N};/256_median 25.8 ns 25.8 ns 4 -lstringa<16> copy{str_with_len_N};/256_stddev 0.492 ns 0.492 ns 4 -lstringa<16> copy{str_with_len_N};/256_cv 1.90 % 1.90 % 4 -lstringa<16> copy{str_with_len_N};/512_mean 29.2 ns 29.2 ns 4 -lstringa<16> copy{str_with_len_N};/512_median 29.1 ns 29.1 ns 4 -lstringa<16> copy{str_with_len_N};/512_stddev 0.960 ns 0.960 ns 4 -lstringa<16> copy{str_with_len_N};/512_cv 3.29 % 3.29 % 4 -lstringa<16> copy{str_with_len_N};/1024_mean 102 ns 102 ns 4 -lstringa<16> copy{str_with_len_N};/1024_median 101 ns 101 ns 4 -lstringa<16> copy{str_with_len_N};/1024_stddev 3.30 ns 3.30 ns 4 -lstringa<16> copy{str_with_len_N};/1024_cv 3.25 % 3.25 % 4 -lstringa<16> copy{str_with_len_N};/2048_mean 115 ns 115 ns 4 -lstringa<16> copy{str_with_len_N};/2048_median 114 ns 114 ns 4 -lstringa<16> copy{str_with_len_N};/2048_stddev 4.40 ns 4.40 ns 4 -lstringa<16> copy{str_with_len_N};/2048_cv 3.84 % 3.84 % 4 -lstringa<16> copy{str_with_len_N};/4096_mean 127 ns 127 ns 4 -lstringa<16> copy{str_with_len_N};/4096_median 127 ns 127 ns 4 -lstringa<16> copy{str_with_len_N};/4096_stddev 1.00 ns 1.00 ns 4 -lstringa<16> copy{str_with_len_N};/4096_cv 0.79 % 0.79 % 4 -lstringa<512> copy{str_with_len_N};/15_mean 1.51 ns 1.51 ns 4 -lstringa<512> copy{str_with_len_N};/15_median 1.51 ns 1.51 ns 4 -lstringa<512> copy{str_with_len_N};/15_stddev 0.034 ns 0.034 ns 4 -lstringa<512> copy{str_with_len_N};/15_cv 2.22 % 2.22 % 4 -lstringa<512> copy{str_with_len_N};/16_mean 5.17 ns 5.17 ns 4 -lstringa<512> copy{str_with_len_N};/16_median 5.13 ns 5.13 ns 4 -lstringa<512> copy{str_with_len_N};/16_stddev 0.136 ns 0.136 ns 4 -lstringa<512> copy{str_with_len_N};/16_cv 2.63 % 2.63 % 4 -lstringa<512> copy{str_with_len_N};/23_mean 5.16 ns 5.16 ns 4 -lstringa<512> copy{str_with_len_N};/23_median 5.15 ns 5.15 ns 4 -lstringa<512> copy{str_with_len_N};/23_stddev 0.081 ns 0.081 ns 4 -lstringa<512> copy{str_with_len_N};/23_cv 1.58 % 1.58 % 4 -lstringa<512> copy{str_with_len_N};/24_mean 4.89 ns 4.89 ns 4 -lstringa<512> copy{str_with_len_N};/24_median 4.88 ns 4.88 ns 4 -lstringa<512> copy{str_with_len_N};/24_stddev 0.061 ns 0.061 ns 4 -lstringa<512> copy{str_with_len_N};/24_cv 1.25 % 1.25 % 4 -lstringa<512> copy{str_with_len_N};/32_mean 4.78 ns 4.78 ns 4 -lstringa<512> copy{str_with_len_N};/32_median 4.77 ns 4.77 ns 4 -lstringa<512> copy{str_with_len_N};/32_stddev 0.061 ns 0.061 ns 4 -lstringa<512> copy{str_with_len_N};/32_cv 1.28 % 1.28 % 4 -lstringa<512> copy{str_with_len_N};/64_mean 6.27 ns 6.27 ns 4 -lstringa<512> copy{str_with_len_N};/64_median 6.24 ns 6.24 ns 4 -lstringa<512> copy{str_with_len_N};/64_stddev 0.161 ns 0.161 ns 4 -lstringa<512> copy{str_with_len_N};/64_cv 2.56 % 2.56 % 4 -lstringa<512> copy{str_with_len_N};/128_mean 6.65 ns 6.65 ns 4 -lstringa<512> copy{str_with_len_N};/128_median 6.67 ns 6.67 ns 4 -lstringa<512> copy{str_with_len_N};/128_stddev 0.073 ns 0.073 ns 4 -lstringa<512> copy{str_with_len_N};/128_cv 1.10 % 1.10 % 4 -lstringa<512> copy{str_with_len_N};/256_mean 8.26 ns 8.26 ns 4 -lstringa<512> copy{str_with_len_N};/256_median 8.19 ns 8.19 ns 4 -lstringa<512> copy{str_with_len_N};/256_stddev 0.250 ns 0.250 ns 4 -lstringa<512> copy{str_with_len_N};/256_cv 3.03 % 3.03 % 4 +stringa copy{str_with_len_N};/64_stddev 0.199 ns 0.199 ns 4 +stringa copy{str_with_len_N};/64_cv 1.24 % 1.24 % 4 +stringa copy{str_with_len_N};/128_mean 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/128_median 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/128_stddev 0.049 ns 0.049 ns 4 +stringa copy{str_with_len_N};/128_cv 0.30 % 0.30 % 4 +stringa copy{str_with_len_N};/256_mean 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/256_median 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/256_stddev 0.138 ns 0.138 ns 4 +stringa copy{str_with_len_N};/256_cv 0.86 % 0.86 % 4 +stringa copy{str_with_len_N};/512_mean 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/512_median 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/512_stddev 0.148 ns 0.148 ns 4 +stringa copy{str_with_len_N};/512_cv 0.92 % 0.92 % 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.230 ns 0.230 ns 4 +stringa copy{str_with_len_N};/1024_cv 1.43 % 1.43 % 4 +stringa copy{str_with_len_N};/2048_mean 15.9 ns 15.9 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.049 ns 0.049 ns 4 +stringa copy{str_with_len_N};/2048_cv 0.31 % 0.31 % 4 +stringa copy{str_with_len_N};/4096_mean 15.9 ns 15.9 ns 4 +stringa copy{str_with_len_N};/4096_median 15.9 ns 15.9 ns 4 +stringa copy{str_with_len_N};/4096_stddev 0.125 ns 0.125 ns 4 +stringa copy{str_with_len_N};/4096_cv 0.79 % 0.79 % 4 +lstringa<16> copy{str_with_len_N};/15_mean 1.47 ns 1.47 ns 4 +lstringa<16> copy{str_with_len_N};/15_median 1.47 ns 1.47 ns 4 +lstringa<16> copy{str_with_len_N};/15_stddev 0.014 ns 0.014 ns 4 +lstringa<16> copy{str_with_len_N};/15_cv 0.94 % 0.94 % 4 +lstringa<16> copy{str_with_len_N};/16_mean 5.22 ns 5.22 ns 4 +lstringa<16> copy{str_with_len_N};/16_median 5.17 ns 5.17 ns 4 +lstringa<16> copy{str_with_len_N};/16_stddev 0.148 ns 0.148 ns 4 +lstringa<16> copy{str_with_len_N};/16_cv 2.83 % 2.83 % 4 +lstringa<16> copy{str_with_len_N};/23_mean 5.16 ns 5.16 ns 4 +lstringa<16> copy{str_with_len_N};/23_median 5.16 ns 5.16 ns 4 +lstringa<16> copy{str_with_len_N};/23_stddev 0.039 ns 0.039 ns 4 +lstringa<16> copy{str_with_len_N};/23_cv 0.77 % 0.77 % 4 +lstringa<16> copy{str_with_len_N};/24_mean 22.6 ns 22.6 ns 4 +lstringa<16> copy{str_with_len_N};/24_median 22.7 ns 22.7 ns 4 +lstringa<16> copy{str_with_len_N};/24_stddev 0.414 ns 0.414 ns 4 +lstringa<16> copy{str_with_len_N};/24_cv 1.83 % 1.83 % 4 +lstringa<16> copy{str_with_len_N};/32_mean 23.0 ns 23.0 ns 4 +lstringa<16> copy{str_with_len_N};/32_median 23.1 ns 23.1 ns 4 +lstringa<16> copy{str_with_len_N};/32_stddev 0.697 ns 0.697 ns 4 +lstringa<16> copy{str_with_len_N};/32_cv 3.03 % 3.03 % 4 +lstringa<16> copy{str_with_len_N};/64_mean 25.5 ns 25.5 ns 4 +lstringa<16> copy{str_with_len_N};/64_median 25.4 ns 25.4 ns 4 +lstringa<16> copy{str_with_len_N};/64_stddev 0.760 ns 0.760 ns 4 +lstringa<16> copy{str_with_len_N};/64_cv 2.98 % 2.98 % 4 +lstringa<16> copy{str_with_len_N};/128_mean 25.7 ns 25.7 ns 4 +lstringa<16> copy{str_with_len_N};/128_median 25.7 ns 25.7 ns 4 +lstringa<16> copy{str_with_len_N};/128_stddev 0.191 ns 0.191 ns 4 +lstringa<16> copy{str_with_len_N};/128_cv 0.75 % 0.75 % 4 +lstringa<16> copy{str_with_len_N};/256_mean 27.1 ns 27.1 ns 4 +lstringa<16> copy{str_with_len_N};/256_median 27.1 ns 27.1 ns 4 +lstringa<16> copy{str_with_len_N};/256_stddev 0.468 ns 0.468 ns 4 +lstringa<16> copy{str_with_len_N};/256_cv 1.73 % 1.73 % 4 +lstringa<16> copy{str_with_len_N};/512_mean 29.8 ns 29.8 ns 4 +lstringa<16> copy{str_with_len_N};/512_median 30.0 ns 30.0 ns 4 +lstringa<16> copy{str_with_len_N};/512_stddev 0.759 ns 0.759 ns 4 +lstringa<16> copy{str_with_len_N};/512_cv 2.55 % 2.55 % 4 +lstringa<16> copy{str_with_len_N};/1024_mean 51.8 ns 51.8 ns 4 +lstringa<16> copy{str_with_len_N};/1024_median 51.4 ns 51.4 ns 4 +lstringa<16> copy{str_with_len_N};/1024_stddev 1.13 ns 1.13 ns 4 +lstringa<16> copy{str_with_len_N};/1024_cv 2.19 % 2.19 % 4 +lstringa<16> copy{str_with_len_N};/2048_mean 65.7 ns 65.7 ns 4 +lstringa<16> copy{str_with_len_N};/2048_median 64.0 ns 64.0 ns 4 +lstringa<16> copy{str_with_len_N};/2048_stddev 5.00 ns 5.00 ns 4 +lstringa<16> copy{str_with_len_N};/2048_cv 7.62 % 7.62 % 4 +lstringa<16> copy{str_with_len_N};/4096_mean 86.4 ns 86.4 ns 4 +lstringa<16> copy{str_with_len_N};/4096_median 87.3 ns 87.3 ns 4 +lstringa<16> copy{str_with_len_N};/4096_stddev 3.27 ns 3.27 ns 4 +lstringa<16> copy{str_with_len_N};/4096_cv 3.79 % 3.79 % 4 +lstringa<512> copy{str_with_len_N};/15_mean 1.49 ns 1.49 ns 4 +lstringa<512> copy{str_with_len_N};/15_median 1.49 ns 1.49 ns 4 +lstringa<512> copy{str_with_len_N};/15_stddev 0.028 ns 0.028 ns 4 +lstringa<512> copy{str_with_len_N};/15_cv 1.91 % 1.91 % 4 +lstringa<512> copy{str_with_len_N};/16_mean 5.15 ns 5.15 ns 4 +lstringa<512> copy{str_with_len_N};/16_median 5.14 ns 5.14 ns 4 +lstringa<512> copy{str_with_len_N};/16_stddev 0.079 ns 0.079 ns 4 +lstringa<512> copy{str_with_len_N};/16_cv 1.54 % 1.54 % 4 +lstringa<512> copy{str_with_len_N};/23_mean 5.25 ns 5.25 ns 4 +lstringa<512> copy{str_with_len_N};/23_median 5.28 ns 5.28 ns 4 +lstringa<512> copy{str_with_len_N};/23_stddev 0.171 ns 0.171 ns 4 +lstringa<512> copy{str_with_len_N};/23_cv 3.26 % 3.26 % 4 +lstringa<512> copy{str_with_len_N};/24_mean 5.09 ns 5.09 ns 4 +lstringa<512> copy{str_with_len_N};/24_median 5.07 ns 5.07 ns 4 +lstringa<512> copy{str_with_len_N};/24_stddev 0.220 ns 0.220 ns 4 +lstringa<512> copy{str_with_len_N};/24_cv 4.32 % 4.32 % 4 +lstringa<512> copy{str_with_len_N};/32_mean 5.26 ns 5.26 ns 4 +lstringa<512> copy{str_with_len_N};/32_median 4.97 ns 4.97 ns 4 +lstringa<512> copy{str_with_len_N};/32_stddev 0.674 ns 0.674 ns 4 +lstringa<512> copy{str_with_len_N};/32_cv 12.81 % 12.81 % 4 +lstringa<512> copy{str_with_len_N};/64_mean 6.39 ns 6.39 ns 4 +lstringa<512> copy{str_with_len_N};/64_median 6.41 ns 6.41 ns 4 +lstringa<512> copy{str_with_len_N};/64_stddev 0.158 ns 0.158 ns 4 +lstringa<512> copy{str_with_len_N};/64_cv 2.47 % 2.47 % 4 +lstringa<512> copy{str_with_len_N};/128_mean 6.59 ns 6.59 ns 4 +lstringa<512> copy{str_with_len_N};/128_median 6.60 ns 6.60 ns 4 +lstringa<512> copy{str_with_len_N};/128_stddev 0.100 ns 0.100 ns 4 +lstringa<512> copy{str_with_len_N};/128_cv 1.52 % 1.52 % 4 +lstringa<512> copy{str_with_len_N};/256_mean 7.99 ns 7.99 ns 4 +lstringa<512> copy{str_with_len_N};/256_median 7.99 ns 7.99 ns 4 +lstringa<512> copy{str_with_len_N};/256_stddev 0.072 ns 0.072 ns 4 +lstringa<512> copy{str_with_len_N};/256_cv 0.91 % 0.91 % 4 lstringa<512> copy{str_with_len_N};/512_mean 10.5 ns 10.5 ns 4 -lstringa<512> copy{str_with_len_N};/512_median 10.6 ns 10.6 ns 4 -lstringa<512> copy{str_with_len_N};/512_stddev 0.164 ns 0.164 ns 4 -lstringa<512> copy{str_with_len_N};/512_cv 1.56 % 1.56 % 4 -lstringa<512> copy{str_with_len_N};/1024_mean 105 ns 105 ns 4 -lstringa<512> copy{str_with_len_N};/1024_median 105 ns 105 ns 4 -lstringa<512> copy{str_with_len_N};/1024_stddev 2.09 ns 2.09 ns 4 -lstringa<512> copy{str_with_len_N};/1024_cv 2.00 % 2.00 % 4 -lstringa<512> copy{str_with_len_N};/2048_mean 116 ns 116 ns 4 -lstringa<512> copy{str_with_len_N};/2048_median 113 ns 113 ns 4 -lstringa<512> copy{str_with_len_N};/2048_stddev 7.60 ns 7.60 ns 4 -lstringa<512> copy{str_with_len_N};/2048_cv 6.57 % 6.57 % 4 -lstringa<512> copy{str_with_len_N};/4096_mean 128 ns 128 ns 4 -lstringa<512> copy{str_with_len_N};/4096_median 128 ns 128 ns 4 -lstringa<512> copy{str_with_len_N};/4096_stddev 4.65 ns 4.65 ns 4 -lstringa<512> copy{str_with_len_N};/4096_cv 3.62 % 3.62 % 4 +lstringa<512> copy{str_with_len_N};/512_median 10.5 ns 10.5 ns 4 +lstringa<512> copy{str_with_len_N};/512_stddev 0.236 ns 0.236 ns 4 +lstringa<512> copy{str_with_len_N};/512_cv 2.23 % 2.23 % 4 +lstringa<512> copy{str_with_len_N};/1024_mean 52.1 ns 52.1 ns 4 +lstringa<512> copy{str_with_len_N};/1024_median 51.8 ns 51.8 ns 4 +lstringa<512> copy{str_with_len_N};/1024_stddev 0.882 ns 0.882 ns 4 +lstringa<512> copy{str_with_len_N};/1024_cv 1.69 % 1.69 % 4 +lstringa<512> copy{str_with_len_N};/2048_mean 64.9 ns 64.9 ns 4 +lstringa<512> copy{str_with_len_N};/2048_median 62.7 ns 62.7 ns 4 +lstringa<512> copy{str_with_len_N};/2048_stddev 5.84 ns 5.84 ns 4 +lstringa<512> copy{str_with_len_N};/2048_cv 9.00 % 9.00 % 4 +lstringa<512> copy{str_with_len_N};/4096_mean 87.6 ns 87.6 ns 4 +lstringa<512> copy{str_with_len_N};/4096_median 87.2 ns 87.2 ns 4 +lstringa<512> copy{str_with_len_N};/4096_stddev 3.98 ns 3.98 ns 4 +lstringa<512> copy{str_with_len_N};/4096_cv 4.54 % 4.54 % 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 26.4 ns 26.4 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 26.4 ns 26.4 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.306 ns 0.306 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 1.16 % 1.16 % 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 14.9 ns 14.9 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 14.9 ns 14.9 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.194 ns 0.194 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 1.30 % 1.30 % 4 -stringa s = "123456789"; int res = s.to_int_mean 12.6 ns 12.6 ns 4 -stringa s = "123456789"; int res = s.to_int_median 12.5 ns 12.5 ns 4 -stringa s = "123456789"; int res = s.to_int_stddev 0.219 ns 0.220 ns 4 -stringa s = "123456789"; int res = s.to_int_cv 1.74 % 1.74 % 4 -ssa s = "123456789"; int res = s.to_int_mean 12.3 ns 12.3 ns 4 -ssa s = "123456789"; int res = s.to_int_median 12.4 ns 12.4 ns 4 -ssa s = "123456789"; int res = s.to_int_stddev 0.054 ns 0.054 ns 4 -ssa s = "123456789"; int res = s.to_int_cv 0.44 % 0.44 % 4 -lstringa<20> s = "123456789"; int res = s.to_int_mean 12.2 ns 12.2 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_median 12.2 ns 12.2 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.281 ns 0.281 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_cv 2.31 % 2.31 % 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_mean 26.9 ns 26.9 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 27.0 ns 27.0 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.443 ns 0.443 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 1.65 % 1.65 % 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 14.5 ns 14.5 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 14.5 ns 14.5 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.296 ns 0.296 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 2.05 % 2.05 % 4 +stringa s = "123456789"; int res = s.to_int_mean 9.62 ns 9.62 ns 4 +stringa s = "123456789"; int res = s.to_int_median 9.59 ns 9.59 ns 4 +stringa s = "123456789"; int res = s.to_int_stddev 0.185 ns 0.185 ns 4 +stringa s = "123456789"; int res = s.to_int_cv 1.93 % 1.93 % 4 +ssa s = "123456789"; int res = s.to_int_mean 9.84 ns 9.84 ns 4 +ssa s = "123456789"; int res = s.to_int_median 9.86 ns 9.86 ns 4 +ssa s = "123456789"; int res = s.to_int_stddev 0.137 ns 0.137 ns 4 +ssa s = "123456789"; int res = s.to_int_cv 1.39 % 1.39 % 4 +lstringa<20> s = "123456789"; int res = s.to_int_mean 9.22 ns 9.22 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_median 9.21 ns 9.21 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.165 ns 0.165 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_cv 1.79 % 1.79 % 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 23.5 ns 23.5 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 23.5 ns 23.5 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 0.418 ns 0.418 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 1.78 % 1.78 % 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 9.65 ns 9.65 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 9.68 ns 9.68 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.191 ns 0.191 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 1.98 % 1.98 % 4 -stringa s = "abcDef"; int res = s.to_int_mean 12.5 ns 12.5 ns 4 -stringa s = "abcDef"; int res = s.to_int_median 12.4 ns 12.4 ns 4 -stringa s = "abcDef"; int res = s.to_int_stddev 0.283 ns 0.283 ns 4 -stringa s = "abcDef"; int res = s.to_int_cv 2.26 % 2.26 % 4 -ssa s = "abcDef"; int res = s.to_int_mean 13.0 ns 13.0 ns 4 -ssa s = "abcDef"; int res = s.to_int_median 12.9 ns 12.9 ns 4 -ssa s = "abcDef"; int res = s.to_int_stddev 0.492 ns 0.492 ns 4 -ssa s = "abcDef"; int res = s.to_int_cv 3.79 % 3.79 % 4 -lstringa<20> s = "abcDef"; int res = s.to_int_mean 12.5 ns 12.5 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_median 12.5 ns 12.5 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.182 ns 0.182 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_cv 1.45 % 1.45 % 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_mean 22.8 ns 22.8 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 22.9 ns 22.9 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 0.461 ns 0.461 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 2.02 % 2.02 % 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 9.22 ns 9.22 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 9.19 ns 9.19 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.133 ns 0.133 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 1.44 % 1.44 % 4 +stringa s = "abcDef"; int res = s.to_int_mean 7.55 ns 7.55 ns 4 +stringa s = "abcDef"; int res = s.to_int_median 7.55 ns 7.55 ns 4 +stringa s = "abcDef"; int res = s.to_int_stddev 0.120 ns 0.120 ns 4 +stringa s = "abcDef"; int res = s.to_int_cv 1.59 % 1.59 % 4 +ssa s = "abcDef"; int res = s.to_int_mean 7.55 ns 7.55 ns 4 +ssa s = "abcDef"; int res = s.to_int_median 7.56 ns 7.56 ns 4 +ssa s = "abcDef"; int res = s.to_int_stddev 0.092 ns 0.092 ns 4 +ssa s = "abcDef"; int res = s.to_int_cv 1.22 % 1.22 % 4 +lstringa<20> s = "abcDef"; int res = s.to_int_mean 7.45 ns 7.45 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_median 7.44 ns 7.44 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.140 ns 0.140 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_cv 1.88 % 1.88 % 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 28.6 ns 28.6 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_mean 28.8 ns 28.8 ns 4 std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 28.3 ns 28.3 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 0.673 ns 0.673 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 2.36 % 2.36 % 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 18.5 ns 18.5 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 18.5 ns 18.5 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.260 ns 0.260 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 1.41 % 1.41 % 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 15.5 ns 15.5 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 15.5 ns 15.5 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.424 ns 0.424 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 2.74 % 2.74 % 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 1.38 ns 1.38 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 4.81 % 4.81 % 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 11.4 ns 11.4 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 11.4 ns 11.4 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.762 ns 0.762 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 6.67 % 6.67 % 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 12.9 ns 12.9 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 12.9 ns 12.9 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.105 ns 0.104 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 0.81 % 0.81 % 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 63.7 ns 63.7 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 63.1 ns 63.1 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 2.17 ns 2.17 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 3.40 % 3.40 % 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 25.0 ns 25.0 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 25.2 ns 25.2 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 0.489 ns 0.489 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 1.95 % 1.95 % 4 -ssa s = "1234.567e10"; double res = *s.to_double()_mean 25.4 ns 25.4 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_median 25.4 ns 25.4 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.377 ns 0.377 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_cv 1.49 % 1.49 % 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_mean 66.2 ns 66.2 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 64.9 ns 64.9 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 5.02 ns 5.02 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 7.59 % 7.59 % 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 23.6 ns 23.6 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 23.7 ns 23.7 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 0.374 ns 0.374 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 1.58 % 1.58 % 4 +ssa s = "1234.567e10"; double res = *s.to_double()_mean 24.8 ns 24.8 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_median 24.7 ns 24.7 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.446 ns 0.446 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_cv 1.80 % 1.80 % 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 1351 ns 1351 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_median 1349 ns 1349 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 31.3 ns 31.3 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.32 % 2.32 % 4 -std::string str; ... str += "abbaabbaabbaabba";_mean 383 ns 383 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_median 384 ns 384 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_stddev 8.39 ns 8.39 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_cv 2.19 % 2.19 % 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 378 ns 378 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_median 376 ns 376 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 12.3 ns 12.3 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 3.26 % 3.26 % 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 253 ns 253 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_median 256 ns 256 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 9.34 ns 9.34 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 3.69 % 3.69 % 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 223 ns 223 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_median 229 ns 229 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 16.0 ns 16.0 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 7.20 % 7.20 % 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_mean 1336 ns 1336 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_median 1342 ns 1342 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 28.7 ns 28.7 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.15 % 2.15 % 4 +std::string str; ... str += "abbaabbaabbaabba";_mean 407 ns 407 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_median 404 ns 404 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_stddev 16.5 ns 16.5 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_cv 4.04 % 4.04 % 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 376 ns 376 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_median 377 ns 377 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 3.32 ns 3.32 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 0.88 % 0.88 % 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 236 ns 236 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_median 230 ns 230 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 13.5 ns 13.5 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 5.72 % 5.72 % 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 206 ns 206 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_median 201 ns 201 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 12.4 ns 12.4 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 6.00 % 6.00 % 4 lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 136 ns 136 ns 4 lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 136 ns 136 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 1.55 ns 1.55 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 1.14 % 1.14 % 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 1.37 ns 1.37 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 1.01 % 1.01 % 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 1337 ns 1337 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 1340 ns 1340 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 21.2 ns 21.2 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 1.59 % 1.59 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 1269 ns 1269 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_median 1261 ns 1261 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 40.7 ns 40.7 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 3.21 % 3.21 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 479 ns 479 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 478 ns 478 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 11.5 ns 11.5 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.41 % 2.41 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 354 ns 354 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 352 ns 352 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 35.7 ns 35.7 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 10.09 % 10.09 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 329 ns 329 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 335 ns 335 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 18.8 ns 18.8 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 5.72 % 5.72 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 236 ns 236 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 236 ns 236 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 6.51 ns 6.51 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.76 % 2.76 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_mean 1362 ns 1362 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 1350 ns 1350 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 59.5 ns 59.5 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 4.37 % 4.37 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 1221 ns 1221 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_median 1224 ns 1224 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 15.0 ns 15.0 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 1.23 % 1.23 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 385 ns 385 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 382 ns 382 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 17.2 ns 17.2 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 4.48 % 4.48 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 301 ns 301 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 296 ns 296 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 13.1 ns 13.1 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 4.34 % 4.34 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 293 ns 293 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 287 ns 287 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 18.1 ns 18.1 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 6.18 % 6.18 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 235 ns 235 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 233 ns 233 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 6.46 ns 6.46 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.75 % 2.75 % 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 73877 ns 73878 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 74052 ns 74052 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 1595 ns 1595 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 2.16 % 2.16 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 71203 ns 71203 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 71803 ns 71804 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 2013 ns 2013 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.83 % 2.83 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 18653 ns 18653 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 18523 ns 18523 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 442 ns 442 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.37 % 2.37 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 19018 ns 19018 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 18745 ns 18745 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 814 ns 814 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 4.28 % 4.28 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 15905 ns 15905 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 15943 ns 15943 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 190 ns 190 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.20 % 1.20 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 15724 ns 15724 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 15719 ns 15719 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 178 ns 178 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.13 % 1.13 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_mean 111021 ns 111022 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 111439 ns 111439 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 1127 ns 1127 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 1.02 % 1.02 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 69967 ns 69967 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 70178 ns 70178 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 865 ns 866 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.24 % 1.24 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 45414 ns 45414 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 44421 ns 44421 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 3132 ns 3132 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 6.90 % 6.90 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 23033 ns 23033 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 23360 ns 23360 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 677 ns 677 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.94 % 2.94 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 19267 ns 19267 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 17701 ns 17701 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 3296 ns 3296 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 17.11 % 17.11 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 17475 ns 17475 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 17460 ns 17460 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 118 ns 118 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 0.67 % 0.67 % 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 1399 ns 1399 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_median 1402 ns 1402 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_stddev 29.5 ns 29.5 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_cv 2.11 % 2.11 % 4 -std::string str; ... str += str_var1 + str_var2;_mean 1356 ns 1356 ns 4 -std::string str; ... str += str_var1 + str_var2;_median 1353 ns 1353 ns 4 -std::string str; ... str += str_var1 + str_var2;_stddev 20.3 ns 20.3 ns 4 -std::string str; ... str += str_var1 + str_var2;_cv 1.49 % 1.49 % 4 -lstringa<16> str; ... str += str_var1 + str_var2;_mean 536 ns 536 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_median 536 ns 536 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_stddev 1.18 ns 1.18 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_cv 0.22 % 0.22 % 4 -lstringa<128> str; ... str += str_var1 + str_var2;_mean 431 ns 431 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_median 439 ns 439 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_stddev 20.9 ns 20.9 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_cv 4.85 % 4.85 % 4 -lstringa<512> str; ... str += str_var1 + str_var2;_mean 404 ns 404 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_median 408 ns 408 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_stddev 20.2 ns 20.2 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_cv 5.01 % 5.01 % 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_mean 283 ns 283 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_median 280 ns 280 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 5.83 ns 5.83 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_cv 2.06 % 2.06 % 4 +std::stringstream str; ... str << str_var1 << str_var2;_mean 1361 ns 1361 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_median 1358 ns 1358 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_stddev 20.0 ns 20.0 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_cv 1.47 % 1.47 % 4 +std::string str; ... str += str_var1 + str_var2;_mean 1397 ns 1397 ns 4 +std::string str; ... str += str_var1 + str_var2;_median 1381 ns 1381 ns 4 +std::string str; ... str += str_var1 + str_var2;_stddev 41.0 ns 41.0 ns 4 +std::string str; ... str += str_var1 + str_var2;_cv 2.94 % 2.94 % 4 +lstringa<16> str; ... str += str_var1 + str_var2;_mean 452 ns 452 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_median 453 ns 453 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_stddev 11.6 ns 11.6 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_cv 2.56 % 2.56 % 4 +lstringa<128> str; ... str += str_var1 + str_var2;_mean 407 ns 407 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_median 407 ns 407 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_stddev 5.34 ns 5.34 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_cv 1.31 % 1.31 % 4 +lstringa<512> str; ... str += str_var1 + str_var2;_mean 351 ns 351 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_median 349 ns 349 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_stddev 11.7 ns 11.7 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_cv 3.33 % 3.33 % 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_mean 300 ns 300 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_median 300 ns 300 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 5.91 ns 5.91 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_cv 1.97 % 1.97 % 4 -- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; str << "test = " << k << " times";_mean 2975 ns 2975 ns 4 -std::stringstream str; str << "test = " << k << " times";_median 2976 ns 2976 ns 4 -std::stringstream str; str << "test = " << k << " times";_stddev 44.2 ns 44.3 ns 4 -std::stringstream str; str << "test = " << k << " times";_cv 1.49 % 1.49 % 4 -std::string str = "test = " + std::to_string(k) + " times";_mean 470 ns 470 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_median 468 ns 468 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_stddev 9.94 ns 9.94 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_cv 2.12 % 2.12 % 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 1363 ns 1363 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 1370 ns 1370 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 26.7 ns 26.7 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 1.96 % 1.96 % 4 -std::string str = std::format("test = {} times", k);_mean 1112 ns 1112 ns 4 -std::string str = std::format("test = {} times", k);_median 1119 ns 1119 ns 4 -std::string str = std::format("test = {} times", k);_stddev 31.5 ns 31.5 ns 4 -std::string str = std::format("test = {} times", k);_cv 2.83 % 2.83 % 4 -lstringa<8> str; str.format("test = {} times", k);_mean 1306 ns 1306 ns 4 -lstringa<8> str; str.format("test = {} times", k);_median 1305 ns 1305 ns 4 -lstringa<8> str; str.format("test = {} times", k);_stddev 28.1 ns 28.1 ns 4 -lstringa<8> str; str.format("test = {} times", k);_cv 2.15 % 2.15 % 4 -lstringa<32> str; str.format("test = {} times", k);_mean 946 ns 946 ns 4 -lstringa<32> str; str.format("test = {} times", k);_median 947 ns 947 ns 4 -lstringa<32> str; str.format("test = {} times", k);_stddev 12.7 ns 12.7 ns 4 -lstringa<32> str; str.format("test = {} times", k);_cv 1.34 % 1.34 % 4 -lstringa<8> str = "test = " + k + " times";_mean 292 ns 292 ns 4 -lstringa<8> str = "test = " + k + " times";_median 290 ns 290 ns 4 -lstringa<8> str = "test = " + k + " times";_stddev 16.1 ns 16.1 ns 4 -lstringa<8> str = "test = " + k + " times";_cv 5.52 % 5.52 % 4 -lstringa<32> str = "test = " + k + " times";_mean 151 ns 151 ns 4 -lstringa<32> str = "test = " + k + " times";_median 151 ns 151 ns 4 -lstringa<32> str = "test = " + k + " times";_stddev 0.838 ns 0.838 ns 4 -lstringa<32> str = "test = " + k + " times";_cv 0.55 % 0.55 % 4 -stringa str = "test = " + k + " times";_mean 154 ns 154 ns 4 -stringa str = "test = " + k + " times";_median 153 ns 153 ns 4 -stringa str = "test = " + k + " times";_stddev 8.03 ns 8.03 ns 4 -stringa str = "test = " + k + " times";_cv 5.21 % 5.21 % 4 +std::stringstream str; str << "test = " << k << " times";_mean 3011 ns 3011 ns 4 +std::stringstream str; str << "test = " << k << " times";_median 2989 ns 2989 ns 4 +std::stringstream str; str << "test = " << k << " times";_stddev 61.4 ns 61.4 ns 4 +std::stringstream str; str << "test = " << k << " times";_cv 2.04 % 2.04 % 4 +std::string str = "test = " + std::to_string(k) + " times";_mean 434 ns 434 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_median 436 ns 436 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_stddev 8.83 ns 8.83 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_cv 2.04 % 2.04 % 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 1391 ns 1391 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 1388 ns 1388 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 18.3 ns 18.3 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 1.31 % 1.31 % 4 +std::string str = std::format("test = {} times", k);_mean 1154 ns 1154 ns 4 +std::string str = std::format("test = {} times", k);_median 1155 ns 1155 ns 4 +std::string str = std::format("test = {} times", k);_stddev 28.0 ns 28.0 ns 4 +std::string str = std::format("test = {} times", k);_cv 2.43 % 2.43 % 4 +lstringa<8> str; str.format("test = {} times", k);_mean 1374 ns 1374 ns 4 +lstringa<8> str; str.format("test = {} times", k);_median 1360 ns 1360 ns 4 +lstringa<8> str; str.format("test = {} times", k);_stddev 39.2 ns 39.2 ns 4 +lstringa<8> str; str.format("test = {} times", k);_cv 2.85 % 2.85 % 4 +lstringa<32> str; str.format("test = {} times", k);_mean 997 ns 997 ns 4 +lstringa<32> str; str.format("test = {} times", k);_median 990 ns 990 ns 4 +lstringa<32> str; str.format("test = {} times", k);_stddev 15.3 ns 15.3 ns 4 +lstringa<32> str; str.format("test = {} times", k);_cv 1.53 % 1.53 % 4 +lstringa<8> str = "test = " + k + " times";_mean 272 ns 272 ns 4 +lstringa<8> str = "test = " + k + " times";_median 270 ns 270 ns 4 +lstringa<8> str = "test = " + k + " times";_stddev 12.4 ns 12.4 ns 4 +lstringa<8> str = "test = " + k + " times";_cv 4.54 % 4.54 % 4 +lstringa<32> str = "test = " + k + " times";_mean 124 ns 124 ns 4 +lstringa<32> str = "test = " + k + " times";_median 125 ns 125 ns 4 +lstringa<32> str = "test = " + k + " times";_stddev 2.19 ns 2.19 ns 4 +lstringa<32> str = "test = " + k + " times";_cv 1.76 % 1.76 % 4 +stringa str = "test = " + k + " times";_mean 117 ns 117 ns 4 +stringa str = "test = " + k + " times";_median 117 ns 117 ns 4 +stringa str = "test = " + k + " times";_stddev 2.04 ns 2.04 ns 4 +stringa str = "test = " + k + " times";_cv 1.75 % 1.75 % 4 -- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string::find + substr + std::strtol_mean 287 ns 287 ns 4 -std::string::find + substr + std::strtol_median 278 ns 278 ns 4 -std::string::find + substr + std::strtol_stddev 23.8 ns 23.8 ns 4 -std::string::find + substr + std::strtol_cv 8.28 % 8.28 % 4 -ssa::splitter + ssa::as_int_mean 150 ns 150 ns 4 -ssa::splitter + ssa::as_int_median 150 ns 150 ns 4 -ssa::splitter + ssa::as_int_stddev 2.59 ns 2.59 ns 4 -ssa::splitter + ssa::as_int_cv 1.72 % 1.72 % 4 -ssa::splitf + functor_mean 204 ns 204 ns 4 -ssa::splitf + functor_median 206 ns 206 ns 4 -ssa::splitf + functor_stddev 4.33 ns 4.33 ns 4 -ssa::splitf + functor_cv 2.12 % 2.12 % 4 +std::string::find + substr + std::strtol_mean 266 ns 266 ns 4 +std::string::find + substr + std::strtol_median 262 ns 262 ns 4 +std::string::find + substr + std::strtol_stddev 12.0 ns 12.0 ns 4 +std::string::find + substr + std::strtol_cv 4.51 % 4.51 % 4 +ssa::splitter + ssa::as_int_mean 156 ns 156 ns 4 +ssa::splitter + ssa::as_int_median 151 ns 151 ns 4 +ssa::splitter + ssa::as_int_stddev 11.0 ns 11.0 ns 4 +ssa::splitter + ssa::as_int_cv 7.06 % 7.06 % 4 +ssa::splitf + functor_mean 208 ns 208 ns 4 +ssa::splitf + functor_median 207 ns 207 ns 4 +ssa::splitf + functor_stddev 3.53 ns 3.53 ns 4 +ssa::splitf + functor_cv 1.70 % 1.70 % 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 847 ns 847 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_median 851 ns 851 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_stddev 12.0 ns 12.0 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_cv 1.41 % 1.41 % 4 -replace symbols with std::string find_first_of + replace_mean 2405 ns 2405 ns 4 -replace symbols with std::string find_first_of + replace_median 2387 ns 2387 ns 4 -replace symbols with std::string find_first_of + replace_stddev 56.7 ns 56.7 ns 4 -replace symbols with std::string find_first_of + replace_cv 2.36 % 2.36 % 4 -replace symbols with std::string_view find_first_of + copy_mean 1081 ns 1081 ns 4 -replace symbols with std::string_view find_first_of + copy_median 1077 ns 1077 ns 4 -replace symbols with std::string_view find_first_of + copy_stddev 16.1 ns 16.1 ns 4 -replace symbols with std::string_view find_first_of + copy_cv 1.49 % 1.49 % 4 -replace runtime symbols with string expressions and without remembering all search results_mean 1234 ns 1234 ns 4 -replace runtime symbols with string expressions and without remembering all search results_median 1226 ns 1226 ns 4 -replace runtime symbols with string expressions and without remembering all search results_stddev 29.9 ns 29.9 ns 4 -replace runtime symbols with string expressions and without remembering all search results_cv 2.42 % 2.42 % 4 -replace runtime symbols with simstr and memorization of all search results_mean 989 ns 989 ns 4 -replace runtime symbols with simstr and memorization of all search results_median 993 ns 993 ns 4 -replace runtime symbols with simstr and memorization of all search results_stddev 14.6 ns 14.6 ns 4 -replace runtime symbols with simstr and memorization of all search results_cv 1.47 % 1.47 % 4 -replace const symbols with string expressions and without remembering all search results_mean 1099 ns 1099 ns 4 -replace const symbols with string expressions and without remembering all search results_median 1097 ns 1097 ns 4 -replace const symbols with string expressions and without remembering all search results_stddev 15.6 ns 15.6 ns 4 -replace const symbols with string expressions and without remembering all search results_cv 1.42 % 1.42 % 4 -replace const symbols with string expressions and memorization of all search results_mean 862 ns 862 ns 4 -replace const symbols with string expressions and memorization of all search results_median 856 ns 856 ns 4 -replace const symbols with string expressions and memorization of all search results_stddev 19.9 ns 19.9 ns 4 -replace const symbols with string expressions and memorization of all search results_cv 2.31 % 2.31 % 4 +Naive (and wrong) replace symbols with std::string find + replace_mean 835 ns 835 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_median 833 ns 833 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_stddev 15.8 ns 15.8 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_cv 1.89 % 1.89 % 4 +replace symbols with std::string find_first_of + replace_mean 2459 ns 2459 ns 4 +replace symbols with std::string find_first_of + replace_median 2443 ns 2443 ns 4 +replace symbols with std::string find_first_of + replace_stddev 57.5 ns 57.5 ns 4 +replace symbols with std::string find_first_of + replace_cv 2.34 % 2.34 % 4 +replace symbols with std::string_view find_first_of + copy_mean 1128 ns 1128 ns 4 +replace symbols with std::string_view find_first_of + copy_median 1136 ns 1136 ns 4 +replace symbols with std::string_view find_first_of + copy_stddev 26.7 ns 26.7 ns 4 +replace symbols with std::string_view find_first_of + copy_cv 2.37 % 2.37 % 4 +replace runtime symbols with string expressions and without remembering all search results_mean 1268 ns 1268 ns 4 +replace runtime symbols with string expressions and without remembering all search results_median 1266 ns 1266 ns 4 +replace runtime symbols with string expressions and without remembering all search results_stddev 34.1 ns 34.1 ns 4 +replace runtime symbols with string expressions and without remembering all search results_cv 2.69 % 2.69 % 4 +replace runtime symbols with simstr and memorization of all search results_mean 1010 ns 1010 ns 4 +replace runtime symbols with simstr and memorization of all search results_median 972 ns 972 ns 4 +replace runtime symbols with simstr and memorization of all search results_stddev 81.6 ns 81.6 ns 4 +replace runtime symbols with simstr and memorization of all search results_cv 8.08 % 8.08 % 4 +replace const symbols with string expressions and without remembering all search results_mean 1061 ns 1061 ns 4 +replace const symbols with string expressions and without remembering all search results_median 1057 ns 1057 ns 4 +replace const symbols with string expressions and without remembering all search results_stddev 16.4 ns 16.4 ns 4 +replace const symbols with string expressions and without remembering all search results_cv 1.55 % 1.55 % 4 +replace const symbols with string expressions and memorization of all search results_mean 840 ns 840 ns 4 +replace const symbols with string expressions and memorization of all search results_median 837 ns 837 ns 4 +replace const symbols with string expressions and memorization of all search results_stddev 28.9 ns 28.9 ns 4 +replace const symbols with string expressions and memorization of all search results_cv 3.44 % 3.44 % 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 163 ns 163 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_median 163 ns 163 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_stddev 2.97 ns 2.97 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_cv 1.82 % 1.82 % 4 -Short replace symbols with std::string find_first_of + replace_mean 319 ns 319 ns 4 -Short replace symbols with std::string find_first_of + replace_median 320 ns 320 ns 4 -Short replace symbols with std::string find_first_of + replace_stddev 6.76 ns 6.76 ns 4 -Short replace symbols with std::string find_first_of + replace_cv 2.12 % 2.12 % 4 -Short replace symbols with std::string_view find_first_of + copy_mean 162 ns 162 ns 4 -Short replace symbols with std::string_view find_first_of + copy_median 163 ns 163 ns 4 -Short replace symbols with std::string_view find_first_of + copy_stddev 3.49 ns 3.49 ns 4 -Short replace symbols with std::string_view find_first_of + copy_cv 2.15 % 2.15 % 4 -Short replace runtime symbols with string expressions and without remembering all search results_mean 175 ns 175 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_median 176 ns 176 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_stddev 3.30 ns 3.30 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_cv 1.89 % 1.89 % 4 -Short replace runtime symbols with simstr and memorization of all search results_mean 180 ns 180 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_median 181 ns 181 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_stddev 2.01 ns 2.01 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_cv 1.12 % 1.12 % 4 -Short replace const symbols with string expressions and without remembering all search results_mean 137 ns 137 ns 4 -Short replace const symbols with string expressions and without remembering all search results_median 134 ns 134 ns 4 -Short replace const symbols with string expressions and without remembering all search results_stddev 7.35 ns 7.35 ns 4 -Short replace const symbols with string expressions and without remembering all search results_cv 5.37 % 5.37 % 4 -Short replace const symbols with string expressions and memorization of all search results_mean 142 ns 142 ns 4 -Short replace const symbols with string expressions and memorization of all search results_median 143 ns 143 ns 4 -Short replace const symbols with string expressions and memorization of all search results_stddev 3.49 ns 3.49 ns 4 -Short replace const symbols with string expressions and memorization of all search results_cv 2.45 % 2.45 % 4 +Short Naive (and wrong) replace symbols with std::string find + replace_mean 150 ns 150 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_median 149 ns 149 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_stddev 4.70 ns 4.70 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_cv 3.14 % 3.14 % 4 +Short replace symbols with std::string find_first_of + replace_mean 313 ns 313 ns 4 +Short replace symbols with std::string find_first_of + replace_median 312 ns 312 ns 4 +Short replace symbols with std::string find_first_of + replace_stddev 6.70 ns 6.70 ns 4 +Short replace symbols with std::string find_first_of + replace_cv 2.14 % 2.14 % 4 +Short replace symbols with std::string_view find_first_of + copy_mean 153 ns 153 ns 4 +Short replace symbols with std::string_view find_first_of + copy_median 153 ns 153 ns 4 +Short replace symbols with std::string_view find_first_of + copy_stddev 3.76 ns 3.76 ns 4 +Short replace symbols with std::string_view find_first_of + copy_cv 2.46 % 2.46 % 4 +Short replace runtime symbols with string expressions and without remembering all search results_mean 172 ns 172 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_median 171 ns 171 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_stddev 4.58 ns 4.58 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_cv 2.66 % 2.66 % 4 +Short replace runtime symbols with simstr and memorization of all search results_mean 173 ns 173 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_median 173 ns 173 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_stddev 0.959 ns 0.959 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_cv 0.55 % 0.55 % 4 +Short replace const symbols with string expressions and without remembering all search results_mean 138 ns 138 ns 4 +Short replace const symbols with string expressions and without remembering all search results_median 136 ns 136 ns 4 +Short replace const symbols with string expressions and without remembering all search results_stddev 9.47 ns 9.47 ns 4 +Short replace const symbols with string expressions and without remembering all search results_cv 6.84 % 6.84 % 4 +Short replace const symbols with string expressions and memorization of all search results_mean 141 ns 141 ns 4 +Short replace const symbols with string expressions and memorization of all search results_median 141 ns 141 ns 4 +Short replace const symbols with string expressions and memorization of all search results_stddev 2.25 ns 2.25 ns 4 +Short replace const symbols with string expressions and memorization of all search results_cv 1.60 % 1.60 % 4 ----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to ---- in std::string|64_mean 158 ns 158 ns 4 -replace bb to ---- in std::string|64_median 159 ns 159 ns 4 -replace bb to ---- in std::string|64_stddev 3.78 ns 3.78 ns 4 -replace bb to ---- in std::string|64_cv 2.40 % 2.40 % 4 -replace bb to ---- in std::string|256_mean 532 ns 532 ns 4 -replace bb to ---- in std::string|256_median 532 ns 532 ns 4 -replace bb to ---- in std::string|256_stddev 5.39 ns 5.39 ns 4 -replace bb to ---- in std::string|256_cv 1.01 % 1.01 % 4 -replace bb to ---- in std::string|512_mean 1023 ns 1023 ns 4 -replace bb to ---- in std::string|512_median 1023 ns 1023 ns 4 -replace bb to ---- in std::string|512_stddev 6.21 ns 6.21 ns 4 -replace bb to ---- in std::string|512_cv 0.61 % 0.61 % 4 -replace bb to ---- in std::string|1024_mean 2357 ns 2357 ns 4 -replace bb to ---- in std::string|1024_median 2323 ns 2323 ns 4 -replace bb to ---- in std::string|1024_stddev 186 ns 186 ns 4 -replace bb to ---- in std::string|1024_cv 7.88 % 7.88 % 4 -replace bb to ---- in std::string|2048_mean 5789 ns 5789 ns 4 -replace bb to ---- in std::string|2048_median 5704 ns 5704 ns 4 -replace bb to ---- in std::string|2048_stddev 243 ns 243 ns 4 -replace bb to ---- in std::string|2048_cv 4.20 % 4.20 % 4 -replace bb to ---- in lstringa<8>|64_mean 141 ns 141 ns 4 -replace bb to ---- in lstringa<8>|64_median 141 ns 141 ns 4 -replace bb to ---- in lstringa<8>|64_stddev 5.96 ns 5.96 ns 4 -replace bb to ---- in lstringa<8>|64_cv 4.21 % 4.21 % 4 -replace bb to ---- in lstringa<8>|256_mean 441 ns 441 ns 4 -replace bb to ---- in lstringa<8>|256_median 442 ns 442 ns 4 -replace bb to ---- in lstringa<8>|256_stddev 3.42 ns 3.42 ns 4 -replace bb to ---- in lstringa<8>|256_cv 0.78 % 0.78 % 4 -replace bb to ---- in lstringa<8>|512_mean 828 ns 828 ns 4 -replace bb to ---- in lstringa<8>|512_median 828 ns 828 ns 4 -replace bb to ---- in lstringa<8>|512_stddev 7.01 ns 6.98 ns 4 -replace bb to ---- in lstringa<8>|512_cv 0.85 % 0.84 % 4 -replace bb to ---- in lstringa<8>|1024_mean 1689 ns 1689 ns 4 -replace bb to ---- in lstringa<8>|1024_median 1678 ns 1678 ns 4 -replace bb to ---- in lstringa<8>|1024_stddev 40.6 ns 40.6 ns 4 -replace bb to ---- in lstringa<8>|1024_cv 2.40 % 2.40 % 4 -replace bb to ---- in lstringa<8>|2048_mean 3162 ns 3162 ns 4 -replace bb to ---- in lstringa<8>|2048_median 3153 ns 3153 ns 4 -replace bb to ---- in lstringa<8>|2048_stddev 101 ns 101 ns 4 -replace bb to ---- in lstringa<8>|2048_cv 3.20 % 3.20 % 4 -replace bb to ---- by init stringa|64_mean 95.5 ns 95.5 ns 4 -replace bb to ---- by init stringa|64_median 95.5 ns 95.5 ns 4 -replace bb to ---- by init stringa|64_stddev 2.06 ns 2.06 ns 4 -replace bb to ---- by init stringa|64_cv 2.15 % 2.15 % 4 +replace bb to ---- in std::string|64_mean 157 ns 157 ns 4 +replace bb to ---- in std::string|64_median 155 ns 155 ns 4 +replace bb to ---- in std::string|64_stddev 4.12 ns 4.12 ns 4 +replace bb to ---- in std::string|64_cv 2.63 % 2.63 % 4 +replace bb to ---- in std::string|256_mean 527 ns 527 ns 4 +replace bb to ---- in std::string|256_median 528 ns 528 ns 4 +replace bb to ---- in std::string|256_stddev 8.98 ns 8.98 ns 4 +replace bb to ---- in std::string|256_cv 1.70 % 1.70 % 4 +replace bb to ---- in std::string|512_mean 1332 ns 1332 ns 4 +replace bb to ---- in std::string|512_median 1329 ns 1329 ns 4 +replace bb to ---- in std::string|512_stddev 8.67 ns 8.67 ns 4 +replace bb to ---- in std::string|512_cv 0.65 % 0.65 % 4 +replace bb to ---- in std::string|1024_mean 2359 ns 2359 ns 4 +replace bb to ---- in std::string|1024_median 2389 ns 2389 ns 4 +replace bb to ---- in std::string|1024_stddev 212 ns 212 ns 4 +replace bb to ---- in std::string|1024_cv 8.98 % 8.98 % 4 +replace bb to ---- in std::string|2048_mean 5479 ns 5479 ns 4 +replace bb to ---- in std::string|2048_median 5398 ns 5398 ns 4 +replace bb to ---- in std::string|2048_stddev 332 ns 332 ns 4 +replace bb to ---- in std::string|2048_cv 6.06 % 6.06 % 4 +replace bb to ---- in lstringa<8>|64_mean 137 ns 137 ns 4 +replace bb to ---- in lstringa<8>|64_median 136 ns 136 ns 4 +replace bb to ---- in lstringa<8>|64_stddev 2.34 ns 2.34 ns 4 +replace bb to ---- in lstringa<8>|64_cv 1.70 % 1.70 % 4 +replace bb to ---- in lstringa<8>|256_mean 426 ns 426 ns 4 +replace bb to ---- in lstringa<8>|256_median 427 ns 427 ns 4 +replace bb to ---- in lstringa<8>|256_stddev 9.27 ns 9.27 ns 4 +replace bb to ---- in lstringa<8>|256_cv 2.18 % 2.18 % 4 +replace bb to ---- in lstringa<8>|512_mean 781 ns 781 ns 4 +replace bb to ---- in lstringa<8>|512_median 785 ns 785 ns 4 +replace bb to ---- in lstringa<8>|512_stddev 20.5 ns 20.5 ns 4 +replace bb to ---- in lstringa<8>|512_cv 2.63 % 2.63 % 4 +replace bb to ---- in lstringa<8>|1024_mean 1574 ns 1574 ns 4 +replace bb to ---- in lstringa<8>|1024_median 1565 ns 1565 ns 4 +replace bb to ---- in lstringa<8>|1024_stddev 44.2 ns 44.2 ns 4 +replace bb to ---- in lstringa<8>|1024_cv 2.81 % 2.81 % 4 +replace bb to ---- in lstringa<8>|2048_mean 3024 ns 3024 ns 4 +replace bb to ---- in lstringa<8>|2048_median 3024 ns 3024 ns 4 +replace bb to ---- in lstringa<8>|2048_stddev 57.1 ns 57.1 ns 4 +replace bb to ---- in lstringa<8>|2048_cv 1.89 % 1.89 % 4 +replace bb to ---- by init stringa|64_mean 91.9 ns 91.9 ns 4 +replace bb to ---- by init stringa|64_median 91.4 ns 91.4 ns 4 +replace bb to ---- by init stringa|64_stddev 1.30 ns 1.30 ns 4 +replace bb to ---- by init stringa|64_cv 1.42 % 1.42 % 4 replace bb to ---- by init stringa|256_mean 305 ns 305 ns 4 -replace bb to ---- by init stringa|256_median 301 ns 301 ns 4 -replace bb to ---- by init stringa|256_stddev 8.27 ns 8.27 ns 4 -replace bb to ---- by init stringa|256_cv 2.72 % 2.72 % 4 -replace bb to ---- by init stringa|512_mean 729 ns 729 ns 4 -replace bb to ---- by init stringa|512_median 723 ns 723 ns 4 -replace bb to ---- by init stringa|512_stddev 18.8 ns 18.8 ns 4 -replace bb to ---- by init stringa|512_cv 2.58 % 2.58 % 4 -replace bb to ---- by init stringa|1024_mean 1502 ns 1502 ns 4 -replace bb to ---- by init stringa|1024_median 1506 ns 1506 ns 4 -replace bb to ---- by init stringa|1024_stddev 19.5 ns 19.5 ns 4 -replace bb to ---- by init stringa|1024_cv 1.30 % 1.30 % 4 -replace bb to ---- by init stringa|2048_mean 3150 ns 3150 ns 4 -replace bb to ---- by init stringa|2048_median 3107 ns 3107 ns 4 -replace bb to ---- by init stringa|2048_stddev 158 ns 158 ns 4 -replace bb to ---- by init stringa|2048_cv 5.03 % 5.03 % 4 +replace bb to ---- by init stringa|256_median 303 ns 303 ns 4 +replace bb to ---- by init stringa|256_stddev 6.13 ns 6.13 ns 4 +replace bb to ---- by init stringa|256_cv 2.01 % 2.01 % 4 +replace bb to ---- by init stringa|512_mean 700 ns 700 ns 4 +replace bb to ---- by init stringa|512_median 701 ns 701 ns 4 +replace bb to ---- by init stringa|512_stddev 6.78 ns 6.78 ns 4 +replace bb to ---- by init stringa|512_cv 0.97 % 0.97 % 4 +replace bb to ---- by init stringa|1024_mean 1564 ns 1564 ns 4 +replace bb to ---- by init stringa|1024_median 1564 ns 1564 ns 4 +replace bb to ---- by init stringa|1024_stddev 2.18 ns 2.18 ns 4 +replace bb to ---- by init stringa|1024_cv 0.14 % 0.14 % 4 +replace bb to ---- by init stringa|2048_mean 3148 ns 3148 ns 4 +replace bb to ---- by init stringa|2048_median 3152 ns 3152 ns 4 +replace bb to ---- by init stringa|2048_stddev 20.7 ns 20.7 ns 4 +replace bb to ---- by init stringa|2048_cv 0.66 % 0.66 % 4 ----- Replace All Str To Same Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to -- in std::string|64_mean 125 ns 125 ns 4 -replace bb to -- in std::string|64_median 122 ns 122 ns 4 -replace bb to -- in std::string|64_stddev 9.24 ns 9.24 ns 4 -replace bb to -- in std::string|64_cv 7.41 % 7.41 % 4 -replace bb to -- in std::string|256_mean 392 ns 392 ns 4 -replace bb to -- in std::string|256_median 393 ns 393 ns 4 -replace bb to -- in std::string|256_stddev 9.41 ns 9.41 ns 4 -replace bb to -- in std::string|256_cv 2.40 % 2.40 % 4 -replace bb to -- in std::string|512_mean 758 ns 758 ns 4 -replace bb to -- in std::string|512_median 759 ns 759 ns 4 -replace bb to -- in std::string|512_stddev 20.3 ns 20.3 ns 4 -replace bb to -- in std::string|512_cv 2.68 % 2.68 % 4 -replace bb to -- in std::string|1024_mean 1415 ns 1415 ns 4 -replace bb to -- in std::string|1024_median 1417 ns 1417 ns 4 -replace bb to -- in std::string|1024_stddev 21.3 ns 21.3 ns 4 -replace bb to -- in std::string|1024_cv 1.50 % 1.50 % 4 -replace bb to -- in std::string|2048_mean 3032 ns 3032 ns 4 -replace bb to -- in std::string|2048_median 3047 ns 3047 ns 4 -replace bb to -- in std::string|2048_stddev 39.0 ns 39.0 ns 4 -replace bb to -- in std::string|2048_cv 1.29 % 1.29 % 4 -replace bb to -- in lstringa<8>|64_mean 97.7 ns 97.7 ns 4 -replace bb to -- in lstringa<8>|64_median 97.6 ns 97.6 ns 4 -replace bb to -- in lstringa<8>|64_stddev 0.342 ns 0.342 ns 4 -replace bb to -- in lstringa<8>|64_cv 0.35 % 0.35 % 4 -replace bb to -- in lstringa<8>|256_mean 290 ns 290 ns 4 -replace bb to -- in lstringa<8>|256_median 285 ns 285 ns 4 -replace bb to -- in lstringa<8>|256_stddev 12.1 ns 12.1 ns 4 -replace bb to -- in lstringa<8>|256_cv 4.17 % 4.17 % 4 -replace bb to -- in lstringa<8>|512_mean 551 ns 551 ns 4 -replace bb to -- in lstringa<8>|512_median 548 ns 548 ns 4 -replace bb to -- in lstringa<8>|512_stddev 12.8 ns 12.8 ns 4 -replace bb to -- in lstringa<8>|512_cv 2.33 % 2.33 % 4 -replace bb to -- in lstringa<8>|1024_mean 1129 ns 1129 ns 4 -replace bb to -- in lstringa<8>|1024_median 1131 ns 1131 ns 4 -replace bb to -- in lstringa<8>|1024_stddev 18.7 ns 18.7 ns 4 -replace bb to -- in lstringa<8>|1024_cv 1.66 % 1.66 % 4 -replace bb to -- in lstringa<8>|2048_mean 2146 ns 2146 ns 4 -replace bb to -- in lstringa<8>|2048_median 2138 ns 2138 ns 4 -replace bb to -- in lstringa<8>|2048_stddev 58.0 ns 58.0 ns 4 -replace bb to -- in lstringa<8>|2048_cv 2.70 % 2.70 % 4 -replace bb to -- by init stringa|64_mean 84.5 ns 84.5 ns 4 -replace bb to -- by init stringa|64_median 84.7 ns 84.7 ns 4 -replace bb to -- by init stringa|64_stddev 2.16 ns 2.16 ns 4 -replace bb to -- by init stringa|64_cv 2.56 % 2.56 % 4 -replace bb to -- by init stringa|256_mean 239 ns 239 ns 4 -replace bb to -- by init stringa|256_median 239 ns 239 ns 4 -replace bb to -- by init stringa|256_stddev 3.13 ns 3.13 ns 4 -replace bb to -- by init stringa|256_cv 1.31 % 1.31 % 4 -replace bb to -- by init stringa|512_mean 424 ns 424 ns 4 -replace bb to -- by init stringa|512_median 425 ns 425 ns 4 -replace bb to -- by init stringa|512_stddev 6.55 ns 6.55 ns 4 -replace bb to -- by init stringa|512_cv 1.54 % 1.54 % 4 -replace bb to -- by init stringa|1024_mean 896 ns 896 ns 4 -replace bb to -- by init stringa|1024_median 894 ns 894 ns 4 -replace bb to -- by init stringa|1024_stddev 15.7 ns 15.7 ns 4 -replace bb to -- by init stringa|1024_cv 1.75 % 1.75 % 4 -replace bb to -- by init stringa|2048_mean 1685 ns 1685 ns 4 -replace bb to -- by init stringa|2048_median 1694 ns 1694 ns 4 -replace bb to -- by init stringa|2048_stddev 28.9 ns 28.9 ns 4 -replace bb to -- by init stringa|2048_cv 1.71 % 1.71 % 4 +replace bb to -- in std::string|64_mean 131 ns 131 ns 4 +replace bb to -- in std::string|64_median 131 ns 131 ns 4 +replace bb to -- in std::string|64_stddev 3.33 ns 3.33 ns 4 +replace bb to -- in std::string|64_cv 2.53 % 2.53 % 4 +replace bb to -- in std::string|256_mean 367 ns 367 ns 4 +replace bb to -- in std::string|256_median 369 ns 369 ns 4 +replace bb to -- in std::string|256_stddev 8.59 ns 8.59 ns 4 +replace bb to -- in std::string|256_cv 2.34 % 2.34 % 4 +replace bb to -- in std::string|512_mean 722 ns 722 ns 4 +replace bb to -- in std::string|512_median 719 ns 719 ns 4 +replace bb to -- in std::string|512_stddev 9.53 ns 9.53 ns 4 +replace bb to -- in std::string|512_cv 1.32 % 1.32 % 4 +replace bb to -- in std::string|1024_mean 1429 ns 1429 ns 4 +replace bb to -- in std::string|1024_median 1432 ns 1432 ns 4 +replace bb to -- in std::string|1024_stddev 20.3 ns 20.3 ns 4 +replace bb to -- in std::string|1024_cv 1.42 % 1.42 % 4 +replace bb to -- in std::string|2048_mean 2801 ns 2801 ns 4 +replace bb to -- in std::string|2048_median 2800 ns 2800 ns 4 +replace bb to -- in std::string|2048_stddev 11.5 ns 11.5 ns 4 +replace bb to -- in std::string|2048_cv 0.41 % 0.41 % 4 +replace bb to -- in lstringa<8>|64_mean 99.6 ns 99.6 ns 4 +replace bb to -- in lstringa<8>|64_median 95.2 ns 95.2 ns 4 +replace bb to -- in lstringa<8>|64_stddev 12.2 ns 12.2 ns 4 +replace bb to -- in lstringa<8>|64_cv 12.27 % 12.27 % 4 +replace bb to -- in lstringa<8>|256_mean 289 ns 289 ns 4 +replace bb to -- in lstringa<8>|256_median 289 ns 289 ns 4 +replace bb to -- in lstringa<8>|256_stddev 3.67 ns 3.67 ns 4 +replace bb to -- in lstringa<8>|256_cv 1.27 % 1.27 % 4 +replace bb to -- in lstringa<8>|512_mean 523 ns 523 ns 4 +replace bb to -- in lstringa<8>|512_median 518 ns 518 ns 4 +replace bb to -- in lstringa<8>|512_stddev 20.1 ns 20.1 ns 4 +replace bb to -- in lstringa<8>|512_cv 3.84 % 3.84 % 4 +replace bb to -- in lstringa<8>|1024_mean 1058 ns 1058 ns 4 +replace bb to -- in lstringa<8>|1024_median 1060 ns 1060 ns 4 +replace bb to -- in lstringa<8>|1024_stddev 18.3 ns 18.3 ns 4 +replace bb to -- in lstringa<8>|1024_cv 1.73 % 1.73 % 4 +replace bb to -- in lstringa<8>|2048_mean 2093 ns 2093 ns 4 +replace bb to -- in lstringa<8>|2048_median 2097 ns 2097 ns 4 +replace bb to -- in lstringa<8>|2048_stddev 104 ns 104 ns 4 +replace bb to -- in lstringa<8>|2048_cv 4.97 % 4.97 % 4 +replace bb to -- by init stringa|64_mean 74.4 ns 74.4 ns 4 +replace bb to -- by init stringa|64_median 74.0 ns 74.0 ns 4 +replace bb to -- by init stringa|64_stddev 1.67 ns 1.67 ns 4 +replace bb to -- by init stringa|64_cv 2.24 % 2.24 % 4 +replace bb to -- by init stringa|256_mean 238 ns 238 ns 4 +replace bb to -- by init stringa|256_median 230 ns 230 ns 4 +replace bb to -- by init stringa|256_stddev 17.1 ns 17.1 ns 4 +replace bb to -- by init stringa|256_cv 7.17 % 7.17 % 4 +replace bb to -- by init stringa|512_mean 420 ns 420 ns 4 +replace bb to -- by init stringa|512_median 420 ns 420 ns 4 +replace bb to -- by init stringa|512_stddev 4.50 ns 4.50 ns 4 +replace bb to -- by init stringa|512_cv 1.07 % 1.07 % 4 +replace bb to -- by init stringa|1024_mean 869 ns 869 ns 4 +replace bb to -- by init stringa|1024_median 872 ns 872 ns 4 +replace bb to -- by init stringa|1024_stddev 21.6 ns 21.6 ns 4 +replace bb to -- by init stringa|1024_cv 2.48 % 2.48 % 4 +replace bb to -- by init stringa|2048_mean 1707 ns 1707 ns 4 +replace bb to -- by init stringa|2048_median 1668 ns 1668 ns 4 +replace bb to -- by init stringa|2048_stddev 99.1 ns 99.1 ns 4 +replace bb to -- by init stringa|2048_cv 5.81 % 5.81 % 4 ----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -hashStrMapA emplace & find stringa;_mean 3547342 ns 3547308 ns 4 -hashStrMapA emplace & find stringa;_median 3536291 ns 3536208 ns 4 -hashStrMapA emplace & find stringa;_stddev 49586 ns 49600 ns 4 -hashStrMapA emplace & find stringa;_cv 1.40 % 1.40 % 4 -std::unordered_map emplace & find std::string;_mean 3523732 ns 3523744 ns 4 -std::unordered_map emplace & find std::string;_median 3514345 ns 3514358 ns 4 -std::unordered_map emplace & find std::string;_stddev 52176 ns 52175 ns 4 -std::unordered_map emplace & find std::string;_cv 1.48 % 1.48 % 4 -hashStrMapA emplace & find ssa;_mean 3554403 ns 3554420 ns 4 -hashStrMapA emplace & find ssa;_median 3555498 ns 3555516 ns 4 -hashStrMapA emplace & find ssa;_stddev 10914 ns 10917 ns 4 -hashStrMapA emplace & find ssa;_cv 0.31 % 0.31 % 4 -std::unordered_map emplace & find std::string_view;_mean 3955601 ns 3955552 ns 4 -std::unordered_map emplace & find std::string_view;_median 3947240 ns 3947129 ns 4 -std::unordered_map emplace & find std::string_view;_stddev 77785 ns 77814 ns 4 -std::unordered_map emplace & find std::string_view;_cv 1.97 % 1.97 % 4 +hashStrMapA emplace & find stringa;_mean 3519614 ns 3519627 ns 4 +hashStrMapA emplace & find stringa;_median 3513825 ns 3513839 ns 4 +hashStrMapA emplace & find stringa;_stddev 45672 ns 45672 ns 4 +hashStrMapA emplace & find stringa;_cv 1.30 % 1.30 % 4 +std::unordered_map emplace & find std::string;_mean 3429563 ns 3429501 ns 4 +std::unordered_map emplace & find std::string;_median 3448425 ns 3448440 ns 4 +std::unordered_map emplace & find std::string;_stddev 93486 ns 93625 ns 4 +std::unordered_map emplace & find std::string;_cv 2.73 % 2.73 % 4 +hashStrMapA emplace & find ssa;_mean 3526598 ns 3526615 ns 4 +hashStrMapA emplace & find ssa;_median 3533238 ns 3533255 ns 4 +hashStrMapA emplace & find ssa;_stddev 53366 ns 53367 ns 4 +hashStrMapA emplace & find ssa;_cv 1.51 % 1.51 % 4 +std::unordered_map emplace & find std::string_view;_mean 4067399 ns 4067414 ns 4 +std::unordered_map emplace & find std::string_view;_median 4067333 ns 4067348 ns 4 +std::unordered_map emplace & find std::string_view;_stddev 56632 ns 56637 ns 4 +std::unordered_map emplace & find std::string_view;_cv 1.39 % 1.39 % 4 ----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Build func full name std::string;_mean 721 ns 721 ns 4 -Build func full name std::string;_median 724 ns 724 ns 4 -Build func full name std::string;_stddev 32.3 ns 32.3 ns 4 -Build func full name std::string;_cv 4.48 % 4.48 % 4 -Build func full name std::string 1;_mean 828 ns 828 ns 4 -Build func full name std::string 1;_median 833 ns 833 ns 4 +Build func full name std::string;_mean 660 ns 660 ns 4 +Build func full name std::string;_median 665 ns 665 ns 4 +Build func full name std::string;_stddev 21.8 ns 21.8 ns 4 +Build func full name std::string;_cv 3.30 % 3.30 % 4 +Build func full name std::string 1;_mean 758 ns 758 ns 4 +Build func full name std::string 1;_median 761 ns 761 ns 4 Build func full name std::string 1;_stddev 15.9 ns 15.9 ns 4 -Build func full name std::string 1;_cv 1.92 % 1.92 % 4 -Build func full name std::stream;_mean 2561 ns 2561 ns 4 -Build func full name std::stream;_median 2562 ns 2562 ns 4 -Build func full name std::stream;_stddev 8.50 ns 8.50 ns 4 -Build func full name std::stream;_cv 0.33 % 0.33 % 4 -Build func full name stringa;_mean 503 ns 503 ns 4 -Build func full name stringa;_median 503 ns 503 ns 4 -Build func full name stringa;_stddev 12.5 ns 12.5 ns 4 -Build func full name stringa;_cv 2.49 % 2.49 % 4 -Build func full name stringa 1;_mean 671 ns 671 ns 4 -Build func full name stringa 1;_median 674 ns 674 ns 4 -Build func full name stringa 1;_stddev 8.48 ns 8.48 ns 4 -Build func full name stringa 1;_cv 1.26 % 1.26 % 4 +Build func full name std::string 1;_cv 2.10 % 2.10 % 4 +Build func full name std::stream;_mean 2557 ns 2557 ns 4 +Build func full name std::stream;_median 2568 ns 2568 ns 4 +Build func full name std::stream;_stddev 53.3 ns 53.3 ns 4 +Build func full name std::stream;_cv 2.08 % 2.08 % 4 +Build func full name stringa;_mean 494 ns 494 ns 4 +Build func full name stringa;_median 493 ns 493 ns 4 +Build func full name stringa;_stddev 4.59 ns 4.60 ns 4 +Build func full name stringa;_cv 0.93 % 0.93 % 4 +Build func full name stringa 1;_mean 607 ns 607 ns 4 +Build func full name stringa 1;_median 590 ns 590 ns 4 +Build func full name stringa 1;_stddev 41.2 ns 41.2 ns 4 +Build func full name stringa 1;_cv 6.78 % 6.78 % 4 diff --git a/bench/results/001-Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13.txt b/bench/results/001-Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13.txt index 6956b70..e687949 100644 --- a/bench/results/001-Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13.txt +++ b/bench/results/001-Xeon E5-2682 v4, Ubuntu 22 (WSL), GCC-13.txt @@ -2,7 +2,7 @@ Benchmarks of simstr, version 1.6.7 Sources: https://github.com/orefkov/simstr Results: https://orefkov.github.io/simstr/results.html -2026-02-12T15:27:04+03:00 +2026-02-14T11:48:18+03:00 Running ./benchStr Run on (32 X 2494.22 MHz CPU s) CPU Caches: @@ -10,930 +10,967 @@ CPU Caches: L1 Instruction 32 KiB (x16) L2 Unified 256 KiB (x16) L3 Unified 40960 KiB (x1) -Load Average: 0.19, 0.64, 0.48 +Load Average: 0.00, 0.00, 0.00 ***WARNING*** ASLR is enabled, the results may have unreproducible noise in them. -------------------------------------------------------------------------------------------------------------------------------------------------------- Benchmark Time CPU Iterations -------------------------------------------------------------------------------------------------------------------------------------------------------- +----- Concatenate email ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 +Concat email std::format_mean 177 ns 177 ns 4 +Concat email std::format_median 176 ns 176 ns 4 +Concat email std::format_stddev 3.45 ns 3.45 ns 4 +Concat email std::format_cv 1.95 % 1.95 % 4 +Concat email std::stringstream_mean 328 ns 328 ns 4 +Concat email std::stringstream_median 324 ns 324 ns 4 +Concat email std::stringstream_stddev 18.4 ns 18.4 ns 4 +Concat email std::stringstream_cv 5.62 % 5.62 % 4 +Concat email stringzilla append_mean 115 ns 115 ns 4 +Concat email stringzilla append_median 115 ns 115 ns 4 +Concat email stringzilla append_stddev 3.71 ns 3.71 ns 4 +Concat email stringzilla append_cv 3.21 % 3.21 % 4 +Concat email stringzilla concat_mean 48.3 ns 48.3 ns 4 +Concat email stringzilla concat_median 48.0 ns 48.0 ns 4 +Concat email stringzilla concat_stddev 3.91 ns 3.91 ns 4 +Concat email stringzilla concat_cv 8.10 % 8.10 % 4 +Concat email std::string append_mean 96.7 ns 96.7 ns 4 +Concat email std::string append_median 96.0 ns 96.0 ns 4 +Concat email std::string append_stddev 3.02 ns 3.02 ns 4 +Concat email std::string append_cv 3.12 % 3.12 % 4 +Concat email std::string by strexpr_mean 33.5 ns 33.5 ns 4 +Concat email std::string by strexpr_median 33.5 ns 33.5 ns 4 +Concat email std::string by strexpr_stddev 0.634 ns 0.634 ns 4 +Concat email std::string by strexpr_cv 1.89 % 1.89 % 4 +Concat email stringa_mean 40.3 ns 40.3 ns 4 +Concat email stringa_median 40.6 ns 40.6 ns 4 +Concat email stringa_stddev 0.692 ns 0.692 ns 4 +Concat email stringa_cv 1.72 % 1.72 % 4 ----- Concatenate string + Number + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string and number by std to std::string_mean 202 ns 202 ns 4 -Concat std::string and number by std to std::string_median 199 ns 199 ns 4 -Concat std::string and number by std to std::string_stddev 6.88 ns 6.88 ns 4 -Concat std::string and number by std to std::string_cv 3.41 % 3.41 % 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 101 ns 101 ns 4 -Concat std::string and number by StrExpr to std::string_stddev 2.79 ns 2.79 ns 4 -Concat std::string and number by StrExpr to std::string_cv 2.77 % 2.77 % 4 -Concat stringa and number by StrExpr to simstr::stringa_mean 72.1 ns 72.1 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_median 71.6 ns 71.6 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_stddev 1.55 ns 1.55 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_cv 2.15 % 2.15 % 4 -Concat stringa and number by e_concat to simstr::stringa_mean 75.9 ns 75.9 ns 4 -Concat stringa and number by e_concat to simstr::stringa_median 76.2 ns 76.2 ns 4 -Concat stringa and number by e_concat to simstr::stringa_stddev 0.726 ns 0.725 ns 4 -Concat stringa and number by e_concat to simstr::stringa_cv 0.96 % 0.96 % 4 +Concat std::string and number by std to std::string_mean 224 ns 224 ns 4 +Concat std::string and number by std to std::string_median 224 ns 224 ns 4 +Concat std::string and number by std to std::string_stddev 5.87 ns 5.87 ns 4 +Concat std::string and number by std to std::string_cv 2.62 % 2.62 % 4 +Concat std::string and number by StrExpr to std::string_mean 100 ns 100 ns 4 +Concat std::string and number by StrExpr to std::string_median 100 ns 100 ns 4 +Concat std::string and number by StrExpr to std::string_stddev 1.91 ns 1.91 ns 4 +Concat std::string and number by StrExpr to std::string_cv 1.91 % 1.91 % 4 +Concat stringa and number by StrExpr to simstr::stringa_mean 72.8 ns 72.8 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_median 72.7 ns 72.7 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_stddev 1.46 ns 1.46 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_cv 2.01 % 2.01 % 4 +Concat stringa and number by e_concat to simstr::stringa_mean 75.7 ns 75.7 ns 4 +Concat stringa and number by e_concat to simstr::stringa_median 75.7 ns 75.7 ns 4 +Concat stringa and number by e_concat to simstr::stringa_stddev 1.48 ns 1.48 ns 4 +Concat stringa and number by e_concat to simstr::stringa_cv 1.96 % 1.96 % 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 651 ns 651 ns 4 -Concat std::string and format hex number and literal to std::string_median 650 ns 650 ns 4 -Concat std::string and format hex number and literal to std::string_stddev 6.78 ns 6.78 ns 4 -Concat std::string and format hex number and literal to std::string_cv 1.04 % 1.04 % 4 -std::format std::string and hex number by literal to std::string_mean 922 ns 922 ns 4 -std::format std::string and hex number by literal to std::string_median 912 ns 912 ns 4 -std::format std::string and hex number by literal to std::string_stddev 24.9 ns 24.9 ns 4 -std::format std::string and hex number by literal to std::string_cv 2.70 % 2.70 % 4 -Concat std::string and std::to_chars and string to std::string_mean 176 ns 176 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 3.41 ns 3.41 ns 4 -Concat std::string and std::to_chars and string to std::string_cv 1.94 % 1.94 % 4 -Concat std::string and hex number and literal by StrExpr to std::string_mean 125 ns 125 ns 4 +Concat std::string and format hex number and literal to std::string_mean 712 ns 712 ns 4 +Concat std::string and format hex number and literal to std::string_median 705 ns 705 ns 4 +Concat std::string and format hex number and literal to std::string_stddev 26.9 ns 26.9 ns 4 +Concat std::string and format hex number and literal to std::string_cv 3.78 % 3.78 % 4 +std::format std::string and hex number by literal to std::string_mean 969 ns 969 ns 4 +std::format std::string and hex number by literal to std::string_median 970 ns 970 ns 4 +std::format std::string and hex number by literal to std::string_stddev 25.3 ns 25.3 ns 4 +std::format std::string and hex number by literal to std::string_cv 2.61 % 2.61 % 4 +Concat std::string and std::to_chars and string to std::string_mean 252 ns 252 ns 4 +Concat std::string and std::to_chars and string to std::string_median 252 ns 252 ns 4 +Concat std::string and std::to_chars and string to std::string_stddev 5.96 ns 5.96 ns 4 +Concat std::string and std::to_chars and string to std::string_cv 2.37 % 2.37 % 4 +Concat std::string and hex number and literal by StrExpr to std::string_mean 124 ns 124 ns 4 Concat std::string and hex number and literal by StrExpr to std::string_median 125 ns 125 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_stddev 2.60 ns 2.60 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_cv 2.09 % 2.09 % 4 +Concat std::string and hex number and literal by StrExpr to std::string_stddev 0.945 ns 0.945 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_cv 0.76 % 0.76 % 4 Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 120 ns 120 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 120 ns 120 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 1.45 ns 1.45 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 1.20 % 1.20 % 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 StrExpr to simstr::stringa_median 121 ns 121 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 2.08 ns 2.08 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 1.73 % 1.73 % 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 126 ns 126 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.19 ns 1.19 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 0.95 % 0.95 % 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_mean 167 ns 167 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_median 166 ns 166 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 2.81 ns 2.81 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_cv 1.68 % 1.68 % 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 296 ns 296 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 297 ns 297 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 2.96 ns 2.96 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 1.00 % 1.00 % 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 1.94 ns 1.94 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 1.55 % 1.55 % 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_mean 164 ns 164 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_median 165 ns 165 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 2.48 ns 2.48 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_cv 1.51 % 1.51 % 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 302 ns 302 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 303 ns 303 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 4.35 ns 4.35 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 1.44 % 1.44 % 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 339 ns 339 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 337 ns 337 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 6.66 ns 6.66 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 1.97 % 1.97 % 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 320 ns 320 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 318 ns 318 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 6.45 ns 6.45 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 2.02 % 2.02 % 4 -e_vsubst(pattern, i / 0x8a010_fmt)_mean 582 ns 582 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_median 579 ns 579 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_stddev 8.85 ns 8.85 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_cv 1.52 % 1.52 % 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 727 ns 727 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 729 ns 729 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 11.2 ns 11.2 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 1.54 % 1.54 % 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 786 ns 786 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 785 ns 785 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 10.8 ns 10.8 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.37 % 1.37 % 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1222 ns 1222 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_median 1218 ns 1218 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 23.8 ns 23.8 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.95 % 1.95 % 4 -std::vformat(pattern, std::make_format_args(i))_mean 1143 ns 1143 ns 4 -std::vformat(pattern, std::make_format_args(i))_median 1148 ns 1148 ns 4 -std::vformat(pattern, std::make_format_args(i))_stddev 21.3 ns 21.3 ns 4 -std::vformat(pattern, std::make_format_args(i))_cv 1.86 % 1.86 % 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 2092 ns 2092 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 2072 ns 2072 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 46.7 ns 46.7 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 2.23 % 2.23 % 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_mean 266 ns 266 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 268 ns 268 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 13.8 ns 13.8 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 5.17 % 5.17 % 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 324 ns 324 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 325 ns 325 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 5.51 ns 5.51 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 1.70 % 1.70 % 4 +e_vsubst(pattern, i / 0x8a010_fmt)_mean 583 ns 583 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_median 584 ns 584 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_stddev 11.6 ns 11.6 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_cv 1.99 % 1.99 % 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 785 ns 785 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 789 ns 789 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 27.6 ns 27.6 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 3.52 % 3.52 % 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 827 ns 827 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 825 ns 825 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 9.91 ns 9.91 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.20 % 1.20 % 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1224 ns 1224 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_median 1227 ns 1227 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 8.73 ns 8.73 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_cv 0.71 % 0.71 % 4 +std::vformat(pattern, std::make_format_args(i))_mean 1100 ns 1100 ns 4 +std::vformat(pattern, std::make_format_args(i))_median 1105 ns 1105 ns 4 +std::vformat(pattern, std::make_format_args(i))_stddev 18.9 ns 18.9 ns 4 +std::vformat(pattern, std::make_format_args(i))_cv 1.72 % 1.72 % 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 2121 ns 2121 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 2103 ns 2103 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 107 ns 107 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 5.04 % 5.04 % 4 ----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string by std to std::string_mean 49.8 ns 49.8 ns 4 -Concat std::string by std to std::string_median 49.9 ns 49.9 ns 4 -Concat std::string by std to std::string_stddev 1.10 ns 1.10 ns 4 -Concat std::string by std to std::string_cv 2.21 % 2.21 % 4 -Concat std::string by StrExpr to std::string_mean 30.3 ns 30.3 ns 4 -Concat std::string by StrExpr to std::string_median 30.5 ns 30.5 ns 4 -Concat std::string by StrExpr to std::string_stddev 1.00 ns 1.00 ns 4 -Concat std::string by StrExpr to std::string_cv 3.31 % 3.31 % 4 -Concat stringa by StrExpr to stringa_mean 26.6 ns 26.6 ns 4 -Concat stringa by StrExpr to stringa_median 26.6 ns 26.6 ns 4 -Concat stringa by StrExpr to stringa_stddev 0.270 ns 0.270 ns 4 -Concat stringa by StrExpr to stringa_cv 1.02 % 1.02 % 4 +Concat std::string by std to std::string_mean 52.3 ns 52.3 ns 4 +Concat std::string by std to std::string_median 52.4 ns 52.4 ns 4 +Concat std::string by std to std::string_stddev 0.634 ns 0.634 ns 4 +Concat std::string by std to std::string_cv 1.21 % 1.21 % 4 +Concat std::string by StrExpr to std::string_mean 34.1 ns 34.1 ns 4 +Concat std::string by StrExpr to std::string_median 34.3 ns 34.3 ns 4 +Concat std::string by StrExpr to std::string_stddev 0.729 ns 0.729 ns 4 +Concat std::string by StrExpr to std::string_cv 2.14 % 2.14 % 4 +Concat stringa by StrExpr to stringa_mean 27.5 ns 27.5 ns 4 +Concat stringa by StrExpr to stringa_median 26.3 ns 26.3 ns 4 +Concat stringa by StrExpr to stringa_stddev 2.41 ns 2.41 ns 4 +Concat stringa by StrExpr to stringa_cv 8.75 % 8.75 % 4 ----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Find concat three std::string_mean 192 ns 192 ns 4 -Find concat three std::string_median 193 ns 193 ns 4 -Find concat three std::string_stddev 2.50 ns 2.50 ns 4 -Find concat three std::string_cv 1.30 % 1.30 % 4 -Find concat three strexpr_mean 41.1 ns 41.1 ns 4 -Find concat three strexpr_median 40.7 ns 40.7 ns 4 -Find concat three strexpr_stddev 1.62 ns 1.62 ns 4 -Find concat three strexpr_cv 3.93 % 3.93 % 4 -Find concat three simstr_mean 19.5 ns 19.5 ns 4 -Find concat three simstr_median 19.6 ns 19.6 ns 4 -Find concat three simstr_stddev 0.203 ns 0.203 ns 4 -Find concat three simstr_cv 1.04 % 1.04 % 4 +Find concat three std::string_mean 137 ns 137 ns 4 +Find concat three std::string_median 137 ns 137 ns 4 +Find concat three std::string_stddev 1.27 ns 1.27 ns 4 +Find concat three std::string_cv 0.92 % 0.92 % 4 +Find concat three strexpr_mean 38.1 ns 38.1 ns 4 +Find concat three strexpr_median 38.1 ns 38.1 ns 4 +Find concat three strexpr_stddev 0.509 ns 0.509 ns 4 +Find concat three strexpr_cv 1.33 % 1.33 % 4 +Find concat three simstr_mean 15.9 ns 15.9 ns 4 +Find concat three simstr_median 15.9 ns 15.9 ns 4 +Find concat three simstr_stddev 0.108 ns 0.108 ns 4 +Find concat three simstr_cv 0.68 % 0.68 % 4 +Find concat three stringzilla string_mean 150 ns 150 ns 4 +Find concat three stringzilla string_median 149 ns 149 ns 4 +Find concat three stringzilla string_stddev 4.67 ns 4.67 ns 4 +Find concat three stringzilla string_cv 3.11 % 3.11 % 4 ----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 BuildTypeNameStr 0/0_mean 10.1 ns 10.1 ns 4 BuildTypeNameStr 0/0_median 10.1 ns 10.1 ns 4 -BuildTypeNameStr 0/0_stddev 0.217 ns 0.217 ns 4 -BuildTypeNameStr 0/0_cv 2.16 % 2.16 % 4 -BuildTypeNameExp 0/0_mean 6.62 ns 6.62 ns 4 -BuildTypeNameExp 0/0_median 6.62 ns 6.62 ns 4 -BuildTypeNameExp 0/0_stddev 0.069 ns 0.069 ns 4 -BuildTypeNameExp 0/0_cv 1.04 % 1.04 % 4 -BuildTypeNameSim 0/0_mean 4.89 ns 4.89 ns 4 -BuildTypeNameSim 0/0_median 4.92 ns 4.92 ns 4 -BuildTypeNameSim 0/0_stddev 0.073 ns 0.073 ns 4 -BuildTypeNameSim 0/0_cv 1.50 % 1.50 % 4 -BuildTypeNameStr 10/10_mean 82.3 ns 82.3 ns 4 -BuildTypeNameStr 10/10_median 81.9 ns 81.9 ns 4 -BuildTypeNameStr 10/10_stddev 1.21 ns 1.21 ns 4 -BuildTypeNameStr 10/10_cv 1.47 % 1.47 % 4 -BuildTypeNameExp 10/10_mean 25.3 ns 25.3 ns 4 -BuildTypeNameExp 10/10_median 24.9 ns 24.9 ns 4 -BuildTypeNameExp 10/10_stddev 1.64 ns 1.64 ns 4 -BuildTypeNameExp 10/10_cv 6.48 % 6.48 % 4 -BuildTypeNameSim 10/10_mean 21.6 ns 21.6 ns 4 -BuildTypeNameSim 10/10_median 21.6 ns 21.6 ns 4 -BuildTypeNameSim 10/10_stddev 0.206 ns 0.206 ns 4 -BuildTypeNameSim 10/10_cv 0.95 % 0.95 % 4 +BuildTypeNameStr 0/0_stddev 0.176 ns 0.176 ns 4 +BuildTypeNameStr 0/0_cv 1.73 % 1.73 % 4 +BuildTypeNameExp 0/0_mean 8.75 ns 8.75 ns 4 +BuildTypeNameExp 0/0_median 8.56 ns 8.56 ns 4 +BuildTypeNameExp 0/0_stddev 0.627 ns 0.627 ns 4 +BuildTypeNameExp 0/0_cv 7.16 % 7.16 % 4 +BuildTypeNameSim 0/0_mean 4.90 ns 4.90 ns 4 +BuildTypeNameSim 0/0_median 4.89 ns 4.89 ns 4 +BuildTypeNameSim 0/0_stddev 0.063 ns 0.063 ns 4 +BuildTypeNameSim 0/0_cv 1.28 % 1.28 % 4 +BuildTypeNameStr 10/10_mean 84.3 ns 84.3 ns 4 +BuildTypeNameStr 10/10_median 84.3 ns 84.3 ns 4 +BuildTypeNameStr 10/10_stddev 0.831 ns 0.831 ns 4 +BuildTypeNameStr 10/10_cv 0.99 % 0.99 % 4 +BuildTypeNameExp 10/10_mean 25.9 ns 25.9 ns 4 +BuildTypeNameExp 10/10_median 24.4 ns 24.4 ns 4 +BuildTypeNameExp 10/10_stddev 3.81 ns 3.81 ns 4 +BuildTypeNameExp 10/10_cv 14.68 % 14.68 % 4 +BuildTypeNameSim 10/10_mean 23.6 ns 23.6 ns 4 +BuildTypeNameSim 10/10_median 23.8 ns 23.8 ns 4 +BuildTypeNameSim 10/10_stddev 1.71 ns 1.71 ns 4 +BuildTypeNameSim 10/10_cv 7.24 % 7.24 % 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 226 ns 226 ns 4 -Concat with replace str_stddev 2.79 ns 2.79 ns 4 -Concat with replace str_cv 1.24 % 1.24 % 4 -Concat with replace exp_mean 135 ns 135 ns 4 -Concat with replace exp_median 135 ns 135 ns 4 -Concat with replace exp_stddev 3.82 ns 3.82 ns 4 -Concat with replace exp_cv 2.83 % 2.83 % 4 +Concat with replace str_mean 250 ns 250 ns 4 +Concat with replace str_median 239 ns 239 ns 4 +Concat with replace str_stddev 25.4 ns 25.4 ns 4 +Concat with replace str_cv 10.14 % 10.14 % 4 +Concat with replace exp_mean 133 ns 133 ns 4 +Concat with replace exp_median 131 ns 131 ns 4 +Concat with replace exp_stddev 8.52 ns 8.52 ns 4 +Concat with replace exp_cv 6.40 % 6.40 % 4 ----- Create Empty Str ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e;_mean 1.13 ns 1.13 ns 4 -std::string e;_median 1.13 ns 1.13 ns 4 -std::string e;_stddev 0.023 ns 0.023 ns 4 -std::string e;_cv 2.01 % 2.01 % 4 +std::string e;_mean 1.09 ns 1.09 ns 4 +std::string e;_median 1.10 ns 1.10 ns 4 +std::string e;_stddev 0.013 ns 0.013 ns 4 +std::string e;_cv 1.23 % 1.23 % 4 std::string_view e;_mean 0.739 ns 0.739 ns 4 -std::string_view e;_median 0.737 ns 0.737 ns 4 -std::string_view e;_stddev 0.016 ns 0.016 ns 4 -std::string_view e;_cv 2.12 % 2.12 % 4 -ssa e;_mean 0.182 ns 0.182 ns 4 -ssa e;_median 0.182 ns 0.182 ns 4 -ssa e;_stddev 0.000 ns 0.000 ns 4 -ssa e;_cv 0.21 % 0.21 % 4 -stringa e;_mean 0.736 ns 0.736 ns 4 -stringa e;_median 0.741 ns 0.741 ns 4 -stringa e;_stddev 0.015 ns 0.015 ns 4 -stringa e;_cv 2.05 % 2.05 % 4 +std::string_view e;_median 0.741 ns 0.741 ns 4 +std::string_view e;_stddev 0.008 ns 0.008 ns 4 +std::string_view e;_cv 1.07 % 1.07 % 4 +ssa e;_mean 0.183 ns 0.183 ns 4 +ssa e;_median 0.181 ns 0.181 ns 4 +ssa e;_stddev 0.007 ns 0.007 ns 4 +ssa e;_cv 3.83 % 3.83 % 4 +stringa e;_mean 0.731 ns 0.731 ns 4 +stringa e;_median 0.730 ns 0.730 ns 4 +stringa e;_stddev 0.010 ns 0.010 ns 4 +stringa e;_cv 1.41 % 1.41 % 4 lstringa<20> e;_mean 1.11 ns 1.11 ns 4 lstringa<20> e;_median 1.11 ns 1.11 ns 4 -lstringa<20> e;_stddev 0.018 ns 0.018 ns 4 -lstringa<20> e;_cv 1.64 % 1.64 % 4 -lstringa<40> e;_mean 1.10 ns 1.10 ns 4 -lstringa<40> e;_median 1.11 ns 1.11 ns 4 -lstringa<40> e;_stddev 0.017 ns 0.017 ns 4 -lstringa<40> e;_cv 1.56 % 1.56 % 4 +lstringa<20> e;_stddev 0.008 ns 0.008 ns 4 +lstringa<20> e;_cv 0.70 % 0.70 % 4 +lstringa<40> e;_mean 1.11 ns 1.11 ns 4 +lstringa<40> e;_median 1.10 ns 1.10 ns 4 +lstringa<40> e;_stddev 0.031 ns 0.031 ns 4 +lstringa<40> e;_cv 2.79 % 2.79 % 4 ----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "Test text";_mean 1.82 ns 1.82 ns 4 -std::string e = "Test text";_median 1.81 ns 1.81 ns 4 -std::string e = "Test text";_stddev 0.030 ns 0.030 ns 4 -std::string e = "Test text";_cv 1.63 % 1.63 % 4 -std::string_view e = "Test text";_mean 0.742 ns 0.742 ns 4 -std::string_view e = "Test text";_median 0.738 ns 0.738 ns 4 -std::string_view e = "Test text";_stddev 0.013 ns 0.013 ns 4 -std::string_view e = "Test text";_cv 1.79 % 1.79 % 4 -ssa e = "Test text";_mean 0.736 ns 0.736 ns 4 -ssa e = "Test text";_median 0.738 ns 0.738 ns 4 -ssa e = "Test text";_stddev 0.011 ns 0.011 ns 4 -ssa e = "Test text";_cv 1.49 % 1.49 % 4 -stringa e = "Test text";_mean 1.10 ns 1.10 ns 4 -stringa e = "Test text";_median 1.10 ns 1.10 ns 4 -stringa e = "Test text";_stddev 0.018 ns 0.018 ns 4 -stringa e = "Test text";_cv 1.61 % 1.61 % 4 -lstringa<20> e = "Test text";_mean 1.85 ns 1.85 ns 4 -lstringa<20> e = "Test text";_median 1.85 ns 1.85 ns 4 -lstringa<20> e = "Test text";_stddev 0.010 ns 0.010 ns 4 -lstringa<20> e = "Test text";_cv 0.56 % 0.56 % 4 -lstringa<40> e = "Test text";_mean 1.83 ns 1.83 ns 4 -lstringa<40> e = "Test text";_median 1.83 ns 1.83 ns 4 -lstringa<40> e = "Test text";_stddev 0.030 ns 0.030 ns 4 -lstringa<40> e = "Test text";_cv 1.64 % 1.64 % 4 +std::string e = "Test text";_mean 1.84 ns 1.84 ns 4 +std::string e = "Test text";_median 1.84 ns 1.84 ns 4 +std::string e = "Test text";_stddev 0.011 ns 0.011 ns 4 +std::string e = "Test text";_cv 0.61 % 0.61 % 4 +std::string_view e = "Test text";_mean 0.736 ns 0.736 ns 4 +std::string_view e = "Test text";_median 0.736 ns 0.736 ns 4 +std::string_view e = "Test text";_stddev 0.010 ns 0.010 ns 4 +std::string_view e = "Test text";_cv 1.29 % 1.29 % 4 +ssa e = "Test text";_mean 0.750 ns 0.750 ns 4 +ssa e = "Test text";_median 0.730 ns 0.730 ns 4 +ssa e = "Test text";_stddev 0.049 ns 0.049 ns 4 +ssa e = "Test text";_cv 6.57 % 6.57 % 4 +stringa e = "Test text";_mean 1.11 ns 1.11 ns 4 +stringa e = "Test text";_median 1.12 ns 1.12 ns 4 +stringa e = "Test text";_stddev 0.024 ns 0.024 ns 4 +stringa e = "Test text";_cv 2.16 % 2.16 % 4 +lstringa<20> e = "Test text";_mean 1.84 ns 1.84 ns 4 +lstringa<20> e = "Test text";_median 1.84 ns 1.84 ns 4 +lstringa<20> e = "Test text";_stddev 0.033 ns 0.033 ns 4 +lstringa<20> e = "Test text";_cv 1.79 % 1.79 % 4 +lstringa<40> e = "Test text";_mean 1.84 ns 1.84 ns 4 +lstringa<40> e = "Test text";_median 1.84 ns 1.84 ns 4 +lstringa<40> e = "Test text";_stddev 0.009 ns 0.009 ns 4 +lstringa<40> e = "Test text";_cv 0.50 % 0.50 % 4 ----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "123456789012345678901234567890";_mean 19.5 ns 19.5 ns 4 -std::string e = "123456789012345678901234567890";_median 19.6 ns 19.6 ns 4 -std::string e = "123456789012345678901234567890";_stddev 0.159 ns 0.159 ns 4 -std::string e = "123456789012345678901234567890";_cv 0.81 % 0.81 % 4 -std::string_view e = "123456789012345678901234567890";_mean 0.730 ns 0.730 ns 4 -std::string_view e = "123456789012345678901234567890";_median 0.732 ns 0.732 ns 4 -std::string_view e = "123456789012345678901234567890";_stddev 0.016 ns 0.016 ns 4 -std::string_view e = "123456789012345678901234567890";_cv 2.19 % 2.19 % 4 -ssa e = "123456789012345678901234567890";_mean 0.739 ns 0.739 ns 4 -ssa e = "123456789012345678901234567890";_median 0.739 ns 0.739 ns 4 -ssa e = "123456789012345678901234567890";_stddev 0.017 ns 0.017 ns 4 -ssa e = "123456789012345678901234567890";_cv 2.25 % 2.25 % 4 -stringa e = "123456789012345678901234567890";_mean 1.13 ns 1.13 ns 4 -stringa e = "123456789012345678901234567890";_median 1.13 ns 1.13 ns 4 -stringa e = "123456789012345678901234567890";_stddev 0.019 ns 0.019 ns 4 -stringa e = "123456789012345678901234567890";_cv 1.68 % 1.68 % 4 -lstringa<20> e = "123456789012345678901234567890";_mean 19.9 ns 19.9 ns 4 -lstringa<20> e = "123456789012345678901234567890";_median 20.0 ns 20.0 ns 4 -lstringa<20> e = "123456789012345678901234567890";_stddev 0.153 ns 0.153 ns 4 -lstringa<20> e = "123456789012345678901234567890";_cv 0.77 % 0.77 % 4 -lstringa<40> e = "123456789012345678901234567890";_mean 1.87 ns 1.87 ns 4 -lstringa<40> e = "123456789012345678901234567890";_median 1.87 ns 1.87 ns 4 -lstringa<40> e = "123456789012345678901234567890";_stddev 0.033 ns 0.033 ns 4 -lstringa<40> e = "123456789012345678901234567890";_cv 1.75 % 1.75 % 4 +std::string e = "123456789012345678901234567890";_mean 19.2 ns 19.2 ns 4 +std::string e = "123456789012345678901234567890";_median 19.3 ns 19.3 ns 4 +std::string e = "123456789012345678901234567890";_stddev 0.217 ns 0.217 ns 4 +std::string e = "123456789012345678901234567890";_cv 1.13 % 1.13 % 4 +std::string_view e = "123456789012345678901234567890";_mean 0.752 ns 0.752 ns 4 +std::string_view e = "123456789012345678901234567890";_median 0.755 ns 0.755 ns 4 +std::string_view e = "123456789012345678901234567890";_stddev 0.024 ns 0.024 ns 4 +std::string_view e = "123456789012345678901234567890";_cv 3.23 % 3.23 % 4 +ssa e = "123456789012345678901234567890";_mean 0.733 ns 0.733 ns 4 +ssa e = "123456789012345678901234567890";_median 0.734 ns 0.734 ns 4 +ssa e = "123456789012345678901234567890";_stddev 0.004 ns 0.004 ns 4 +ssa e = "123456789012345678901234567890";_cv 0.55 % 0.55 % 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.028 ns 0.028 ns 4 +stringa e = "123456789012345678901234567890";_cv 2.52 % 2.52 % 4 +lstringa<20> e = "123456789012345678901234567890";_mean 20.4 ns 20.4 ns 4 +lstringa<20> e = "123456789012345678901234567890";_median 20.4 ns 20.4 ns 4 +lstringa<20> e = "123456789012345678901234567890";_stddev 0.404 ns 0.404 ns 4 +lstringa<20> e = "123456789012345678901234567890";_cv 1.98 % 1.98 % 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.046 ns 0.046 ns 4 +lstringa<40> e = "123456789012345678901234567890";_cv 2.50 % 2.50 % 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.76 ns 5.76 ns 4 -std::string e = "Test text"; auto c{e};_median 5.77 ns 5.77 ns 4 -std::string e = "Test text"; auto c{e};_stddev 0.103 ns 0.103 ns 4 -std::string e = "Test text"; auto c{e};_cv 1.78 % 1.78 % 4 -std::string_view e = "Test text"; auto c{e};_mean 0.443 ns 0.443 ns 4 -std::string_view e = "Test text"; auto c{e};_median 0.433 ns 0.433 ns 4 -std::string_view e = "Test text"; auto c{e};_stddev 0.027 ns 0.027 ns 4 -std::string_view e = "Test text"; auto c{e};_cv 5.99 % 5.99 % 4 -ssa e = "Test text"; auto c{e};_mean 0.395 ns 0.395 ns 4 -ssa e = "Test text"; auto c{e};_median 0.387 ns 0.387 ns 4 -ssa e = "Test text"; auto c{e};_stddev 0.030 ns 0.030 ns 4 -ssa e = "Test text"; auto c{e};_cv 7.54 % 7.54 % 4 -stringa e = "Test text"; auto c{e};_mean 1.35 ns 1.35 ns 4 -stringa e = "Test text"; auto c{e};_median 1.37 ns 1.37 ns 4 -stringa e = "Test text"; auto c{e};_stddev 0.060 ns 0.060 ns 4 -stringa e = "Test text"; auto c{e};_cv 4.43 % 4.43 % 4 -lstringa<20> e = "Test text"; auto c{e};_mean 1.25 ns 1.25 ns 4 -lstringa<20> e = "Test text"; auto c{e};_median 1.23 ns 1.23 ns 4 -lstringa<20> e = "Test text"; auto c{e};_stddev 0.053 ns 0.053 ns 4 -lstringa<20> e = "Test text"; auto c{e};_cv 4.24 % 4.24 % 4 -lstringa<40> e = "Test text"; auto c{e};_mean 1.25 ns 1.25 ns 4 -lstringa<40> e = "Test text"; auto c{e};_median 1.25 ns 1.25 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 4.41 % 4.41 % 4 +std::string e = "Test text"; auto c{e};_mean 5.62 ns 5.62 ns 4 +std::string e = "Test text"; auto c{e};_median 5.63 ns 5.63 ns 4 +std::string e = "Test text"; auto c{e};_stddev 0.055 ns 0.055 ns 4 +std::string e = "Test text"; auto c{e};_cv 0.97 % 0.97 % 4 +std::string_view e = "Test text"; auto c{e};_mean 0.365 ns 0.365 ns 4 +std::string_view e = "Test text"; auto c{e};_median 0.364 ns 0.364 ns 4 +std::string_view e = "Test text"; auto c{e};_stddev 0.004 ns 0.004 ns 4 +std::string_view e = "Test text"; auto c{e};_cv 0.96 % 0.96 % 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.375 ns 0.375 ns 4 +ssa e = "Test text"; auto c{e};_stddev 0.009 ns 0.009 ns 4 +ssa e = "Test text"; auto c{e};_cv 2.53 % 2.53 % 4 +stringa e = "Test text"; auto c{e};_mean 1.11 ns 1.11 ns 4 +stringa e = "Test text"; auto c{e};_median 1.11 ns 1.11 ns 4 +stringa e = "Test text"; auto c{e};_stddev 0.030 ns 0.030 ns 4 +stringa e = "Test text"; auto c{e};_cv 2.70 % 2.70 % 4 +lstringa<20> e = "Test text"; auto c{e};_mean 1.11 ns 1.11 ns 4 +lstringa<20> e = "Test text"; auto c{e};_median 1.10 ns 1.10 ns 4 +lstringa<20> e = "Test text"; auto c{e};_stddev 0.003 ns 0.003 ns 4 +lstringa<20> e = "Test text"; auto c{e};_cv 0.29 % 0.29 % 4 +lstringa<40> e = "Test text"; auto c{e};_mean 1.13 ns 1.13 ns 4 +lstringa<40> e = "Test text"; auto c{e};_median 1.12 ns 1.12 ns 4 +lstringa<40> e = "Test text"; auto c{e};_stddev 0.032 ns 0.032 ns 4 +lstringa<40> e = "Test text"; auto c{e};_cv 2.80 % 2.80 % 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 22.8 ns 22.8 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_median 22.7 ns 22.7 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_stddev 0.811 ns 0.811 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_cv 3.56 % 3.56 % 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.786 ns 0.786 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.772 ns 0.772 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.036 ns 0.036 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 4.60 % 4.60 % 4 -ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.820 ns 0.820 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_median 0.825 ns 0.825 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.032 ns 0.032 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_cv 3.88 % 3.88 % 4 -stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.11 ns 1.11 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_median 1.11 ns 1.11 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.019 ns 0.019 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.68 % 1.68 % 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 20.6 ns 20.6 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 20.7 ns 20.7 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 0.316 ns 0.316 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 1.53 % 1.53 % 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.70 ns 4.70 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.67 ns 4.67 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.088 ns 0.088 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 1.87 % 1.87 % 4 +std::string e = "123456789012345678901234567890"; auto c{e};_mean 23.8 ns 23.8 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_median 23.8 ns 23.8 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_stddev 0.745 ns 0.745 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_cv 3.13 % 3.13 % 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.735 ns 0.735 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.733 ns 0.733 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.008 ns 0.008 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 1.13 % 1.13 % 4 +ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.742 ns 0.742 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_median 0.746 ns 0.746 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.025 ns 0.025 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_cv 3.37 % 3.37 % 4 +stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.30 ns 1.30 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_median 1.29 ns 1.29 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.020 ns 0.020 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.56 % 1.56 % 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 19.8 ns 19.8 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 19.8 ns 19.8 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 0.314 ns 0.314 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 1.59 % 1.59 % 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.67 ns 4.67 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.64 ns 4.64 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.081 ns 0.081 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 1.73 % 1.73 % 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.92 ns 6.92 ns 4 -std::string::find;_median 6.91 ns 6.91 ns 4 -std::string::find;_stddev 0.112 ns 0.112 ns 4 -std::string::find;_cv 1.61 % 1.61 % 4 -std::string_view::find;_mean 6.75 ns 6.75 ns 4 -std::string_view::find;_median 6.78 ns 6.78 ns 4 -std::string_view::find;_stddev 0.175 ns 0.175 ns 4 -std::string_view::find;_cv 2.59 % 2.59 % 4 -ssa::find;_mean 6.52 ns 6.52 ns 4 -ssa::find;_median 6.50 ns 6.50 ns 4 -ssa::find;_stddev 0.253 ns 0.253 ns 4 -ssa::find;_cv 3.88 % 3.88 % 4 -stringa::find;_mean 6.62 ns 6.62 ns 4 -stringa::find;_median 6.62 ns 6.62 ns 4 -stringa::find;_stddev 0.115 ns 0.115 ns 4 -stringa::find;_cv 1.74 % 1.74 % 4 -lstringa<20>::find;_mean 6.32 ns 6.32 ns 4 -lstringa<20>::find;_median 6.34 ns 6.34 ns 4 -lstringa<20>::find;_stddev 0.038 ns 0.038 ns 4 -lstringa<20>::find;_cv 0.60 % 0.60 % 4 -lstringa<40>::find;_mean 6.33 ns 6.33 ns 4 -lstringa<40>::find;_median 6.32 ns 6.32 ns 4 -lstringa<40>::find;_stddev 0.037 ns 0.037 ns 4 -lstringa<40>::find;_cv 0.58 % 0.58 % 4 +sz::string::find;_mean 93.8 ns 93.8 ns 4 +sz::string::find;_median 93.8 ns 93.8 ns 4 +sz::string::find;_stddev 0.683 ns 0.683 ns 4 +sz::string::find;_cv 0.73 % 0.73 % 4 +std::string::find;_mean 7.67 ns 7.67 ns 4 +std::string::find;_median 7.65 ns 7.65 ns 4 +std::string::find;_stddev 0.093 ns 0.093 ns 4 +std::string::find;_cv 1.21 % 1.21 % 4 +std::string_view::find;_mean 7.48 ns 7.48 ns 4 +std::string_view::find;_median 7.47 ns 7.47 ns 4 +std::string_view::find;_stddev 0.156 ns 0.156 ns 4 +std::string_view::find;_cv 2.09 % 2.09 % 4 +ssa::find;_mean 6.78 ns 6.78 ns 4 +ssa::find;_median 6.81 ns 6.81 ns 4 +ssa::find;_stddev 0.103 ns 0.103 ns 4 +ssa::find;_cv 1.51 % 1.51 % 4 +stringa::find;_mean 7.17 ns 7.17 ns 4 +stringa::find;_median 7.14 ns 7.14 ns 4 +stringa::find;_stddev 0.231 ns 0.231 ns 4 +stringa::find;_cv 3.22 % 3.22 % 4 +lstringa<20>::find;_mean 6.96 ns 6.96 ns 4 +lstringa<20>::find;_median 6.90 ns 6.90 ns 4 +lstringa<20>::find;_stddev 0.365 ns 0.365 ns 4 +lstringa<20>::find;_cv 5.25 % 5.25 % 4 +lstringa<40>::find;_mean 6.64 ns 6.64 ns 4 +lstringa<40>::find;_median 6.64 ns 6.64 ns 4 +lstringa<40>::find;_stddev 0.120 ns 0.120 ns 4 +lstringa<40>::find;_cv 1.81 % 1.81 % 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 6.03 ns 6.03 ns 4 -std::string copy{str_with_len_N};/15_median 6.02 ns 6.02 ns 4 -std::string copy{str_with_len_N};/15_stddev 0.140 ns 0.140 ns 4 -std::string copy{str_with_len_N};/15_cv 2.32 % 2.32 % 4 -std::string copy{str_with_len_N};/16_mean 25.9 ns 25.9 ns 4 -std::string copy{str_with_len_N};/16_median 25.5 ns 25.5 ns 4 -std::string copy{str_with_len_N};/16_stddev 1.96 ns 1.96 ns 4 -std::string copy{str_with_len_N};/16_cv 7.56 % 7.56 % 4 -std::string copy{str_with_len_N};/23_mean 25.0 ns 25.0 ns 4 -std::string copy{str_with_len_N};/23_median 24.7 ns 24.7 ns 4 -std::string copy{str_with_len_N};/23_stddev 0.619 ns 0.619 ns 4 -std::string copy{str_with_len_N};/23_cv 2.48 % 2.48 % 4 -std::string copy{str_with_len_N};/24_mean 25.3 ns 25.3 ns 4 -std::string copy{str_with_len_N};/24_median 25.3 ns 25.3 ns 4 -std::string copy{str_with_len_N};/24_stddev 0.180 ns 0.180 ns 4 -std::string copy{str_with_len_N};/24_cv 0.71 % 0.71 % 4 -std::string copy{str_with_len_N};/32_mean 24.2 ns 24.2 ns 4 -std::string copy{str_with_len_N};/32_median 24.1 ns 24.1 ns 4 -std::string copy{str_with_len_N};/32_stddev 0.451 ns 0.451 ns 4 -std::string copy{str_with_len_N};/32_cv 1.86 % 1.86 % 4 -std::string copy{str_with_len_N};/64_mean 24.1 ns 24.1 ns 4 -std::string copy{str_with_len_N};/64_median 24.2 ns 24.2 ns 4 -std::string copy{str_with_len_N};/64_stddev 0.444 ns 0.444 ns 4 -std::string copy{str_with_len_N};/64_cv 1.84 % 1.84 % 4 -std::string copy{str_with_len_N};/128_mean 25.6 ns 25.6 ns 4 -std::string copy{str_with_len_N};/128_median 25.4 ns 25.4 ns 4 -std::string copy{str_with_len_N};/128_stddev 0.513 ns 0.513 ns 4 -std::string copy{str_with_len_N};/128_cv 2.01 % 2.01 % 4 -std::string copy{str_with_len_N};/256_mean 25.8 ns 25.8 ns 4 -std::string copy{str_with_len_N};/256_median 25.9 ns 25.9 ns 4 -std::string copy{str_with_len_N};/256_stddev 0.246 ns 0.246 ns 4 -std::string copy{str_with_len_N};/256_cv 0.96 % 0.96 % 4 -std::string copy{str_with_len_N};/512_mean 30.4 ns 30.4 ns 4 -std::string copy{str_with_len_N};/512_median 30.3 ns 30.3 ns 4 -std::string copy{str_with_len_N};/512_stddev 0.707 ns 0.707 ns 4 -std::string copy{str_with_len_N};/512_cv 2.32 % 2.32 % 4 -std::string copy{str_with_len_N};/1024_mean 47.0 ns 47.0 ns 4 -std::string copy{str_with_len_N};/1024_median 47.4 ns 47.4 ns 4 -std::string copy{str_with_len_N};/1024_stddev 1.41 ns 1.41 ns 4 -std::string copy{str_with_len_N};/1024_cv 2.99 % 2.99 % 4 -std::string copy{str_with_len_N};/2048_mean 131 ns 131 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 10.3 ns 10.3 ns 4 -std::string copy{str_with_len_N};/2048_cv 7.92 % 7.92 % 4 -std::string copy{str_with_len_N};/4096_mean 159 ns 159 ns 4 -std::string copy{str_with_len_N};/4096_median 159 ns 159 ns 4 -std::string copy{str_with_len_N};/4096_stddev 4.31 ns 4.31 ns 4 -std::string copy{str_with_len_N};/4096_cv 2.70 % 2.70 % 4 -stringa copy{str_with_len_N};/15_mean 1.30 ns 1.30 ns 4 -stringa copy{str_with_len_N};/15_median 1.30 ns 1.30 ns 4 -stringa copy{str_with_len_N};/15_stddev 0.022 ns 0.022 ns 4 -stringa copy{str_with_len_N};/15_cv 1.70 % 1.70 % 4 -stringa copy{str_with_len_N};/16_mean 1.30 ns 1.30 ns 4 -stringa copy{str_with_len_N};/16_median 1.30 ns 1.30 ns 4 -stringa copy{str_with_len_N};/16_stddev 0.017 ns 0.017 ns 4 -stringa copy{str_with_len_N};/16_cv 1.30 % 1.30 % 4 -stringa copy{str_with_len_N};/23_mean 1.30 ns 1.30 ns 4 -stringa copy{str_with_len_N};/23_median 1.30 ns 1.30 ns 4 -stringa copy{str_with_len_N};/23_stddev 0.035 ns 0.035 ns 4 -stringa copy{str_with_len_N};/23_cv 2.71 % 2.71 % 4 +std::string copy{str_with_len_N};/15_mean 7.91 ns 7.91 ns 4 +std::string copy{str_with_len_N};/15_median 7.92 ns 7.92 ns 4 +std::string copy{str_with_len_N};/15_stddev 0.034 ns 0.034 ns 4 +std::string copy{str_with_len_N};/15_cv 0.42 % 0.42 % 4 +std::string copy{str_with_len_N};/16_mean 26.5 ns 26.5 ns 4 +std::string copy{str_with_len_N};/16_median 26.4 ns 26.4 ns 4 +std::string copy{str_with_len_N};/16_stddev 0.579 ns 0.579 ns 4 +std::string copy{str_with_len_N};/16_cv 2.18 % 2.18 % 4 +std::string copy{str_with_len_N};/23_mean 27.3 ns 27.3 ns 4 +std::string copy{str_with_len_N};/23_median 27.0 ns 27.0 ns 4 +std::string copy{str_with_len_N};/23_stddev 1.75 ns 1.75 ns 4 +std::string copy{str_with_len_N};/23_cv 6.39 % 6.39 % 4 +std::string copy{str_with_len_N};/24_mean 27.7 ns 27.7 ns 4 +std::string copy{str_with_len_N};/24_median 27.4 ns 27.4 ns 4 +std::string copy{str_with_len_N};/24_stddev 1.75 ns 1.75 ns 4 +std::string copy{str_with_len_N};/24_cv 6.31 % 6.31 % 4 +std::string copy{str_with_len_N};/32_mean 26.5 ns 26.5 ns 4 +std::string copy{str_with_len_N};/32_median 26.4 ns 26.4 ns 4 +std::string copy{str_with_len_N};/32_stddev 0.639 ns 0.639 ns 4 +std::string copy{str_with_len_N};/32_cv 2.42 % 2.42 % 4 +std::string copy{str_with_len_N};/64_mean 26.9 ns 26.9 ns 4 +std::string copy{str_with_len_N};/64_median 26.7 ns 26.7 ns 4 +std::string copy{str_with_len_N};/64_stddev 1.27 ns 1.27 ns 4 +std::string copy{str_with_len_N};/64_cv 4.73 % 4.73 % 4 +std::string copy{str_with_len_N};/128_mean 28.9 ns 28.9 ns 4 +std::string copy{str_with_len_N};/128_median 28.6 ns 28.6 ns 4 +std::string copy{str_with_len_N};/128_stddev 1.13 ns 1.13 ns 4 +std::string copy{str_with_len_N};/128_cv 3.89 % 3.89 % 4 +std::string copy{str_with_len_N};/256_mean 28.8 ns 28.8 ns 4 +std::string copy{str_with_len_N};/256_median 28.8 ns 28.8 ns 4 +std::string copy{str_with_len_N};/256_stddev 0.613 ns 0.613 ns 4 +std::string copy{str_with_len_N};/256_cv 2.13 % 2.13 % 4 +std::string copy{str_with_len_N};/512_mean 33.6 ns 33.6 ns 4 +std::string copy{str_with_len_N};/512_median 33.5 ns 33.5 ns 4 +std::string copy{str_with_len_N};/512_stddev 0.573 ns 0.573 ns 4 +std::string copy{str_with_len_N};/512_cv 1.71 % 1.71 % 4 +std::string copy{str_with_len_N};/1024_mean 44.2 ns 44.2 ns 4 +std::string copy{str_with_len_N};/1024_median 43.2 ns 43.2 ns 4 +std::string copy{str_with_len_N};/1024_stddev 2.50 ns 2.50 ns 4 +std::string copy{str_with_len_N};/1024_cv 5.64 % 5.64 % 4 +std::string copy{str_with_len_N};/2048_mean 80.3 ns 80.3 ns 4 +std::string copy{str_with_len_N};/2048_median 80.1 ns 80.1 ns 4 +std::string copy{str_with_len_N};/2048_stddev 1.60 ns 1.60 ns 4 +std::string copy{str_with_len_N};/2048_cv 1.99 % 1.99 % 4 +std::string copy{str_with_len_N};/4096_mean 115 ns 115 ns 4 +std::string copy{str_with_len_N};/4096_median 113 ns 113 ns 4 +std::string copy{str_with_len_N};/4096_stddev 6.05 ns 6.05 ns 4 +std::string copy{str_with_len_N};/4096_cv 5.28 % 5.28 % 4 +stringa copy{str_with_len_N};/15_mean 1.09 ns 1.09 ns 4 +stringa copy{str_with_len_N};/15_median 1.09 ns 1.09 ns 4 +stringa copy{str_with_len_N};/15_stddev 0.015 ns 0.015 ns 4 +stringa copy{str_with_len_N};/15_cv 1.34 % 1.34 % 4 +stringa copy{str_with_len_N};/16_mean 1.10 ns 1.10 ns 4 +stringa copy{str_with_len_N};/16_median 1.10 ns 1.10 ns 4 +stringa copy{str_with_len_N};/16_stddev 0.009 ns 0.009 ns 4 +stringa copy{str_with_len_N};/16_cv 0.81 % 0.81 % 4 +stringa copy{str_with_len_N};/23_mean 1.10 ns 1.10 ns 4 +stringa copy{str_with_len_N};/23_median 1.10 ns 1.10 ns 4 +stringa copy{str_with_len_N};/23_stddev 0.021 ns 0.021 ns 4 +stringa copy{str_with_len_N};/23_cv 1.87 % 1.87 % 4 stringa copy{str_with_len_N};/24_mean 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/24_median 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/24_stddev 0.125 ns 0.125 ns 4 -stringa copy{str_with_len_N};/24_cv 0.78 % 0.78 % 4 +stringa copy{str_with_len_N};/24_median 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/24_stddev 0.202 ns 0.202 ns 4 +stringa copy{str_with_len_N};/24_cv 1.26 % 1.26 % 4 stringa copy{str_with_len_N};/32_mean 16.0 ns 16.0 ns 4 -stringa copy{str_with_len_N};/32_median 16.0 ns 16.0 ns 4 -stringa copy{str_with_len_N};/32_stddev 0.173 ns 0.173 ns 4 -stringa copy{str_with_len_N};/32_cv 1.08 % 1.08 % 4 -stringa copy{str_with_len_N};/64_mean 16.0 ns 16.0 ns 4 -stringa copy{str_with_len_N};/64_median 16.0 ns 16.0 ns 4 -stringa copy{str_with_len_N};/64_stddev 0.145 ns 0.145 ns 4 -stringa copy{str_with_len_N};/64_cv 0.91 % 0.91 % 4 +stringa copy{str_with_len_N};/32_median 16.1 ns 16.1 ns 4 +stringa copy{str_with_len_N};/32_stddev 0.065 ns 0.065 ns 4 +stringa copy{str_with_len_N};/32_cv 0.41 % 0.41 % 4 +stringa copy{str_with_len_N};/64_mean 16.1 ns 16.1 ns 4 +stringa copy{str_with_len_N};/64_median 16.1 ns 16.1 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.69 % 0.69 % 4 stringa copy{str_with_len_N};/128_mean 16.0 ns 16.0 ns 4 stringa copy{str_with_len_N};/128_median 16.0 ns 16.0 ns 4 -stringa copy{str_with_len_N};/128_stddev 0.124 ns 0.124 ns 4 -stringa copy{str_with_len_N};/128_cv 0.77 % 0.77 % 4 -stringa copy{str_with_len_N};/256_mean 16.2 ns 16.2 ns 4 -stringa copy{str_with_len_N};/256_median 16.2 ns 16.2 ns 4 -stringa copy{str_with_len_N};/256_stddev 0.233 ns 0.233 ns 4 -stringa copy{str_with_len_N};/256_cv 1.44 % 1.44 % 4 -stringa copy{str_with_len_N};/512_mean 16.2 ns 16.2 ns 4 -stringa copy{str_with_len_N};/512_median 16.2 ns 16.2 ns 4 -stringa copy{str_with_len_N};/512_stddev 0.133 ns 0.133 ns 4 -stringa copy{str_with_len_N};/512_cv 0.82 % 0.82 % 4 +stringa copy{str_with_len_N};/128_stddev 0.083 ns 0.083 ns 4 +stringa copy{str_with_len_N};/128_cv 0.52 % 0.52 % 4 +stringa copy{str_with_len_N};/256_mean 15.9 ns 15.9 ns 4 +stringa copy{str_with_len_N};/256_median 15.9 ns 15.9 ns 4 +stringa copy{str_with_len_N};/256_stddev 0.112 ns 0.112 ns 4 +stringa copy{str_with_len_N};/256_cv 0.70 % 0.70 % 4 +stringa copy{str_with_len_N};/512_mean 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/512_median 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/512_stddev 0.062 ns 0.062 ns 4 +stringa copy{str_with_len_N};/512_cv 0.39 % 0.39 % 4 stringa copy{str_with_len_N};/1024_mean 16.1 ns 16.1 ns 4 stringa copy{str_with_len_N};/1024_median 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/1024_stddev 0.102 ns 0.102 ns 4 -stringa copy{str_with_len_N};/1024_cv 0.64 % 0.64 % 4 +stringa copy{str_with_len_N};/1024_stddev 0.118 ns 0.118 ns 4 +stringa copy{str_with_len_N};/1024_cv 0.74 % 0.74 % 4 stringa copy{str_with_len_N};/2048_mean 16.2 ns 16.2 ns 4 -stringa copy{str_with_len_N};/2048_median 16.1 ns 16.1 ns 4 -stringa copy{str_with_len_N};/2048_stddev 0.270 ns 0.270 ns 4 -stringa copy{str_with_len_N};/2048_cv 1.66 % 1.66 % 4 -stringa copy{str_with_len_N};/4096_mean 16.3 ns 16.3 ns 4 -stringa copy{str_with_len_N};/4096_median 16.3 ns 16.3 ns 4 -stringa copy{str_with_len_N};/4096_stddev 0.202 ns 0.202 ns 4 -stringa copy{str_with_len_N};/4096_cv 1.24 % 1.24 % 4 -lstringa<16> copy{str_with_len_N};/15_mean 1.11 ns 1.11 ns 4 -lstringa<16> copy{str_with_len_N};/15_median 1.11 ns 1.11 ns 4 -lstringa<16> copy{str_with_len_N};/15_stddev 0.025 ns 0.025 ns 4 -lstringa<16> copy{str_with_len_N};/15_cv 2.23 % 2.23 % 4 -lstringa<16> copy{str_with_len_N};/16_mean 5.12 ns 5.12 ns 4 -lstringa<16> copy{str_with_len_N};/16_median 5.08 ns 5.08 ns 4 -lstringa<16> copy{str_with_len_N};/16_stddev 0.236 ns 0.236 ns 4 -lstringa<16> copy{str_with_len_N};/16_cv 4.61 % 4.61 % 4 -lstringa<16> copy{str_with_len_N};/23_mean 5.05 ns 5.05 ns 4 -lstringa<16> copy{str_with_len_N};/23_median 5.09 ns 5.09 ns 4 -lstringa<16> copy{str_with_len_N};/23_stddev 0.105 ns 0.105 ns 4 -lstringa<16> copy{str_with_len_N};/23_cv 2.08 % 2.08 % 4 -lstringa<16> copy{str_with_len_N};/24_mean 24.4 ns 24.4 ns 4 -lstringa<16> copy{str_with_len_N};/24_median 24.3 ns 24.3 ns 4 -lstringa<16> copy{str_with_len_N};/24_stddev 0.660 ns 0.660 ns 4 -lstringa<16> copy{str_with_len_N};/24_cv 2.70 % 2.70 % 4 -lstringa<16> copy{str_with_len_N};/32_mean 24.7 ns 24.7 ns 4 -lstringa<16> copy{str_with_len_N};/32_median 24.6 ns 24.6 ns 4 -lstringa<16> copy{str_with_len_N};/32_stddev 0.521 ns 0.521 ns 4 -lstringa<16> copy{str_with_len_N};/32_cv 2.11 % 2.11 % 4 -lstringa<16> copy{str_with_len_N};/64_mean 26.3 ns 26.3 ns 4 -lstringa<16> copy{str_with_len_N};/64_median 26.3 ns 26.3 ns 4 -lstringa<16> copy{str_with_len_N};/64_stddev 0.762 ns 0.762 ns 4 -lstringa<16> copy{str_with_len_N};/64_cv 2.89 % 2.89 % 4 -lstringa<16> copy{str_with_len_N};/128_mean 26.5 ns 26.5 ns 4 -lstringa<16> copy{str_with_len_N};/128_median 26.5 ns 26.5 ns 4 -lstringa<16> copy{str_with_len_N};/128_stddev 0.376 ns 0.376 ns 4 -lstringa<16> copy{str_with_len_N};/128_cv 1.42 % 1.42 % 4 -lstringa<16> copy{str_with_len_N};/256_mean 28.4 ns 28.4 ns 4 -lstringa<16> copy{str_with_len_N};/256_median 28.3 ns 28.3 ns 4 -lstringa<16> copy{str_with_len_N};/256_stddev 0.396 ns 0.396 ns 4 -lstringa<16> copy{str_with_len_N};/256_cv 1.40 % 1.40 % 4 -lstringa<16> copy{str_with_len_N};/512_mean 31.1 ns 31.1 ns 4 -lstringa<16> copy{str_with_len_N};/512_median 31.2 ns 31.2 ns 4 -lstringa<16> copy{str_with_len_N};/512_stddev 0.499 ns 0.499 ns 4 -lstringa<16> copy{str_with_len_N};/512_cv 1.61 % 1.61 % 4 -lstringa<16> copy{str_with_len_N};/1024_mean 109 ns 109 ns 4 -lstringa<16> copy{str_with_len_N};/1024_median 108 ns 108 ns 4 -lstringa<16> copy{str_with_len_N};/1024_stddev 3.27 ns 3.27 ns 4 -lstringa<16> copy{str_with_len_N};/1024_cv 2.99 % 2.99 % 4 -lstringa<16> copy{str_with_len_N};/2048_mean 120 ns 120 ns 4 -lstringa<16> copy{str_with_len_N};/2048_median 119 ns 119 ns 4 -lstringa<16> copy{str_with_len_N};/2048_stddev 5.23 ns 5.23 ns 4 -lstringa<16> copy{str_with_len_N};/2048_cv 4.37 % 4.37 % 4 -lstringa<16> copy{str_with_len_N};/4096_mean 128 ns 128 ns 4 -lstringa<16> copy{str_with_len_N};/4096_median 129 ns 129 ns 4 -lstringa<16> copy{str_with_len_N};/4096_stddev 3.44 ns 3.44 ns 4 -lstringa<16> copy{str_with_len_N};/4096_cv 2.68 % 2.68 % 4 +stringa copy{str_with_len_N};/2048_median 16.2 ns 16.2 ns 4 +stringa copy{str_with_len_N};/2048_stddev 0.146 ns 0.146 ns 4 +stringa copy{str_with_len_N};/2048_cv 0.90 % 0.90 % 4 +stringa copy{str_with_len_N};/4096_mean 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/4096_median 16.0 ns 16.0 ns 4 +stringa copy{str_with_len_N};/4096_stddev 0.119 ns 0.119 ns 4 +stringa copy{str_with_len_N};/4096_cv 0.74 % 0.74 % 4 +lstringa<16> copy{str_with_len_N};/15_mean 1.10 ns 1.10 ns 4 +lstringa<16> copy{str_with_len_N};/15_median 1.09 ns 1.09 ns 4 +lstringa<16> copy{str_with_len_N};/15_stddev 0.010 ns 0.010 ns 4 +lstringa<16> copy{str_with_len_N};/15_cv 0.89 % 0.89 % 4 +lstringa<16> copy{str_with_len_N};/16_mean 5.38 ns 5.38 ns 4 +lstringa<16> copy{str_with_len_N};/16_median 5.37 ns 5.37 ns 4 +lstringa<16> copy{str_with_len_N};/16_stddev 0.068 ns 0.068 ns 4 +lstringa<16> copy{str_with_len_N};/16_cv 1.27 % 1.27 % 4 +lstringa<16> copy{str_with_len_N};/23_mean 5.43 ns 5.43 ns 4 +lstringa<16> copy{str_with_len_N};/23_median 5.28 ns 5.28 ns 4 +lstringa<16> copy{str_with_len_N};/23_stddev 0.325 ns 0.325 ns 4 +lstringa<16> copy{str_with_len_N};/23_cv 5.99 % 5.99 % 4 +lstringa<16> copy{str_with_len_N};/24_mean 23.6 ns 23.6 ns 4 +lstringa<16> copy{str_with_len_N};/24_median 23.7 ns 23.7 ns 4 +lstringa<16> copy{str_with_len_N};/24_stddev 0.357 ns 0.357 ns 4 +lstringa<16> copy{str_with_len_N};/24_cv 1.51 % 1.51 % 4 +lstringa<16> copy{str_with_len_N};/32_mean 23.5 ns 23.5 ns 4 +lstringa<16> copy{str_with_len_N};/32_median 23.2 ns 23.2 ns 4 +lstringa<16> copy{str_with_len_N};/32_stddev 0.721 ns 0.721 ns 4 +lstringa<16> copy{str_with_len_N};/32_cv 3.07 % 3.07 % 4 +lstringa<16> copy{str_with_len_N};/64_mean 25.7 ns 25.7 ns 4 +lstringa<16> copy{str_with_len_N};/64_median 25.4 ns 25.4 ns 4 +lstringa<16> copy{str_with_len_N};/64_stddev 1.10 ns 1.10 ns 4 +lstringa<16> copy{str_with_len_N};/64_cv 4.27 % 4.27 % 4 +lstringa<16> copy{str_with_len_N};/128_mean 25.6 ns 25.6 ns 4 +lstringa<16> copy{str_with_len_N};/128_median 25.7 ns 25.7 ns 4 +lstringa<16> copy{str_with_len_N};/128_stddev 0.325 ns 0.325 ns 4 +lstringa<16> copy{str_with_len_N};/128_cv 1.27 % 1.27 % 4 +lstringa<16> copy{str_with_len_N};/256_mean 28.0 ns 28.0 ns 4 +lstringa<16> copy{str_with_len_N};/256_median 27.8 ns 27.8 ns 4 +lstringa<16> copy{str_with_len_N};/256_stddev 0.957 ns 0.957 ns 4 +lstringa<16> copy{str_with_len_N};/256_cv 3.42 % 3.42 % 4 +lstringa<16> copy{str_with_len_N};/512_mean 29.6 ns 29.6 ns 4 +lstringa<16> copy{str_with_len_N};/512_median 29.8 ns 29.8 ns 4 +lstringa<16> copy{str_with_len_N};/512_stddev 0.816 ns 0.816 ns 4 +lstringa<16> copy{str_with_len_N};/512_cv 2.75 % 2.75 % 4 +lstringa<16> copy{str_with_len_N};/1024_mean 56.5 ns 56.5 ns 4 +lstringa<16> copy{str_with_len_N};/1024_median 56.6 ns 56.6 ns 4 +lstringa<16> copy{str_with_len_N};/1024_stddev 0.979 ns 0.979 ns 4 +lstringa<16> copy{str_with_len_N};/1024_cv 1.73 % 1.73 % 4 +lstringa<16> copy{str_with_len_N};/2048_mean 66.4 ns 66.4 ns 4 +lstringa<16> copy{str_with_len_N};/2048_median 65.1 ns 65.1 ns 4 +lstringa<16> copy{str_with_len_N};/2048_stddev 5.12 ns 5.12 ns 4 +lstringa<16> copy{str_with_len_N};/2048_cv 7.72 % 7.72 % 4 +lstringa<16> copy{str_with_len_N};/4096_mean 87.0 ns 87.0 ns 4 +lstringa<16> copy{str_with_len_N};/4096_median 86.2 ns 86.2 ns 4 +lstringa<16> copy{str_with_len_N};/4096_stddev 2.74 ns 2.74 ns 4 +lstringa<16> copy{str_with_len_N};/4096_cv 3.15 % 3.15 % 4 lstringa<512> copy{str_with_len_N};/15_mean 1.14 ns 1.14 ns 4 lstringa<512> copy{str_with_len_N};/15_median 1.14 ns 1.14 ns 4 -lstringa<512> copy{str_with_len_N};/15_stddev 0.037 ns 0.037 ns 4 -lstringa<512> copy{str_with_len_N};/15_cv 3.21 % 3.21 % 4 -lstringa<512> copy{str_with_len_N};/16_mean 4.92 ns 4.92 ns 4 -lstringa<512> copy{str_with_len_N};/16_median 4.95 ns 4.95 ns 4 -lstringa<512> copy{str_with_len_N};/16_stddev 0.158 ns 0.158 ns 4 -lstringa<512> copy{str_with_len_N};/16_cv 3.21 % 3.21 % 4 -lstringa<512> copy{str_with_len_N};/23_mean 5.05 ns 5.05 ns 4 -lstringa<512> copy{str_with_len_N};/23_median 5.07 ns 5.07 ns 4 -lstringa<512> copy{str_with_len_N};/23_stddev 0.083 ns 0.083 ns 4 -lstringa<512> copy{str_with_len_N};/23_cv 1.65 % 1.65 % 4 -lstringa<512> copy{str_with_len_N};/24_mean 4.58 ns 4.58 ns 4 -lstringa<512> copy{str_with_len_N};/24_median 4.58 ns 4.58 ns 4 -lstringa<512> copy{str_with_len_N};/24_stddev 0.144 ns 0.144 ns 4 -lstringa<512> copy{str_with_len_N};/24_cv 3.14 % 3.14 % 4 -lstringa<512> copy{str_with_len_N};/32_mean 4.73 ns 4.73 ns 4 -lstringa<512> copy{str_with_len_N};/32_median 4.74 ns 4.74 ns 4 -lstringa<512> copy{str_with_len_N};/32_stddev 0.045 ns 0.045 ns 4 -lstringa<512> copy{str_with_len_N};/32_cv 0.96 % 0.96 % 4 -lstringa<512> copy{str_with_len_N};/64_mean 6.23 ns 6.23 ns 4 -lstringa<512> copy{str_with_len_N};/64_median 6.32 ns 6.32 ns 4 -lstringa<512> copy{str_with_len_N};/64_stddev 0.329 ns 0.329 ns 4 -lstringa<512> copy{str_with_len_N};/64_cv 5.27 % 5.27 % 4 -lstringa<512> copy{str_with_len_N};/128_mean 8.44 ns 8.44 ns 4 -lstringa<512> copy{str_with_len_N};/128_median 8.44 ns 8.44 ns 4 -lstringa<512> copy{str_with_len_N};/128_stddev 0.149 ns 0.149 ns 4 -lstringa<512> copy{str_with_len_N};/128_cv 1.77 % 1.77 % 4 -lstringa<512> copy{str_with_len_N};/256_mean 9.03 ns 9.03 ns 4 -lstringa<512> copy{str_with_len_N};/256_median 8.82 ns 8.82 ns 4 -lstringa<512> copy{str_with_len_N};/256_stddev 0.723 ns 0.723 ns 4 -lstringa<512> copy{str_with_len_N};/256_cv 8.01 % 8.01 % 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.8 ns 12.8 ns 4 -lstringa<512> copy{str_with_len_N};/512_stddev 0.352 ns 0.352 ns 4 -lstringa<512> copy{str_with_len_N};/512_cv 2.74 % 2.74 % 4 -lstringa<512> copy{str_with_len_N};/1024_mean 110 ns 110 ns 4 -lstringa<512> copy{str_with_len_N};/1024_median 110 ns 110 ns 4 -lstringa<512> copy{str_with_len_N};/1024_stddev 0.487 ns 0.487 ns 4 -lstringa<512> copy{str_with_len_N};/1024_cv 0.44 % 0.44 % 4 -lstringa<512> copy{str_with_len_N};/2048_mean 116 ns 116 ns 4 -lstringa<512> copy{str_with_len_N};/2048_median 114 ns 114 ns 4 -lstringa<512> copy{str_with_len_N};/2048_stddev 5.66 ns 5.66 ns 4 -lstringa<512> copy{str_with_len_N};/2048_cv 4.86 % 4.86 % 4 -lstringa<512> copy{str_with_len_N};/4096_mean 130 ns 130 ns 4 -lstringa<512> copy{str_with_len_N};/4096_median 131 ns 131 ns 4 -lstringa<512> copy{str_with_len_N};/4096_stddev 4.27 ns 4.27 ns 4 -lstringa<512> copy{str_with_len_N};/4096_cv 3.30 % 3.30 % 4 +lstringa<512> copy{str_with_len_N};/15_stddev 0.055 ns 0.055 ns 4 +lstringa<512> copy{str_with_len_N};/15_cv 4.83 % 4.83 % 4 +lstringa<512> copy{str_with_len_N};/16_mean 4.46 ns 4.46 ns 4 +lstringa<512> copy{str_with_len_N};/16_median 4.51 ns 4.51 ns 4 +lstringa<512> copy{str_with_len_N};/16_stddev 0.138 ns 0.138 ns 4 +lstringa<512> copy{str_with_len_N};/16_cv 3.09 % 3.09 % 4 +lstringa<512> copy{str_with_len_N};/23_mean 4.67 ns 4.67 ns 4 +lstringa<512> copy{str_with_len_N};/23_median 4.49 ns 4.49 ns 4 +lstringa<512> copy{str_with_len_N};/23_stddev 0.394 ns 0.394 ns 4 +lstringa<512> copy{str_with_len_N};/23_cv 8.44 % 8.44 % 4 +lstringa<512> copy{str_with_len_N};/24_mean 4.10 ns 4.10 ns 4 +lstringa<512> copy{str_with_len_N};/24_median 4.09 ns 4.09 ns 4 +lstringa<512> copy{str_with_len_N};/24_stddev 0.081 ns 0.081 ns 4 +lstringa<512> copy{str_with_len_N};/24_cv 1.98 % 1.98 % 4 +lstringa<512> copy{str_with_len_N};/32_mean 4.20 ns 4.20 ns 4 +lstringa<512> copy{str_with_len_N};/32_median 4.07 ns 4.07 ns 4 +lstringa<512> copy{str_with_len_N};/32_stddev 0.287 ns 0.287 ns 4 +lstringa<512> copy{str_with_len_N};/32_cv 6.83 % 6.83 % 4 +lstringa<512> copy{str_with_len_N};/64_mean 5.66 ns 5.66 ns 4 +lstringa<512> copy{str_with_len_N};/64_median 5.61 ns 5.61 ns 4 +lstringa<512> copy{str_with_len_N};/64_stddev 0.160 ns 0.160 ns 4 +lstringa<512> copy{str_with_len_N};/64_cv 2.83 % 2.83 % 4 +lstringa<512> copy{str_with_len_N};/128_mean 6.97 ns 6.97 ns 4 +lstringa<512> copy{str_with_len_N};/128_median 6.96 ns 6.96 ns 4 +lstringa<512> copy{str_with_len_N};/128_stddev 0.072 ns 0.072 ns 4 +lstringa<512> copy{str_with_len_N};/128_cv 1.03 % 1.03 % 4 +lstringa<512> copy{str_with_len_N};/256_mean 7.99 ns 7.99 ns 4 +lstringa<512> copy{str_with_len_N};/256_median 7.98 ns 7.98 ns 4 +lstringa<512> copy{str_with_len_N};/256_stddev 0.165 ns 0.165 ns 4 +lstringa<512> copy{str_with_len_N};/256_cv 2.06 % 2.06 % 4 +lstringa<512> copy{str_with_len_N};/512_mean 10.3 ns 10.3 ns 4 +lstringa<512> copy{str_with_len_N};/512_median 10.3 ns 10.3 ns 4 +lstringa<512> copy{str_with_len_N};/512_stddev 0.134 ns 0.134 ns 4 +lstringa<512> copy{str_with_len_N};/512_cv 1.30 % 1.30 % 4 +lstringa<512> copy{str_with_len_N};/1024_mean 54.2 ns 54.2 ns 4 +lstringa<512> copy{str_with_len_N};/1024_median 53.3 ns 53.3 ns 4 +lstringa<512> copy{str_with_len_N};/1024_stddev 3.68 ns 3.68 ns 4 +lstringa<512> copy{str_with_len_N};/1024_cv 6.79 % 6.79 % 4 +lstringa<512> copy{str_with_len_N};/2048_mean 66.7 ns 66.7 ns 4 +lstringa<512> copy{str_with_len_N};/2048_median 65.1 ns 65.1 ns 4 +lstringa<512> copy{str_with_len_N};/2048_stddev 5.55 ns 5.55 ns 4 +lstringa<512> copy{str_with_len_N};/2048_cv 8.32 % 8.32 % 4 +lstringa<512> copy{str_with_len_N};/4096_mean 85.2 ns 85.2 ns 4 +lstringa<512> copy{str_with_len_N};/4096_median 85.5 ns 85.5 ns 4 +lstringa<512> copy{str_with_len_N};/4096_stddev 2.30 ns 2.30 ns 4 +lstringa<512> copy{str_with_len_N};/4096_cv 2.70 % 2.70 % 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 26.4 ns 26.4 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 26.6 ns 26.6 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.614 ns 0.614 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 2.32 % 2.32 % 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 11.4 ns 11.4 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 11.3 ns 11.3 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.109 ns 0.109 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 0.96 % 0.96 % 4 -stringa s = "123456789"; int res = s.to_int_mean 8.36 ns 8.36 ns 4 -stringa s = "123456789"; int res = s.to_int_median 8.36 ns 8.36 ns 4 -stringa s = "123456789"; int res = s.to_int_stddev 0.359 ns 0.359 ns 4 -stringa s = "123456789"; int res = s.to_int_cv 4.30 % 4.30 % 4 -ssa s = "123456789"; int res = s.to_int_mean 7.83 ns 7.83 ns 4 -ssa s = "123456789"; int res = s.to_int_median 7.84 ns 7.84 ns 4 -ssa s = "123456789"; int res = s.to_int_stddev 0.155 ns 0.155 ns 4 -ssa s = "123456789"; int res = s.to_int_cv 1.99 % 1.99 % 4 -lstringa<20> s = "123456789"; int res = s.to_int_mean 8.38 ns 8.38 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_median 8.46 ns 8.46 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.258 ns 0.258 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_cv 3.08 % 3.08 % 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_mean 27.2 ns 27.2 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 26.5 ns 26.5 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 1.65 ns 1.65 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 6.07 % 6.07 % 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 12.0 ns 12.0 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 11.7 ns 11.7 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.655 ns 0.655 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 5.47 % 5.47 % 4 +stringa s = "123456789"; int res = s.to_int_mean 8.54 ns 8.54 ns 4 +stringa s = "123456789"; int res = s.to_int_median 8.53 ns 8.53 ns 4 +stringa s = "123456789"; int res = s.to_int_stddev 0.076 ns 0.076 ns 4 +stringa s = "123456789"; int res = s.to_int_cv 0.89 % 0.89 % 4 +ssa s = "123456789"; int res = s.to_int_mean 7.79 ns 7.79 ns 4 +ssa s = "123456789"; int res = s.to_int_median 7.83 ns 7.83 ns 4 +ssa s = "123456789"; int res = s.to_int_stddev 0.118 ns 0.118 ns 4 +ssa s = "123456789"; int res = s.to_int_cv 1.52 % 1.52 % 4 +lstringa<20> s = "123456789"; int res = s.to_int_mean 8.67 ns 8.67 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_median 8.65 ns 8.65 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.080 ns 0.080 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_cv 0.93 % 0.93 % 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 23.5 ns 23.5 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 23.5 ns 23.5 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 0.556 ns 0.556 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 2.37 % 2.37 % 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 9.89 ns 9.89 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 9.82 ns 9.82 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.223 ns 0.223 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 2.25 % 2.25 % 4 -stringa s = "abcDef"; int res = s.to_int_mean 8.19 ns 8.19 ns 4 -stringa s = "abcDef"; int res = s.to_int_median 8.16 ns 8.16 ns 4 -stringa s = "abcDef"; int res = s.to_int_stddev 0.106 ns 0.106 ns 4 -stringa s = "abcDef"; int res = s.to_int_cv 1.29 % 1.29 % 4 -ssa s = "abcDef"; int res = s.to_int_mean 7.77 ns 7.77 ns 4 -ssa s = "abcDef"; int res = s.to_int_median 7.77 ns 7.77 ns 4 -ssa s = "abcDef"; int res = s.to_int_stddev 0.082 ns 0.082 ns 4 -ssa s = "abcDef"; int res = s.to_int_cv 1.06 % 1.06 % 4 -lstringa<20> s = "abcDef"; int res = s.to_int_mean 8.12 ns 8.12 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_median 8.12 ns 8.12 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.177 ns 0.177 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_cv 2.19 % 2.19 % 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_mean 23.8 ns 23.8 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 23.8 ns 23.8 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 0.404 ns 0.404 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 1.70 % 1.70 % 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 8.07 ns 8.07 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 8.12 ns 8.12 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.200 ns 0.200 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 2.47 % 2.47 % 4 +stringa s = "abcDef"; int res = s.to_int_mean 8.44 ns 8.44 ns 4 +stringa s = "abcDef"; int res = s.to_int_median 8.39 ns 8.39 ns 4 +stringa s = "abcDef"; int res = s.to_int_stddev 0.140 ns 0.140 ns 4 +stringa s = "abcDef"; int res = s.to_int_cv 1.66 % 1.66 % 4 +ssa s = "abcDef"; int res = s.to_int_mean 6.72 ns 6.72 ns 4 +ssa s = "abcDef"; int res = s.to_int_median 6.71 ns 6.71 ns 4 +ssa s = "abcDef"; int res = s.to_int_stddev 0.160 ns 0.160 ns 4 +ssa s = "abcDef"; int res = s.to_int_cv 2.38 % 2.38 % 4 +lstringa<20> s = "abcDef"; int res = s.to_int_mean 8.42 ns 8.42 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_median 8.44 ns 8.44 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.072 ns 0.072 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_cv 0.85 % 0.85 % 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 28.4 ns 28.4 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 28.6 ns 28.6 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 0.374 ns 0.374 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 1.31 % 1.31 % 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 14.9 ns 14.9 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 14.9 ns 14.9 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.479 ns 0.479 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 3.21 % 3.21 % 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 13.7 ns 13.7 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 13.8 ns 13.8 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.232 ns 0.232 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 1.69 % 1.69 % 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_mean 27.8 ns 27.8 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 27.7 ns 27.7 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 0.355 ns 0.355 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 1.28 % 1.28 % 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 15.3 ns 15.3 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 15.3 ns 15.3 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.158 ns 0.158 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 1.03 % 1.03 % 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 10.8 ns 10.8 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 10.7 ns 10.7 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.227 ns 0.227 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 2.11 % 2.11 % 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 66.8 ns 66.8 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 66.0 ns 66.0 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 1.89 ns 1.88 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 2.82 % 2.82 % 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 25.0 ns 25.0 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 24.6 ns 24.6 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 0.985 ns 0.985 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 3.94 % 3.94 % 4 -ssa s = "1234.567e10"; double res = *s.to_double()_mean 25.2 ns 25.2 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_median 25.0 ns 25.0 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_stddev 1.33 ns 1.33 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_cv 5.30 % 5.30 % 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_mean 62.8 ns 62.8 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 62.1 ns 62.1 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 2.10 ns 2.10 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 3.33 % 3.33 % 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 24.2 ns 24.2 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 24.2 ns 24.2 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 0.171 ns 0.171 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 0.71 % 0.71 % 4 +ssa s = "1234.567e10"; double res = *s.to_double()_mean 24.5 ns 24.5 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_median 24.4 ns 24.4 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.578 ns 0.578 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_cv 2.36 % 2.36 % 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 1359 ns 1359 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_median 1355 ns 1355 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 31.1 ns 31.1 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.29 % 2.29 % 4 -std::string str; ... str += "abbaabbaabbaabba";_mean 380 ns 380 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_median 379 ns 379 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_stddev 9.64 ns 9.64 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_cv 2.54 % 2.54 % 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 435 ns 435 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_median 438 ns 438 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 11.2 ns 11.2 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 2.58 % 2.58 % 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 280 ns 280 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_median 287 ns 287 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 26.3 ns 26.3 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 9.40 % 9.40 % 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 255 ns 255 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_median 263 ns 263 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 17.6 ns 17.6 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 6.90 % 6.90 % 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 141 ns 141 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 142 ns 142 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 2.92 ns 2.92 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 2.08 % 2.08 % 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_mean 1345 ns 1345 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_median 1335 ns 1335 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 29.1 ns 29.0 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.16 % 2.16 % 4 +std::string str; ... str += "abbaabbaabbaabba";_mean 346 ns 346 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_median 336 ns 336 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_stddev 29.3 ns 29.3 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_cv 8.46 % 8.46 % 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 345 ns 345 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_median 344 ns 344 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 3.53 ns 3.53 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 1.02 % 1.02 % 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 239 ns 239 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_median 237 ns 237 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 13.4 ns 13.4 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 5.60 % 5.60 % 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 209 ns 209 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_median 204 ns 204 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 11.3 ns 11.3 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 5.42 % 5.42 % 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 139 ns 139 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 139 ns 139 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 1.80 ns 1.80 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 1.30 % 1.30 % 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 1357 ns 1357 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 1346 ns 1346 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 28.4 ns 28.4 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 2.09 % 2.09 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 1291 ns 1291 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_median 1271 ns 1271 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 54.7 ns 54.7 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 4.24 % 4.24 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 450 ns 450 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 448 ns 448 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 7.75 ns 7.75 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.72 % 1.72 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 373 ns 373 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 373 ns 373 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 14.0 ns 14.0 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 3.75 % 3.75 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 337 ns 337 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 338 ns 338 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 23.7 ns 23.7 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 7.03 % 7.03 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 246 ns 246 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 245 ns 245 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 3.93 ns 3.93 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.60 % 1.60 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_mean 1345 ns 1345 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 1344 ns 1344 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 29.9 ns 29.9 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 2.22 % 2.22 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 1298 ns 1298 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_median 1261 ns 1261 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 81.3 ns 81.3 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 6.27 % 6.27 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 403 ns 403 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 406 ns 406 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 10.2 ns 10.2 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.54 % 2.54 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 342 ns 342 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 340 ns 340 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 8.89 ns 8.89 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.60 % 2.60 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 299 ns 299 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 299 ns 299 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 9.68 ns 9.68 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 3.24 % 3.24 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 254 ns 254 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 256 ns 256 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 3.19 ns 3.19 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.25 % 1.25 % 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 76165 ns 76165 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 75195 ns 75195 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 2995 ns 2995 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 3.93 % 3.93 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 74730 ns 74730 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 75093 ns 75094 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1648 ns 1648 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.21 % 2.21 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 20473 ns 20473 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 20456 ns 20456 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 726 ns 726 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.54 % 3.55 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 17347 ns 17347 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 17374 ns 17374 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 231 ns 231 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.33 % 1.33 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 17337 ns 17337 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 17362 ns 17362 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 639 ns 639 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.69 % 3.69 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 17747 ns 17747 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 17380 ns 17380 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 849 ns 849 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 4.78 % 4.78 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_mean 113874 ns 113875 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 112092 ns 112092 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 7677 ns 7677 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 6.74 % 6.74 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 73347 ns 73348 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 72413 ns 72414 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 2893 ns 2893 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.94 % 3.94 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 44770 ns 44770 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 44972 ns 44973 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 572 ns 572 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.28 % 1.28 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 25460 ns 25460 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 25397 ns 25397 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1600 ns 1600 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 6.28 % 6.28 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 18428 ns 18428 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16917 ns 16917 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 3164 ns 3164 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 17.17 % 17.17 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 17351 ns 17351 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 17290 ns 17290 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 464 ns 464 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.68 % 2.68 % 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 1390 ns 1390 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_median 1391 ns 1391 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_stddev 22.6 ns 22.6 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_cv 1.62 % 1.62 % 4 -std::string str; ... str += str_var1 + str_var2;_mean 1351 ns 1351 ns 4 -std::string str; ... str += str_var1 + str_var2;_median 1354 ns 1354 ns 4 -std::string str; ... str += str_var1 + str_var2;_stddev 42.1 ns 42.1 ns 4 -std::string str; ... str += str_var1 + str_var2;_cv 3.11 % 3.11 % 4 -lstringa<16> str; ... str += str_var1 + str_var2;_mean 547 ns 547 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_median 545 ns 545 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_stddev 16.7 ns 16.7 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_cv 3.05 % 3.05 % 4 -lstringa<128> str; ... str += str_var1 + str_var2;_mean 455 ns 455 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_median 457 ns 457 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_stddev 24.4 ns 24.4 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_cv 5.36 % 5.36 % 4 -lstringa<512> str; ... str += str_var1 + str_var2;_mean 428 ns 428 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_median 430 ns 430 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_stddev 15.2 ns 15.2 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_cv 3.56 % 3.56 % 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_mean 318 ns 318 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_median 320 ns 320 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 6.09 ns 6.09 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_cv 1.91 % 1.91 % 4 +std::stringstream str; ... str << str_var1 << str_var2;_mean 1352 ns 1352 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_median 1356 ns 1356 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_stddev 15.2 ns 15.2 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_cv 1.12 % 1.12 % 4 +std::string str; ... str += str_var1 + str_var2;_mean 1422 ns 1422 ns 4 +std::string str; ... str += str_var1 + str_var2;_median 1378 ns 1378 ns 4 +std::string str; ... str += str_var1 + str_var2;_stddev 94.5 ns 94.5 ns 4 +std::string str; ... str += str_var1 + str_var2;_cv 6.64 % 6.64 % 4 +lstringa<16> str; ... str += str_var1 + str_var2;_mean 465 ns 465 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_median 465 ns 465 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_stddev 7.14 ns 7.14 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_cv 1.53 % 1.53 % 4 +lstringa<128> str; ... str += str_var1 + str_var2;_mean 415 ns 415 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_median 416 ns 416 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_stddev 17.9 ns 17.9 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_cv 4.31 % 4.31 % 4 +lstringa<512> str; ... str += str_var1 + str_var2;_mean 361 ns 361 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_median 361 ns 361 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_stddev 2.70 ns 2.70 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_cv 0.75 % 0.75 % 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_mean 322 ns 322 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_median 313 ns 313 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 21.2 ns 21.2 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_cv 6.61 % 6.61 % 4 -- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; str << "test = " << k << " times";_mean 3118 ns 3118 ns 4 -std::stringstream str; str << "test = " << k << " times";_median 3175 ns 3175 ns 4 -std::stringstream str; str << "test = " << k << " times";_stddev 118 ns 118 ns 4 -std::stringstream str; str << "test = " << k << " times";_cv 3.78 % 3.78 % 4 -std::string str = "test = " + std::to_string(k) + " times";_mean 444 ns 444 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_median 444 ns 444 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_stddev 10.2 ns 10.2 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_cv 2.30 % 2.30 % 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 1517 ns 1517 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 1519 ns 1519 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 18.8 ns 18.8 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 1.24 % 1.24 % 4 -std::string str = std::format("test = {} times", k);_mean 1221 ns 1221 ns 4 -std::string str = std::format("test = {} times", k);_median 1231 ns 1231 ns 4 -std::string str = std::format("test = {} times", k);_stddev 33.1 ns 33.1 ns 4 -std::string str = std::format("test = {} times", k);_cv 2.71 % 2.71 % 4 -lstringa<8> str; str.format("test = {} times", k);_mean 1732 ns 1732 ns 4 -lstringa<8> str; str.format("test = {} times", k);_median 1737 ns 1737 ns 4 -lstringa<8> str; str.format("test = {} times", k);_stddev 71.0 ns 71.0 ns 4 -lstringa<8> str; str.format("test = {} times", k);_cv 4.10 % 4.10 % 4 -lstringa<32> str; str.format("test = {} times", k);_mean 1099 ns 1099 ns 4 -lstringa<32> str; str.format("test = {} times", k);_median 1103 ns 1103 ns 4 -lstringa<32> str; str.format("test = {} times", k);_stddev 16.7 ns 16.7 ns 4 -lstringa<32> str; str.format("test = {} times", k);_cv 1.52 % 1.52 % 4 -lstringa<8> str = "test = " + k + " times";_mean 299 ns 299 ns 4 -lstringa<8> str = "test = " + k + " times";_median 299 ns 299 ns 4 -lstringa<8> str = "test = " + k + " times";_stddev 7.24 ns 7.24 ns 4 -lstringa<8> str = "test = " + k + " times";_cv 2.42 % 2.42 % 4 -lstringa<32> str = "test = " + k + " times";_mean 180 ns 180 ns 4 -lstringa<32> str = "test = " + k + " times";_median 180 ns 180 ns 4 -lstringa<32> str = "test = " + k + " times";_stddev 7.19 ns 7.19 ns 4 -lstringa<32> str = "test = " + k + " times";_cv 3.99 % 3.99 % 4 -stringa str = "test = " + k + " times";_mean 189 ns 189 ns 4 -stringa str = "test = " + k + " times";_median 185 ns 185 ns 4 -stringa str = "test = " + k + " times";_stddev 14.9 ns 14.9 ns 4 -stringa str = "test = " + k + " times";_cv 7.86 % 7.86 % 4 +std::stringstream str; str << "test = " << k << " times";_mean 3192 ns 3192 ns 4 +std::stringstream str; str << "test = " << k << " times";_median 3192 ns 3192 ns 4 +std::stringstream str; str << "test = " << k << " times";_stddev 20.8 ns 20.8 ns 4 +std::stringstream str; str << "test = " << k << " times";_cv 0.65 % 0.65 % 4 +std::string str = "test = " + std::to_string(k) + " times";_mean 505 ns 505 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_median 507 ns 507 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_stddev 19.9 ns 19.9 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_cv 3.94 % 3.94 % 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 1544 ns 1544 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 1542 ns 1542 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 104 ns 104 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 6.76 % 6.76 % 4 +std::string str = std::format("test = {} times", k);_mean 1453 ns 1453 ns 4 +std::string str = std::format("test = {} times", k);_median 1457 ns 1457 ns 4 +std::string str = std::format("test = {} times", k);_stddev 13.7 ns 13.7 ns 4 +std::string str = std::format("test = {} times", k);_cv 0.94 % 0.94 % 4 +lstringa<8> str; str.format("test = {} times", k);_mean 1547 ns 1547 ns 4 +lstringa<8> str; str.format("test = {} times", k);_median 1553 ns 1553 ns 4 +lstringa<8> str; str.format("test = {} times", k);_stddev 66.4 ns 66.4 ns 4 +lstringa<8> str; str.format("test = {} times", k);_cv 4.29 % 4.29 % 4 +lstringa<32> str; str.format("test = {} times", k);_mean 1083 ns 1083 ns 4 +lstringa<32> str; str.format("test = {} times", k);_median 1094 ns 1094 ns 4 +lstringa<32> str; str.format("test = {} times", k);_stddev 33.6 ns 33.6 ns 4 +lstringa<32> str; str.format("test = {} times", k);_cv 3.10 % 3.10 % 4 +lstringa<8> str = "test = " + k + " times";_mean 295 ns 295 ns 4 +lstringa<8> str = "test = " + k + " times";_median 292 ns 292 ns 4 +lstringa<8> str = "test = " + k + " times";_stddev 10.1 ns 10.1 ns 4 +lstringa<8> str = "test = " + k + " times";_cv 3.41 % 3.41 % 4 +lstringa<32> str = "test = " + k + " times";_mean 149 ns 149 ns 4 +lstringa<32> str = "test = " + k + " times";_median 148 ns 148 ns 4 +lstringa<32> str = "test = " + k + " times";_stddev 2.86 ns 2.86 ns 4 +lstringa<32> str = "test = " + k + " times";_cv 1.92 % 1.92 % 4 +stringa str = "test = " + k + " times";_mean 130 ns 130 ns 4 +stringa str = "test = " + k + " times";_median 130 ns 130 ns 4 +stringa str = "test = " + k + " times";_stddev 4.49 ns 4.49 ns 4 +stringa str = "test = " + k + " times";_cv 3.45 % 3.45 % 4 -- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string::find + substr + std::strtol_mean 290 ns 290 ns 4 -std::string::find + substr + std::strtol_median 286 ns 286 ns 4 -std::string::find + substr + std::strtol_stddev 11.6 ns 11.6 ns 4 -std::string::find + substr + std::strtol_cv 4.00 % 4.00 % 4 -ssa::splitter + ssa::as_int_mean 147 ns 147 ns 4 -ssa::splitter + ssa::as_int_median 146 ns 146 ns 4 -ssa::splitter + ssa::as_int_stddev 4.68 ns 4.68 ns 4 -ssa::splitter + ssa::as_int_cv 3.18 % 3.18 % 4 -ssa::splitf + functor_mean 136 ns 136 ns 4 -ssa::splitf + functor_median 138 ns 138 ns 4 -ssa::splitf + functor_stddev 8.48 ns 8.48 ns 4 -ssa::splitf + functor_cv 6.22 % 6.22 % 4 +std::string::find + substr + std::strtol_mean 275 ns 275 ns 4 +std::string::find + substr + std::strtol_median 275 ns 275 ns 4 +std::string::find + substr + std::strtol_stddev 5.18 ns 5.18 ns 4 +std::string::find + substr + std::strtol_cv 1.88 % 1.88 % 4 +ssa::splitter + ssa::as_int_mean 151 ns 151 ns 4 +ssa::splitter + ssa::as_int_median 150 ns 150 ns 4 +ssa::splitter + ssa::as_int_stddev 3.87 ns 3.87 ns 4 +ssa::splitter + ssa::as_int_cv 2.57 % 2.57 % 4 +ssa::splitf + functor_mean 122 ns 122 ns 4 +ssa::splitf + functor_median 121 ns 121 ns 4 +ssa::splitf + functor_stddev 1.56 ns 1.56 ns 4 +ssa::splitf + functor_cv 1.28 % 1.28 % 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 925 ns 925 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_median 936 ns 936 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_stddev 53.5 ns 53.5 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_cv 5.79 % 5.79 % 4 -replace symbols with std::string find_first_of + replace_mean 2787 ns 2787 ns 4 -replace symbols with std::string find_first_of + replace_median 2753 ns 2753 ns 4 -replace symbols with std::string find_first_of + replace_stddev 118 ns 118 ns 4 -replace symbols with std::string find_first_of + replace_cv 4.22 % 4.22 % 4 -replace symbols with std::string_view find_first_of + copy_mean 1082 ns 1082 ns 4 -replace symbols with std::string_view find_first_of + copy_median 1087 ns 1087 ns 4 -replace symbols with std::string_view find_first_of + copy_stddev 27.8 ns 27.8 ns 4 -replace symbols with std::string_view find_first_of + copy_cv 2.57 % 2.57 % 4 -replace runtime symbols with string expressions and without remembering all search results_mean 1483 ns 1483 ns 4 -replace runtime symbols with string expressions and without remembering all search results_median 1485 ns 1485 ns 4 -replace runtime symbols with string expressions and without remembering all search results_stddev 21.7 ns 21.7 ns 4 -replace runtime symbols with string expressions and without remembering all search results_cv 1.46 % 1.46 % 4 -replace runtime symbols with simstr and memorization of all search results_mean 1047 ns 1047 ns 4 -replace runtime symbols with simstr and memorization of all search results_median 1047 ns 1047 ns 4 -replace runtime symbols with simstr and memorization of all search results_stddev 32.5 ns 32.5 ns 4 -replace runtime symbols with simstr and memorization of all search results_cv 3.10 % 3.10 % 4 -replace const symbols with string expressions and without remembering all search results_mean 1228 ns 1228 ns 4 -replace const symbols with string expressions and without remembering all search results_median 1225 ns 1225 ns 4 -replace const symbols with string expressions and without remembering all search results_stddev 33.4 ns 33.4 ns 4 -replace const symbols with string expressions and without remembering all search results_cv 2.72 % 2.72 % 4 -replace const symbols with string expressions and memorization of all search results_mean 850 ns 850 ns 4 -replace const symbols with string expressions and memorization of all search results_median 848 ns 848 ns 4 -replace const symbols with string expressions and memorization of all search results_stddev 14.1 ns 14.1 ns 4 -replace const symbols with string expressions and memorization of all search results_cv 1.66 % 1.66 % 4 +Naive (and wrong) replace symbols with std::string find + replace_mean 834 ns 834 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_median 832 ns 832 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_stddev 10.4 ns 10.4 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_cv 1.25 % 1.25 % 4 +replace symbols with std::string find_first_of + replace_mean 2603 ns 2603 ns 4 +replace symbols with std::string find_first_of + replace_median 2605 ns 2605 ns 4 +replace symbols with std::string find_first_of + replace_stddev 11.1 ns 11.1 ns 4 +replace symbols with std::string find_first_of + replace_cv 0.43 % 0.43 % 4 +replace symbols with std::string_view find_first_of + copy_mean 1037 ns 1037 ns 4 +replace symbols with std::string_view find_first_of + copy_median 1039 ns 1039 ns 4 +replace symbols with std::string_view find_first_of + copy_stddev 8.97 ns 8.97 ns 4 +replace symbols with std::string_view find_first_of + copy_cv 0.86 % 0.86 % 4 +replace runtime symbols with string expressions and without remembering all search results_mean 1542 ns 1542 ns 4 +replace runtime symbols with string expressions and without remembering all search results_median 1568 ns 1568 ns 4 +replace runtime symbols with string expressions and without remembering all search results_stddev 86.7 ns 86.7 ns 4 +replace runtime symbols with string expressions and without remembering all search results_cv 5.62 % 5.62 % 4 +replace runtime symbols with simstr and memorization of all search results_mean 1156 ns 1156 ns 4 +replace runtime symbols with simstr and memorization of all search results_median 1149 ns 1149 ns 4 +replace runtime symbols with simstr and memorization of all search results_stddev 19.1 ns 19.1 ns 4 +replace runtime symbols with simstr and memorization of all search results_cv 1.66 % 1.66 % 4 +replace const symbols with string expressions and without remembering all search results_mean 1193 ns 1193 ns 4 +replace const symbols with string expressions and without remembering all search results_median 1203 ns 1203 ns 4 +replace const symbols with string expressions and without remembering all search results_stddev 29.8 ns 29.8 ns 4 +replace const symbols with string expressions and without remembering all search results_cv 2.50 % 2.49 % 4 +replace const symbols with string expressions and memorization of all search results_mean 837 ns 837 ns 4 +replace const symbols with string expressions and memorization of all search results_median 835 ns 835 ns 4 +replace const symbols with string expressions and memorization of all search results_stddev 7.17 ns 7.17 ns 4 +replace const symbols with string expressions and memorization of all search results_cv 0.86 % 0.86 % 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 165 ns 165 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_median 166 ns 166 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_stddev 4.82 ns 4.82 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_cv 2.93 % 2.93 % 4 -Short replace symbols with std::string find_first_of + replace_mean 313 ns 313 ns 4 -Short replace symbols with std::string find_first_of + replace_median 310 ns 310 ns 4 -Short replace symbols with std::string find_first_of + replace_stddev 9.34 ns 9.34 ns 4 -Short replace symbols with std::string find_first_of + replace_cv 2.98 % 2.98 % 4 -Short replace symbols with std::string_view find_first_of + copy_mean 156 ns 156 ns 4 -Short replace symbols with std::string_view find_first_of + copy_median 156 ns 156 ns 4 -Short replace symbols with std::string_view find_first_of + copy_stddev 1.79 ns 1.79 ns 4 -Short replace symbols with std::string_view find_first_of + copy_cv 1.14 % 1.14 % 4 -Short replace runtime symbols with string expressions and without remembering all search results_mean 188 ns 188 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_median 188 ns 188 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_stddev 1.91 ns 1.91 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_cv 1.01 % 1.01 % 4 -Short replace runtime symbols with simstr and memorization of all search results_mean 193 ns 193 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_median 191 ns 191 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_stddev 8.96 ns 8.96 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_cv 4.65 % 4.65 % 4 -Short replace const symbols with string expressions and without remembering all search results_mean 150 ns 150 ns 4 -Short replace const symbols with string expressions and without remembering all search results_median 148 ns 148 ns 4 -Short replace const symbols with string expressions and without remembering all search results_stddev 5.36 ns 5.36 ns 4 -Short replace const symbols with string expressions and without remembering all search results_cv 3.58 % 3.58 % 4 -Short replace const symbols with string expressions and memorization of all search results_mean 143 ns 143 ns 4 -Short replace const symbols with string expressions and memorization of all search results_median 142 ns 142 ns 4 -Short replace const symbols with string expressions and memorization of all search results_stddev 4.69 ns 4.69 ns 4 -Short replace const symbols with string expressions and memorization of all search results_cv 3.27 % 3.27 % 4 +Short Naive (and wrong) replace symbols with std::string find + replace_mean 154 ns 154 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_median 153 ns 153 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_stddev 5.93 ns 5.93 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_cv 3.85 % 3.84 % 4 +Short replace symbols with std::string find_first_of + replace_mean 301 ns 301 ns 4 +Short replace symbols with std::string find_first_of + replace_median 302 ns 302 ns 4 +Short replace symbols with std::string find_first_of + replace_stddev 4.86 ns 4.86 ns 4 +Short replace symbols with std::string find_first_of + replace_cv 1.61 % 1.61 % 4 +Short replace symbols with std::string_view find_first_of + copy_mean 154 ns 154 ns 4 +Short replace symbols with std::string_view find_first_of + copy_median 153 ns 153 ns 4 +Short replace symbols with std::string_view find_first_of + copy_stddev 5.14 ns 5.14 ns 4 +Short replace symbols with std::string_view find_first_of + copy_cv 3.34 % 3.34 % 4 +Short replace runtime symbols with string expressions and without remembering all search results_mean 178 ns 178 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_median 177 ns 177 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_stddev 2.09 ns 2.09 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_cv 1.18 % 1.18 % 4 +Short replace runtime symbols with simstr and memorization of all search results_mean 192 ns 192 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_median 185 ns 185 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_stddev 17.6 ns 17.6 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_cv 9.21 % 9.21 % 4 +Short replace const symbols with string expressions and without remembering all search results_mean 149 ns 149 ns 4 +Short replace const symbols with string expressions and without remembering all search results_median 150 ns 150 ns 4 +Short replace const symbols with string expressions and without remembering all search results_stddev 2.94 ns 2.94 ns 4 +Short replace const symbols with string expressions and without remembering all search results_cv 1.98 % 1.98 % 4 +Short replace const symbols with string expressions and memorization of all search results_mean 134 ns 134 ns 4 +Short replace const symbols with string expressions and memorization of all search results_median 133 ns 133 ns 4 +Short replace const symbols with string expressions and memorization of all search results_stddev 2.82 ns 2.82 ns 4 +Short replace const symbols with string expressions and memorization of all search results_cv 2.11 % 2.11 % 4 ----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to ---- in std::string|64_mean 159 ns 159 ns 4 -replace bb to ---- in std::string|64_median 158 ns 158 ns 4 -replace bb to ---- in std::string|64_stddev 1.80 ns 1.80 ns 4 -replace bb to ---- in std::string|64_cv 1.13 % 1.13 % 4 -replace bb to ---- in std::string|256_mean 502 ns 502 ns 4 -replace bb to ---- in std::string|256_median 505 ns 505 ns 4 -replace bb to ---- in std::string|256_stddev 15.1 ns 15.1 ns 4 -replace bb to ---- in std::string|256_cv 3.00 % 3.00 % 4 -replace bb to ---- in std::string|512_mean 1124 ns 1124 ns 4 -replace bb to ---- in std::string|512_median 1129 ns 1129 ns 4 -replace bb to ---- in std::string|512_stddev 18.6 ns 18.6 ns 4 -replace bb to ---- in std::string|512_cv 1.65 % 1.65 % 4 -replace bb to ---- in std::string|1024_mean 2263 ns 2263 ns 4 -replace bb to ---- in std::string|1024_median 2211 ns 2211 ns 4 -replace bb to ---- in std::string|1024_stddev 148 ns 148 ns 4 -replace bb to ---- in std::string|1024_cv 6.55 % 6.55 % 4 -replace bb to ---- in std::string|2048_mean 5898 ns 5898 ns 4 -replace bb to ---- in std::string|2048_median 5930 ns 5930 ns 4 -replace bb to ---- in std::string|2048_stddev 134 ns 134 ns 4 -replace bb to ---- in std::string|2048_cv 2.27 % 2.27 % 4 -replace bb to ---- in lstringa<8>|64_mean 163 ns 163 ns 4 -replace bb to ---- in lstringa<8>|64_median 157 ns 157 ns 4 -replace bb to ---- in lstringa<8>|64_stddev 12.3 ns 12.3 ns 4 -replace bb to ---- in lstringa<8>|64_cv 7.56 % 7.56 % 4 -replace bb to ---- in lstringa<8>|256_mean 480 ns 480 ns 4 -replace bb to ---- in lstringa<8>|256_median 478 ns 478 ns 4 -replace bb to ---- in lstringa<8>|256_stddev 12.4 ns 12.4 ns 4 -replace bb to ---- in lstringa<8>|256_cv 2.58 % 2.58 % 4 -replace bb to ---- in lstringa<8>|512_mean 909 ns 909 ns 4 -replace bb to ---- in lstringa<8>|512_median 918 ns 918 ns 4 -replace bb to ---- in lstringa<8>|512_stddev 19.8 ns 19.8 ns 4 -replace bb to ---- in lstringa<8>|512_cv 2.17 % 2.17 % 4 -replace bb to ---- in lstringa<8>|1024_mean 1860 ns 1860 ns 4 -replace bb to ---- in lstringa<8>|1024_median 1861 ns 1861 ns 4 -replace bb to ---- in lstringa<8>|1024_stddev 41.4 ns 41.4 ns 4 -replace bb to ---- in lstringa<8>|1024_cv 2.23 % 2.23 % 4 -replace bb to ---- in lstringa<8>|2048_mean 3465 ns 3465 ns 4 -replace bb to ---- in lstringa<8>|2048_median 3464 ns 3464 ns 4 -replace bb to ---- in lstringa<8>|2048_stddev 54.7 ns 54.7 ns 4 -replace bb to ---- in lstringa<8>|2048_cv 1.58 % 1.58 % 4 -replace bb to ---- by init stringa|64_mean 98.5 ns 98.5 ns 4 -replace bb to ---- by init stringa|64_median 98.1 ns 98.1 ns 4 -replace bb to ---- by init stringa|64_stddev 2.17 ns 2.17 ns 4 -replace bb to ---- by init stringa|64_cv 2.20 % 2.20 % 4 -replace bb to ---- by init stringa|256_mean 302 ns 302 ns 4 -replace bb to ---- by init stringa|256_median 304 ns 304 ns 4 -replace bb to ---- by init stringa|256_stddev 4.64 ns 4.64 ns 4 -replace bb to ---- by init stringa|256_cv 1.54 % 1.53 % 4 -replace bb to ---- by init stringa|512_mean 729 ns 729 ns 4 -replace bb to ---- by init stringa|512_median 729 ns 729 ns 4 -replace bb to ---- by init stringa|512_stddev 11.3 ns 11.3 ns 4 -replace bb to ---- by init stringa|512_cv 1.55 % 1.55 % 4 -replace bb to ---- by init stringa|1024_mean 1639 ns 1639 ns 4 -replace bb to ---- by init stringa|1024_median 1646 ns 1646 ns 4 -replace bb to ---- by init stringa|1024_stddev 58.9 ns 58.9 ns 4 -replace bb to ---- by init stringa|1024_cv 3.59 % 3.59 % 4 -replace bb to ---- by init stringa|2048_mean 3376 ns 3376 ns 4 -replace bb to ---- by init stringa|2048_median 3364 ns 3364 ns 4 -replace bb to ---- by init stringa|2048_stddev 68.3 ns 68.3 ns 4 -replace bb to ---- by init stringa|2048_cv 2.02 % 2.02 % 4 +replace bb to ---- in std::string|64_mean 152 ns 152 ns 4 +replace bb to ---- in std::string|64_median 153 ns 153 ns 4 +replace bb to ---- in std::string|64_stddev 3.54 ns 3.54 ns 4 +replace bb to ---- in std::string|64_cv 2.33 % 2.33 % 4 +replace bb to ---- in std::string|256_mean 463 ns 463 ns 4 +replace bb to ---- in std::string|256_median 464 ns 464 ns 4 +replace bb to ---- in std::string|256_stddev 8.51 ns 8.51 ns 4 +replace bb to ---- in std::string|256_cv 1.84 % 1.84 % 4 +replace bb to ---- in std::string|512_mean 1323 ns 1323 ns 4 +replace bb to ---- in std::string|512_median 1303 ns 1303 ns 4 +replace bb to ---- in std::string|512_stddev 76.1 ns 76.1 ns 4 +replace bb to ---- in std::string|512_cv 5.75 % 5.75 % 4 +replace bb to ---- in std::string|1024_mean 2217 ns 2217 ns 4 +replace bb to ---- in std::string|1024_median 2228 ns 2228 ns 4 +replace bb to ---- in std::string|1024_stddev 205 ns 205 ns 4 +replace bb to ---- in std::string|1024_cv 9.24 % 9.24 % 4 +replace bb to ---- in std::string|2048_mean 5811 ns 5811 ns 4 +replace bb to ---- in std::string|2048_median 5725 ns 5725 ns 4 +replace bb to ---- in std::string|2048_stddev 492 ns 492 ns 4 +replace bb to ---- in std::string|2048_cv 8.47 % 8.47 % 4 +replace bb to ---- in lstringa<8>|64_mean 137 ns 137 ns 4 +replace bb to ---- in lstringa<8>|64_median 137 ns 137 ns 4 +replace bb to ---- in lstringa<8>|64_stddev 1.21 ns 1.21 ns 4 +replace bb to ---- in lstringa<8>|64_cv 0.88 % 0.88 % 4 +replace bb to ---- in lstringa<8>|256_mean 451 ns 451 ns 4 +replace bb to ---- in lstringa<8>|256_median 449 ns 449 ns 4 +replace bb to ---- in lstringa<8>|256_stddev 4.69 ns 4.69 ns 4 +replace bb to ---- in lstringa<8>|256_cv 1.04 % 1.04 % 4 +replace bb to ---- in lstringa<8>|512_mean 857 ns 857 ns 4 +replace bb to ---- in lstringa<8>|512_median 845 ns 845 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 3.64 % 3.64 % 4 +replace bb to ---- in lstringa<8>|1024_mean 1683 ns 1683 ns 4 +replace bb to ---- in lstringa<8>|1024_median 1678 ns 1678 ns 4 +replace bb to ---- in lstringa<8>|1024_stddev 23.3 ns 23.3 ns 4 +replace bb to ---- in lstringa<8>|1024_cv 1.38 % 1.38 % 4 +replace bb to ---- in lstringa<8>|2048_mean 3386 ns 3386 ns 4 +replace bb to ---- in lstringa<8>|2048_median 3370 ns 3370 ns 4 +replace bb to ---- in lstringa<8>|2048_stddev 88.8 ns 88.8 ns 4 +replace bb to ---- in lstringa<8>|2048_cv 2.62 % 2.62 % 4 +replace bb to ---- by init stringa|64_mean 90.1 ns 90.1 ns 4 +replace bb to ---- by init stringa|64_median 90.0 ns 90.0 ns 4 +replace bb to ---- by init stringa|64_stddev 2.44 ns 2.44 ns 4 +replace bb to ---- by init stringa|64_cv 2.71 % 2.71 % 4 +replace bb to ---- by init stringa|256_mean 294 ns 294 ns 4 +replace bb to ---- by init stringa|256_median 289 ns 289 ns 4 +replace bb to ---- by init stringa|256_stddev 10.6 ns 10.6 ns 4 +replace bb to ---- by init stringa|256_cv 3.62 % 3.62 % 4 +replace bb to ---- by init stringa|512_mean 673 ns 673 ns 4 +replace bb to ---- by init stringa|512_median 669 ns 669 ns 4 +replace bb to ---- by init stringa|512_stddev 11.6 ns 11.6 ns 4 +replace bb to ---- by init stringa|512_cv 1.72 % 1.72 % 4 +replace bb to ---- by init stringa|1024_mean 1470 ns 1470 ns 4 +replace bb to ---- by init stringa|1024_median 1472 ns 1472 ns 4 +replace bb to ---- by init stringa|1024_stddev 8.67 ns 8.67 ns 4 +replace bb to ---- by init stringa|1024_cv 0.59 % 0.59 % 4 +replace bb to ---- by init stringa|2048_mean 2966 ns 2966 ns 4 +replace bb to ---- by init stringa|2048_median 2970 ns 2970 ns 4 +replace bb to ---- by init stringa|2048_stddev 39.2 ns 39.2 ns 4 +replace bb to ---- by init stringa|2048_cv 1.32 % 1.32 % 4 ----- Replace All Str To Same Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to -- in std::string|64_mean 117 ns 117 ns 4 -replace bb to -- in std::string|64_median 117 ns 117 ns 4 -replace bb to -- in std::string|64_stddev 2.88 ns 2.88 ns 4 -replace bb to -- in std::string|64_cv 2.46 % 2.46 % 4 -replace bb to -- in std::string|256_mean 392 ns 392 ns 4 -replace bb to -- in std::string|256_median 394 ns 394 ns 4 -replace bb to -- in std::string|256_stddev 3.26 ns 3.26 ns 4 -replace bb to -- in std::string|256_cv 0.83 % 0.83 % 4 -replace bb to -- in std::string|512_mean 705 ns 705 ns 4 -replace bb to -- in std::string|512_median 699 ns 699 ns 4 -replace bb to -- in std::string|512_stddev 30.8 ns 30.8 ns 4 -replace bb to -- in std::string|512_cv 4.37 % 4.37 % 4 -replace bb to -- in std::string|1024_mean 1346 ns 1346 ns 4 -replace bb to -- in std::string|1024_median 1346 ns 1346 ns 4 -replace bb to -- in std::string|1024_stddev 2.10 ns 2.10 ns 4 -replace bb to -- in std::string|1024_cv 0.16 % 0.16 % 4 -replace bb to -- in std::string|2048_mean 2835 ns 2835 ns 4 -replace bb to -- in std::string|2048_median 2815 ns 2815 ns 4 -replace bb to -- in std::string|2048_stddev 81.8 ns 81.8 ns 4 -replace bb to -- in std::string|2048_cv 2.88 % 2.88 % 4 -replace bb to -- in lstringa<8>|64_mean 102 ns 102 ns 4 -replace bb to -- in lstringa<8>|64_median 102 ns 102 ns 4 -replace bb to -- in lstringa<8>|64_stddev 2.17 ns 2.17 ns 4 -replace bb to -- in lstringa<8>|64_cv 2.12 % 2.12 % 4 +replace bb to -- in std::string|64_mean 113 ns 113 ns 4 +replace bb to -- in std::string|64_median 112 ns 112 ns 4 +replace bb to -- in std::string|64_stddev 6.55 ns 6.55 ns 4 +replace bb to -- in std::string|64_cv 5.79 % 5.79 % 4 +replace bb to -- in std::string|256_mean 360 ns 360 ns 4 +replace bb to -- in std::string|256_median 361 ns 361 ns 4 +replace bb to -- in std::string|256_stddev 6.85 ns 6.85 ns 4 +replace bb to -- in std::string|256_cv 1.90 % 1.90 % 4 +replace bb to -- in std::string|512_mean 729 ns 729 ns 4 +replace bb to -- in std::string|512_median 733 ns 733 ns 4 +replace bb to -- in std::string|512_stddev 12.1 ns 12.1 ns 4 +replace bb to -- in std::string|512_cv 1.66 % 1.66 % 4 +replace bb to -- in std::string|1024_mean 1303 ns 1303 ns 4 +replace bb to -- in std::string|1024_median 1307 ns 1307 ns 4 +replace bb to -- in std::string|1024_stddev 25.7 ns 25.7 ns 4 +replace bb to -- in std::string|1024_cv 1.97 % 1.97 % 4 +replace bb to -- in std::string|2048_mean 2642 ns 2642 ns 4 +replace bb to -- in std::string|2048_median 2645 ns 2645 ns 4 +replace bb to -- in std::string|2048_stddev 70.8 ns 70.8 ns 4 +replace bb to -- in std::string|2048_cv 2.68 % 2.68 % 4 +replace bb to -- in lstringa<8>|64_mean 93.3 ns 93.3 ns 4 +replace bb to -- in lstringa<8>|64_median 93.1 ns 93.1 ns 4 +replace bb to -- in lstringa<8>|64_stddev 0.890 ns 0.890 ns 4 +replace bb to -- in lstringa<8>|64_cv 0.95 % 0.95 % 4 replace bb to -- in lstringa<8>|256_mean 284 ns 284 ns 4 -replace bb to -- in lstringa<8>|256_median 284 ns 284 ns 4 -replace bb to -- in lstringa<8>|256_stddev 2.90 ns 2.90 ns 4 -replace bb to -- in lstringa<8>|256_cv 1.02 % 1.02 % 4 -replace bb to -- in lstringa<8>|512_mean 525 ns 525 ns 4 -replace bb to -- in lstringa<8>|512_median 519 ns 519 ns 4 -replace bb to -- in lstringa<8>|512_stddev 13.5 ns 13.5 ns 4 -replace bb to -- in lstringa<8>|512_cv 2.57 % 2.57 % 4 -replace bb to -- in lstringa<8>|1024_mean 1047 ns 1047 ns 4 -replace bb to -- in lstringa<8>|1024_median 1058 ns 1058 ns 4 -replace bb to -- in lstringa<8>|1024_stddev 31.4 ns 31.4 ns 4 -replace bb to -- in lstringa<8>|1024_cv 3.00 % 3.00 % 4 -replace bb to -- in lstringa<8>|2048_mean 1993 ns 1993 ns 4 -replace bb to -- in lstringa<8>|2048_median 1994 ns 1994 ns 4 -replace bb to -- in lstringa<8>|2048_stddev 37.8 ns 37.8 ns 4 -replace bb to -- in lstringa<8>|2048_cv 1.90 % 1.90 % 4 -replace bb to -- by init stringa|64_mean 93.5 ns 93.5 ns 4 -replace bb to -- by init stringa|64_median 92.9 ns 92.9 ns 4 -replace bb to -- by init stringa|64_stddev 2.08 ns 2.08 ns 4 -replace bb to -- by init stringa|64_cv 2.22 % 2.22 % 4 -replace bb to -- by init stringa|256_mean 268 ns 268 ns 4 -replace bb to -- by init stringa|256_median 267 ns 267 ns 4 -replace bb to -- by init stringa|256_stddev 4.69 ns 4.69 ns 4 -replace bb to -- by init stringa|256_cv 1.75 % 1.75 % 4 -replace bb to -- by init stringa|512_mean 506 ns 506 ns 4 -replace bb to -- by init stringa|512_median 506 ns 506 ns 4 -replace bb to -- by init stringa|512_stddev 9.79 ns 9.79 ns 4 -replace bb to -- by init stringa|512_cv 1.93 % 1.93 % 4 -replace bb to -- by init stringa|1024_mean 1045 ns 1045 ns 4 -replace bb to -- by init stringa|1024_median 1033 ns 1033 ns 4 -replace bb to -- by init stringa|1024_stddev 26.6 ns 26.6 ns 4 -replace bb to -- by init stringa|1024_cv 2.55 % 2.55 % 4 -replace bb to -- by init stringa|2048_mean 2003 ns 2003 ns 4 -replace bb to -- by init stringa|2048_median 2005 ns 2005 ns 4 -replace bb to -- by init stringa|2048_stddev 23.3 ns 23.3 ns 4 -replace bb to -- by init stringa|2048_cv 1.16 % 1.16 % 4 +replace bb to -- in lstringa<8>|256_median 285 ns 285 ns 4 +replace bb to -- in lstringa<8>|256_stddev 4.44 ns 4.44 ns 4 +replace bb to -- in lstringa<8>|256_cv 1.56 % 1.56 % 4 +replace bb to -- in lstringa<8>|512_mean 517 ns 517 ns 4 +replace bb to -- in lstringa<8>|512_median 518 ns 518 ns 4 +replace bb to -- in lstringa<8>|512_stddev 4.93 ns 4.93 ns 4 +replace bb to -- in lstringa<8>|512_cv 0.95 % 0.95 % 4 +replace bb to -- in lstringa<8>|1024_mean 1029 ns 1029 ns 4 +replace bb to -- in lstringa<8>|1024_median 1019 ns 1019 ns 4 +replace bb to -- in lstringa<8>|1024_stddev 22.3 ns 22.3 ns 4 +replace bb to -- in lstringa<8>|1024_cv 2.16 % 2.16 % 4 +replace bb to -- in lstringa<8>|2048_mean 2035 ns 2035 ns 4 +replace bb to -- in lstringa<8>|2048_median 2042 ns 2042 ns 4 +replace bb to -- in lstringa<8>|2048_stddev 20.9 ns 20.9 ns 4 +replace bb to -- in lstringa<8>|2048_cv 1.03 % 1.03 % 4 +replace bb to -- by init stringa|64_mean 83.5 ns 83.5 ns 4 +replace bb to -- by init stringa|64_median 83.2 ns 83.2 ns 4 +replace bb to -- by init stringa|64_stddev 1.22 ns 1.22 ns 4 +replace bb to -- by init stringa|64_cv 1.46 % 1.46 % 4 +replace bb to -- by init stringa|256_mean 263 ns 263 ns 4 +replace bb to -- by init stringa|256_median 261 ns 261 ns 4 +replace bb to -- by init stringa|256_stddev 6.35 ns 6.35 ns 4 +replace bb to -- by init stringa|256_cv 2.42 % 2.42 % 4 +replace bb to -- by init stringa|512_mean 516 ns 516 ns 4 +replace bb to -- by init stringa|512_median 502 ns 502 ns 4 +replace bb to -- by init stringa|512_stddev 37.9 ns 37.9 ns 4 +replace bb to -- by init stringa|512_cv 7.34 % 7.34 % 4 +replace bb to -- by init stringa|1024_mean 999 ns 999 ns 4 +replace bb to -- by init stringa|1024_median 996 ns 996 ns 4 +replace bb to -- by init stringa|1024_stddev 18.4 ns 18.4 ns 4 +replace bb to -- by init stringa|1024_cv 1.84 % 1.84 % 4 +replace bb to -- by init stringa|2048_mean 1966 ns 1966 ns 4 +replace bb to -- by init stringa|2048_median 1971 ns 1971 ns 4 +replace bb to -- by init stringa|2048_stddev 35.7 ns 35.7 ns 4 +replace bb to -- by init stringa|2048_cv 1.82 % 1.82 % 4 ----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -hashStrMapA emplace & find stringa;_mean 3717070 ns 3717106 ns 4 -hashStrMapA emplace & find stringa;_median 3715946 ns 3715961 ns 4 -hashStrMapA emplace & find stringa;_stddev 23646 ns 23682 ns 4 -hashStrMapA emplace & find stringa;_cv 0.64 % 0.64 % 4 -std::unordered_map emplace & find std::string;_mean 3567358 ns 3567368 ns 4 -std::unordered_map emplace & find std::string;_median 3550488 ns 3550497 ns 4 -std::unordered_map emplace & find std::string;_stddev 50396 ns 50396 ns 4 -std::unordered_map emplace & find std::string;_cv 1.41 % 1.41 % 4 -hashStrMapA emplace & find ssa;_mean 3701465 ns 3701479 ns 4 -hashStrMapA emplace & find ssa;_median 3710816 ns 3710831 ns 4 -hashStrMapA emplace & find ssa;_stddev 57949 ns 57948 ns 4 -hashStrMapA emplace & find ssa;_cv 1.57 % 1.57 % 4 -std::unordered_map emplace & find std::string_view;_mean 3941394 ns 3941409 ns 4 -std::unordered_map emplace & find std::string_view;_median 3932719 ns 3932733 ns 4 -std::unordered_map emplace & find std::string_view;_stddev 42603 ns 42603 ns 4 -std::unordered_map emplace & find std::string_view;_cv 1.08 % 1.08 % 4 +hashStrMapA emplace & find stringa;_mean 3793699 ns 3793714 ns 4 +hashStrMapA emplace & find stringa;_median 3789128 ns 3789143 ns 4 +hashStrMapA emplace & find stringa;_stddev 159548 ns 159547 ns 4 +hashStrMapA emplace & find stringa;_cv 4.21 % 4.21 % 4 +std::unordered_map emplace & find std::string;_mean 3632923 ns 3632933 ns 4 +std::unordered_map emplace & find std::string;_median 3618001 ns 3618010 ns 4 +std::unordered_map emplace & find std::string;_stddev 98152 ns 98151 ns 4 +std::unordered_map emplace & find std::string;_cv 2.70 % 2.70 % 4 +hashStrMapA emplace & find ssa;_mean 3697109 ns 3697125 ns 4 +hashStrMapA emplace & find ssa;_median 3701481 ns 3701498 ns 4 +hashStrMapA emplace & find ssa;_stddev 81924 ns 81922 ns 4 +hashStrMapA emplace & find ssa;_cv 2.22 % 2.22 % 4 +std::unordered_map emplace & find std::string_view;_mean 3939262 ns 3939278 ns 4 +std::unordered_map emplace & find std::string_view;_median 3931674 ns 3931690 ns 4 +std::unordered_map emplace & find std::string_view;_stddev 43207 ns 43208 ns 4 +std::unordered_map emplace & find std::string_view;_cv 1.10 % 1.10 % 4 ----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Build func full name std::string;_mean 971 ns 971 ns 4 -Build func full name std::string;_median 955 ns 955 ns 4 -Build func full name std::string;_stddev 49.0 ns 49.0 ns 4 -Build func full name std::string;_cv 5.04 % 5.04 % 4 -Build func full name std::string 1;_mean 1015 ns 1015 ns 4 -Build func full name std::string 1;_median 1014 ns 1014 ns 4 -Build func full name std::string 1;_stddev 15.0 ns 15.0 ns 4 -Build func full name std::string 1;_cv 1.48 % 1.48 % 4 -Build func full name std::stream;_mean 2569 ns 2569 ns 4 -Build func full name std::stream;_median 2576 ns 2576 ns 4 -Build func full name std::stream;_stddev 27.2 ns 27.2 ns 4 -Build func full name std::stream;_cv 1.06 % 1.06 % 4 -Build func full name stringa;_mean 463 ns 463 ns 4 -Build func full name stringa;_median 463 ns 463 ns 4 -Build func full name stringa;_stddev 12.9 ns 12.9 ns 4 -Build func full name stringa;_cv 2.79 % 2.79 % 4 -Build func full name stringa 1;_mean 664 ns 664 ns 4 -Build func full name stringa 1;_median 663 ns 663 ns 4 -Build func full name stringa 1;_stddev 7.82 ns 7.82 ns 4 -Build func full name stringa 1;_cv 1.18 % 1.18 % 4 +Build func full name std::string;_mean 812 ns 812 ns 4 +Build func full name std::string;_median 814 ns 814 ns 4 +Build func full name std::string;_stddev 16.6 ns 16.6 ns 4 +Build func full name std::string;_cv 2.05 % 2.05 % 4 +Build func full name std::string 1;_mean 935 ns 935 ns 4 +Build func full name std::string 1;_median 942 ns 942 ns 4 +Build func full name std::string 1;_stddev 32.7 ns 32.7 ns 4 +Build func full name std::string 1;_cv 3.50 % 3.50 % 4 +Build func full name std::stream;_mean 2527 ns 2527 ns 4 +Build func full name std::stream;_median 2531 ns 2531 ns 4 +Build func full name std::stream;_stddev 34.3 ns 34.3 ns 4 +Build func full name std::stream;_cv 1.36 % 1.36 % 4 +Build func full name stringa;_mean 446 ns 446 ns 4 +Build func full name stringa;_median 437 ns 437 ns 4 +Build func full name stringa;_stddev 20.2 ns 20.2 ns 4 +Build func full name stringa;_cv 4.54 % 4.54 % 4 +Build func full name stringa 1;_mean 624 ns 624 ns 4 +Build func full name stringa 1;_median 626 ns 626 ns 4 +Build func full name stringa 1;_stddev 12.3 ns 12.3 ns 4 +Build func full name stringa 1;_cv 1.97 % 1.97 % 4 diff --git a/bench/results/002-Xeon E5-2682 v4, Windows 10, Clang-19.txt b/bench/results/002-Xeon E5-2682 v4, Windows 10, Clang-19.txt index 530b323..1e5ca84 100644 --- a/bench/results/002-Xeon E5-2682 v4, Windows 10, Clang-19.txt +++ b/bench/results/002-Xeon E5-2682 v4, Windows 10, Clang-19.txt @@ -2,7 +2,7 @@ Benchmarks of simstr, version 1.6.7 Sources: https://github.com/orefkov/simstr Results: https://orefkov.github.io/simstr/results.html -2026-02-12T15:02:25+03:00 +2026-02-14T11:03:52+03:00 Running benchStr.exe Run on (32 X 2494 MHz CPU s) CPU Caches: @@ -13,925 +13,962 @@ CPU Caches: -------------------------------------------------------------------------------------------------------------------------------------------------------- Benchmark Time CPU Iterations -------------------------------------------------------------------------------------------------------------------------------------------------------- +----- Concatenate email ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 +Concat email std::format_mean 203 ns 203 ns 4 +Concat email std::format_median 202 ns 201 ns 4 +Concat email std::format_stddev 5.59 ns 4.19 ns 4 +Concat email std::format_cv 2.75 % 2.06 % 4 +Concat email std::stringstream_mean 792 ns 795 ns 4 +Concat email std::stringstream_median 794 ns 788 ns 4 +Concat email std::stringstream_stddev 19.8 ns 19.7 ns 4 +Concat email std::stringstream_cv 2.51 % 2.48 % 4 +Concat email stringzilla append_mean 268 ns 266 ns 4 +Concat email stringzilla append_median 267 ns 268 ns 4 +Concat email stringzilla append_stddev 6.46 ns 11.5 ns 4 +Concat email stringzilla append_cv 2.41 % 4.32 % 4 +Concat email stringzilla concat_mean 126 ns 126 ns 4 +Concat email stringzilla concat_median 126 ns 126 ns 4 +Concat email stringzilla concat_stddev 1.04 ns 1.40 ns 4 +Concat email stringzilla concat_cv 0.83 % 1.10 % 4 +Concat email std::string append_mean 189 ns 189 ns 4 +Concat email std::string append_median 187 ns 188 ns 4 +Concat email std::string append_stddev 8.95 ns 8.63 ns 4 +Concat email std::string append_cv 4.73 % 4.56 % 4 +Concat email std::string by strexpr_mean 108 ns 107 ns 4 +Concat email std::string by strexpr_median 107 ns 107 ns 4 +Concat email std::string by strexpr_stddev 5.11 ns 4.46 ns 4 +Concat email std::string by strexpr_cv 4.75 % 4.15 % 4 +Concat email stringa_mean 92.7 ns 92.1 ns 4 +Concat email stringa_median 91.9 ns 92.1 ns 4 +Concat email stringa_stddev 2.35 ns 3.42 ns 4 +Concat email stringa_cv 2.54 % 3.71 % 4 ----- Concatenate string + Number + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string and number by std to std::string_mean 272 ns 270 ns 4 -Concat std::string and number by std to std::string_median 269 ns 267 ns 4 -Concat std::string and number by std to std::string_stddev 14.5 ns 11.4 ns 4 -Concat std::string and number by std to std::string_cv 5.32 % 4.21 % 4 -Concat std::string and number by StrExpr to std::string_mean 154 ns 154 ns 4 -Concat std::string and number by StrExpr to std::string_median 154 ns 154 ns 4 -Concat std::string and number by StrExpr to std::string_stddev 2.69 ns 2.56 ns 4 -Concat std::string and number by StrExpr to std::string_cv 1.74 % 1.67 % 4 -Concat stringa and number by StrExpr to simstr::stringa_mean 68.4 ns 68.4 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_median 68.7 ns 69.1 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_stddev 1.22 ns 1.97 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_cv 1.79 % 2.89 % 4 -Concat stringa and number by e_concat to simstr::stringa_mean 73.2 ns 73.2 ns 4 -Concat stringa and number by e_concat to simstr::stringa_median 72.9 ns 73.2 ns 4 -Concat stringa and number by e_concat to simstr::stringa_stddev 1.32 ns 1.42 ns 4 -Concat stringa and number by e_concat to simstr::stringa_cv 1.80 % 1.94 % 4 +Concat std::string and number by std to std::string_mean 273 ns 273 ns 4 +Concat std::string and number by std to std::string_median 273 ns 273 ns 4 +Concat std::string and number by std to std::string_stddev 3.27 ns 4.84 ns 4 +Concat std::string and number by std to std::string_cv 1.20 % 1.77 % 4 +Concat std::string and number by StrExpr to std::string_mean 152 ns 151 ns 4 +Concat std::string and number by StrExpr to std::string_median 152 ns 151 ns 4 +Concat std::string and number by StrExpr to std::string_stddev 3.63 ns 3.95 ns 4 +Concat std::string and number by StrExpr to std::string_cv 2.39 % 2.61 % 4 +Concat stringa and number by StrExpr to simstr::stringa_mean 70.1 ns 69.8 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_median 70.2 ns 70.5 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_stddev 2.78 ns 3.01 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_cv 3.97 % 4.32 % 4 +Concat stringa and number by e_concat to simstr::stringa_mean 74.4 ns 74.6 ns 4 +Concat stringa and number by e_concat to simstr::stringa_median 75.3 ns 75.0 ns 4 +Concat stringa and number by e_concat to simstr::stringa_stddev 2.15 ns 2.19 ns 4 +Concat stringa and number by e_concat to simstr::stringa_cv 2.89 % 2.94 % 4 ----- Concatenate string + Hex Number + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string and format hex number and literal to std::string_mean 724 ns 725 ns 4 -Concat std::string and format hex number and literal to std::string_median 713 ns 711 ns 4 -Concat std::string and format hex number and literal to std::string_stddev 25.8 ns 27.9 ns 4 -Concat std::string and format hex number and literal to std::string_cv 3.57 % 3.85 % 4 -std::format std::string and hex number by literal to std::string_mean 1505 ns 1506 ns 4 -std::format std::string and hex number by literal to std::string_median 1502 ns 1496 ns 4 -std::format std::string and hex number by literal to std::string_stddev 28.5 ns 48.3 ns 4 -std::format std::string and hex number by literal to std::string_cv 1.89 % 3.21 % 4 -Concat std::string and std::to_chars and string to std::string_mean 194 ns 191 ns 4 -Concat std::string and std::to_chars and string to std::string_median 194 ns 190 ns 4 -Concat std::string and std::to_chars and string to std::string_stddev 2.21 ns 4.01 ns 4 -Concat std::string and std::to_chars and string to std::string_cv 1.14 % 2.09 % 4 -Concat std::string and hex number and literal by StrExpr to std::string_mean 79.4 ns 79.0 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_median 80.3 ns 79.5 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_stddev 2.41 ns 2.63 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_cv 3.04 % 3.33 % 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 73.6 ns 73.8 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 74.1 ns 74.3 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 3.30 ns 3.57 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 4.48 % 4.84 % 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 80.7 ns 81.1 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_median 80.3 ns 80.2 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 2.59 ns 3.34 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 3.21 % 4.12 % 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_mean 148 ns 148 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_median 148 ns 148 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 6.14 ns 5.73 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_cv 4.16 % 3.88 % 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 286 ns 283 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 282 ns 279 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 8.46 ns 8.89 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 2.96 % 3.14 % 4 +Concat std::string and format hex number and literal to std::string_mean 705 ns 706 ns 4 +Concat std::string and format hex number and literal to std::string_median 708 ns 706 ns 4 +Concat std::string and format hex number and literal to std::string_stddev 11.7 ns 10.1 ns 4 +Concat std::string and format hex number and literal to std::string_cv 1.65 % 1.43 % 4 +std::format std::string and hex number by literal to std::string_mean 1462 ns 1465 ns 4 +std::format std::string and hex number by literal to std::string_median 1453 ns 1447 ns 4 +std::format std::string and hex number by literal to std::string_stddev 42.2 ns 49.3 ns 4 +std::format std::string and hex number by literal to std::string_cv 2.89 % 3.37 % 4 +Concat std::string and std::to_chars and string to std::string_mean 189 ns 189 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 5.14 ns 6.28 ns 4 +Concat std::string and std::to_chars and string to std::string_cv 2.71 % 3.31 % 4 +Concat std::string and hex number and literal by StrExpr to std::string_mean 87.4 ns 87.6 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_median 87.7 ns 88.1 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_stddev 1.32 ns 1.67 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_cv 1.51 % 1.91 % 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 77.7 ns 77.2 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 73.8 ns 73.2 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 9.46 ns 9.16 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 12.17 % 11.87 % 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 76.3 ns 76.7 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_median 76.2 ns 76.7 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 1.98 ns 2.01 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 2.59 % 2.62 % 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_mean 152 ns 151 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_median 152 ns 152 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 2.08 ns 3.34 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_cv 1.36 % 2.21 % 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 279 ns 279 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 278 ns 279 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 8.89 ns 13.1 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 3.19 % 4.68 % 4 ---- format/vformat and subst/vsubst octal number to 32 symbols result ----/repeats:1 0.000 ns 0.000 ns 1000000000000 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_mean 669 ns 670 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 671 ns 677 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 13.9 ns 19.7 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 2.07 % 2.95 % 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 745 ns 741 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 745 ns 741 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 17.7 ns 10.1 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 2.38 % 1.36 % 4 -e_vsubst(pattern, i / 0x8a010_fmt)_mean 1036 ns 1038 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_median 1038 ns 1038 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_stddev 15.0 ns 14.1 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_cv 1.45 % 1.36 % 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 1405 ns 1405 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 1395 ns 1397 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 31.2 ns 30.1 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 2.22 % 2.14 % 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 1331 ns 1325 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 1323 ns 1325 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 28.2 ns 16.1 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.12 % 1.22 % 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1540 ns 1535 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_median 1541 ns 1535 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 43.3 ns 57.0 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.81 % 3.71 % 4 -std::vformat(pattern, std::make_format_args(i))_mean 1608 ns 1583 ns 4 -std::vformat(pattern, std::make_format_args(i))_median 1578 ns 1573 ns 4 -std::vformat(pattern, std::make_format_args(i))_stddev 75.3 ns 19.2 ns 4 -std::vformat(pattern, std::make_format_args(i))_cv 4.68 % 1.21 % 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 6435 ns 6383 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 6449 ns 6417 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 82.1 ns 69.8 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 1.28 % 1.09 % 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_mean 660 ns 656 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 654 ns 656 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 17.1 ns 22.8 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 2.59 % 3.47 % 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 778 ns 776 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 773 ns 767 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 24.5 ns 30.2 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 3.15 % 3.89 % 4 +e_vsubst(pattern, i / 0x8a010_fmt)_mean 1061 ns 1062 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_median 1068 ns 1062 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_stddev 26.9 ns 31.5 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_cv 2.53 % 2.97 % 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 1404 ns 1405 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 1405 ns 1413 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 44.2 ns 47.1 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 3.15 % 3.35 % 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 1355 ns 1346 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 1352 ns 1353 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 27.2 ns 47.7 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.01 % 3.54 % 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1542 ns 1543 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_median 1540 ns 1552 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 29.8 ns 33.4 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.93 % 2.16 % 4 +std::vformat(pattern, std::make_format_args(i))_mean 1549 ns 1543 ns 4 +std::vformat(pattern, std::make_format_args(i))_median 1539 ns 1535 ns 4 +std::vformat(pattern, std::make_format_args(i))_stddev 31.6 ns 43.9 ns 4 +std::vformat(pattern, std::make_format_args(i))_cv 2.04 % 2.84 % 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 6785 ns 6801 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 6807 ns 6836 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 182 ns 176 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 2.69 % 2.58 % 4 ----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string by std to std::string_mean 39.6 ns 39.5 ns 4 -Concat std::string by std to std::string_median 39.9 ns 40.1 ns 4 -Concat std::string by std to std::string_stddev 3.05 ns 2.97 ns 4 -Concat std::string by std to std::string_cv 7.71 % 7.52 % 4 -Concat std::string by StrExpr to std::string_mean 41.1 ns 41.0 ns 4 -Concat std::string by StrExpr to std::string_median 40.9 ns 40.5 ns 4 -Concat std::string by StrExpr to std::string_stddev 1.16 ns 1.23 ns 4 -Concat std::string by StrExpr to std::string_cv 2.83 % 3.01 % 4 -Concat stringa by StrExpr to stringa_mean 28.5 ns 28.4 ns 4 -Concat stringa by StrExpr to stringa_median 28.5 ns 28.6 ns 4 -Concat stringa by StrExpr to stringa_stddev 0.559 ns 0.601 ns 4 -Concat stringa by StrExpr to stringa_cv 1.96 % 2.12 % 4 +Concat std::string by std to std::string_mean 41.5 ns 41.5 ns 4 +Concat std::string by std to std::string_median 41.3 ns 41.3 ns 4 +Concat std::string by std to std::string_stddev 1.69 ns 1.55 ns 4 +Concat std::string by std to std::string_cv 4.07 % 3.73 % 4 +Concat std::string by StrExpr to std::string_mean 38.6 ns 38.1 ns 4 +Concat std::string by StrExpr to std::string_median 38.6 ns 38.1 ns 4 +Concat std::string by StrExpr to std::string_stddev 1.19 ns 0.740 ns 4 +Concat std::string by StrExpr to std::string_cv 3.08 % 1.94 % 4 +Concat stringa by StrExpr to stringa_mean 28.7 ns 28.6 ns 4 +Concat stringa by StrExpr to stringa_median 28.7 ns 28.9 ns 4 +Concat stringa by StrExpr to stringa_stddev 0.410 ns 0.628 ns 4 +Concat stringa by StrExpr to stringa_cv 1.43 % 2.20 % 4 ----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Find concat three std::string_mean 200 ns 201 ns 4 -Find concat three std::string_median 201 ns 201 ns 4 -Find concat three std::string_stddev 4.02 ns 3.42 ns 4 -Find concat three std::string_cv 2.01 % 1.70 % 4 -Find concat three strexpr_mean 116 ns 116 ns 4 -Find concat three strexpr_median 115 ns 116 ns 4 -Find concat three strexpr_stddev 3.22 ns 3.15 ns 4 -Find concat three strexpr_cv 2.77 % 2.72 % 4 -Find concat three simstr_mean 28.2 ns 28.2 ns 4 -Find concat three simstr_median 27.5 ns 27.3 ns 4 -Find concat three simstr_stddev 1.59 ns 1.78 ns 4 -Find concat three simstr_cv 5.63 % 6.32 % 4 +Find concat three std::string_mean 205 ns 205 ns 4 +Find concat three std::string_median 204 ns 204 ns 4 +Find concat three std::string_stddev 2.80 ns 2.27 ns 4 +Find concat three std::string_cv 1.36 % 1.10 % 4 +Find concat three strexpr_mean 118 ns 118 ns 4 +Find concat three strexpr_median 118 ns 118 ns 4 +Find concat three strexpr_stddev 1.98 ns 2.34 ns 4 +Find concat three strexpr_cv 1.68 % 1.98 % 4 +Find concat three simstr_mean 27.2 ns 27.3 ns 4 +Find concat three simstr_median 27.3 ns 27.3 ns 4 +Find concat three simstr_stddev 0.267 ns 0.362 ns 4 +Find concat three simstr_cv 0.98 % 1.33 % 4 +Find concat three stringzilla string_mean 215 ns 214 ns 4 +Find concat three stringzilla string_median 215 ns 212 ns 4 +Find concat three stringzilla string_stddev 6.28 ns 4.67 ns 4 +Find concat three stringzilla string_cv 2.92 % 2.19 % 4 ----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -BuildTypeNameStr 0/0_mean 7.98 ns 7.93 ns 4 -BuildTypeNameStr 0/0_median 7.98 ns 7.93 ns 4 -BuildTypeNameStr 0/0_stddev 0.087 ns 0.101 ns 4 -BuildTypeNameStr 0/0_cv 1.08 % 1.27 % 4 -BuildTypeNameExp 0/0_mean 7.44 ns 7.46 ns 4 -BuildTypeNameExp 0/0_median 7.47 ns 7.50 ns 4 -BuildTypeNameExp 0/0_stddev 0.147 ns 0.087 ns 4 -BuildTypeNameExp 0/0_cv 1.98 % 1.17 % 4 -BuildTypeNameSim 0/0_mean 7.74 ns 7.76 ns 4 -BuildTypeNameSim 0/0_median 7.81 ns 7.76 ns 4 -BuildTypeNameSim 0/0_stddev 0.181 ns 0.225 ns 4 -BuildTypeNameSim 0/0_cv 2.34 % 2.90 % 4 -BuildTypeNameStr 10/10_mean 58.7 ns 58.6 ns 4 -BuildTypeNameStr 10/10_median 58.8 ns 58.6 ns 4 -BuildTypeNameStr 10/10_stddev 0.838 ns 1.14 ns 4 -BuildTypeNameStr 10/10_cv 1.43 % 1.94 % 4 -BuildTypeNameExp 10/10_mean 32.2 ns 32.3 ns 4 -BuildTypeNameExp 10/10_median 32.4 ns 32.4 ns 4 -BuildTypeNameExp 10/10_stddev 0.808 ns 0.668 ns 4 -BuildTypeNameExp 10/10_cv 2.51 % 2.07 % 4 -BuildTypeNameSim 10/10_mean 25.3 ns 25.3 ns 4 -BuildTypeNameSim 10/10_median 25.2 ns 25.1 ns 4 -BuildTypeNameSim 10/10_stddev 0.497 ns 0.279 ns 4 -BuildTypeNameSim 10/10_cv 1.96 % 1.10 % 4 +BuildTypeNameStr 0/0_mean 8.48 ns 8.50 ns 4 +BuildTypeNameStr 0/0_median 8.34 ns 8.28 ns 4 +BuildTypeNameStr 0/0_stddev 0.433 ns 0.501 ns 4 +BuildTypeNameStr 0/0_cv 5.11 % 5.89 % 4 +BuildTypeNameExp 0/0_mean 7.64 ns 7.64 ns 4 +BuildTypeNameExp 0/0_median 7.48 ns 7.53 ns 4 +BuildTypeNameExp 0/0_stddev 0.470 ns 0.432 ns 4 +BuildTypeNameExp 0/0_cv 6.15 % 5.65 % 4 +BuildTypeNameSim 0/0_mean 7.75 ns 7.72 ns 4 +BuildTypeNameSim 0/0_median 7.73 ns 7.67 ns 4 +BuildTypeNameSim 0/0_stddev 0.190 ns 0.219 ns 4 +BuildTypeNameSim 0/0_cv 2.45 % 2.84 % 4 +BuildTypeNameStr 10/10_mean 59.6 ns 59.8 ns 4 +BuildTypeNameStr 10/10_median 59.9 ns 60.2 ns 4 +BuildTypeNameStr 10/10_stddev 1.68 ns 1.50 ns 4 +BuildTypeNameStr 10/10_cv 2.82 % 2.50 % 4 +BuildTypeNameExp 10/10_mean 33.3 ns 33.2 ns 4 +BuildTypeNameExp 10/10_median 33.6 ns 33.4 ns 4 +BuildTypeNameExp 10/10_stddev 0.948 ns 1.31 ns 4 +BuildTypeNameExp 10/10_cv 2.85 % 3.95 % 4 +BuildTypeNameSim 10/10_mean 25.6 ns 25.6 ns 4 +BuildTypeNameSim 10/10_median 25.5 ns 25.6 ns 4 +BuildTypeNameSim 10/10_stddev 0.498 ns 0.604 ns 4 +BuildTypeNameSim 10/10_cv 1.94 % 2.36 % 4 ----- Replace string by copy -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat with replace str_mean 309 ns 308 ns 4 -Concat with replace str_median 309 ns 308 ns 4 -Concat with replace str_stddev 3.50 ns 8.46 ns 4 -Concat with replace str_cv 1.13 % 2.75 % 4 -Concat with replace exp_mean 214 ns 214 ns 4 -Concat with replace exp_median 215 ns 215 ns 4 -Concat with replace exp_stddev 3.45 ns 2.44 ns 4 -Concat with replace exp_cv 1.61 % 1.14 % 4 +Concat with replace str_mean 308 ns 305 ns 4 +Concat with replace str_median 306 ns 303 ns 4 +Concat with replace str_stddev 5.60 ns 7.35 ns 4 +Concat with replace str_cv 1.82 % 2.41 % 4 +Concat with replace exp_mean 222 ns 222 ns 4 +Concat with replace exp_median 220 ns 220 ns 4 +Concat with replace exp_stddev 12.9 ns 12.3 ns 4 +Concat with replace exp_cv 5.81 % 5.53 % 4 ----- Create Empty Str ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e;_mean 1.09 ns 1.09 ns 4 -std::string e;_median 1.08 ns 1.09 ns 4 -std::string e;_stddev 0.023 ns 0.032 ns 4 -std::string e;_cv 2.09 % 2.90 % 4 -std::string_view e;_mean 0.364 ns 0.360 ns 4 -std::string_view e;_median 0.364 ns 0.356 ns 4 -std::string_view e;_stddev 0.009 ns 0.012 ns 4 -std::string_view e;_cv 2.39 % 3.29 % 4 -ssa e;_mean 0.360 ns 0.355 ns 4 -ssa e;_median 0.357 ns 0.353 ns 4 -ssa e;_stddev 0.010 ns 0.004 ns 4 -ssa e;_cv 2.68 % 1.13 % 4 -stringa e;_mean 0.733 ns 0.732 ns 4 -stringa e;_median 0.738 ns 0.732 ns 4 -stringa e;_stddev 0.013 ns 0.014 ns 4 -stringa e;_cv 1.74 % 1.94 % 4 -lstringa<20> e;_mean 1.09 ns 1.09 ns 4 -lstringa<20> e;_median 1.09 ns 1.09 ns 4 -lstringa<20> e;_stddev 0.021 ns 0.023 ns 4 -lstringa<20> e;_cv 1.96 % 2.14 % 4 +std::string e;_mean 1.14 ns 1.14 ns 4 +std::string e;_median 1.12 ns 1.12 ns 4 +std::string e;_stddev 0.062 ns 0.054 ns 4 +std::string e;_cv 5.40 % 4.74 % 4 +std::string_view e;_mean 0.372 ns 0.372 ns 4 +std::string_view e;_median 0.377 ns 0.377 ns 4 +std::string_view e;_stddev 0.016 ns 0.014 ns 4 +std::string_view e;_cv 4.26 % 3.89 % 4 +ssa e;_mean 0.359 ns 0.357 ns 4 +ssa e;_median 0.359 ns 0.357 ns 4 +ssa e;_stddev 0.007 ns 0.010 ns 4 +ssa e;_cv 1.97 % 2.90 % 4 +stringa e;_mean 0.736 ns 0.737 ns 4 +stringa e;_median 0.734 ns 0.732 ns 4 +stringa e;_stddev 0.017 ns 0.026 ns 4 +stringa e;_cv 2.24 % 3.55 % 4 +lstringa<20> e;_mean 1.11 ns 1.11 ns 4 +lstringa<20> e;_median 1.11 ns 1.12 ns 4 +lstringa<20> e;_stddev 0.020 ns 0.014 ns 4 +lstringa<20> e;_cv 1.75 % 1.26 % 4 lstringa<40> e;_mean 1.10 ns 1.10 ns 4 -lstringa<40> e;_median 1.10 ns 1.10 ns 4 -lstringa<40> e;_stddev 0.006 ns 0.012 ns 4 -lstringa<40> e;_cv 0.56 % 1.10 % 4 +lstringa<40> e;_median 1.11 ns 1.10 ns 4 +lstringa<40> e;_stddev 0.021 ns 0.012 ns 4 +lstringa<40> e;_cv 1.91 % 1.10 % 4 ----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "Test text";_mean 1.83 ns 1.83 ns 4 -std::string e = "Test text";_median 1.84 ns 1.84 ns 4 -std::string e = "Test text";_stddev 0.030 ns 0.021 ns 4 -std::string e = "Test text";_cv 1.64 % 1.14 % 4 -std::string_view e = "Test text";_mean 0.753 ns 0.750 ns 4 -std::string_view e = "Test text";_median 0.759 ns 0.750 ns 4 -std::string_view e = "Test text";_stddev 0.034 ns 0.045 ns 4 -std::string_view e = "Test text";_cv 4.51 % 6.00 % 4 -ssa e = "Test text";_mean 0.360 ns 0.359 ns 4 -ssa e = "Test text";_median 0.360 ns 0.357 ns 4 -ssa e = "Test text";_stddev 0.003 ns 0.008 ns 4 -ssa e = "Test text";_cv 0.90 % 2.14 % 4 -stringa e = "Test text";_mean 1.10 ns 1.09 ns 4 -stringa e = "Test text";_median 1.10 ns 1.10 ns 4 -stringa e = "Test text";_stddev 0.016 ns 0.020 ns 4 -stringa e = "Test text";_cv 1.49 % 1.83 % 4 -lstringa<20> e = "Test text";_mean 1.82 ns 1.81 ns 4 -lstringa<20> e = "Test text";_median 1.82 ns 1.80 ns 4 -lstringa<20> e = "Test text";_stddev 0.018 ns 0.019 ns 4 -lstringa<20> e = "Test text";_cv 0.97 % 1.06 % 4 -lstringa<40> e = "Test text";_mean 1.82 ns 1.82 ns 4 -lstringa<40> e = "Test text";_median 1.82 ns 1.82 ns 4 -lstringa<40> e = "Test text";_stddev 0.015 ns 0.022 ns 4 -lstringa<40> e = "Test text";_cv 0.81 % 1.22 % 4 +std::string e = "Test text";_mean 1.81 ns 1.81 ns 4 +std::string e = "Test text";_median 1.81 ns 1.80 ns 4 +std::string e = "Test text";_stddev 0.020 ns 0.058 ns 4 +std::string e = "Test text";_cv 1.11 % 3.17 % 4 +std::string_view e = "Test text";_mean 0.734 ns 0.736 ns 4 +std::string_view e = "Test text";_median 0.728 ns 0.725 ns 4 +std::string_view e = "Test text";_stddev 0.021 ns 0.021 ns 4 +std::string_view e = "Test text";_cv 2.80 % 2.84 % 4 +ssa e = "Test text";_mean 0.364 ns 0.364 ns 4 +ssa e = "Test text";_median 0.363 ns 0.364 ns 4 +ssa e = "Test text";_stddev 0.006 ns 0.005 ns 4 +ssa e = "Test text";_cv 1.62 % 1.33 % 4 +stringa e = "Test text";_mean 1.11 ns 1.11 ns 4 +stringa e = "Test text";_median 1.11 ns 1.11 ns 4 +stringa e = "Test text";_stddev 0.016 ns 0.014 ns 4 +stringa e = "Test text";_cv 1.40 % 1.27 % 4 +lstringa<20> e = "Test text";_mean 1.87 ns 1.87 ns 4 +lstringa<20> e = "Test text";_median 1.87 ns 1.88 ns 4 +lstringa<20> e = "Test text";_stddev 0.055 ns 0.048 ns 4 +lstringa<20> e = "Test text";_cv 2.96 % 2.58 % 4 +lstringa<40> e = "Test text";_mean 1.94 ns 1.93 ns 4 +lstringa<40> e = "Test text";_median 1.92 ns 1.90 ns 4 +lstringa<40> e = "Test text";_stddev 0.080 ns 0.059 ns 4 +lstringa<40> e = "Test text";_cv 4.11 % 3.07 % 4 ----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "123456789012345678901234567890";_mean 73.4 ns 73.7 ns 4 -std::string e = "123456789012345678901234567890";_median 73.5 ns 74.1 ns 4 -std::string e = "123456789012345678901234567890";_stddev 1.29 ns 1.67 ns 4 -std::string e = "123456789012345678901234567890";_cv 1.75 % 2.27 % 4 -std::string_view e = "123456789012345678901234567890";_mean 0.729 ns 0.732 ns 4 -std::string_view e = "123456789012345678901234567890";_median 0.731 ns 0.739 ns 4 -std::string_view e = "123456789012345678901234567890";_stddev 0.008 ns 0.014 ns 4 -std::string_view e = "123456789012345678901234567890";_cv 1.10 % 1.90 % 4 -ssa e = "123456789012345678901234567890";_mean 0.364 ns 0.361 ns 4 -ssa e = "123456789012345678901234567890";_median 0.363 ns 0.361 ns 4 +std::string e = "123456789012345678901234567890";_mean 73.4 ns 73.2 ns 4 +std::string e = "123456789012345678901234567890";_median 73.3 ns 73.2 ns 4 +std::string e = "123456789012345678901234567890";_stddev 0.800 ns 0.000 ns 4 +std::string e = "123456789012345678901234567890";_cv 1.09 % 0.00 % 4 +std::string_view e = "123456789012345678901234567890";_mean 0.750 ns 0.750 ns 4 +std::string_view e = "123456789012345678901234567890";_median 0.735 ns 0.732 ns 4 +std::string_view e = "123456789012345678901234567890";_stddev 0.035 ns 0.040 ns 4 +std::string_view e = "123456789012345678901234567890";_cv 4.65 % 5.34 % 4 +ssa e = "123456789012345678901234567890";_mean 0.360 ns 0.361 ns 4 +ssa e = "123456789012345678901234567890";_median 0.361 ns 0.361 ns 4 ssa e = "123456789012345678901234567890";_stddev 0.005 ns 0.007 ns 4 -ssa e = "123456789012345678901234567890";_cv 1.28 % 1.81 % 4 -stringa e = "123456789012345678901234567890";_mean 1.08 ns 1.09 ns 4 -stringa e = "123456789012345678901234567890";_median 1.09 ns 1.09 ns 4 -stringa e = "123456789012345678901234567890";_stddev 0.020 ns 0.014 ns 4 -stringa e = "123456789012345678901234567890";_cv 1.80 % 1.30 % 4 -lstringa<20> e = "123456789012345678901234567890";_mean 74.8 ns 74.6 ns 4 -lstringa<20> e = "123456789012345678901234567890";_median 74.2 ns 74.1 ns 4 -lstringa<20> e = "123456789012345678901234567890";_stddev 1.24 ns 1.67 ns 4 -lstringa<20> e = "123456789012345678901234567890";_cv 1.66 % 2.24 % 4 -lstringa<40> e = "123456789012345678901234567890";_mean 2.56 ns 2.55 ns 4 -lstringa<40> e = "123456789012345678901234567890";_median 2.57 ns 2.55 ns 4 -lstringa<40> e = "123456789012345678901234567890";_stddev 0.058 ns 0.048 ns 4 -lstringa<40> e = "123456789012345678901234567890";_cv 2.25 % 1.90 % 4 +ssa e = "123456789012345678901234567890";_cv 1.33 % 1.81 % 4 +stringa e = "123456789012345678901234567890";_mean 1.08 ns 1.07 ns 4 +stringa e = "123456789012345678901234567890";_median 1.09 ns 1.07 ns 4 +stringa e = "123456789012345678901234567890";_stddev 0.015 ns 0.010 ns 4 +stringa e = "123456789012345678901234567890";_cv 1.41 % 0.98 % 4 +lstringa<20> e = "123456789012345678901234567890";_mean 73.6 ns 73.2 ns 4 +lstringa<20> e = "123456789012345678901234567890";_median 73.5 ns 73.2 ns 4 +lstringa<20> e = "123456789012345678901234567890";_stddev 0.402 ns 1.42 ns 4 +lstringa<20> e = "123456789012345678901234567890";_cv 0.55 % 1.94 % 4 +lstringa<40> e = "123456789012345678901234567890";_mean 2.50 ns 2.48 ns 4 +lstringa<40> e = "123456789012345678901234567890";_median 2.49 ns 2.48 ns 4 +lstringa<40> e = "123456789012345678901234567890";_stddev 0.045 ns 0.032 ns 4 +lstringa<40> e = "123456789012345678901234567890";_cv 1.80 % 1.30 % 4 ----- Create copy of Str with 9 symbols ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 std::string e = "Test text"; auto c{e};_mean 1.82 ns 1.81 ns 4 std::string e = "Test text"; auto c{e};_median 1.81 ns 1.80 ns 4 -std::string e = "Test text"; auto c{e};_stddev 0.027 ns 0.019 ns 4 -std::string e = "Test text"; auto c{e};_cv 1.50 % 1.06 % 4 -std::string_view e = "Test text"; auto c{e};_mean 0.363 ns 0.363 ns 4 -std::string_view e = "Test text"; auto c{e};_median 0.363 ns 0.365 ns 4 -std::string_view e = "Test text"; auto c{e};_stddev 0.004 ns 0.008 ns 4 -std::string_view e = "Test text"; auto c{e};_cv 0.97 % 2.12 % 4 -ssa e = "Test text"; auto c{e};_mean 0.363 ns 0.363 ns 4 -ssa e = "Test text"; auto c{e};_median 0.364 ns 0.361 ns 4 -ssa e = "Test text"; auto c{e};_stddev 0.004 ns 0.004 ns 4 -ssa e = "Test text"; auto c{e};_cv 1.21 % 1.10 % 4 -stringa e = "Test text"; auto c{e};_mean 1.28 ns 1.28 ns 4 -stringa e = "Test text"; auto c{e};_median 1.27 ns 1.28 ns 4 -stringa e = "Test text"; auto c{e};_stddev 0.034 ns 0.032 ns 4 -stringa e = "Test text"; auto c{e};_cv 2.65 % 2.51 % 4 -lstringa<20> e = "Test text"; auto c{e};_mean 1.46 ns 1.45 ns 4 -lstringa<20> e = "Test text"; auto c{e};_median 1.46 ns 1.46 ns 4 -lstringa<20> e = "Test text"; auto c{e};_stddev 0.022 ns 0.030 ns 4 -lstringa<20> e = "Test text"; auto c{e};_cv 1.49 % 2.07 % 4 -lstringa<40> e = "Test text"; auto c{e};_mean 1.46 ns 1.47 ns 4 +std::string e = "Test text"; auto c{e};_stddev 0.013 ns 0.021 ns 4 +std::string e = "Test text"; auto c{e};_cv 0.70 % 1.16 % 4 +std::string_view e = "Test text"; auto c{e};_mean 0.363 ns 0.358 ns 4 +std::string_view e = "Test text"; auto c{e};_median 0.362 ns 0.360 ns 4 +std::string_view e = "Test text"; auto c{e};_stddev 0.005 ns 0.004 ns 4 +std::string_view e = "Test text"; auto c{e};_cv 1.35 % 1.17 % 4 +ssa e = "Test text"; auto c{e};_mean 0.366 ns 0.367 ns 4 +ssa e = "Test text"; auto c{e};_median 0.366 ns 0.365 ns 4 +ssa e = "Test text"; auto c{e};_stddev 0.005 ns 0.008 ns 4 +ssa e = "Test text"; auto c{e};_cv 1.43 % 2.09 % 4 +stringa e = "Test text"; auto c{e};_mean 1.28 ns 1.29 ns 4 +stringa e = "Test text"; auto c{e};_median 1.28 ns 1.27 ns 4 +stringa e = "Test text"; auto c{e};_stddev 0.028 ns 0.044 ns 4 +stringa e = "Test text"; auto c{e};_cv 2.21 % 3.45 % 4 +lstringa<20> e = "Test text"; auto c{e};_mean 1.50 ns 1.48 ns 4 +lstringa<20> e = "Test text"; auto c{e};_median 1.50 ns 1.49 ns 4 +lstringa<20> e = "Test text"; auto c{e};_stddev 0.020 ns 0.030 ns 4 +lstringa<20> e = "Test text"; auto c{e};_cv 1.32 % 2.03 % 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.47 ns 1.48 ns 4 -lstringa<40> e = "Test text"; auto c{e};_stddev 0.030 ns 0.047 ns 4 -lstringa<40> e = "Test text"; auto c{e};_cv 2.03 % 3.21 % 4 +lstringa<40> e = "Test text"; auto c{e};_stddev 0.044 ns 0.047 ns 4 +lstringa<40> e = "Test text"; auto c{e};_cv 3.02 % 3.21 % 4 ----- Create copy of Str with 30 symbols ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "123456789012345678901234567890"; auto c{e};_mean 74.7 ns 74.6 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_median 74.6 ns 74.1 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_stddev 0.952 ns 1.67 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_cv 1.27 % 2.24 % 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.732 ns 0.732 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.734 ns 0.732 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.013 ns 0.014 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 1.72 % 1.94 % 4 -ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.368 ns 0.366 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_median 0.369 ns 0.368 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.007 ns 0.010 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_cv 1.82 % 2.64 % 4 -stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.80 ns 1.79 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_median 1.80 ns 1.80 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.029 ns 0.021 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.61 % 1.17 % 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 73.7 ns 73.7 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 73.7 ns 74.1 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 1.44 ns 1.67 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 1.95 % 2.27 % 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.79 ns 4.81 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.82 ns 4.81 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.097 ns 0.140 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 2.03 % 2.90 % 4 +std::string e = "123456789012345678901234567890"; auto c{e};_mean 75.8 ns 75.9 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_median 76.6 ns 76.4 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_stddev 2.37 ns 2.00 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_cv 3.13 % 2.64 % 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 0.735 ns 0.737 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_median 0.738 ns 0.741 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.025 ns 0.030 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 3.40 % 4.04 % 4 +ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.361 ns 0.359 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_median 0.362 ns 0.357 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.007 ns 0.008 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_cv 1.85 % 2.14 % 4 +stringa e = "123456789012345678901234567890"; auto c{e};_mean 1.82 ns 1.82 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_median 1.81 ns 1.82 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.030 ns 0.050 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.68 % 2.72 % 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 75.1 ns 75.0 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 74.9 ns 75.0 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 1.12 ns 1.42 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 1.50 % 1.90 % 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 4.73 ns 4.71 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 4.71 ns 4.74 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.122 ns 0.176 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 2.58 % 3.73 % 4 ----- Find 9 symbols text in end of 99 symbols text ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string::find;_mean 38.5 ns 38.1 ns 4 -std::string::find;_median 38.6 ns 38.4 ns 4 -std::string::find;_stddev 0.485 ns 0.436 ns 4 -std::string::find;_cv 1.26 % 1.14 % 4 -std::string_view::find;_mean 37.7 ns 37.7 ns 4 -std::string_view::find;_median 37.7 ns 37.7 ns 4 -std::string_view::find;_stddev 0.142 ns 0.683 ns 4 -std::string_view::find;_cv 0.38 % 1.81 % 4 -ssa::find;_mean 17.5 ns 17.5 ns 4 -ssa::find;_median 17.3 ns 17.3 ns 4 -ssa::find;_stddev 0.518 ns 0.665 ns 4 -ssa::find;_cv 2.97 % 3.81 % 4 -stringa::find;_mean 17.9 ns 17.8 ns 4 -stringa::find;_median 17.9 ns 17.8 ns 4 -stringa::find;_stddev 0.221 ns 0.495 ns 4 -stringa::find;_cv 1.23 % 2.78 % 4 -lstringa<20>::find;_mean 18.2 ns 18.1 ns 4 -lstringa<20>::find;_median 18.1 ns 18.0 ns 4 -lstringa<20>::find;_stddev 0.260 ns 0.209 ns 4 -lstringa<20>::find;_cv 1.43 % 1.16 % 4 -lstringa<40>::find;_mean 17.5 ns 17.5 ns 4 -lstringa<40>::find;_median 17.5 ns 17.5 ns 4 -lstringa<40>::find;_stddev 0.310 ns 0.222 ns 4 -lstringa<40>::find;_cv 1.77 % 1.27 % 4 +sz::string::find;_mean 98.8 ns 98.9 ns 4 +sz::string::find;_median 97.9 ns 98.9 ns 4 +sz::string::find;_stddev 2.01 ns 3.15 ns 4 +sz::string::find;_cv 2.03 % 3.19 % 4 +std::string::find;_mean 39.3 ns 39.2 ns 4 +std::string::find;_median 39.3 ns 39.4 ns 4 +std::string::find;_stddev 0.447 ns 0.868 ns 4 +std::string::find;_cv 1.14 % 2.21 % 4 +std::string_view::find;_mean 52.1 ns 52.0 ns 4 +std::string_view::find;_median 52.0 ns 51.6 ns 4 +std::string_view::find;_stddev 0.931 ns 0.781 ns 4 +std::string_view::find;_cv 1.79 % 1.50 % 4 +ssa::find;_mean 19.5 ns 19.4 ns 4 +ssa::find;_median 19.5 ns 19.2 ns 4 +ssa::find;_stddev 0.850 ns 0.735 ns 4 +ssa::find;_cv 4.35 % 3.79 % 4 +stringa::find;_mean 18.9 ns 18.9 ns 4 +stringa::find;_median 18.7 ns 18.8 ns 4 +stringa::find;_stddev 0.307 ns 0.434 ns 4 +stringa::find;_cv 1.63 % 2.29 % 4 +lstringa<20>::find;_mean 17.6 ns 17.6 ns 4 +lstringa<20>::find;_median 17.6 ns 17.6 ns 4 +lstringa<20>::find;_stddev 0.363 ns 0.192 ns 4 +lstringa<20>::find;_cv 2.07 % 1.09 % 4 +lstringa<40>::find;_mean 18.2 ns 18.1 ns 4 +lstringa<40>::find;_median 18.2 ns 18.2 ns 4 +lstringa<40>::find;_stddev 0.304 ns 0.367 ns 4 +lstringa<40>::find;_cv 1.67 % 2.03 % 4 ------- Copy not literal Str with N symbols ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 std::string copy{str_with_len_N};/15_mean 1.83 ns 1.83 ns 4 std::string copy{str_with_len_N};/15_median 1.83 ns 1.84 ns 4 -std::string copy{str_with_len_N};/15_stddev 0.015 ns 0.019 ns 4 -std::string copy{str_with_len_N};/15_cv 0.81 % 1.05 % 4 -std::string copy{str_with_len_N};/16_mean 77.7 ns 77.6 ns 4 -std::string copy{str_with_len_N};/16_median 77.7 ns 77.6 ns 4 -std::string copy{str_with_len_N};/16_stddev 1.33 ns 1.01 ns 4 -std::string copy{str_with_len_N};/16_cv 1.71 % 1.30 % 4 -std::string copy{str_with_len_N};/23_mean 76.4 ns 76.3 ns 4 -std::string copy{str_with_len_N};/23_median 76.3 ns 75.9 ns 4 -std::string copy{str_with_len_N};/23_stddev 1.43 ns 1.67 ns 4 -std::string copy{str_with_len_N};/23_cv 1.88 % 2.19 % 4 -std::string copy{str_with_len_N};/24_mean 77.9 ns 78.1 ns 4 -std::string copy{str_with_len_N};/24_median 78.0 ns 78.1 ns 4 -std::string copy{str_with_len_N};/24_stddev 0.821 ns 1.61 ns 4 -std::string copy{str_with_len_N};/24_cv 1.05 % 2.06 % 4 -std::string copy{str_with_len_N};/32_mean 81.7 ns 81.1 ns 4 -std::string copy{str_with_len_N};/32_median 81.8 ns 82.0 ns 4 -std::string copy{str_with_len_N};/32_stddev 2.01 ns 1.74 ns 4 -std::string copy{str_with_len_N};/32_cv 2.46 % 2.15 % 4 -std::string copy{str_with_len_N};/64_mean 84.6 ns 84.2 ns 4 -std::string copy{str_with_len_N};/64_median 84.8 ns 84.8 ns 4 -std::string copy{str_with_len_N};/64_stddev 1.84 ns 2.00 ns 4 -std::string copy{str_with_len_N};/64_cv 2.18 % 2.38 % 4 -std::string copy{str_with_len_N};/128_mean 85.5 ns 85.4 ns 4 -std::string copy{str_with_len_N};/128_median 85.6 ns 85.4 ns 4 -std::string copy{str_with_len_N};/128_stddev 0.807 ns 1.42 ns 4 -std::string copy{str_with_len_N};/128_cv 0.94 % 1.67 % 4 -std::string copy{str_with_len_N};/256_mean 84.3 ns 84.2 ns 4 -std::string copy{str_with_len_N};/256_median 84.3 ns 84.8 ns 4 -std::string copy{str_with_len_N};/256_stddev 1.94 ns 2.00 ns 4 -std::string copy{str_with_len_N};/256_cv 2.30 % 2.38 % 4 -std::string copy{str_with_len_N};/512_mean 88.0 ns 87.9 ns 4 -std::string copy{str_with_len_N};/512_median 87.7 ns 87.9 ns 4 -std::string copy{str_with_len_N};/512_stddev 2.24 ns 1.71 ns 4 -std::string copy{str_with_len_N};/512_cv 2.54 % 1.94 % 4 -std::string copy{str_with_len_N};/1024_mean 104 ns 104 ns 4 -std::string copy{str_with_len_N};/1024_median 99.8 ns 99.4 ns 4 -std::string copy{str_with_len_N};/1024_stddev 12.3 ns 10.6 ns 4 -std::string copy{str_with_len_N};/1024_cv 11.79 % 10.23 % 4 -std::string copy{str_with_len_N};/2048_mean 131 ns 130 ns 4 -std::string copy{str_with_len_N};/2048_median 132 ns 128 ns 4 -std::string copy{str_with_len_N};/2048_stddev 6.89 ns 6.19 ns 4 -std::string copy{str_with_len_N};/2048_cv 5.24 % 4.74 % 4 -std::string copy{str_with_len_N};/4096_mean 178 ns 177 ns 4 -std::string copy{str_with_len_N};/4096_median 177 ns 178 ns 4 -std::string copy{str_with_len_N};/4096_stddev 4.97 ns 4.01 ns 4 -std::string copy{str_with_len_N};/4096_cv 2.80 % 2.27 % 4 -stringa copy{str_with_len_N};/15_mean 1.27 ns 1.27 ns 4 -stringa copy{str_with_len_N};/15_median 1.27 ns 1.28 ns 4 -stringa copy{str_with_len_N};/15_stddev 0.021 ns 0.028 ns 4 -stringa copy{str_with_len_N};/15_cv 1.61 % 2.20 % 4 -stringa copy{str_with_len_N};/16_mean 1.28 ns 1.28 ns 4 -stringa copy{str_with_len_N};/16_median 1.29 ns 1.28 ns 4 -stringa copy{str_with_len_N};/16_stddev 0.023 ns 0.035 ns 4 -stringa copy{str_with_len_N};/16_cv 1.81 % 2.75 % 4 -stringa copy{str_with_len_N};/23_mean 1.28 ns 1.28 ns 4 -stringa copy{str_with_len_N};/23_median 1.27 ns 1.26 ns 4 -stringa copy{str_with_len_N};/23_stddev 0.034 ns 0.047 ns 4 -stringa copy{str_with_len_N};/23_cv 2.64 % 3.68 % 4 +std::string copy{str_with_len_N};/15_stddev 0.053 ns 0.058 ns 4 +std::string copy{str_with_len_N};/15_cv 2.89 % 3.14 % 4 +std::string copy{str_with_len_N};/16_mean 80.8 ns 80.6 ns 4 +std::string copy{str_with_len_N};/16_median 77.5 ns 77.4 ns 4 +std::string copy{str_with_len_N};/16_stddev 7.70 ns 7.76 ns 4 +std::string copy{str_with_len_N};/16_cv 9.53 % 9.63 % 4 +std::string copy{str_with_len_N};/23_mean 78.3 ns 78.1 ns 4 +std::string copy{str_with_len_N};/23_median 78.5 ns 78.1 ns 4 +std::string copy{str_with_len_N};/23_stddev 1.62 ns 1.61 ns 4 +std::string copy{str_with_len_N};/23_cv 2.07 % 2.06 % 4 +std::string copy{str_with_len_N};/24_mean 78.5 ns 78.5 ns 4 +std::string copy{str_with_len_N};/24_median 78.0 ns 78.5 ns 4 +std::string copy{str_with_len_N};/24_stddev 1.27 ns 1.42 ns 4 +std::string copy{str_with_len_N};/24_cv 1.62 % 1.81 % 4 +std::string copy{str_with_len_N};/32_mean 81.8 ns 82.0 ns 4 +std::string copy{str_with_len_N};/32_median 81.9 ns 82.8 ns 4 +std::string copy{str_with_len_N};/32_stddev 2.16 ns 2.47 ns 4 +std::string copy{str_with_len_N};/32_cv 2.64 % 3.01 % 4 +std::string copy{str_with_len_N};/64_mean 82.8 ns 83.2 ns 4 +std::string copy{str_with_len_N};/64_median 83.2 ns 83.7 ns 4 +std::string copy{str_with_len_N};/64_stddev 4.62 ns 4.64 ns 4 +std::string copy{str_with_len_N};/64_cv 5.58 % 5.58 % 4 +std::string copy{str_with_len_N};/128_mean 82.6 ns 82.8 ns 4 +std::string copy{str_with_len_N};/128_median 82.8 ns 83.7 ns 4 +std::string copy{str_with_len_N};/128_stddev 1.46 ns 1.74 ns 4 +std::string copy{str_with_len_N};/128_cv 1.77 % 2.11 % 4 +std::string copy{str_with_len_N};/256_mean 85.0 ns 83.7 ns 4 +std::string copy{str_with_len_N};/256_median 85.2 ns 83.7 ns 4 +std::string copy{str_with_len_N};/256_stddev 1.69 ns 1.71 ns 4 +std::string copy{str_with_len_N};/256_cv 1.98 % 2.04 % 4 +std::string copy{str_with_len_N};/512_mean 86.5 ns 86.8 ns 4 +std::string copy{str_with_len_N};/512_median 86.3 ns 86.3 ns 4 +std::string copy{str_with_len_N};/512_stddev 0.681 ns 1.67 ns 4 +std::string copy{str_with_len_N};/512_cv 0.79 % 1.92 % 4 +std::string copy{str_with_len_N};/1024_mean 95.3 ns 95.7 ns 4 +std::string copy{str_with_len_N};/1024_median 95.6 ns 96.3 ns 4 +std::string copy{str_with_len_N};/1024_stddev 1.19 ns 1.05 ns 4 +std::string copy{str_with_len_N};/1024_cv 1.25 % 1.09 % 4 +std::string copy{str_with_len_N};/2048_mean 133 ns 133 ns 4 +std::string copy{str_with_len_N};/2048_median 132 ns 133 ns 4 +std::string copy{str_with_len_N};/2048_stddev 5.46 ns 4.05 ns 4 +std::string copy{str_with_len_N};/2048_cv 4.11 % 3.04 % 4 +std::string copy{str_with_len_N};/4096_mean 179 ns 177 ns 4 +std::string copy{str_with_len_N};/4096_median 176 ns 175 ns 4 +std::string copy{str_with_len_N};/4096_stddev 7.28 ns 7.26 ns 4 +std::string copy{str_with_len_N};/4096_cv 4.08 % 4.09 % 4 +stringa copy{str_with_len_N};/15_mean 1.29 ns 1.29 ns 4 +stringa copy{str_with_len_N};/15_median 1.28 ns 1.29 ns 4 +stringa copy{str_with_len_N};/15_stddev 0.020 ns 0.026 ns 4 +stringa copy{str_with_len_N};/15_cv 1.58 % 1.99 % 4 +stringa copy{str_with_len_N};/16_mean 1.32 ns 1.32 ns 4 +stringa copy{str_with_len_N};/16_median 1.33 ns 1.33 ns 4 +stringa copy{str_with_len_N};/16_stddev 0.039 ns 0.048 ns 4 +stringa copy{str_with_len_N};/16_cv 2.93 % 3.61 % 4 +stringa copy{str_with_len_N};/23_mean 1.29 ns 1.29 ns 4 +stringa copy{str_with_len_N};/23_median 1.29 ns 1.30 ns 4 +stringa copy{str_with_len_N};/23_stddev 0.024 ns 0.027 ns 4 +stringa copy{str_with_len_N};/23_cv 1.85 % 2.07 % 4 stringa copy{str_with_len_N};/24_mean 15.8 ns 15.8 ns 4 -stringa copy{str_with_len_N};/24_median 15.8 ns 15.9 ns 4 -stringa copy{str_with_len_N};/24_stddev 0.109 ns 0.334 ns 4 -stringa copy{str_with_len_N};/24_cv 0.69 % 2.12 % 4 +stringa copy{str_with_len_N};/24_median 15.7 ns 15.7 ns 4 +stringa copy{str_with_len_N};/24_stddev 0.168 ns 0.174 ns 4 +stringa copy{str_with_len_N};/24_cv 1.07 % 1.10 % 4 stringa copy{str_with_len_N};/32_mean 15.8 ns 15.7 ns 4 stringa copy{str_with_len_N};/32_median 15.8 ns 15.7 ns 4 -stringa copy{str_with_len_N};/32_stddev 0.054 ns 0.000 ns 4 -stringa copy{str_with_len_N};/32_cv 0.34 % 0.00 % 4 -stringa copy{str_with_len_N};/64_mean 15.8 ns 15.8 ns 4 +stringa copy{str_with_len_N};/32_stddev 0.085 ns 0.285 ns 4 +stringa copy{str_with_len_N};/32_cv 0.54 % 1.81 % 4 +stringa copy{str_with_len_N};/64_mean 15.8 ns 15.7 ns 4 stringa copy{str_with_len_N};/64_median 15.7 ns 15.7 ns 4 -stringa copy{str_with_len_N};/64_stddev 0.095 ns 0.174 ns 4 -stringa copy{str_with_len_N};/64_cv 0.60 % 1.10 % 4 -stringa copy{str_with_len_N};/128_mean 15.8 ns 15.9 ns 4 -stringa copy{str_with_len_N};/128_median 15.8 ns 15.9 ns 4 -stringa copy{str_with_len_N};/128_stddev 0.128 ns 0.201 ns 4 -stringa copy{str_with_len_N};/128_cv 0.81 % 1.27 % 4 +stringa copy{str_with_len_N};/64_stddev 0.157 ns 0.000 ns 4 +stringa copy{str_with_len_N};/64_cv 0.99 % 0.00 % 4 +stringa copy{str_with_len_N};/128_mean 15.7 ns 15.7 ns 4 +stringa copy{str_with_len_N};/128_median 15.8 ns 15.7 ns 4 +stringa copy{str_with_len_N};/128_stddev 0.082 ns 0.285 ns 4 +stringa copy{str_with_len_N};/128_cv 0.52 % 1.81 % 4 stringa copy{str_with_len_N};/256_mean 15.8 ns 15.7 ns 4 stringa copy{str_with_len_N};/256_median 15.8 ns 15.7 ns 4 -stringa copy{str_with_len_N};/256_stddev 0.130 ns 0.285 ns 4 -stringa copy{str_with_len_N};/256_cv 0.82 % 1.81 % 4 -stringa copy{str_with_len_N};/512_mean 15.8 ns 15.7 ns 4 -stringa copy{str_with_len_N};/512_median 15.8 ns 15.7 ns 4 -stringa copy{str_with_len_N};/512_stddev 0.066 ns 0.000 ns 4 -stringa copy{str_with_len_N};/512_cv 0.42 % 0.00 % 4 -stringa copy{str_with_len_N};/1024_mean 15.9 ns 15.8 ns 4 -stringa copy{str_with_len_N};/1024_median 15.9 ns 15.9 ns 4 -stringa copy{str_with_len_N};/1024_stddev 0.152 ns 0.367 ns 4 -stringa copy{str_with_len_N};/1024_cv 0.96 % 2.32 % 4 -stringa copy{str_with_len_N};/2048_mean 15.8 ns 15.8 ns 4 +stringa copy{str_with_len_N};/256_stddev 0.060 ns 0.000 ns 4 +stringa copy{str_with_len_N};/256_cv 0.38 % 0.00 % 4 +stringa copy{str_with_len_N};/512_mean 15.7 ns 15.7 ns 4 +stringa copy{str_with_len_N};/512_median 15.7 ns 15.7 ns 4 +stringa copy{str_with_len_N};/512_stddev 0.021 ns 0.000 ns 4 +stringa copy{str_with_len_N};/512_cv 0.13 % 0.00 % 4 +stringa copy{str_with_len_N};/1024_mean 15.8 ns 15.8 ns 4 +stringa copy{str_with_len_N};/1024_median 15.8 ns 15.7 ns 4 +stringa copy{str_with_len_N};/1024_stddev 0.108 ns 0.174 ns 4 +stringa copy{str_with_len_N};/1024_cv 0.69 % 1.10 % 4 +stringa copy{str_with_len_N};/2048_mean 16.8 ns 16.7 ns 4 stringa copy{str_with_len_N};/2048_median 15.8 ns 15.7 ns 4 -stringa copy{str_with_len_N};/2048_stddev 0.094 ns 0.174 ns 4 -stringa copy{str_with_len_N};/2048_cv 0.60 % 1.10 % 4 -stringa copy{str_with_len_N};/4096_mean 15.8 ns 15.8 ns 4 +stringa copy{str_with_len_N};/2048_stddev 2.13 ns 2.33 ns 4 +stringa copy{str_with_len_N};/2048_cv 12.68 % 13.92 % 4 +stringa copy{str_with_len_N};/4096_mean 15.7 ns 15.7 ns 4 stringa copy{str_with_len_N};/4096_median 15.8 ns 15.7 ns 4 -stringa copy{str_with_len_N};/4096_stddev 0.113 ns 0.174 ns 4 -stringa copy{str_with_len_N};/4096_cv 0.72 % 1.10 % 4 +stringa copy{str_with_len_N};/4096_stddev 0.078 ns 0.313 ns 4 +stringa copy{str_with_len_N};/4096_cv 0.49 % 1.99 % 4 lstringa<16> copy{str_with_len_N};/15_mean 1.50 ns 1.51 ns 4 lstringa<16> copy{str_with_len_N};/15_median 1.50 ns 1.51 ns 4 -lstringa<16> copy{str_with_len_N};/15_stddev 0.029 ns 0.026 ns 4 -lstringa<16> copy{str_with_len_N};/15_cv 1.92 % 1.70 % 4 -lstringa<16> copy{str_with_len_N};/16_mean 5.06 ns 5.08 ns 4 -lstringa<16> copy{str_with_len_N};/16_median 4.98 ns 5.00 ns 4 -lstringa<16> copy{str_with_len_N};/16_stddev 0.202 ns 0.156 ns 4 -lstringa<16> copy{str_with_len_N};/16_cv 3.98 % 3.08 % 4 -lstringa<16> copy{str_with_len_N};/23_mean 5.09 ns 5.12 ns 4 -lstringa<16> copy{str_with_len_N};/23_median 5.06 ns 5.16 ns 4 -lstringa<16> copy{str_with_len_N};/23_stddev 0.061 ns 0.078 ns 4 -lstringa<16> copy{str_with_len_N};/23_cv 1.20 % 1.53 % 4 -lstringa<16> copy{str_with_len_N};/24_mean 75.9 ns 75.9 ns 4 -lstringa<16> copy{str_with_len_N};/24_median 76.3 ns 75.9 ns 4 -lstringa<16> copy{str_with_len_N};/24_stddev 2.18 ns 2.25 ns 4 -lstringa<16> copy{str_with_len_N};/24_cv 2.88 % 2.97 % 4 -lstringa<16> copy{str_with_len_N};/32_mean 78.1 ns 78.1 ns 4 -lstringa<16> copy{str_with_len_N};/32_median 78.0 ns 78.1 ns 4 -lstringa<16> copy{str_with_len_N};/32_stddev 2.17 ns 2.28 ns 4 -lstringa<16> copy{str_with_len_N};/32_cv 2.78 % 2.92 % 4 -lstringa<16> copy{str_with_len_N};/64_mean 80.4 ns 79.3 ns 4 -lstringa<16> copy{str_with_len_N};/64_median 80.7 ns 79.3 ns 4 -lstringa<16> copy{str_with_len_N};/64_stddev 1.99 ns 2.25 ns 4 -lstringa<16> copy{str_with_len_N};/64_cv 2.47 % 2.84 % 4 -lstringa<16> copy{str_with_len_N};/128_mean 82.0 ns 81.5 ns 4 -lstringa<16> copy{str_with_len_N};/128_median 82.1 ns 81.1 ns 4 -lstringa<16> copy{str_with_len_N};/128_stddev 1.74 ns 1.67 ns 4 -lstringa<16> copy{str_with_len_N};/128_cv 2.13 % 2.05 % 4 -lstringa<16> copy{str_with_len_N};/256_mean 83.4 ns 83.3 ns 4 -lstringa<16> copy{str_with_len_N};/256_median 83.4 ns 82.8 ns 4 -lstringa<16> copy{str_with_len_N};/256_stddev 1.47 ns 1.67 ns 4 -lstringa<16> copy{str_with_len_N};/256_cv 1.77 % 2.01 % 4 -lstringa<16> copy{str_with_len_N};/512_mean 84.4 ns 83.7 ns 4 -lstringa<16> copy{str_with_len_N};/512_median 84.2 ns 83.7 ns 4 -lstringa<16> copy{str_with_len_N};/512_stddev 1.76 ns 3.82 ns 4 -lstringa<16> copy{str_with_len_N};/512_cv 2.08 % 4.56 % 4 -lstringa<16> copy{str_with_len_N};/1024_mean 94.4 ns 94.7 ns 4 -lstringa<16> copy{str_with_len_N};/1024_median 94.2 ns 94.2 ns 4 -lstringa<16> copy{str_with_len_N};/1024_stddev 1.29 ns 1.05 ns 4 -lstringa<16> copy{str_with_len_N};/1024_cv 1.37 % 1.10 % 4 -lstringa<16> copy{str_with_len_N};/2048_mean 127 ns 127 ns 4 -lstringa<16> copy{str_with_len_N};/2048_median 129 ns 127 ns 4 -lstringa<16> copy{str_with_len_N};/2048_stddev 4.04 ns 3.60 ns 4 -lstringa<16> copy{str_with_len_N};/2048_cv 3.19 % 2.84 % 4 -lstringa<16> copy{str_with_len_N};/4096_mean 184 ns 183 ns 4 -lstringa<16> copy{str_with_len_N};/4096_median 184 ns 184 ns 4 -lstringa<16> copy{str_with_len_N};/4096_stddev 1.01 ns 5.27 ns 4 -lstringa<16> copy{str_with_len_N};/4096_cv 0.55 % 2.88 % 4 -lstringa<512> copy{str_with_len_N};/15_mean 1.47 ns 1.47 ns 4 -lstringa<512> copy{str_with_len_N};/15_median 1.48 ns 1.48 ns 4 -lstringa<512> copy{str_with_len_N};/15_stddev 0.030 ns 0.039 ns 4 -lstringa<512> copy{str_with_len_N};/15_cv 2.08 % 2.69 % 4 -lstringa<512> copy{str_with_len_N};/16_mean 5.10 ns 5.12 ns 4 -lstringa<512> copy{str_with_len_N};/16_median 5.11 ns 5.16 ns 4 -lstringa<512> copy{str_with_len_N};/16_stddev 0.067 ns 0.078 ns 4 -lstringa<512> copy{str_with_len_N};/16_cv 1.32 % 1.53 % 4 -lstringa<512> copy{str_with_len_N};/23_mean 5.25 ns 5.27 ns 4 -lstringa<512> copy{str_with_len_N};/23_median 5.21 ns 5.23 ns 4 -lstringa<512> copy{str_with_len_N};/23_stddev 0.175 ns 0.150 ns 4 -lstringa<512> copy{str_with_len_N};/23_cv 3.34 % 2.84 % 4 -lstringa<512> copy{str_with_len_N};/24_mean 5.15 ns 5.13 ns 4 -lstringa<512> copy{str_with_len_N};/24_median 5.15 ns 5.16 ns 4 -lstringa<512> copy{str_with_len_N};/24_stddev 0.056 ns 0.070 ns 4 -lstringa<512> copy{str_with_len_N};/24_cv 1.08 % 1.36 % 4 -lstringa<512> copy{str_with_len_N};/32_mean 8.25 ns 8.24 ns 4 -lstringa<512> copy{str_with_len_N};/32_median 8.27 ns 8.28 ns 4 -lstringa<512> copy{str_with_len_N};/32_stddev 0.121 ns 0.167 ns 4 -lstringa<512> copy{str_with_len_N};/32_cv 1.46 % 2.03 % 4 -lstringa<512> copy{str_with_len_N};/64_mean 8.13 ns 8.11 ns 4 -lstringa<512> copy{str_with_len_N};/64_median 8.15 ns 8.16 ns 4 -lstringa<512> copy{str_with_len_N};/64_stddev 0.287 ns 0.314 ns 4 -lstringa<512> copy{str_with_len_N};/64_cv 3.53 % 3.87 % 4 -lstringa<512> copy{str_with_len_N};/128_mean 8.42 ns 8.37 ns 4 -lstringa<512> copy{str_with_len_N};/128_median 8.44 ns 8.37 ns 4 -lstringa<512> copy{str_with_len_N};/128_stddev 0.133 ns 0.000 ns 4 -lstringa<512> copy{str_with_len_N};/128_cv 1.57 % 0.00 % 4 -lstringa<512> copy{str_with_len_N};/256_mean 10.1 ns 10.1 ns 4 -lstringa<512> copy{str_with_len_N};/256_median 10.1 ns 10.1 ns 4 -lstringa<512> copy{str_with_len_N};/256_stddev 0.141 ns 0.234 ns 4 -lstringa<512> copy{str_with_len_N};/256_cv 1.40 % 2.32 % 4 -lstringa<512> copy{str_with_len_N};/512_mean 11.1 ns 11.0 ns 4 -lstringa<512> copy{str_with_len_N};/512_median 11.1 ns 11.0 ns 4 -lstringa<512> copy{str_with_len_N};/512_stddev 0.282 ns 0.161 ns 4 -lstringa<512> copy{str_with_len_N};/512_cv 2.53 % 1.46 % 4 -lstringa<512> copy{str_with_len_N};/1024_mean 96.6 ns 96.3 ns 4 -lstringa<512> copy{str_with_len_N};/1024_median 96.4 ns 95.2 ns 4 -lstringa<512> copy{str_with_len_N};/1024_stddev 2.79 ns 2.96 ns 4 -lstringa<512> copy{str_with_len_N};/1024_cv 2.89 % 3.07 % 4 -lstringa<512> copy{str_with_len_N};/2048_mean 129 ns 129 ns 4 -lstringa<512> copy{str_with_len_N};/2048_median 130 ns 131 ns 4 -lstringa<512> copy{str_with_len_N};/2048_stddev 5.88 ns 6.59 ns 4 -lstringa<512> copy{str_with_len_N};/2048_cv 4.55 % 5.11 % 4 -lstringa<512> copy{str_with_len_N};/4096_mean 184 ns 184 ns 4 -lstringa<512> copy{str_with_len_N};/4096_median 183 ns 184 ns 4 -lstringa<512> copy{str_with_len_N};/4096_stddev 3.25 ns 3.42 ns 4 -lstringa<512> copy{str_with_len_N};/4096_cv 1.76 % 1.86 % 4 +lstringa<16> copy{str_with_len_N};/15_stddev 0.033 ns 0.036 ns 4 +lstringa<16> copy{str_with_len_N};/15_cv 2.23 % 2.41 % 4 +lstringa<16> copy{str_with_len_N};/16_mean 5.09 ns 5.09 ns 4 +lstringa<16> copy{str_with_len_N};/16_median 5.09 ns 5.16 ns 4 +lstringa<16> copy{str_with_len_N};/16_stddev 0.077 ns 0.140 ns 4 +lstringa<16> copy{str_with_len_N};/16_cv 1.50 % 2.74 % 4 +lstringa<16> copy{str_with_len_N};/23_mean 5.36 ns 5.35 ns 4 +lstringa<16> copy{str_with_len_N};/23_median 5.38 ns 5.39 ns 4 +lstringa<16> copy{str_with_len_N};/23_stddev 0.100 ns 0.150 ns 4 +lstringa<16> copy{str_with_len_N};/23_cv 1.87 % 2.80 % 4 +lstringa<16> copy{str_with_len_N};/24_mean 76.8 ns 76.7 ns 4 +lstringa<16> copy{str_with_len_N};/24_median 75.8 ns 75.9 ns 4 +lstringa<16> copy{str_with_len_N};/24_stddev 1.89 ns 2.47 ns 4 +lstringa<16> copy{str_with_len_N};/24_cv 2.46 % 3.21 % 4 +lstringa<16> copy{str_with_len_N};/32_mean 81.4 ns 81.5 ns 4 +lstringa<16> copy{str_with_len_N};/32_median 81.8 ns 82.0 ns 4 +lstringa<16> copy{str_with_len_N};/32_stddev 2.10 ns 2.19 ns 4 +lstringa<16> copy{str_with_len_N};/32_cv 2.58 % 2.69 % 4 +lstringa<16> copy{str_with_len_N};/64_mean 80.8 ns 81.1 ns 4 +lstringa<16> copy{str_with_len_N};/64_median 80.8 ns 81.1 ns 4 +lstringa<16> copy{str_with_len_N};/64_stddev 1.42 ns 1.01 ns 4 +lstringa<16> copy{str_with_len_N};/64_cv 1.75 % 1.24 % 4 +lstringa<16> copy{str_with_len_N};/128_mean 82.8 ns 82.0 ns 4 +lstringa<16> copy{str_with_len_N};/128_median 82.0 ns 82.0 ns 4 +lstringa<16> copy{str_with_len_N};/128_stddev 1.96 ns 1.42 ns 4 +lstringa<16> copy{str_with_len_N};/128_cv 2.37 % 1.74 % 4 +lstringa<16> copy{str_with_len_N};/256_mean 87.4 ns 87.2 ns 4 +lstringa<16> copy{str_with_len_N};/256_median 87.0 ns 87.2 ns 4 +lstringa<16> copy{str_with_len_N};/256_stddev 1.21 ns 1.42 ns 4 +lstringa<16> copy{str_with_len_N};/256_cv 1.38 % 1.63 % 4 +lstringa<16> copy{str_with_len_N};/512_mean 86.9 ns 85.4 ns 4 +lstringa<16> copy{str_with_len_N};/512_median 86.7 ns 85.4 ns 4 +lstringa<16> copy{str_with_len_N};/512_stddev 1.91 ns 1.42 ns 4 +lstringa<16> copy{str_with_len_N};/512_cv 2.20 % 1.67 % 4 +lstringa<16> copy{str_with_len_N};/1024_mean 93.4 ns 93.6 ns 4 +lstringa<16> copy{str_with_len_N};/1024_median 91.8 ns 92.1 ns 4 +lstringa<16> copy{str_with_len_N};/1024_stddev 3.66 ns 3.14 ns 4 +lstringa<16> copy{str_with_len_N};/1024_cv 3.92 % 3.35 % 4 +lstringa<16> copy{str_with_len_N};/2048_mean 133 ns 133 ns 4 +lstringa<16> copy{str_with_len_N};/2048_median 134 ns 134 ns 4 +lstringa<16> copy{str_with_len_N};/2048_stddev 4.12 ns 3.51 ns 4 +lstringa<16> copy{str_with_len_N};/2048_cv 3.09 % 2.64 % 4 +lstringa<16> copy{str_with_len_N};/4096_mean 189 ns 189 ns 4 +lstringa<16> copy{str_with_len_N};/4096_median 191 ns 193 ns 4 +lstringa<16> copy{str_with_len_N};/4096_stddev 8.95 ns 9.89 ns 4 +lstringa<16> copy{str_with_len_N};/4096_cv 4.73 % 5.22 % 4 +lstringa<512> copy{str_with_len_N};/15_mean 1.49 ns 1.48 ns 4 +lstringa<512> copy{str_with_len_N};/15_median 1.49 ns 1.48 ns 4 +lstringa<512> copy{str_with_len_N};/15_stddev 0.047 ns 0.051 ns 4 +lstringa<512> copy{str_with_len_N};/15_cv 3.15 % 3.47 % 4 +lstringa<512> copy{str_with_len_N};/16_mean 5.15 ns 5.16 ns 4 +lstringa<512> copy{str_with_len_N};/16_median 5.14 ns 5.16 ns 4 +lstringa<512> copy{str_with_len_N};/16_stddev 0.094 ns 0.128 ns 4 +lstringa<512> copy{str_with_len_N};/16_cv 1.83 % 2.47 % 4 +lstringa<512> copy{str_with_len_N};/23_mean 5.14 ns 5.12 ns 4 +lstringa<512> copy{str_with_len_N};/23_median 5.13 ns 5.08 ns 4 +lstringa<512> copy{str_with_len_N};/23_stddev 0.104 ns 0.150 ns 4 +lstringa<512> copy{str_with_len_N};/23_cv 2.01 % 2.92 % 4 +lstringa<512> copy{str_with_len_N};/24_mean 5.12 ns 5.09 ns 4 +lstringa<512> copy{str_with_len_N};/24_median 5.12 ns 5.09 ns 4 +lstringa<512> copy{str_with_len_N};/24_stddev 0.140 ns 0.081 ns 4 +lstringa<512> copy{str_with_len_N};/24_cv 2.73 % 1.58 % 4 +lstringa<512> copy{str_with_len_N};/32_mean 8.25 ns 8.21 ns 4 +lstringa<512> copy{str_with_len_N};/32_median 8.18 ns 8.16 ns 4 +lstringa<512> copy{str_with_len_N};/32_stddev 0.268 ns 0.263 ns 4 +lstringa<512> copy{str_with_len_N};/32_cv 3.25 % 3.21 % 4 +lstringa<512> copy{str_with_len_N};/64_mean 8.00 ns 7.93 ns 4 +lstringa<512> copy{str_with_len_N};/64_median 8.01 ns 7.93 ns 4 +lstringa<512> copy{str_with_len_N};/64_stddev 0.275 ns 0.225 ns 4 +lstringa<512> copy{str_with_len_N};/64_cv 3.44 % 2.84 % 4 +lstringa<512> copy{str_with_len_N};/128_mean 8.46 ns 8.42 ns 4 +lstringa<512> copy{str_with_len_N};/128_median 8.32 ns 8.27 ns 4 +lstringa<512> copy{str_with_len_N};/128_stddev 0.393 ns 0.396 ns 4 +lstringa<512> copy{str_with_len_N};/128_cv 4.65 % 4.70 % 4 +lstringa<512> copy{str_with_len_N};/256_mean 9.58 ns 9.52 ns 4 +lstringa<512> copy{str_with_len_N};/256_median 9.55 ns 9.52 ns 4 +lstringa<512> copy{str_with_len_N};/256_stddev 0.105 ns 0.121 ns 4 +lstringa<512> copy{str_with_len_N};/256_cv 1.10 % 1.27 % 4 +lstringa<512> copy{str_with_len_N};/512_mean 11.0 ns 11.0 ns 4 +lstringa<512> copy{str_with_len_N};/512_median 11.0 ns 11.0 ns 4 +lstringa<512> copy{str_with_len_N};/512_stddev 0.236 ns 0.282 ns 4 +lstringa<512> copy{str_with_len_N};/512_cv 2.15 % 2.57 % 4 +lstringa<512> copy{str_with_len_N};/1024_mean 94.5 ns 94.7 ns 4 +lstringa<512> copy{str_with_len_N};/1024_median 94.3 ns 94.2 ns 4 +lstringa<512> copy{str_with_len_N};/1024_stddev 2.42 ns 2.63 ns 4 +lstringa<512> copy{str_with_len_N};/1024_cv 2.56 % 2.78 % 4 +lstringa<512> copy{str_with_len_N};/2048_mean 134 ns 135 ns 4 +lstringa<512> copy{str_with_len_N};/2048_median 135 ns 134 ns 4 +lstringa<512> copy{str_with_len_N};/2048_stddev 3.36 ns 4.19 ns 4 +lstringa<512> copy{str_with_len_N};/2048_cv 2.51 % 3.11 % 4 +lstringa<512> copy{str_with_len_N};/4096_mean 193 ns 191 ns 4 +lstringa<512> copy{str_with_len_N};/4096_median 193 ns 193 ns 4 +lstringa<512> copy{str_with_len_N};/4096_stddev 2.96 ns 2.09 ns 4 +lstringa<512> copy{str_with_len_N};/4096_cv 1.54 % 1.09 % 4 ----- Convert to int '1234567' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_mean 31.0 ns 30.8 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 30.9 ns 30.8 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.241 ns 0.383 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 0.77 % 1.24 % 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 13.3 ns 13.3 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 13.3 ns 13.3 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.253 ns 0.301 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 1.90 % 2.27 % 4 -stringa s = "123456789"; int res = s.to_int_mean 13.9 ns 14.0 ns 4 -stringa s = "123456789"; int res = s.to_int_median 14.0 ns 14.0 ns 4 -stringa s = "123456789"; int res = s.to_int_stddev 0.223 ns 0.228 ns 4 -stringa s = "123456789"; int res = s.to_int_cv 1.60 % 1.63 % 4 -ssa s = "123456789"; int res = s.to_int_mean 12.9 ns 12.8 ns 4 -ssa s = "123456789"; int res = s.to_int_median 12.9 ns 12.7 ns 4 -ssa s = "123456789"; int res = s.to_int_stddev 0.171 ns 0.267 ns 4 -ssa s = "123456789"; int res = s.to_int_cv 1.33 % 2.09 % 4 -lstringa<20> s = "123456789"; int res = s.to_int_mean 13.3 ns 13.2 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_median 13.3 ns 13.2 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.240 ns 0.495 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_cv 1.80 % 3.74 % 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_mean 30.6 ns 30.7 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 30.7 ns 30.7 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.391 ns 0.570 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 1.28 % 1.86 % 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 13.5 ns 13.5 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 13.5 ns 13.4 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.552 ns 0.619 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 4.09 % 4.60 % 4 +stringa s = "123456789"; int res = s.to_int_mean 13.8 ns 13.7 ns 4 +stringa s = "123456789"; int res = s.to_int_median 13.9 ns 13.8 ns 4 +stringa s = "123456789"; int res = s.to_int_stddev 0.147 ns 0.395 ns 4 +stringa s = "123456789"; int res = s.to_int_cv 1.06 % 2.88 % 4 +ssa s = "123456789"; int res = s.to_int_mean 9.17 ns 9.10 ns 4 +ssa s = "123456789"; int res = s.to_int_median 9.14 ns 9.10 ns 4 +ssa s = "123456789"; int res = s.to_int_stddev 0.188 ns 0.121 ns 4 +ssa s = "123456789"; int res = s.to_int_cv 2.05 % 1.33 % 4 +lstringa<20> s = "123456789"; int res = s.to_int_mean 13.9 ns 13.9 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_median 13.9 ns 13.8 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.142 ns 0.157 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_cv 1.02 % 1.13 % 4 ----- Convert to unsigned 'abcDef' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_mean 34.4 ns 34.1 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 33.6 ns 33.0 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 1.96 ns 2.30 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 5.69 % 6.74 % 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 8.71 ns 8.63 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 8.50 ns 8.37 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.776 ns 0.826 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 8.91 % 9.57 % 4 -stringa s = "abcDef"; int res = s.to_int_mean 12.0 ns 12.0 ns 4 -stringa s = "abcDef"; int res = s.to_int_median 12.0 ns 12.0 ns 4 -stringa s = "abcDef"; int res = s.to_int_stddev 0.118 ns 0.228 ns 4 -stringa s = "abcDef"; int res = s.to_int_cv 0.98 % 1.90 % 4 -ssa s = "abcDef"; int res = s.to_int_mean 11.8 ns 11.8 ns 4 -ssa s = "abcDef"; int res = s.to_int_median 11.9 ns 11.9 ns 4 -ssa s = "abcDef"; int res = s.to_int_stddev 0.183 ns 0.267 ns 4 -ssa s = "abcDef"; int res = s.to_int_cv 1.54 % 2.27 % 4 -lstringa<20> s = "abcDef"; int res = s.to_int_mean 12.3 ns 12.3 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_median 12.2 ns 12.3 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.498 ns 0.456 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_cv 4.06 % 3.71 % 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_mean 34.2 ns 33.7 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 33.4 ns 33.3 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 2.54 ns 1.73 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 7.42 % 5.14 % 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 8.11 ns 8.11 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 8.07 ns 8.02 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.148 ns 0.174 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 1.83 % 2.15 % 4 +stringa s = "abcDef"; int res = s.to_int_mean 12.7 ns 12.8 ns 4 +stringa s = "abcDef"; int res = s.to_int_median 12.8 ns 12.8 ns 4 +stringa s = "abcDef"; int res = s.to_int_stddev 0.207 ns 0.140 ns 4 +stringa s = "abcDef"; int res = s.to_int_cv 1.63 % 1.09 % 4 +ssa s = "abcDef"; int res = s.to_int_mean 7.39 ns 7.24 ns 4 +ssa s = "abcDef"; int res = s.to_int_median 7.34 ns 7.15 ns 4 +ssa s = "abcDef"; int res = s.to_int_stddev 0.269 ns 0.461 ns 4 +ssa s = "abcDef"; int res = s.to_int_cv 3.63 % 6.38 % 4 +lstringa<20> s = "abcDef"; int res = s.to_int_mean 12.7 ns 12.7 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_median 12.7 ns 12.7 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.034 ns 0.161 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_cv 0.27 % 1.27 % 4 ----- Convert to int ' 1234567' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_mean 44.2 ns 44.2 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 44.4 ns 44.4 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 1.81 ns 1.67 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 4.10 % 3.77 % 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 17.7 ns 17.6 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 17.6 ns 17.6 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.270 ns 0.342 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 1.53 % 1.94 % 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 15.9 ns 15.9 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 15.9 ns 15.9 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.103 ns 0.201 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 0.65 % 1.27 % 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_mean 42.8 ns 43.0 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 43.3 ns 43.0 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 1.04 ns 0.797 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 2.43 % 1.86 % 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 18.5 ns 18.4 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 18.5 ns 18.4 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.204 ns 0.342 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 1.11 % 1.86 % 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 13.6 ns 13.5 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 13.6 ns 13.7 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.279 ns 0.279 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 2.05 % 2.06 % 4 ----- Convert to double '1234.567e10' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_mean 102 ns 101 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 102 ns 101 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 2.13 ns 3.15 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 2.09 % 3.11 % 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 58.7 ns 58.6 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 58.5 ns 58.6 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 1.83 ns 1.61 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 3.12 % 2.75 % 4 -ssa s = "1234.567e10"; double res = *s.to_double()_mean 35.2 ns 35.1 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_median 35.2 ns 35.3 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.374 ns 0.384 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_cv 1.06 % 1.09 % 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_mean 97.9 ns 97.8 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 97.9 ns 98.4 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 0.764 ns 2.63 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 0.78 % 2.69 % 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 58.4 ns 58.2 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 58.3 ns 57.9 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 1.60 ns 2.38 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 2.75 % 4.09 % 4 +ssa s = "1234.567e10"; double res = *s.to_double()_mean 35.1 ns 34.7 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_median 35.3 ns 34.5 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.515 ns 1.01 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_cv 1.47 % 2.91 % 4 -- Append const literal of 16 bytes 64 times, 1024 total length --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; ... str << "abbaabbaabbaabba";_mean 4625 ns 4604 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_median 4624 ns 4604 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 111 ns 161 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.41 % 3.50 % 4 -std::string str; ... str += "abbaabbaabbaabba";_mean 1067 ns 1068 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_median 1068 ns 1062 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_stddev 27.9 ns 23.4 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_cv 2.61 % 2.19 % 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 746 ns 746 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_median 743 ns 739 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 12.5 ns 14.0 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 1.67 % 1.87 % 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 388 ns 389 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_median 387 ns 387 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 4.24 ns 4.20 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 1.09 % 1.08 % 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 227 ns 228 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_median 229 ns 229 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 5.32 ns 4.34 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 2.34 % 1.91 % 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 135 ns 135 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 135 ns 133 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 1.77 ns 4.44 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 1.31 % 3.29 % 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_mean 4844 ns 4844 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_median 4854 ns 4844 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 98.7 ns 128 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.04 % 2.63 % 4 +std::string str; ... str += "abbaabbaabbaabba";_mean 1045 ns 1046 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_median 1049 ns 1046 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_stddev 21.8 ns 24.2 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_cv 2.09 % 2.31 % 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 782 ns 785 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_median 781 ns 781 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 6.56 ns 6.98 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 0.84 % 0.89 % 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 406 ns 404 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_median 406 ns 406 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 6.45 ns 8.01 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 1.59 % 1.98 % 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 268 ns 268 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_median 270 ns 270 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 4.37 ns 5.68 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 1.63 % 2.12 % 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 156 ns 156 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 156 ns 157 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 0.663 ns 1.74 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 0.42 % 1.12 % 4 -- Append string of 16 bytes and const literal of 16 bytes 32 times, 1024 total length --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_mean 4517 ns 4517 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 4516 ns 4541 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 83.6 ns 93.5 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 1.85 % 2.07 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 3763 ns 3771 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_median 3732 ns 3749 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 92.8 ns 110 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 2.46 % 2.91 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 703 ns 702 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 700 ns 698 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 11.2 ns 8.72 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.59 % 1.24 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 450 ns 449 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 449 ns 444 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 25.6 ns 28.7 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 5.69 % 6.40 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 300 ns 300 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 302 ns 301 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 6.36 ns 7.90 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.12 % 2.64 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 209 ns 210 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 209 ns 209 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 0.643 ns 2.27 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 0.31 % 1.08 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_mean 4654 ns 4656 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 4665 ns 4656 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 84.4 ns 135 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 1.81 % 2.90 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 3736 ns 3730 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_median 3714 ns 3690 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 67.1 ns 80.2 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 1.80 % 2.15 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 713 ns 715 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 715 ns 715 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 15.9 ns 20.1 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.23 % 2.82 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 437 ns 435 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 436 ns 435 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 1.89 ns 8.26 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 0.43 % 1.90 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 281 ns 283 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 281 ns 283 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 2.76 ns 0.000 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 0.98 % 0.00 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 187 ns 187 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 187 ns 188 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 2.88 ns 1.92 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.54 % 1.03 % 4 -- Append string of 16 bytes and const literal of 16 bytes 2048 times, 65536 total length --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_mean 221538 ns 221010 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 220176 ns 217087 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 7840 ns 9902 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 3.54 % 4.48 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 187478 ns 187038 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 187660 ns 185904 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 7729 ns 6801 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 4.12 % 3.64 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 18490 ns 18415 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 18387 ns 18415 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 449 ns 342 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.43 % 1.86 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16842 ns 16828 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16953 ns 16915 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 505 ns 596 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.00 % 3.54 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16140 ns 16044 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16193 ns 16044 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 362 ns 285 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.25 % 1.77 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16187 ns 16131 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16200 ns 16218 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 191 ns 334 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.18 % 2.07 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_mean 234977 ns 235596 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 235722 ns 236816 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 13239 ns 13446 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 5.63 % 5.71 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 192544 ns 192705 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 193142 ns 192705 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 4934 ns 5854 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.56 % 3.04 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 20077 ns 20063 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 20076 ns 20176 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 430 ns 434 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.14 % 2.16 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16403 ns 16305 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16379 ns 16113 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 388 ns 384 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.37 % 2.35 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 16237 ns 16209 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 16280 ns 16113 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 190 ns 192 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.17 % 1.18 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 15954 ns 15956 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 15846 ns 16044 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 412 ns 439 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.58 % 2.75 % 4 -- Append 2 string of 16 bytes 32 times, 1024 total length --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; ... str << str_var1 << str_var2;_mean 4542 ns 4544 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_median 4385 ns 4379 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_stddev 429 ns 431 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_cv 9.44 % 9.48 % 4 -std::string str; ... str += str_var1 + str_var2;_mean 3837 ns 3830 ns 4 -std::string str; ... str += str_var1 + str_var2;_median 3859 ns 3850 ns 4 -std::string str; ... str += str_var1 + str_var2;_stddev 61.7 ns 41.9 ns 4 -std::string str; ... str += str_var1 + str_var2;_cv 1.61 % 1.09 % 4 -lstringa<16> str; ... str += str_var1 + str_var2;_mean 816 ns 811 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_median 817 ns 811 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_stddev 5.69 ns 10.1 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_cv 0.70 % 1.24 % 4 -lstringa<128> str; ... str += str_var1 + str_var2;_mean 526 ns 520 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_median 529 ns 516 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_stddev 11.8 ns 20.9 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_cv 2.25 % 4.03 % 4 -lstringa<512> str; ... str += str_var1 + str_var2;_mean 382 ns 381 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_median 375 ns 375 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_stddev 16.1 ns 13.1 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_cv 4.23 % 3.43 % 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_mean 277 ns 278 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_median 276 ns 279 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 5.68 ns 6.01 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_cv 2.05 % 2.16 % 4 +std::stringstream str; ... str << str_var1 << str_var2;_mean 4325 ns 4332 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_median 4320 ns 4332 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_stddev 98.0 ns 76.9 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_cv 2.27 % 1.77 % 4 +std::string str; ... str += str_var1 + str_var2;_mean 4072 ns 4058 ns 4 +std::string str; ... str += str_var1 + str_var2;_median 4095 ns 4081 ns 4 +std::string str; ... str += str_var1 + str_var2;_stddev 90.4 ns 45.3 ns 4 +std::string str; ... str += str_var1 + str_var2;_cv 2.22 % 1.12 % 4 +lstringa<16> str; ... str += str_var1 + str_var2;_mean 794 ns 793 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_median 794 ns 793 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_stddev 15.7 ns 22.5 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_cv 1.97 % 2.84 % 4 +lstringa<128> str; ... str += str_var1 + str_var2;_mean 512 ns 513 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_median 513 ns 516 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_stddev 9.21 ns 6.98 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_cv 1.80 % 1.36 % 4 +lstringa<512> str; ... str += str_var1 + str_var2;_mean 395 ns 396 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_median 393 ns 393 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_stddev 10.4 ns 12.6 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_cv 2.65 % 3.17 % 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_mean 287 ns 289 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_median 288 ns 289 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 3.70 ns 5.13 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_cv 1.29 % 1.77 % 4 -- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; str << "test = " << k << " times";_mean 10808 ns 10742 ns 4 -std::stringstream str; str << "test = " << k << " times";_median 10860 ns 10742 ns 4 -std::stringstream str; str << "test = " << k << " times";_stddev 324 ns 399 ns 4 -std::stringstream str; str << "test = " << k << " times";_cv 3.00 % 3.71 % 4 -std::string str = "test = " + std::to_string(k) + " times";_mean 1044 ns 1046 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_median 1046 ns 1046 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_stddev 17.5 ns 17.1 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_cv 1.68 % 1.63 % 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 2812 ns 2816 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 2832 ns 2846 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 89.7 ns 114 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 3.19 % 4.03 % 4 -std::string str = std::format("test = {} times", k);_mean 1913 ns 1915 ns 4 -std::string str = std::format("test = {} times", k);_median 1898 ns 1904 ns 4 -std::string str = std::format("test = {} times", k);_stddev 93.7 ns 115 ns 4 -std::string str = std::format("test = {} times", k);_cv 4.90 % 6.02 % 4 -lstringa<8> str; str.format("test = {} times", k);_mean 2071 ns 2061 ns 4 -lstringa<8> str; str.format("test = {} times", k);_median 2078 ns 2051 ns 4 -lstringa<8> str; str.format("test = {} times", k);_stddev 39.9 ns 52.7 ns 4 -lstringa<8> str; str.format("test = {} times", k);_cv 1.92 % 2.55 % 4 -lstringa<32> str; str.format("test = {} times", k);_mean 1006 ns 1007 ns 4 -lstringa<32> str; str.format("test = {} times", k);_median 997 ns 1001 ns 4 -lstringa<32> str; str.format("test = {} times", k);_stddev 22.1 ns 30.7 ns 4 -lstringa<32> str; str.format("test = {} times", k);_cv 2.20 % 3.05 % 4 -lstringa<8> str = "test = " + k + " times";_mean 836 ns 837 ns 4 -lstringa<8> str = "test = " + k + " times";_median 834 ns 837 ns 4 -lstringa<8> str = "test = " + k + " times";_stddev 11.9 ns 14.2 ns 4 -lstringa<8> str = "test = " + k + " times";_cv 1.43 % 1.70 % 4 -lstringa<32> str = "test = " + k + " times";_mean 155 ns 155 ns 4 -lstringa<32> str = "test = " + k + " times";_median 155 ns 155 ns 4 -lstringa<32> str = "test = " + k + " times";_stddev 5.90 ns 6.04 ns 4 -lstringa<32> str = "test = " + k + " times";_cv 3.79 % 3.89 % 4 -stringa str = "test = " + k + " times";_mean 156 ns 156 ns 4 -stringa str = "test = " + k + " times";_median 153 ns 153 ns 4 -stringa str = "test = " + k + " times";_stddev 8.76 ns 7.73 ns 4 -stringa str = "test = " + k + " times";_cv 5.62 % 4.95 % 4 +std::stringstream str; str << "test = " << k << " times";_mean 10825 ns 10803 ns 4 +std::stringstream str; str << "test = " << k << " times";_median 10927 ns 10864 ns 4 +std::stringstream str; str << "test = " << k << " times";_stddev 263 ns 234 ns 4 +std::stringstream str; str << "test = " << k << " times";_cv 2.43 % 2.16 % 4 +std::string str = "test = " + std::to_string(k) + " times";_mean 1066 ns 1062 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_median 1060 ns 1050 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_stddev 45.9 ns 42.3 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_cv 4.31 % 3.98 % 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 2723 ns 2715 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 2730 ns 2699 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 47.5 ns 94.2 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 1.74 % 3.47 % 4 +std::string str = std::format("test = {} times", k);_mean 1842 ns 1821 ns 4 +std::string str = std::format("test = {} times", k);_median 1839 ns 1800 ns 4 +std::string str = std::format("test = {} times", k);_stddev 44.1 ns 72.5 ns 4 +std::string str = std::format("test = {} times", k);_cv 2.40 % 3.98 % 4 +lstringa<8> str; str.format("test = {} times", k);_mean 2012 ns 2002 ns 4 +lstringa<8> str; str.format("test = {} times", k);_median 1998 ns 2002 ns 4 +lstringa<8> str; str.format("test = {} times", k);_stddev 45.7 ns 56.4 ns 4 +lstringa<8> str; str.format("test = {} times", k);_cv 2.27 % 2.82 % 4 +lstringa<32> str; str.format("test = {} times", k);_mean 1004 ns 1004 ns 4 +lstringa<32> str; str.format("test = {} times", k);_median 1000 ns 1004 ns 4 +lstringa<32> str; str.format("test = {} times", k);_stddev 12.0 ns 17.1 ns 4 +lstringa<32> str; str.format("test = {} times", k);_cv 1.19 % 1.70 % 4 +lstringa<8> str = "test = " + k + " times";_mean 821 ns 821 ns 4 +lstringa<8> str = "test = " + k + " times";_median 824 ns 827 ns 4 +lstringa<8> str = "test = " + k + " times";_stddev 20.2 ns 20.0 ns 4 +lstringa<8> str = "test = " + k + " times";_cv 2.46 % 2.44 % 4 +lstringa<32> str = "test = " + k + " times";_mean 136 ns 136 ns 4 +lstringa<32> str = "test = " + k + " times";_median 135 ns 135 ns 4 +lstringa<32> str = "test = " + k + " times";_stddev 4.46 ns 4.77 ns 4 +lstringa<32> str = "test = " + k + " times";_cv 3.28 % 3.50 % 4 +stringa str = "test = " + k + " times";_mean 121 ns 120 ns 4 +stringa str = "test = " + k + " times";_median 120 ns 119 ns 4 +stringa str = "test = " + k + " times";_stddev 3.98 ns 3.95 ns 4 +stringa str = "test = " + k + " times";_cv 3.30 % 3.29 % 4 -- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string::find + substr + std::strtol_mean 541 ns 539 ns 4 -std::string::find + substr + std::strtol_median 540 ns 539 ns 4 -std::string::find + substr + std::strtol_stddev 15.1 ns 9.02 ns 4 -std::string::find + substr + std::strtol_cv 2.79 % 1.67 % 4 -ssa::splitter + ssa::as_int_mean 158 ns 156 ns 4 -ssa::splitter + ssa::as_int_median 157 ns 157 ns 4 -ssa::splitter + ssa::as_int_stddev 2.68 ns 4.39 ns 4 -ssa::splitter + ssa::as_int_cv 1.70 % 2.81 % 4 -ssa::splitf + functor_mean 181 ns 181 ns 4 -ssa::splitf + functor_median 181 ns 180 ns 4 -ssa::splitf + functor_stddev 1.01 ns 1.92 ns 4 -ssa::splitf + functor_cv 0.56 % 1.06 % 4 +std::string::find + substr + std::strtol_mean 546 ns 547 ns 4 +std::string::find + substr + std::strtol_median 547 ns 547 ns 4 +std::string::find + substr + std::strtol_stddev 8.88 ns 12.8 ns 4 +std::string::find + substr + std::strtol_cv 1.63 % 2.33 % 4 +ssa::splitter + ssa::as_int_mean 165 ns 165 ns 4 +ssa::splitter + ssa::as_int_median 164 ns 163 ns 4 +ssa::splitter + ssa::as_int_stddev 3.58 ns 4.19 ns 4 +ssa::splitter + ssa::as_int_cv 2.16 % 2.53 % 4 +ssa::splitf + functor_mean 191 ns 191 ns 4 +ssa::splitf + functor_median 191 ns 190 ns 4 +ssa::splitf + functor_stddev 4.25 ns 4.01 ns 4 +ssa::splitf + functor_cv 2.23 % 2.09 % 4 -- Replace symbols in text ~400 symbols --/repeats:1 0.000 ns 0.000 ns 1000000000000 -Naive (and wrong) replace symbols with std::string find + replace_mean 1171 ns 1169 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_median 1167 ns 1161 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_stddev 29.7 ns 39.5 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_cv 2.54 % 3.38 % 4 -replace symbols with std::string find_first_of + replace_mean 2049 ns 2052 ns 4 -replace symbols with std::string find_first_of + replace_median 2043 ns 2040 ns 4 -replace symbols with std::string find_first_of + replace_stddev 83.1 ns 68.0 ns 4 -replace symbols with std::string find_first_of + replace_cv 4.06 % 3.31 % 4 -replace symbols with std::string_view find_first_of + copy_mean 2357 ns 2341 ns 4 -replace symbols with std::string_view find_first_of + copy_median 2379 ns 2380 ns 4 -replace symbols with std::string_view find_first_of + copy_stddev 56.8 ns 99.0 ns 4 -replace symbols with std::string_view find_first_of + copy_cv 2.41 % 4.23 % 4 -replace runtime symbols with string expressions and without remembering all search results_mean 1451 ns 1452 ns 4 -replace runtime symbols with string expressions and without remembering all search results_median 1457 ns 1460 ns 4 -replace runtime symbols with string expressions and without remembering all search results_stddev 29.9 ns 30.1 ns 4 -replace runtime symbols with string expressions and without remembering all search results_cv 2.06 % 2.07 % 4 -replace runtime symbols with simstr and memorization of all search results_mean 1346 ns 1342 ns 4 -replace runtime symbols with simstr and memorization of all search results_median 1341 ns 1334 ns 4 -replace runtime symbols with simstr and memorization of all search results_stddev 19.6 ns 30.1 ns 4 -replace runtime symbols with simstr and memorization of all search results_cv 1.46 % 2.24 % 4 -replace const symbols with string expressions and without remembering all search results_mean 1228 ns 1221 ns 4 -replace const symbols with string expressions and without remembering all search results_median 1230 ns 1214 ns 4 -replace const symbols with string expressions and without remembering all search results_stddev 12.7 ns 26.7 ns 4 -replace const symbols with string expressions and without remembering all search results_cv 1.03 % 2.19 % 4 -replace const symbols with string expressions and memorization of all search results_mean 1121 ns 1123 ns 4 -replace const symbols with string expressions and memorization of all search results_median 1118 ns 1130 ns 4 -replace const symbols with string expressions and memorization of all search results_stddev 16.2 ns 26.7 ns 4 -replace const symbols with string expressions and memorization of all search results_cv 1.45 % 2.38 % 4 +Naive (and wrong) replace symbols with std::string find + replace_mean 1108 ns 1106 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_median 1111 ns 1114 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_stddev 13.6 ns 30.1 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_cv 1.23 % 2.72 % 4 +replace symbols with std::string find_first_of + replace_mean 2009 ns 2009 ns 4 +replace symbols with std::string find_first_of + replace_median 2011 ns 2030 ns 4 +replace symbols with std::string find_first_of + replace_stddev 48.8 ns 59.2 ns 4 +replace symbols with std::string find_first_of + replace_cv 2.43 % 2.95 % 4 +replace symbols with std::string_view find_first_of + copy_mean 2277 ns 2283 ns 4 +replace symbols with std::string_view find_first_of + copy_median 2276 ns 2271 ns 4 +replace symbols with std::string_view find_first_of + copy_stddev 41.5 ns 46.7 ns 4 +replace symbols with std::string_view find_first_of + copy_cv 1.82 % 2.05 % 4 +replace runtime symbols with string expressions and without remembering all search results_mean 1448 ns 1444 ns 4 +replace runtime symbols with string expressions and without remembering all search results_median 1451 ns 1444 ns 4 +replace runtime symbols with string expressions and without remembering all search results_stddev 48.3 ns 57.3 ns 4 +replace runtime symbols with string expressions and without remembering all search results_cv 3.34 % 3.97 % 4 +replace runtime symbols with simstr and memorization of all search results_mean 1363 ns 1350 ns 4 +replace runtime symbols with simstr and memorization of all search results_median 1359 ns 1334 ns 4 +replace runtime symbols with simstr and memorization of all search results_stddev 36.4 ns 44.4 ns 4 +replace runtime symbols with simstr and memorization of all search results_cv 2.67 % 3.29 % 4 +replace const symbols with string expressions and without remembering all search results_mean 1229 ns 1228 ns 4 +replace const symbols with string expressions and without remembering all search results_median 1219 ns 1228 ns 4 +replace const symbols with string expressions and without remembering all search results_stddev 35.0 ns 32.2 ns 4 +replace const symbols with string expressions and without remembering all search results_cv 2.85 % 2.62 % 4 +replace const symbols with string expressions and memorization of all search results_mean 1096 ns 1093 ns 4 +replace const symbols with string expressions and memorization of all search results_median 1094 ns 1099 ns 4 +replace const symbols with string expressions and memorization of all search results_stddev 5.98 ns 12.2 ns 4 +replace const symbols with string expressions and memorization of all search results_cv 0.55 % 1.12 % 4 -- Replace symbols in text ~40 symbols --/repeats:1 0.000 ns 0.000 ns 1000000000000 -Short Naive (and wrong) replace symbols with std::string find + replace_mean 320 ns 319 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_median 318 ns 317 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_stddev 5.52 ns 6.68 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_cv 1.73 % 2.09 % 4 -Short replace symbols with std::string find_first_of + replace_mean 364 ns 360 ns 4 -Short replace symbols with std::string find_first_of + replace_median 364 ns 360 ns 4 -Short replace symbols with std::string find_first_of + replace_stddev 7.93 ns 6.83 ns 4 -Short replace symbols with std::string find_first_of + replace_cv 2.18 % 1.90 % 4 -Short replace symbols with std::string_view find_first_of + copy_mean 319 ns 317 ns 4 -Short replace symbols with std::string_view find_first_of + copy_median 319 ns 318 ns 4 -Short replace symbols with std::string_view find_first_of + copy_stddev 7.88 ns 13.1 ns 4 -Short replace symbols with std::string_view find_first_of + copy_cv 2.47 % 4.14 % 4 -Short replace runtime symbols with string expressions and without remembering all search results_mean 266 ns 267 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_median 265 ns 267 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_stddev 6.04 ns 4.84 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_cv 2.27 % 1.81 % 4 -Short replace runtime symbols with simstr and memorization of all search results_mean 355 ns 355 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_median 355 ns 357 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_stddev 6.73 ns 7.68 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_cv 1.90 % 2.16 % 4 -Short replace const symbols with string expressions and without remembering all search results_mean 225 ns 224 ns 4 -Short replace const symbols with string expressions and without remembering all search results_median 227 ns 225 ns 4 -Short replace const symbols with string expressions and without remembering all search results_stddev 6.21 ns 6.58 ns 4 -Short replace const symbols with string expressions and without remembering all search results_cv 2.76 % 2.94 % 4 -Short replace const symbols with string expressions and memorization of all search results_mean 292 ns 292 ns 4 -Short replace const symbols with string expressions and memorization of all search results_median 292 ns 292 ns 4 -Short replace const symbols with string expressions and memorization of all search results_stddev 6.45 ns 7.65 ns 4 -Short replace const symbols with string expressions and memorization of all search results_cv 2.21 % 2.62 % 4 +Short Naive (and wrong) replace symbols with std::string find + replace_mean 305 ns 300 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_median 301 ns 302 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_stddev 19.3 ns 11.3 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_cv 6.35 % 3.77 % 4 +Short replace symbols with std::string find_first_of + replace_mean 356 ns 355 ns 4 +Short replace symbols with std::string find_first_of + replace_median 354 ns 353 ns 4 +Short replace symbols with std::string find_first_of + replace_stddev 11.7 ns 10.1 ns 4 +Short replace symbols with std::string find_first_of + replace_cv 3.28 % 2.84 % 4 +Short replace symbols with std::string_view find_first_of + copy_mean 307 ns 306 ns 4 +Short replace symbols with std::string_view find_first_of + copy_median 306 ns 305 ns 4 +Short replace symbols with std::string_view find_first_of + copy_stddev 9.99 ns 9.94 ns 4 +Short replace symbols with std::string_view find_first_of + copy_cv 3.26 % 3.24 % 4 +Short replace runtime symbols with string expressions and without remembering all search results_mean 259 ns 258 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_median 258 ns 258 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_stddev 2.09 ns 7.65 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_cv 0.81 % 2.97 % 4 +Short replace runtime symbols with simstr and memorization of all search results_mean 355 ns 353 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_median 353 ns 353 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_stddev 7.74 ns 6.55 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_cv 2.18 % 1.86 % 4 +Short replace const symbols with string expressions and without remembering all search results_mean 199 ns 198 ns 4 +Short replace const symbols with string expressions and without remembering all search results_median 199 ns 197 ns 4 +Short replace const symbols with string expressions and without remembering all search results_stddev 4.27 ns 4.34 ns 4 +Short replace const symbols with string expressions and without remembering all search results_cv 2.15 % 2.19 % 4 +Short replace const symbols with string expressions and memorization of all search results_mean 289 ns 289 ns 4 +Short replace const symbols with string expressions and memorization of all search results_median 290 ns 289 ns 4 +Short replace const symbols with string expressions and memorization of all search results_stddev 9.47 ns 11.5 ns 4 +Short replace const symbols with string expressions and memorization of all search results_cv 3.28 % 3.97 % 4 ----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to ---- in std::string|64_mean 224 ns 224 ns 4 -replace bb to ---- in std::string|64_median 224 ns 224 ns 4 -replace bb to ---- in std::string|64_stddev 6.25 ns 5.85 ns 4 -replace bb to ---- in std::string|64_cv 2.79 % 2.61 % 4 -replace bb to ---- in std::string|256_mean 756 ns 753 ns 4 -replace bb to ---- in std::string|256_median 755 ns 753 ns 4 -replace bb to ---- in std::string|256_stddev 11.5 ns 17.1 ns 4 -replace bb to ---- in std::string|256_cv 1.52 % 2.27 % 4 -replace bb to ---- in std::string|512_mean 1431 ns 1436 ns 4 -replace bb to ---- in std::string|512_median 1431 ns 1428 ns 4 -replace bb to ---- in std::string|512_stddev 24.9 ns 30.1 ns 4 -replace bb to ---- in std::string|512_cv 1.74 % 2.09 % 4 -replace bb to ---- in std::string|1024_mean 3112 ns 3108 ns 4 -replace bb to ---- in std::string|1024_median 3080 ns 3108 ns 4 -replace bb to ---- in std::string|1024_stddev 98.9 ns 99.1 ns 4 -replace bb to ---- in std::string|1024_cv 3.18 % 3.19 % 4 -replace bb to ---- in std::string|2048_mean 7873 ns 7847 ns 4 -replace bb to ---- in std::string|2048_median 7859 ns 7847 ns 4 -replace bb to ---- in std::string|2048_stddev 172 ns 142 ns 4 -replace bb to ---- in std::string|2048_cv 2.19 % 1.81 % 4 -replace bb to ---- in lstringa<8>|64_mean 217 ns 217 ns 4 -replace bb to ---- in lstringa<8>|64_median 216 ns 217 ns 4 -replace bb to ---- in lstringa<8>|64_stddev 4.54 ns 6.75 ns 4 -replace bb to ---- in lstringa<8>|64_cv 2.09 % 3.11 % 4 -replace bb to ---- in lstringa<8>|256_mean 622 ns 624 ns 4 -replace bb to ---- in lstringa<8>|256_median 621 ns 621 ns 4 -replace bb to ---- in lstringa<8>|256_stddev 23.6 ns 23.8 ns 4 -replace bb to ---- in lstringa<8>|256_cv 3.79 % 3.82 % 4 -replace bb to ---- in lstringa<8>|512_mean 1050 ns 1050 ns 4 -replace bb to ---- in lstringa<8>|512_median 1044 ns 1038 ns 4 -replace bb to ---- in lstringa<8>|512_stddev 32.8 ns 34.5 ns 4 -replace bb to ---- in lstringa<8>|512_cv 3.12 % 3.29 % 4 -replace bb to ---- in lstringa<8>|1024_mean 1906 ns 1894 ns 4 -replace bb to ---- in lstringa<8>|1024_median 1900 ns 1862 ns 4 -replace bb to ---- in lstringa<8>|1024_stddev 64.8 ns 79.2 ns 4 -replace bb to ---- in lstringa<8>|1024_cv 3.40 % 4.18 % 4 -replace bb to ---- in lstringa<8>|2048_mean 3604 ns 3610 ns 4 -replace bb to ---- in lstringa<8>|2048_median 3604 ns 3610 ns 4 -replace bb to ---- in lstringa<8>|2048_stddev 53.7 ns 0.000 ns 4 -replace bb to ---- in lstringa<8>|2048_cv 1.49 % 0.00 % 4 -replace bb to ---- by init stringa|64_mean 184 ns 181 ns 4 -replace bb to ---- by init stringa|64_median 183 ns 180 ns 4 -replace bb to ---- by init stringa|64_stddev 11.1 ns 8.51 ns 4 -replace bb to ---- by init stringa|64_cv 6.04 % 4.69 % 4 -replace bb to ---- by init stringa|256_mean 373 ns 373 ns 4 -replace bb to ---- by init stringa|256_median 374 ns 373 ns 4 -replace bb to ---- by init stringa|256_stddev 2.79 ns 4.63 ns 4 -replace bb to ---- by init stringa|256_cv 0.75 % 1.24 % 4 -replace bb to ---- by init stringa|512_mean 814 ns 811 ns 4 -replace bb to ---- by init stringa|512_median 825 ns 820 ns 4 -replace bb to ---- by init stringa|512_stddev 22.9 ns 30.2 ns 4 -replace bb to ---- by init stringa|512_cv 2.81 % 3.72 % 4 -replace bb to ---- by init stringa|1024_mean 1629 ns 1622 ns 4 -replace bb to ---- by init stringa|1024_median 1637 ns 1639 ns 4 -replace bb to ---- by init stringa|1024_stddev 20.2 ns 34.9 ns 4 -replace bb to ---- by init stringa|1024_cv 1.24 % 2.15 % 4 -replace bb to ---- by init stringa|2048_mean 3029 ns 3015 ns 4 -replace bb to ---- by init stringa|2048_median 3032 ns 3015 ns 4 -replace bb to ---- by init stringa|2048_stddev 14.6 ns 38.3 ns 4 -replace bb to ---- by init stringa|2048_cv 0.48 % 1.27 % 4 +replace bb to ---- in std::string|64_mean 217 ns 217 ns 4 +replace bb to ---- in std::string|64_median 216 ns 217 ns 4 +replace bb to ---- in std::string|64_stddev 3.68 ns 2.82 ns 4 +replace bb to ---- in std::string|64_cv 1.69 % 1.30 % 4 +replace bb to ---- in std::string|256_mean 736 ns 737 ns 4 +replace bb to ---- in std::string|256_median 739 ns 741 ns 4 +replace bb to ---- in std::string|256_stddev 30.6 ns 29.8 ns 4 +replace bb to ---- in std::string|256_cv 4.16 % 4.04 % 4 +replace bb to ---- in std::string|512_mean 1385 ns 1381 ns 4 +replace bb to ---- in std::string|512_median 1412 ns 1395 ns 4 +replace bb to ---- in std::string|512_stddev 65.5 ns 48.3 ns 4 +replace bb to ---- in std::string|512_cv 4.73 % 3.50 % 4 +replace bb to ---- in std::string|1024_mean 3048 ns 3048 ns 4 +replace bb to ---- in std::string|1024_median 3045 ns 3081 ns 4 +replace bb to ---- in std::string|1024_stddev 68.7 ns 93.7 ns 4 +replace bb to ---- in std::string|1024_cv 2.25 % 3.07 % 4 +replace bb to ---- in std::string|2048_mean 7662 ns 7673 ns 4 +replace bb to ---- in std::string|2048_median 7620 ns 7673 ns 4 +replace bb to ---- in std::string|2048_stddev 197 ns 142 ns 4 +replace bb to ---- in std::string|2048_cv 2.57 % 1.86 % 4 +replace bb to ---- in lstringa<8>|64_mean 218 ns 217 ns 4 +replace bb to ---- in lstringa<8>|64_median 219 ns 220 ns 4 +replace bb to ---- in lstringa<8>|64_stddev 3.38 ns 4.88 ns 4 +replace bb to ---- in lstringa<8>|64_cv 1.55 % 2.25 % 4 +replace bb to ---- in lstringa<8>|256_mean 613 ns 607 ns 4 +replace bb to ---- in lstringa<8>|256_median 608 ns 607 ns 4 +replace bb to ---- in lstringa<8>|256_stddev 23.0 ns 29.0 ns 4 +replace bb to ---- in lstringa<8>|256_cv 3.75 % 4.79 % 4 +replace bb to ---- in lstringa<8>|512_mean 1056 ns 1046 ns 4 +replace bb to ---- in lstringa<8>|512_median 1058 ns 1057 ns 4 +replace bb to ---- in lstringa<8>|512_stddev 23.6 ns 29.6 ns 4 +replace bb to ---- in lstringa<8>|512_cv 2.24 % 2.83 % 4 +replace bb to ---- in lstringa<8>|1024_mean 1894 ns 1880 ns 4 +replace bb to ---- in lstringa<8>|1024_median 1903 ns 1861 ns 4 +replace bb to ---- in lstringa<8>|1024_stddev 68.0 ns 54.3 ns 4 +replace bb to ---- in lstringa<8>|1024_cv 3.59 % 2.89 % 4 +replace bb to ---- in lstringa<8>|2048_mean 3567 ns 3537 ns 4 +replace bb to ---- in lstringa<8>|2048_median 3510 ns 3474 ns 4 +replace bb to ---- in lstringa<8>|2048_stddev 151 ns 220 ns 4 +replace bb to ---- in lstringa<8>|2048_cv 4.24 % 6.22 % 4 +replace bb to ---- by init stringa|64_mean 170 ns 171 ns 4 +replace bb to ---- by init stringa|64_median 169 ns 167 ns 4 +replace bb to ---- by init stringa|64_stddev 8.86 ns 9.86 ns 4 +replace bb to ---- by init stringa|64_cv 5.20 % 5.77 % 4 +replace bb to ---- by init stringa|256_mean 369 ns 368 ns 4 +replace bb to ---- by init stringa|256_median 370 ns 368 ns 4 +replace bb to ---- by init stringa|256_stddev 9.91 ns 6.26 ns 4 +replace bb to ---- by init stringa|256_cv 2.68 % 1.70 % 4 +replace bb to ---- by init stringa|512_mean 806 ns 802 ns 4 +replace bb to ---- by init stringa|512_median 802 ns 793 ns 4 +replace bb to ---- by init stringa|512_stddev 13.8 ns 24.7 ns 4 +replace bb to ---- by init stringa|512_cv 1.71 % 3.07 % 4 +replace bb to ---- by init stringa|1024_mean 1658 ns 1659 ns 4 +replace bb to ---- by init stringa|1024_median 1660 ns 1669 ns 4 +replace bb to ---- by init stringa|1024_stddev 50.8 ns 36.7 ns 4 +replace bb to ---- by init stringa|1024_cv 3.06 % 2.21 % 4 +replace bb to ---- by init stringa|2048_mean 3213 ns 3164 ns 4 +replace bb to ---- by init stringa|2048_median 3177 ns 3148 ns 4 +replace bb to ---- by init stringa|2048_stddev 89.0 ns 63.4 ns 4 +replace bb to ---- by init stringa|2048_cv 2.77 % 2.01 % 4 ----- Replace All Str To Same Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to -- in std::string|64_mean 193 ns 193 ns 4 -replace bb to -- in std::string|64_median 192 ns 190 ns 4 -replace bb to -- in std::string|64_stddev 3.96 ns 5.92 ns 4 -replace bb to -- in std::string|64_cv 2.06 % 3.07 % 4 -replace bb to -- in std::string|256_mean 561 ns 562 ns 4 -replace bb to -- in std::string|256_median 559 ns 558 ns 4 -replace bb to -- in std::string|256_stddev 6.54 ns 6.98 ns 4 -replace bb to -- in std::string|256_cv 1.17 % 1.24 % 4 -replace bb to -- in std::string|512_mean 1022 ns 1020 ns 4 -replace bb to -- in std::string|512_median 1022 ns 1015 ns 4 -replace bb to -- in std::string|512_stddev 12.6 ns 20.0 ns 4 -replace bb to -- in std::string|512_cv 1.24 % 1.96 % 4 -replace bb to -- in std::string|1024_mean 1596 ns 1593 ns 4 -replace bb to -- in std::string|1024_median 1600 ns 1585 ns 4 -replace bb to -- in std::string|1024_stddev 17.4 ns 30.1 ns 4 -replace bb to -- in std::string|1024_cv 1.09 % 1.89 % 4 -replace bb to -- in std::string|2048_mean 3489 ns 3479 ns 4 -replace bb to -- in std::string|2048_median 3489 ns 3442 ns 4 -replace bb to -- in std::string|2048_stddev 168 ns 140 ns 4 -replace bb to -- in std::string|2048_cv 4.83 % 4.03 % 4 -replace bb to -- in lstringa<8>|64_mean 184 ns 184 ns 4 -replace bb to -- in lstringa<8>|64_median 184 ns 184 ns 4 -replace bb to -- in lstringa<8>|64_stddev 6.48 ns 7.00 ns 4 -replace bb to -- in lstringa<8>|64_cv 3.52 % 3.80 % 4 -replace bb to -- in lstringa<8>|256_mean 435 ns 432 ns 4 -replace bb to -- in lstringa<8>|256_median 439 ns 435 ns 4 -replace bb to -- in lstringa<8>|256_stddev 7.63 ns 9.35 ns 4 -replace bb to -- in lstringa<8>|256_cv 1.75 % 2.16 % 4 -replace bb to -- in lstringa<8>|512_mean 746 ns 746 ns 4 -replace bb to -- in lstringa<8>|512_median 741 ns 746 ns 4 -replace bb to -- in lstringa<8>|512_stddev 21.0 ns 18.0 ns 4 -replace bb to -- in lstringa<8>|512_cv 2.81 % 2.41 % 4 -replace bb to -- in lstringa<8>|1024_mean 1361 ns 1350 ns 4 -replace bb to -- in lstringa<8>|1024_median 1351 ns 1350 ns 4 -replace bb to -- in lstringa<8>|1024_stddev 28.5 ns 25.6 ns 4 -replace bb to -- in lstringa<8>|1024_cv 2.09 % 1.90 % 4 -replace bb to -- in lstringa<8>|2048_mean 2648 ns 2653 ns 4 -replace bb to -- in lstringa<8>|2048_median 2624 ns 2638 ns 4 -replace bb to -- in lstringa<8>|2048_stddev 65.0 ns 56.8 ns 4 -replace bb to -- in lstringa<8>|2048_cv 2.45 % 2.14 % 4 -replace bb to -- by init stringa|64_mean 155 ns 154 ns 4 -replace bb to -- by init stringa|64_median 155 ns 153 ns 4 -replace bb to -- by init stringa|64_stddev 3.36 ns 1.74 ns 4 -replace bb to -- by init stringa|64_cv 2.17 % 1.13 % 4 -replace bb to -- by init stringa|256_mean 349 ns 349 ns 4 -replace bb to -- by init stringa|256_median 344 ns 345 ns 4 -replace bb to -- by init stringa|256_stddev 11.0 ns 13.9 ns 4 -replace bb to -- by init stringa|256_cv 3.16 % 3.98 % 4 -replace bb to -- by init stringa|512_mean 599 ns 596 ns 4 -replace bb to -- by init stringa|512_median 598 ns 600 ns 4 -replace bb to -- by init stringa|512_stddev 6.95 ns 6.98 ns 4 -replace bb to -- by init stringa|512_cv 1.16 % 1.17 % 4 -replace bb to -- by init stringa|1024_mean 1056 ns 1053 ns 4 -replace bb to -- by init stringa|1024_median 1058 ns 1060 ns 4 -replace bb to -- by init stringa|1024_stddev 10.7 ns 14.0 ns 4 -replace bb to -- by init stringa|1024_cv 1.01 % 1.32 % 4 -replace bb to -- by init stringa|2048_mean 2024 ns 2018 ns 4 -replace bb to -- by init stringa|2048_median 2031 ns 1995 ns 4 -replace bb to -- by init stringa|2048_stddev 23.0 ns 45.3 ns 4 -replace bb to -- by init stringa|2048_cv 1.14 % 2.25 % 4 +replace bb to -- in std::string|64_mean 186 ns 185 ns 4 +replace bb to -- in std::string|64_median 186 ns 186 ns 4 +replace bb to -- in std::string|64_stddev 2.91 ns 2.27 ns 4 +replace bb to -- in std::string|64_cv 1.57 % 1.23 % 4 +replace bb to -- in std::string|256_mean 464 ns 463 ns 4 +replace bb to -- in std::string|256_median 464 ns 460 ns 4 +replace bb to -- in std::string|256_stddev 1.48 ns 5.23 ns 4 +replace bb to -- in std::string|256_cv 0.32 % 1.13 % 4 +replace bb to -- in std::string|512_mean 843 ns 833 ns 4 +replace bb to -- in std::string|512_median 840 ns 837 ns 4 +replace bb to -- in std::string|512_stddev 22.6 ns 8.72 ns 4 +replace bb to -- in std::string|512_cv 2.68 % 1.05 % 4 +replace bb to -- in std::string|1024_mean 1576 ns 1577 ns 4 +replace bb to -- in std::string|1024_median 1576 ns 1569 ns 4 +replace bb to -- in std::string|1024_stddev 22.1 ns 15.7 ns 4 +replace bb to -- in std::string|1024_cv 1.40 % 1.00 % 4 +replace bb to -- in std::string|2048_mean 3142 ns 3128 ns 4 +replace bb to -- in std::string|2048_median 3120 ns 3083 ns 4 +replace bb to -- in std::string|2048_stddev 64.0 ns 90.7 ns 4 +replace bb to -- in std::string|2048_cv 2.04 % 2.90 % 4 +replace bb to -- in lstringa<8>|64_mean 185 ns 183 ns 4 +replace bb to -- in lstringa<8>|64_median 186 ns 184 ns 4 +replace bb to -- in lstringa<8>|64_stddev 2.94 ns 5.75 ns 4 +replace bb to -- in lstringa<8>|64_cv 1.59 % 3.14 % 4 +replace bb to -- in lstringa<8>|256_mean 423 ns 423 ns 4 +replace bb to -- in lstringa<8>|256_median 421 ns 423 ns 4 +replace bb to -- in lstringa<8>|256_stddev 9.33 ns 11.3 ns 4 +replace bb to -- in lstringa<8>|256_cv 2.21 % 2.66 % 4 +replace bb to -- in lstringa<8>|512_mean 728 ns 729 ns 4 +replace bb to -- in lstringa<8>|512_median 728 ns 725 ns 4 +replace bb to -- in lstringa<8>|512_stddev 11.6 ns 17.6 ns 4 +replace bb to -- in lstringa<8>|512_cv 1.60 % 2.41 % 4 +replace bb to -- in lstringa<8>|1024_mean 1403 ns 1389 ns 4 +replace bb to -- in lstringa<8>|1024_median 1367 ns 1365 ns 4 +replace bb to -- in lstringa<8>|1024_stddev 105 ns 82.6 ns 4 +replace bb to -- in lstringa<8>|1024_cv 7.49 % 5.94 % 4 +replace bb to -- in lstringa<8>|2048_mean 2686 ns 2609 ns 4 +replace bb to -- in lstringa<8>|2048_median 2677 ns 2609 ns 4 +replace bb to -- in lstringa<8>|2048_stddev 47.0 ns 48.4 ns 4 +replace bb to -- in lstringa<8>|2048_cv 1.75 % 1.86 % 4 +replace bb to -- by init stringa|64_mean 151 ns 151 ns 4 +replace bb to -- by init stringa|64_median 150 ns 151 ns 4 +replace bb to -- by init stringa|64_stddev 4.70 ns 3.95 ns 4 +replace bb to -- by init stringa|64_cv 3.11 % 2.61 % 4 +replace bb to -- by init stringa|256_mean 320 ns 319 ns 4 +replace bb to -- by init stringa|256_median 319 ns 315 ns 4 +replace bb to -- by init stringa|256_stddev 7.65 ns 7.32 ns 4 +replace bb to -- by init stringa|256_cv 2.39 % 2.30 % 4 +replace bb to -- by init stringa|512_mean 523 ns 523 ns 4 +replace bb to -- by init stringa|512_median 522 ns 523 ns 4 +replace bb to -- by init stringa|512_stddev 8.09 ns 9.02 ns 4 +replace bb to -- by init stringa|512_cv 1.55 % 1.72 % 4 +replace bb to -- by init stringa|1024_mean 978 ns 978 ns 4 +replace bb to -- by init stringa|1024_median 978 ns 984 ns 4 +replace bb to -- by init stringa|1024_stddev 11.8 ns 10.5 ns 4 +replace bb to -- by init stringa|1024_cv 1.21 % 1.07 % 4 +replace bb to -- by init stringa|2048_mean 1763 ns 1758 ns 4 +replace bb to -- by init stringa|2048_median 1761 ns 1758 ns 4 +replace bb to -- by init stringa|2048_stddev 58.8 ns 48.3 ns 4 +replace bb to -- by init stringa|2048_cv 3.33 % 2.75 % 4 ----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -hashStrMapA emplace & find stringa;_mean 3990260 ns 3974382 ns 4 -hashStrMapA emplace & find stringa;_median 3979718 ns 3951672 ns 4 -hashStrMapA emplace & find stringa;_stddev 92066 ns 86976 ns 4 -hashStrMapA emplace & find stringa;_cv 2.31 % 2.19 % 4 -std::unordered_map emplace & find std::string;_mean 5696770 ns 5650112 ns 4 -std::unordered_map emplace & find std::string;_median 5747354 ns 5719866 ns 4 -std::unordered_map emplace & find std::string;_stddev 277872 ns 267139 ns 4 -std::unordered_map emplace & find std::string;_cv 4.88 % 4.73 % 4 -hashStrMapA emplace & find ssa;_mean 3453562 ns 3466109 ns 4 -hashStrMapA emplace & find ssa;_median 3446008 ns 3447770 ns 4 -hashStrMapA emplace & find ssa;_stddev 53499 ns 36678 ns 4 -hashStrMapA emplace & find ssa;_cv 1.55 % 1.06 % 4 -std::unordered_map emplace & find std::string_view;_mean 6293665 ns 6312779 ns 4 -std::unordered_map emplace & find std::string_view;_median 6269807 ns 6347656 ns 4 -std::unordered_map emplace & find std::string_view;_stddev 106013 ns 133570 ns 4 -std::unordered_map emplace & find std::string_view;_cv 1.68 % 2.12 % 4 +hashStrMapA emplace & find stringa;_mean 3922015 ns 3928073 ns 4 +hashStrMapA emplace & find stringa;_median 3894926 ns 3928073 ns 4 +hashStrMapA emplace & find stringa;_stddev 127123 ns 142545 ns 4 +hashStrMapA emplace & find stringa;_cv 3.24 % 3.63 % 4 +std::unordered_map emplace & find std::string;_mean 5584695 ns 5546875 ns 4 +std::unordered_map emplace & find std::string;_median 5600902 ns 5546875 ns 4 +std::unordered_map emplace & find std::string;_stddev 245431 ns 270633 ns 4 +std::unordered_map emplace & find std::string;_cv 4.39 % 4.88 % 4 +hashStrMapA emplace & find ssa;_mean 3523219 ns 3523284 ns 4 +hashStrMapA emplace & find ssa;_median 3536825 ns 3523284 ns 4 +hashStrMapA emplace & find ssa;_stddev 57435 ns 62538 ns 4 +hashStrMapA emplace & find ssa;_cv 1.63 % 1.77 % 4 +std::unordered_map emplace & find std::string_view;_mean 6362266 ns 6312779 ns 4 +std::unordered_map emplace & find std::string_view;_median 6361217 ns 6277902 ns 4 +std::unordered_map emplace & find std::string_view;_stddev 140421 ns 175545 ns 4 +std::unordered_map emplace & find std::string_view;_cv 2.21 % 2.78 % 4 ----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Build func full name std::string;_mean 1593 ns 1592 ns 4 -Build func full name std::string;_median 1591 ns 1592 ns 4 -Build func full name std::string;_stddev 37.9 ns 49.5 ns 4 -Build func full name std::string;_cv 2.38 % 3.11 % 4 -Build func full name std::string 1;_mean 1585 ns 1578 ns 4 -Build func full name std::string 1;_median 1576 ns 1569 ns 4 -Build func full name std::string 1;_stddev 49.6 ns 71.9 ns 4 -Build func full name std::string 1;_cv 3.13 % 4.56 % 4 -Build func full name std::stream;_mean 8042 ns 8022 ns 4 -Build func full name std::stream;_median 8091 ns 8022 ns 4 -Build func full name std::stream;_stddev 125 ns 142 ns 4 -Build func full name std::stream;_cv 1.56 % 1.77 % 4 -Build func full name stringa;_mean 807 ns 807 ns 4 -Build func full name stringa;_median 803 ns 802 ns 4 -Build func full name stringa;_stddev 25.5 ns 26.2 ns 4 -Build func full name stringa;_cv 3.16 % 3.24 % 4 -Build func full name stringa 1;_mean 900 ns 900 ns 4 -Build func full name stringa 1;_median 894 ns 900 ns 4 -Build func full name stringa 1;_stddev 21.9 ns 17.1 ns 4 -Build func full name stringa 1;_cv 2.44 % 1.90 % 4 +Build func full name std::string;_mean 1505 ns 1499 ns 4 +Build func full name std::string;_median 1494 ns 1491 ns 4 +Build func full name std::string;_stddev 61.9 ns 53.6 ns 4 +Build func full name std::string;_cv 4.12 % 3.58 % 4 +Build func full name std::string 1;_mean 1501 ns 1499 ns 4 +Build func full name std::string 1;_median 1511 ns 1507 ns 4 +Build func full name std::string 1;_stddev 27.4 ns 39.5 ns 4 +Build func full name std::string 1;_cv 1.83 % 2.64 % 4 +Build func full name std::stream;_mean 8093 ns 8065 ns 4 +Build func full name std::stream;_median 8095 ns 8022 ns 4 +Build func full name std::stream;_stddev 79.4 ns 87.2 ns 4 +Build func full name std::stream;_cv 0.98 % 1.08 % 4 +Build func full name stringa;_mean 747 ns 746 ns 4 +Build func full name stringa;_median 750 ns 746 ns 4 +Build func full name stringa;_stddev 9.81 ns 18.0 ns 4 +Build func full name stringa;_cv 1.31 % 2.41 % 4 +Build func full name stringa 1;_mean 898 ns 897 ns 4 +Build func full name stringa 1;_median 895 ns 891 ns 4 +Build func full name stringa 1;_stddev 23.2 ns 23.4 ns 4 +Build func full name stringa 1;_cv 2.58 % 2.61 % 4 diff --git a/bench/results/003-Xeon E5-2682 v4, Windows 10, MSVC-19.txt b/bench/results/003-Xeon E5-2682 v4, Windows 10, MSVC-19.txt index 35b4671..e9a774e 100644 --- a/bench/results/003-Xeon E5-2682 v4, Windows 10, MSVC-19.txt +++ b/bench/results/003-Xeon E5-2682 v4, Windows 10, MSVC-19.txt @@ -2,7 +2,7 @@ Benchmarks of simstr, version 1.6.7 Sources: https://github.com/orefkov/simstr Results: https://orefkov.github.io/simstr/results.html -2026-02-12T14:50:38+03:00 +2026-02-14T11:16:06+03:00 Running benchStr.exe Run on (32 X 2494 MHz CPU s) CPU Caches: @@ -13,925 +13,962 @@ CPU Caches: -------------------------------------------------------------------------------------------------------------------------------------------------------- Benchmark Time CPU Iterations -------------------------------------------------------------------------------------------------------------------------------------------------------- +----- Concatenate email ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 +Concat email std::format_mean 259 ns 257 ns 4 +Concat email std::format_median 257 ns 257 ns 4 +Concat email std::format_stddev 4.37 ns 0.000 ns 4 +Concat email std::format_cv 1.69 % 0.00 % 4 +Concat email std::stringstream_mean 898 ns 895 ns 4 +Concat email std::stringstream_median 900 ns 889 ns 4 +Concat email std::stringstream_stddev 30.7 ns 20.0 ns 4 +Concat email std::stringstream_cv 3.42 % 2.24 % 4 +Concat email stringzilla append_mean 282 ns 281 ns 4 +Concat email stringzilla append_median 283 ns 283 ns 4 +Concat email stringzilla append_stddev 13.9 ns 12.9 ns 4 +Concat email stringzilla append_cv 4.94 % 4.61 % 4 +Concat email stringzilla concat_mean 131 ns 130 ns 4 +Concat email stringzilla concat_median 131 ns 130 ns 4 +Concat email stringzilla concat_stddev 2.70 ns 2.67 ns 4 +Concat email stringzilla concat_cv 2.06 % 2.05 % 4 +Concat email std::string append_mean 198 ns 197 ns 4 +Concat email std::string append_median 198 ns 197 ns 4 +Concat email std::string append_stddev 1.95 ns 4.83 ns 4 +Concat email std::string append_cv 0.99 % 2.46 % 4 +Concat email std::string by strexpr_mean 106 ns 106 ns 4 +Concat email std::string by strexpr_median 106 ns 105 ns 4 +Concat email std::string by strexpr_stddev 3.71 ns 3.66 ns 4 +Concat email std::string by strexpr_cv 3.50 % 3.47 % 4 +Concat email stringa_mean 103 ns 102 ns 4 +Concat email stringa_median 104 ns 103 ns 4 +Concat email stringa_stddev 3.36 ns 5.03 ns 4 +Concat email stringa_cv 3.26 % 4.94 % 4 ----- Concatenate string + Number + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string and number by std to std::string_mean 319 ns 320 ns 4 -Concat std::string and number by std to std::string_median 320 ns 321 ns 4 -Concat std::string and number by std to std::string_stddev 5.66 ns 6.34 ns 4 -Concat std::string and number by std to std::string_cv 1.78 % 1.98 % 4 -Concat std::string and number by StrExpr to std::string_mean 207 ns 206 ns 4 -Concat std::string and number by StrExpr to std::string_median 205 ns 205 ns 4 -Concat std::string and number by StrExpr to std::string_stddev 5.26 ns 6.14 ns 4 -Concat std::string and number by StrExpr to std::string_cv 2.54 % 2.98 % 4 -Concat stringa and number by StrExpr to simstr::stringa_mean 106 ns 106 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_median 106 ns 106 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_stddev 2.07 ns 1.41 ns 4 +Concat std::string and number by std to std::string_mean 320 ns 320 ns 4 +Concat std::string and number by std to std::string_median 321 ns 322 ns 4 +Concat std::string and number by std to std::string_stddev 2.88 ns 3.84 ns 4 +Concat std::string and number by std to std::string_cv 0.90 % 1.20 % 4 +Concat std::string and number by StrExpr to std::string_mean 212 ns 211 ns 4 +Concat std::string and number by StrExpr to std::string_median 211 ns 210 ns 4 +Concat std::string and number by StrExpr to std::string_stddev 6.03 ns 6.14 ns 4 +Concat std::string and number by StrExpr to std::string_cv 2.84 % 2.91 % 4 +Concat stringa and number by StrExpr to simstr::stringa_mean 107 ns 106 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_median 108 ns 106 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_stddev 2.10 ns 1.41 ns 4 Concat stringa and number by StrExpr to simstr::stringa_cv 1.96 % 1.33 % 4 -Concat stringa and number by e_concat to simstr::stringa_mean 116 ns 115 ns 4 -Concat stringa and number by e_concat to simstr::stringa_median 116 ns 115 ns 4 -Concat stringa and number by e_concat to simstr::stringa_stddev 1.14 ns 1.22 ns 4 -Concat stringa and number by e_concat to simstr::stringa_cv 0.98 % 1.06 % 4 +Concat stringa and number by e_concat to simstr::stringa_mean 115 ns 115 ns 4 +Concat stringa and number by e_concat to simstr::stringa_median 115 ns 115 ns 4 +Concat stringa and number by e_concat to simstr::stringa_stddev 1.06 ns 2.85 ns 4 +Concat stringa and number by e_concat to simstr::stringa_cv 0.92 % 2.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 1020 ns 1013 ns 4 -Concat std::string and format hex number and literal to std::string_median 1008 ns 1001 ns 4 -Concat std::string and format hex number and literal to std::string_stddev 25.2 ns 42.3 ns 4 -Concat std::string and format hex number and literal to std::string_cv 2.47 % 4.17 % 4 -std::format std::string and hex number by literal to std::string_mean 1835 ns 1831 ns 4 -std::format std::string and hex number by literal to std::string_median 1843 ns 1842 ns 4 -std::format std::string and hex number by literal to std::string_stddev 29.2 ns 52.7 ns 4 -std::format std::string and hex number by literal to std::string_cv 1.59 % 2.88 % 4 -Concat std::string and std::to_chars and string to std::string_mean 248 ns 248 ns 4 -Concat std::string and std::to_chars and string to std::string_median 247 ns 246 ns 4 -Concat std::string and std::to_chars and string to std::string_stddev 4.85 ns 5.58 ns 4 -Concat std::string and std::to_chars and string to std::string_cv 1.95 % 2.25 % 4 -Concat std::string and hex number and literal by StrExpr to std::string_mean 116 ns 114 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_median 114 ns 113 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_stddev 5.47 ns 6.03 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_cv 4.71 % 5.27 % 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 101 ns 100 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 101 ns 101 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 1.80 ns 2.96 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 1.79 % 2.95 % 4 +Concat std::string and format hex number and literal to std::string_mean 1044 ns 1044 ns 4 +Concat std::string and format hex number and literal to std::string_median 1021 ns 1025 ns 4 +Concat std::string and format hex number and literal to std::string_stddev 70.4 ns 75.6 ns 4 +Concat std::string and format hex number and literal to std::string_cv 6.75 % 7.24 % 4 +std::format std::string and hex number by literal to std::string_mean 1832 ns 1842 ns 4 +std::format std::string and hex number by literal to std::string_median 1831 ns 1842 ns 4 +std::format std::string and hex number by literal to std::string_stddev 23.4 ns 0.000 ns 4 +std::format std::string and hex number by literal to std::string_cv 1.28 % 0.00 % 4 +Concat std::string and std::to_chars and string to std::string_mean 253 ns 253 ns 4 +Concat std::string and std::to_chars and string to std::string_median 252 ns 251 ns 4 +Concat std::string and std::to_chars and string to std::string_stddev 2.44 ns 2.79 ns 4 +Concat std::string and std::to_chars and string to std::string_cv 0.97 % 1.10 % 4 +Concat std::string and hex number and literal by StrExpr to std::string_mean 115 ns 114 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_median 115 ns 113 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_stddev 1.59 ns 2.67 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_cv 1.38 % 2.35 % 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 99.3 ns 99.5 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 99.0 ns 98.9 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 1.32 ns 2.34 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 1.33 % 2.35 % 4 Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 106 ns 106 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_median 106 ns 105 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 2.61 ns 3.66 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 2.47 % 3.47 % 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 173 ns 171 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 1.27 ns 1.74 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_cv 0.74 % 1.02 % 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 355 ns 354 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 356 ns 356 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 7.77 ns 8.01 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 2.19 % 2.27 % 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_median 106 ns 106 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 2.03 ns 2.34 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 1.92 % 2.21 % 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_mean 171 ns 171 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_median 171 ns 172 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 1.55 ns 2.09 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_cv 0.90 % 1.23 % 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 356 ns 357 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 356 ns 357 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 2.78 ns 4.43 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 0.78 % 1.24 % 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 681 ns 680 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 676 ns 680 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 20.8 ns 20.1 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 3.05 % 2.96 % 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 787 ns 788 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 786 ns 788 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 4.68 ns 8.05 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 0.59 % 1.02 % 4 -e_vsubst(pattern, i / 0x8a010_fmt)_mean 1128 ns 1111 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_median 1132 ns 1111 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_stddev 19.0 ns 14.1 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_cv 1.68 % 1.27 % 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 1576 ns 1577 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 1552 ns 1554 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 54.9 ns 59.4 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 3.49 % 3.77 % 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 1432 ns 1436 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 1439 ns 1444 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 30.9 ns 39.5 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.16 % 2.75 % 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1904 ns 1904 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_median 1903 ns 1904 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 15.7 ns 37.0 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_cv 0.82 % 1.94 % 4 -std::vformat(pattern, std::make_format_args(i))_mean 1932 ns 1937 ns 4 -std::vformat(pattern, std::make_format_args(i))_median 1927 ns 1918 ns 4 -std::vformat(pattern, std::make_format_args(i))_stddev 16.0 ns 38.4 ns 4 -std::vformat(pattern, std::make_format_args(i))_cv 0.83 % 1.98 % 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 7651 ns 7150 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 7239 ns 7150 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 870 ns 0.000 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 11.37 % 0.00 % 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_mean 698 ns 701 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 696 ns 698 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 17.9 ns 17.6 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 2.56 % 2.50 % 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 813 ns 798 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 819 ns 802 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 30.0 ns 21.9 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 3.69 % 2.75 % 4 +e_vsubst(pattern, i / 0x8a010_fmt)_mean 1118 ns 1117 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_median 1121 ns 1111 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_stddev 20.6 ns 23.4 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_cv 1.84 % 2.09 % 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 1550 ns 1535 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 1557 ns 1535 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 34.6 ns 31.3 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 2.23 % 2.04 % 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 1431 ns 1420 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 1414 ns 1397 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 47.7 ns 59.4 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 3.33 % 4.18 % 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_mean 1923 ns 1910 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_median 1924 ns 1910 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 57.3 ns 67.5 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_cv 2.98 % 3.54 % 4 +std::vformat(pattern, std::make_format_args(i))_mean 1941 ns 1916 ns 4 +std::vformat(pattern, std::make_format_args(i))_median 1902 ns 1882 ns 4 +std::vformat(pattern, std::make_format_args(i))_stddev 93.0 ns 119 ns 4 +std::vformat(pattern, std::make_format_args(i))_cv 4.79 % 6.22 % 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 7038 ns 6975 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 6948 ns 6888 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 295 ns 247 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 4.19 % 3.54 % 4 ----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string by std to std::string_mean 60.5 ns 60.3 ns 4 -Concat std::string by std to std::string_median 58.7 ns 58.6 ns 4 -Concat std::string by std to std::string_stddev 5.17 ns 4.61 ns 4 -Concat std::string by std to std::string_cv 8.53 % 7.64 % 4 -Concat std::string by StrExpr to std::string_mean 79.0 ns 78.9 ns 4 -Concat std::string by StrExpr to std::string_median 78.7 ns 78.5 ns 4 -Concat std::string by StrExpr to std::string_stddev 1.07 ns 0.872 ns 4 -Concat std::string by StrExpr to std::string_cv 1.35 % 1.10 % 4 -Concat stringa by StrExpr to stringa_mean 51.1 ns 50.6 ns 4 -Concat stringa by StrExpr to stringa_median 51.1 ns 50.2 ns 4 -Concat stringa by StrExpr to stringa_stddev 1.16 ns 0.698 ns 4 -Concat stringa by StrExpr to stringa_cv 2.28 % 1.38 % 4 +Concat std::string by std to std::string_mean 55.6 ns 55.1 ns 4 +Concat std::string by std to std::string_median 55.5 ns 55.1 ns 4 +Concat std::string by std to std::string_stddev 1.67 ns 1.80 ns 4 +Concat std::string by std to std::string_cv 3.01 % 3.27 % 4 +Concat std::string by StrExpr to std::string_mean 81.8 ns 81.5 ns 4 +Concat std::string by StrExpr to std::string_median 81.2 ns 81.1 ns 4 +Concat std::string by StrExpr to std::string_stddev 3.46 ns 2.98 ns 4 +Concat std::string by StrExpr to std::string_cv 4.23 % 3.65 % 4 +Concat stringa by StrExpr to stringa_mean 50.8 ns 50.8 ns 4 +Concat stringa by StrExpr to stringa_median 50.6 ns 50.0 ns 4 +Concat stringa by StrExpr to stringa_stddev 1.05 ns 1.56 ns 4 +Concat stringa by StrExpr to stringa_cv 2.06 % 3.08 % 4 ----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Find concat three std::string_mean 244 ns 244 ns 4 -Find concat three std::string_median 248 ns 246 ns 4 -Find concat three std::string_stddev 13.1 ns 12.4 ns 4 -Find concat three std::string_cv 5.39 % 5.07 % 4 -Find concat three strexpr_mean 121 ns 120 ns 4 -Find concat three strexpr_median 121 ns 119 ns 4 -Find concat three strexpr_stddev 3.18 ns 3.95 ns 4 -Find concat three strexpr_cv 2.63 % 3.29 % 4 -Find concat three simstr_mean 29.0 ns 29.0 ns 4 -Find concat three simstr_median 29.0 ns 29.2 ns 4 -Find concat three simstr_stddev 0.714 ns 0.601 ns 4 -Find concat three simstr_cv 2.46 % 2.07 % 4 +Find concat three std::string_mean 228 ns 226 ns 4 +Find concat three std::string_median 225 ns 222 ns 4 +Find concat three std::string_stddev 8.48 ns 10.1 ns 4 +Find concat three std::string_cv 3.72 % 4.46 % 4 +Find concat three strexpr_mean 132 ns 131 ns 4 +Find concat three strexpr_median 130 ns 129 ns 4 +Find concat three strexpr_stddev 11.6 ns 10.7 ns 4 +Find concat three strexpr_cv 8.74 % 8.15 % 4 +Find concat three simstr_mean 29.2 ns 29.2 ns 4 +Find concat three simstr_median 28.0 ns 27.9 ns 4 +Find concat three simstr_stddev 2.97 ns 3.18 ns 4 +Find concat three simstr_cv 10.14 % 10.90 % 4 +Find concat three stringzilla string_mean 228 ns 228 ns 4 +Find concat three stringzilla string_median 226 ns 228 ns 4 +Find concat three stringzilla string_stddev 7.19 ns 6.75 ns 4 +Find concat three stringzilla string_cv 3.16 % 2.97 % 4 ----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -BuildTypeNameStr 0/0_mean 17.3 ns 17.4 ns 4 -BuildTypeNameStr 0/0_median 17.3 ns 17.3 ns 4 -BuildTypeNameStr 0/0_stddev 0.246 ns 0.192 ns 4 -BuildTypeNameStr 0/0_cv 1.42 % 1.10 % 4 -BuildTypeNameExp 0/0_mean 13.1 ns 13.0 ns 4 -BuildTypeNameExp 0/0_median 12.8 ns 12.7 ns 4 -BuildTypeNameExp 0/0_stddev 0.706 ns 0.664 ns 4 -BuildTypeNameExp 0/0_cv 5.38 % 5.12 % 4 -BuildTypeNameSim 0/0_mean 15.2 ns 15.1 ns 4 -BuildTypeNameSim 0/0_median 15.1 ns 15.0 ns 4 -BuildTypeNameSim 0/0_stddev 0.379 ns 0.439 ns 4 -BuildTypeNameSim 0/0_cv 2.50 % 2.91 % 4 -BuildTypeNameStr 10/10_mean 81.8 ns 81.5 ns 4 -BuildTypeNameStr 10/10_median 81.9 ns 81.1 ns 4 -BuildTypeNameStr 10/10_stddev 1.87 ns 1.67 ns 4 -BuildTypeNameStr 10/10_cv 2.28 % 2.05 % 4 -BuildTypeNameExp 10/10_mean 38.8 ns 38.8 ns 4 -BuildTypeNameExp 10/10_median 38.9 ns 39.0 ns 4 -BuildTypeNameExp 10/10_stddev 0.987 ns 1.36 ns 4 -BuildTypeNameExp 10/10_cv 2.54 % 3.51 % 4 -BuildTypeNameSim 10/10_mean 36.4 ns 35.7 ns 4 -BuildTypeNameSim 10/10_median 36.4 ns 35.7 ns 4 -BuildTypeNameSim 10/10_stddev 0.258 ns 0.463 ns 4 -BuildTypeNameSim 10/10_cv 0.71 % 1.30 % 4 +BuildTypeNameStr 0/0_mean 18.1 ns 18.0 ns 4 +BuildTypeNameStr 0/0_median 18.0 ns 17.8 ns 4 +BuildTypeNameStr 0/0_stddev 0.371 ns 0.592 ns 4 +BuildTypeNameStr 0/0_cv 2.06 % 3.29 % 4 +BuildTypeNameExp 0/0_mean 14.5 ns 14.3 ns 4 +BuildTypeNameExp 0/0_median 14.5 ns 14.3 ns 4 +BuildTypeNameExp 0/0_stddev 0.455 ns 0.405 ns 4 +BuildTypeNameExp 0/0_cv 3.14 % 2.84 % 4 +BuildTypeNameSim 0/0_mean 16.3 ns 16.3 ns 4 +BuildTypeNameSim 0/0_median 16.4 ns 16.2 ns 4 +BuildTypeNameSim 0/0_stddev 0.221 ns 0.334 ns 4 +BuildTypeNameSim 0/0_cv 1.35 % 2.05 % 4 +BuildTypeNameStr 10/10_mean 85.7 ns 85.0 ns 4 +BuildTypeNameStr 10/10_median 85.8 ns 86.3 ns 4 +BuildTypeNameStr 10/10_stddev 1.85 ns 3.30 ns 4 +BuildTypeNameStr 10/10_cv 2.16 % 3.88 % 4 +BuildTypeNameExp 10/10_mean 40.1 ns 39.4 ns 4 +BuildTypeNameExp 10/10_median 38.7 ns 39.0 ns 4 +BuildTypeNameExp 10/10_stddev 3.23 ns 2.28 ns 4 +BuildTypeNameExp 10/10_cv 8.06 % 5.79 % 4 +BuildTypeNameSim 10/10_mean 40.1 ns 39.6 ns 4 +BuildTypeNameSim 10/10_median 39.9 ns 39.8 ns 4 +BuildTypeNameSim 10/10_stddev 1.93 ns 0.801 ns 4 +BuildTypeNameSim 10/10_cv 4.80 % 2.03 % 4 ----- Replace string by copy -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat with replace str_mean 351 ns 347 ns 4 -Concat with replace str_median 350 ns 349 ns 4 -Concat with replace str_stddev 8.58 ns 7.35 ns 4 -Concat with replace str_cv 2.45 % 2.12 % 4 -Concat with replace exp_mean 222 ns 221 ns 4 -Concat with replace exp_median 223 ns 220 ns 4 -Concat with replace exp_stddev 3.73 ns 4.34 ns 4 -Concat with replace exp_cv 1.68 % 1.96 % 4 +Concat with replace str_mean 366 ns 360 ns 4 +Concat with replace str_median 369 ns 366 ns 4 +Concat with replace str_stddev 30.7 ns 20.6 ns 4 +Concat with replace str_cv 8.41 % 5.73 % 4 +Concat with replace exp_mean 221 ns 221 ns 4 +Concat with replace exp_median 221 ns 222 ns 4 +Concat with replace exp_stddev 1.78 ns 5.01 ns 4 +Concat with replace exp_cv 0.81 % 2.27 % 4 ----- Create Empty Str ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e;_mean 2.86 ns 2.87 ns 4 -std::string e;_median 2.86 ns 2.86 ns 4 -std::string e;_stddev 0.032 ns 0.060 ns 4 -std::string e;_cv 1.10 % 2.09 % 4 -std::string_view e;_mean 1.81 ns 1.81 ns 4 -std::string_view e;_median 1.82 ns 1.80 ns 4 -std::string_view e;_stddev 0.038 ns 0.063 ns 4 -std::string_view e;_cv 2.07 % 3.47 % 4 -ssa e;_mean 1.50 ns 1.50 ns 4 -ssa e;_median 1.47 ns 1.46 ns 4 -ssa e;_stddev 0.102 ns 0.124 ns 4 -ssa e;_cv 6.79 % 8.28 % 4 -stringa e;_mean 2.23 ns 2.23 ns 4 -stringa e;_median 2.23 ns 2.22 ns 4 -stringa e;_stddev 0.033 ns 0.047 ns 4 -stringa e;_cv 1.49 % 2.09 % 4 -lstringa<20> e;_mean 2.57 ns 2.55 ns 4 -lstringa<20> e;_median 2.55 ns 2.57 ns 4 -lstringa<20> e;_stddev 0.045 ns 0.028 ns 4 -lstringa<20> e;_cv 1.74 % 1.09 % 4 -lstringa<40> e;_mean 2.58 ns 2.55 ns 4 -lstringa<40> e;_median 2.60 ns 2.55 ns 4 -lstringa<40> e;_stddev 0.058 ns 0.048 ns 4 -lstringa<40> e;_cv 2.25 % 1.90 % 4 +std::string e;_mean 3.25 ns 3.22 ns 4 +std::string e;_median 3.25 ns 3.22 ns 4 +std::string e;_stddev 0.019 ns 0.060 ns 4 +std::string e;_cv 0.59 % 1.86 % 4 +std::string_view e;_mean 1.85 ns 1.83 ns 4 +std::string_view e;_median 1.83 ns 1.84 ns 4 +std::string_view e;_stddev 0.051 ns 0.048 ns 4 +std::string_view e;_cv 2.77 % 2.64 % 4 +ssa e;_mean 1.45 ns 1.45 ns 4 +ssa e;_median 1.44 ns 1.44 ns 4 +ssa e;_stddev 0.027 ns 0.039 ns 4 +ssa e;_cv 1.88 % 2.72 % 4 +stringa e;_mean 2.20 ns 2.18 ns 4 +stringa e;_median 2.20 ns 2.20 ns 4 +stringa e;_stddev 0.017 ns 0.026 ns 4 +stringa e;_cv 0.77 % 1.20 % 4 +lstringa<20> e;_mean 2.59 ns 2.59 ns 4 +lstringa<20> e;_median 2.60 ns 2.59 ns 4 +lstringa<20> e;_stddev 0.070 ns 0.032 ns 4 +lstringa<20> e;_cv 2.71 % 1.24 % 4 +lstringa<40> e;_mean 2.62 ns 2.62 ns 4 +lstringa<40> e;_median 2.55 ns 2.57 ns 4 +lstringa<40> e;_stddev 0.177 ns 0.193 ns 4 +lstringa<40> e;_cv 6.76 % 7.37 % 4 ----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "Test text";_mean 2.56 ns 2.55 ns 4 -std::string e = "Test text";_median 2.56 ns 2.57 ns 4 -std::string e = "Test text";_stddev 0.022 ns 0.028 ns 4 -std::string e = "Test text";_cv 0.87 % 1.09 % 4 -std::string_view e = "Test text";_mean 1.81 ns 1.81 ns 4 -std::string_view e = "Test text";_median 1.81 ns 1.82 ns 4 -std::string_view e = "Test text";_stddev 0.020 ns 0.037 ns 4 -std::string_view e = "Test text";_cv 1.11 % 2.03 % 4 -ssa e = "Test text";_mean 1.82 ns 1.82 ns 4 -ssa e = "Test text";_median 1.82 ns 1.82 ns 4 -ssa e = "Test text";_stddev 0.008 ns 0.022 ns 4 -ssa e = "Test text";_cv 0.46 % 1.22 % 4 -stringa e = "Test text";_mean 2.84 ns 2.83 ns 4 -stringa e = "Test text";_median 2.84 ns 2.85 ns 4 -stringa e = "Test text";_stddev 0.028 ns 0.033 ns 4 -stringa e = "Test text";_cv 0.97 % 1.17 % 4 -lstringa<20> e = "Test text";_mean 2.56 ns 2.53 ns 4 -lstringa<20> e = "Test text";_median 2.56 ns 2.55 ns 4 -lstringa<20> e = "Test text";_stddev 0.026 ns 0.030 ns 4 -lstringa<20> e = "Test text";_cv 1.03 % 1.17 % 4 -lstringa<40> e = "Test text";_mean 2.54 ns 2.52 ns 4 -lstringa<40> e = "Test text";_median 2.53 ns 2.52 ns 4 -lstringa<40> e = "Test text";_stddev 0.042 ns 0.034 ns 4 -lstringa<40> e = "Test text";_cv 1.67 % 1.36 % 4 +std::string e = "Test text";_mean 2.67 ns 2.65 ns 4 +std::string e = "Test text";_median 2.68 ns 2.65 ns 4 +std::string e = "Test text";_stddev 0.092 ns 0.116 ns 4 +std::string e = "Test text";_cv 3.43 % 4.38 % 4 +std::string_view e = "Test text";_mean 1.84 ns 1.84 ns 4 +std::string_view e = "Test text";_median 1.84 ns 1.84 ns 4 +std::string_view e = "Test text";_stddev 0.032 ns 0.034 ns 4 +std::string_view e = "Test text";_cv 1.75 % 1.86 % 4 +ssa e = "Test text";_mean 1.87 ns 1.87 ns 4 +ssa e = "Test text";_median 1.86 ns 1.86 ns 4 +ssa e = "Test text";_stddev 0.045 ns 0.037 ns 4 +ssa e = "Test text";_cv 2.40 % 1.96 % 4 +stringa e = "Test text";_mean 2.86 ns 2.83 ns 4 +stringa e = "Test text";_median 2.86 ns 2.83 ns 4 +stringa e = "Test text";_stddev 0.041 ns 0.000 ns 4 +stringa e = "Test text";_cv 1.44 % 0.00 % 4 +lstringa<20> e = "Test text";_mean 2.55 ns 2.54 ns 4 +lstringa<20> e = "Test text";_median 2.54 ns 2.51 ns 4 +lstringa<20> e = "Test text";_stddev 0.046 ns 0.056 ns 4 +lstringa<20> e = "Test text";_cv 1.79 % 2.20 % 4 +lstringa<40> e = "Test text";_mean 2.53 ns 2.53 ns 4 +lstringa<40> e = "Test text";_median 2.53 ns 2.54 ns 4 +lstringa<40> e = "Test text";_stddev 0.029 ns 0.053 ns 4 +lstringa<40> e = "Test text";_cv 1.15 % 2.12 % 4 ----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "123456789012345678901234567890";_mean 79.4 ns 79.3 ns 4 -std::string e = "123456789012345678901234567890";_median 78.9 ns 79.3 ns 4 -std::string e = "123456789012345678901234567890";_stddev 1.50 ns 2.25 ns 4 -std::string e = "123456789012345678901234567890";_cv 1.89 % 2.84 % 4 -std::string_view e = "123456789012345678901234567890";_mean 1.82 ns 1.81 ns 4 -std::string_view e = "123456789012345678901234567890";_median 1.82 ns 1.80 ns 4 -std::string_view e = "123456789012345678901234567890";_stddev 0.018 ns 0.021 ns 4 -std::string_view e = "123456789012345678901234567890";_cv 1.00 % 1.16 % 4 -ssa e = "123456789012345678901234567890";_mean 1.79 ns 1.79 ns 4 -ssa e = "123456789012345678901234567890";_median 1.78 ns 1.80 ns 4 -ssa e = "123456789012345678901234567890";_stddev 0.016 ns 0.019 ns 4 -ssa e = "123456789012345678901234567890";_cv 0.90 % 1.07 % 4 -stringa e = "123456789012345678901234567890";_mean 2.55 ns 2.55 ns 4 -stringa e = "123456789012345678901234567890";_median 2.55 ns 2.54 ns 4 -stringa e = "123456789012345678901234567890";_stddev 0.052 ns 0.053 ns 4 -stringa e = "123456789012345678901234567890";_cv 2.05 % 2.09 % 4 -lstringa<20> e = "123456789012345678901234567890";_mean 76.3 ns 76.3 ns 4 -lstringa<20> e = "123456789012345678901234567890";_median 76.9 ns 76.7 ns 4 -lstringa<20> e = "123456789012345678901234567890";_stddev 1.63 ns 2.19 ns 4 -lstringa<20> e = "123456789012345678901234567890";_cv 2.14 % 2.88 % 4 -lstringa<40> e = "123456789012345678901234567890";_mean 3.25 ns 3.24 ns 4 -lstringa<40> e = "123456789012345678901234567890";_median 3.25 ns 3.24 ns 4 -lstringa<40> e = "123456789012345678901234567890";_stddev 0.016 ns 0.040 ns 4 -lstringa<40> e = "123456789012345678901234567890";_cv 0.49 % 1.24 % 4 +std::string e = "123456789012345678901234567890";_mean 73.6 ns 73.2 ns 4 +std::string e = "123456789012345678901234567890";_median 73.3 ns 73.2 ns 4 +std::string e = "123456789012345678901234567890";_stddev 0.788 ns 1.80 ns 4 +std::string e = "123456789012345678901234567890";_cv 1.07 % 2.46 % 4 +std::string_view e = "123456789012345678901234567890";_mean 1.83 ns 1.82 ns 4 +std::string_view e = "123456789012345678901234567890";_median 1.83 ns 1.82 ns 4 +std::string_view e = "123456789012345678901234567890";_stddev 0.046 ns 0.050 ns 4 +std::string_view e = "123456789012345678901234567890";_cv 2.53 % 2.72 % 4 +ssa e = "123456789012345678901234567890";_mean 1.81 ns 1.81 ns 4 +ssa e = "123456789012345678901234567890";_median 1.81 ns 1.80 ns 4 +ssa e = "123456789012345678901234567890";_stddev 0.010 ns 0.021 ns 4 +ssa e = "123456789012345678901234567890";_cv 0.54 % 1.16 % 4 +stringa e = "123456789012345678901234567890";_mean 2.54 ns 2.52 ns 4 +stringa e = "123456789012345678901234567890";_median 2.54 ns 2.52 ns 4 +stringa e = "123456789012345678901234567890";_stddev 0.062 ns 0.077 ns 4 +stringa e = "123456789012345678901234567890";_cv 2.43 % 3.04 % 4 +lstringa<20> e = "123456789012345678901234567890";_mean 75.1 ns 74.8 ns 4 +lstringa<20> e = "123456789012345678901234567890";_median 75.0 ns 74.3 ns 4 +lstringa<20> e = "123456789012345678901234567890";_stddev 1.37 ns 2.00 ns 4 +lstringa<20> e = "123456789012345678901234567890";_cv 1.82 % 2.68 % 4 +lstringa<40> e = "123456789012345678901234567890";_mean 3.27 ns 3.26 ns 4 +lstringa<40> e = "123456789012345678901234567890";_median 3.25 ns 3.26 ns 4 +lstringa<40> e = "123456789012345678901234567890";_stddev 0.080 ns 0.099 ns 4 +lstringa<40> e = "123456789012345678901234567890";_cv 2.46 % 3.04 % 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.08 ns 5.04 ns 4 -std::string e = "Test text"; auto c{e};_median 5.11 ns 5.08 ns 4 -std::string e = "Test text"; auto c{e};_stddev 0.120 ns 0.150 ns 4 -std::string e = "Test text"; auto c{e};_cv 2.36 % 2.97 % 4 +std::string e = "Test text"; auto c{e};_mean 5.10 ns 5.09 ns 4 +std::string e = "Test text"; auto c{e};_median 5.08 ns 5.09 ns 4 +std::string e = "Test text"; auto c{e};_stddev 0.037 ns 0.081 ns 4 +std::string e = "Test text"; auto c{e};_cv 0.72 % 1.58 % 4 std::string_view e = "Test text"; auto c{e};_mean 3.79 ns 3.79 ns 4 std::string_view e = "Test text"; auto c{e};_median 3.79 ns 3.77 ns 4 -std::string_view e = "Test text"; auto c{e};_stddev 0.013 ns 0.042 ns 4 -std::string_view e = "Test text"; auto c{e};_cv 0.34 % 1.10 % 4 -ssa e = "Test text"; auto c{e};_mean 3.76 ns 3.77 ns 4 -ssa e = "Test text"; auto c{e};_median 3.76 ns 3.77 ns 4 -ssa e = "Test text"; auto c{e};_stddev 0.018 ns 0.000 ns 4 -ssa e = "Test text"; auto c{e};_cv 0.48 % 0.00 % 4 -stringa e = "Test text"; auto c{e};_mean 4.03 ns 4.01 ns 4 -stringa e = "Test text"; auto c{e};_median 4.02 ns 4.01 ns 4 -stringa e = "Test text"; auto c{e};_stddev 0.100 ns 0.071 ns 4 -stringa e = "Test text"; auto c{e};_cv 2.47 % 1.77 % 4 -lstringa<20> e = "Test text"; auto c{e};_mean 4.27 ns 4.27 ns 4 -lstringa<20> e = "Test text"; auto c{e};_median 4.27 ns 4.30 ns 4 -lstringa<20> e = "Test text"; auto c{e};_stddev 0.007 ns 0.049 ns 4 -lstringa<20> e = "Test text"; auto c{e};_cv 0.17 % 1.14 % 4 -lstringa<40> e = "Test text"; auto c{e};_mean 4.54 ns 4.53 ns 4 -lstringa<40> e = "Test text"; auto c{e};_median 4.54 ns 4.53 ns 4 -lstringa<40> e = "Test text"; auto c{e};_stddev 0.073 ns 0.081 ns 4 -lstringa<40> e = "Test text"; auto c{e};_cv 1.62 % 1.78 % 4 +std::string_view e = "Test text"; auto c{e};_stddev 0.027 ns 0.040 ns 4 +std::string_view e = "Test text"; auto c{e};_cv 0.70 % 1.06 % 4 +ssa e = "Test text"; auto c{e};_mean 3.85 ns 3.83 ns 4 +ssa e = "Test text"; auto c{e};_median 3.80 ns 3.81 ns 4 +ssa e = "Test text"; auto c{e};_stddev 0.129 ns 0.080 ns 4 +ssa e = "Test text"; auto c{e};_cv 3.36 % 2.09 % 4 +stringa e = "Test text"; auto c{e};_mean 4.00 ns 3.95 ns 4 +stringa e = "Test text"; auto c{e};_median 3.97 ns 3.97 ns 4 +stringa e = "Test text"; auto c{e};_stddev 0.078 ns 0.083 ns 4 +stringa e = "Test text"; auto c{e};_cv 1.96 % 2.12 % 4 +lstringa<20> e = "Test text"; auto c{e};_mean 4.38 ns 4.37 ns 4 +lstringa<20> e = "Test text"; auto c{e};_median 4.36 ns 4.35 ns 4 +lstringa<20> e = "Test text"; auto c{e};_stddev 0.089 ns 0.093 ns 4 +lstringa<20> e = "Test text"; auto c{e};_cv 2.04 % 2.14 % 4 +lstringa<40> e = "Test text"; auto c{e};_mean 4.52 ns 4.52 ns 4 +lstringa<40> e = "Test text"; auto c{e};_median 4.51 ns 4.49 ns 4 +lstringa<40> e = "Test text"; auto c{e};_stddev 0.062 ns 0.049 ns 4 +lstringa<40> e = "Test text"; auto c{e};_cv 1.36 % 1.08 % 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 77.1 ns 77.2 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_median 77.1 ns 77.6 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_stddev 1.43 ns 1.67 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_cv 1.86 % 2.16 % 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 1.82 ns 1.81 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_median 1.81 ns 1.80 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.016 ns 0.019 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 0.88 % 1.06 % 4 -ssa e = "123456789012345678901234567890"; auto c{e};_mean 1.85 ns 1.85 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_median 1.85 ns 1.84 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.016 ns 0.019 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_cv 0.89 % 1.04 % 4 -stringa e = "123456789012345678901234567890"; auto c{e};_mean 2.97 ns 2.97 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_median 2.99 ns 2.98 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.060 ns 0.060 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_cv 2.03 % 2.03 % 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 77.3 ns 77.4 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 77.1 ns 76.4 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 2.02 ns 2.96 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 2.61 % 3.82 % 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 7.40 ns 7.37 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 7.43 ns 7.32 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.079 ns 0.087 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 1.07 % 1.18 % 4 +std::string e = "123456789012345678901234567890"; auto c{e};_mean 78.3 ns 78.5 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_median 78.1 ns 78.5 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_stddev 1.44 ns 2.01 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_cv 1.84 % 2.57 % 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 1.85 ns 1.84 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_median 1.82 ns 1.80 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.058 ns 0.077 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 3.13 % 4.17 % 4 +ssa e = "123456789012345678901234567890"; auto c{e};_mean 1.81 ns 1.80 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_median 1.81 ns 1.81 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.025 ns 0.023 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_cv 1.39 % 1.26 % 4 +stringa e = "123456789012345678901234567890"; auto c{e};_mean 2.93 ns 2.93 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_median 2.94 ns 2.95 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.073 ns 0.063 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_cv 2.48 % 2.16 % 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 82.0 ns 80.6 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 80.9 ns 80.6 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 4.16 ns 3.62 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 5.08 % 4.50 % 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 7.56 ns 7.54 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 7.52 ns 7.59 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.330 ns 0.360 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 4.37 % 4.77 % 4 ----- Find 9 symbols text in end of 99 symbols text ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string::find;_mean 41.3 ns 41.0 ns 4 -std::string::find;_median 41.4 ns 41.3 ns 4 -std::string::find;_stddev 0.206 ns 0.868 ns 4 -std::string::find;_cv 0.50 % 2.12 % 4 -std::string_view::find;_mean 39.2 ns 39.3 ns 4 -std::string_view::find;_median 39.2 ns 39.3 ns 4 -std::string_view::find;_stddev 0.182 ns 0.683 ns 4 -std::string_view::find;_cv 0.46 % 1.74 % 4 -ssa::find;_mean 20.4 ns 20.4 ns 4 -ssa::find;_median 20.4 ns 20.5 ns 4 -ssa::find;_stddev 0.164 ns 0.209 ns 4 -ssa::find;_cv 0.81 % 1.03 % 4 -stringa::find;_mean 29.3 ns 29.3 ns 4 -stringa::find;_median 29.4 ns 29.5 ns 4 -stringa::find;_stddev 0.928 ns 0.634 ns 4 -stringa::find;_cv 3.17 % 2.16 % 4 -lstringa<20>::find;_mean 20.7 ns 20.7 ns 4 -lstringa<20>::find;_median 20.6 ns 20.6 ns 4 -lstringa<20>::find;_stddev 0.289 ns 0.434 ns 4 -lstringa<20>::find;_cv 1.40 % 2.09 % 4 -lstringa<40>::find;_mean 22.1 ns 22.1 ns 4 -lstringa<40>::find;_median 22.1 ns 22.0 ns 4 -lstringa<40>::find;_stddev 0.774 ns 0.732 ns 4 -lstringa<40>::find;_cv 3.50 % 3.31 % 4 +sz::string::find;_mean 115 ns 116 ns 4 +sz::string::find;_median 115 ns 116 ns 4 +sz::string::find;_stddev 1.37 ns 1.41 ns 4 +sz::string::find;_cv 1.19 % 1.22 % 4 +std::string::find;_mean 39.0 ns 39.0 ns 4 +std::string::find;_median 38.9 ns 39.0 ns 4 +std::string::find;_stddev 0.632 ns 1.05 ns 4 +std::string::find;_cv 1.62 % 2.69 % 4 +std::string_view::find;_mean 40.1 ns 40.1 ns 4 +std::string_view::find;_median 39.8 ns 39.7 ns 4 +std::string_view::find;_stddev 1.51 ns 1.88 ns 4 +std::string_view::find;_cv 3.78 % 4.70 % 4 +ssa::find;_mean 21.4 ns 21.3 ns 4 +ssa::find;_median 21.5 ns 21.3 ns 4 +ssa::find;_stddev 0.564 ns 0.370 ns 4 +ssa::find;_cv 2.63 % 1.74 % 4 +stringa::find;_mean 30.1 ns 30.2 ns 4 +stringa::find;_median 30.4 ns 30.5 ns 4 +stringa::find;_stddev 1.30 ns 1.75 ns 4 +stringa::find;_cv 4.33 % 5.81 % 4 +lstringa<20>::find;_mean 22.0 ns 21.5 ns 4 +lstringa<20>::find;_median 21.3 ns 21.2 ns 4 +lstringa<20>::find;_stddev 1.49 ns 0.691 ns 4 +lstringa<20>::find;_cv 6.77 % 3.21 % 4 +lstringa<40>::find;_mean 20.7 ns 20.6 ns 4 +lstringa<40>::find;_median 20.7 ns 20.6 ns 4 +lstringa<40>::find;_stddev 0.125 ns 0.262 ns 4 +lstringa<40>::find;_cv 0.60 % 1.27 % 4 ------- Copy not literal Str with N symbols ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string copy{str_with_len_N};/15_mean 4.42 ns 4.40 ns 4 -std::string copy{str_with_len_N};/15_median 4.42 ns 4.40 ns 4 -std::string copy{str_with_len_N};/15_stddev 0.023 ns 0.058 ns 4 -std::string copy{str_with_len_N};/15_cv 0.53 % 1.33 % 4 -std::string copy{str_with_len_N};/16_mean 82.2 ns 82.4 ns 4 -std::string copy{str_with_len_N};/16_median 82.2 ns 82.0 ns 4 -std::string copy{str_with_len_N};/16_stddev 0.768 ns 0.872 ns 4 -std::string copy{str_with_len_N};/16_cv 0.93 % 1.06 % 4 -std::string copy{str_with_len_N};/23_mean 83.3 ns 83.3 ns 4 -std::string copy{str_with_len_N};/23_median 83.4 ns 83.7 ns 4 -std::string copy{str_with_len_N};/23_stddev 1.69 ns 0.872 ns 4 -std::string copy{str_with_len_N};/23_cv 2.03 % 1.05 % 4 -std::string copy{str_with_len_N};/24_mean 80.7 ns 80.6 ns 4 -std::string copy{str_with_len_N};/24_median 80.6 ns 80.2 ns 4 -std::string copy{str_with_len_N};/24_stddev 0.679 ns 1.34 ns 4 -std::string copy{str_with_len_N};/24_cv 0.84 % 1.66 % 4 -std::string copy{str_with_len_N};/32_mean 84.3 ns 84.2 ns 4 -std::string copy{str_with_len_N};/32_median 84.6 ns 83.7 ns 4 -std::string copy{str_with_len_N};/32_stddev 2.70 ns 3.14 ns 4 -std::string copy{str_with_len_N};/32_cv 3.20 % 3.73 % 4 -std::string copy{str_with_len_N};/64_mean 88.8 ns 89.1 ns 4 -std::string copy{str_with_len_N};/64_median 88.3 ns 89.1 ns 4 -std::string copy{str_with_len_N};/64_stddev 1.64 ns 1.41 ns 4 -std::string copy{str_with_len_N};/64_cv 1.84 % 1.58 % 4 -std::string copy{str_with_len_N};/128_mean 90.4 ns 90.5 ns 4 -std::string copy{str_with_len_N};/128_median 87.6 ns 88.9 ns 4 -std::string copy{str_with_len_N};/128_stddev 6.20 ns 5.50 ns 4 -std::string copy{str_with_len_N};/128_cv 6.86 % 6.08 % 4 -std::string copy{str_with_len_N};/256_mean 89.8 ns 89.8 ns 4 -std::string copy{str_with_len_N};/256_median 90.2 ns 90.7 ns 4 -std::string copy{str_with_len_N};/256_stddev 1.12 ns 1.74 ns 4 -std::string copy{str_with_len_N};/256_cv 1.24 % 1.94 % 4 -std::string copy{str_with_len_N};/512_mean 93.0 ns 92.6 ns 4 -std::string copy{str_with_len_N};/512_median 93.3 ns 93.1 ns 4 -std::string copy{str_with_len_N};/512_stddev 1.94 ns 2.00 ns 4 -std::string copy{str_with_len_N};/512_cv 2.09 % 2.16 % 4 -std::string copy{str_with_len_N};/1024_mean 109 ns 109 ns 4 -std::string copy{str_with_len_N};/1024_median 109 ns 109 ns 4 -std::string copy{str_with_len_N};/1024_stddev 5.83 ns 5.50 ns 4 -std::string copy{str_with_len_N};/1024_cv 5.34 % 5.03 % 4 -std::string copy{str_with_len_N};/2048_mean 131 ns 131 ns 4 -std::string copy{str_with_len_N};/2048_median 131 ns 130 ns 4 -std::string copy{str_with_len_N};/2048_stddev 3.96 ns 3.95 ns 4 -std::string copy{str_with_len_N};/2048_cv 3.02 % 3.01 % 4 -std::string copy{str_with_len_N};/4096_mean 181 ns 180 ns 4 -std::string copy{str_with_len_N};/4096_median 180 ns 178 ns 4 -std::string copy{str_with_len_N};/4096_stddev 3.61 ns 5.43 ns 4 -std::string copy{str_with_len_N};/4096_cv 2.00 % 3.01 % 4 -stringa copy{str_with_len_N};/15_mean 4.04 ns 4.02 ns 4 -stringa copy{str_with_len_N};/15_median 4.03 ns 3.98 ns 4 -stringa copy{str_with_len_N};/15_stddev 0.076 ns 0.118 ns 4 -stringa copy{str_with_len_N};/15_cv 1.89 % 2.95 % 4 -stringa copy{str_with_len_N};/16_mean 4.08 ns 4.06 ns 4 -stringa copy{str_with_len_N};/16_median 4.09 ns 4.04 ns 4 -stringa copy{str_with_len_N};/16_stddev 0.073 ns 0.087 ns 4 -stringa copy{str_with_len_N};/16_cv 1.79 % 2.14 % 4 -stringa copy{str_with_len_N};/23_mean 3.96 ns 3.92 ns 4 -stringa copy{str_with_len_N};/23_median 3.96 ns 3.90 ns 4 -stringa copy{str_with_len_N};/23_stddev 0.051 ns 0.045 ns 4 -stringa copy{str_with_len_N};/23_cv 1.30 % 1.16 % 4 -stringa copy{str_with_len_N};/24_mean 18.2 ns 18.2 ns 4 -stringa copy{str_with_len_N};/24_median 18.2 ns 18.2 ns 4 -stringa copy{str_with_len_N};/24_stddev 0.087 ns 0.242 ns 4 -stringa copy{str_with_len_N};/24_cv 0.48 % 1.33 % 4 -stringa copy{str_with_len_N};/32_mean 18.2 ns 18.2 ns 4 -stringa copy{str_with_len_N};/32_median 18.2 ns 18.2 ns 4 -stringa copy{str_with_len_N};/32_stddev 0.062 ns 0.242 ns 4 -stringa copy{str_with_len_N};/32_cv 0.34 % 1.33 % 4 +std::string copy{str_with_len_N};/15_mean 4.42 ns 4.36 ns 4 +std::string copy{str_with_len_N};/15_median 4.47 ns 4.38 ns 4 +std::string copy{str_with_len_N};/15_stddev 0.144 ns 0.090 ns 4 +std::string copy{str_with_len_N};/15_cv 3.27 % 2.07 % 4 +std::string copy{str_with_len_N};/16_mean 81.3 ns 81.1 ns 4 +std::string copy{str_with_len_N};/16_median 81.6 ns 81.6 ns 4 +std::string copy{str_with_len_N};/16_stddev 3.91 ns 4.31 ns 4 +std::string copy{str_with_len_N};/16_cv 4.81 % 5.32 % 4 +std::string copy{str_with_len_N};/23_mean 78.6 ns 78.0 ns 4 +std::string copy{str_with_len_N};/23_median 78.3 ns 77.6 ns 4 +std::string copy{str_with_len_N};/23_stddev 1.94 ns 1.67 ns 4 +std::string copy{str_with_len_N};/23_cv 2.46 % 2.14 % 4 +std::string copy{str_with_len_N};/24_mean 79.8 ns 79.8 ns 4 +std::string copy{str_with_len_N};/24_median 79.9 ns 80.2 ns 4 +std::string copy{str_with_len_N};/24_stddev 1.27 ns 2.19 ns 4 +std::string copy{str_with_len_N};/24_cv 1.59 % 2.75 % 4 +std::string copy{str_with_len_N};/32_mean 83.8 ns 83.7 ns 4 +std::string copy{str_with_len_N};/32_median 83.2 ns 82.8 ns 4 +std::string copy{str_with_len_N};/32_stddev 4.07 ns 3.77 ns 4 +std::string copy{str_with_len_N};/32_cv 4.86 % 4.50 % 4 +std::string copy{str_with_len_N};/64_mean 81.7 ns 81.5 ns 4 +std::string copy{str_with_len_N};/64_median 81.6 ns 81.1 ns 4 +std::string copy{str_with_len_N};/64_stddev 0.544 ns 1.67 ns 4 +std::string copy{str_with_len_N};/64_cv 0.67 % 2.05 % 4 +std::string copy{str_with_len_N};/128_mean 87.7 ns 87.2 ns 4 +std::string copy{str_with_len_N};/128_median 86.8 ns 86.3 ns 4 +std::string copy{str_with_len_N};/128_stddev 3.38 ns 3.77 ns 4 +std::string copy{str_with_len_N};/128_cv 3.86 % 4.32 % 4 +std::string copy{str_with_len_N};/256_mean 88.5 ns 88.5 ns 4 +std::string copy{str_with_len_N};/256_median 88.1 ns 88.1 ns 4 +std::string copy{str_with_len_N};/256_stddev 2.63 ns 2.98 ns 4 +std::string copy{str_with_len_N};/256_cv 2.97 % 3.37 % 4 +std::string copy{str_with_len_N};/512_mean 92.7 ns 92.1 ns 4 +std::string copy{str_with_len_N};/512_median 92.8 ns 92.1 ns 4 +std::string copy{str_with_len_N};/512_stddev 1.52 ns 1.71 ns 4 +std::string copy{str_with_len_N};/512_cv 1.64 % 1.86 % 4 +std::string copy{str_with_len_N};/1024_mean 97.1 ns 96.4 ns 4 +std::string copy{str_with_len_N};/1024_median 97.0 ns 97.7 ns 4 +std::string copy{str_with_len_N};/1024_stddev 2.83 ns 4.67 ns 4 +std::string copy{str_with_len_N};/1024_cv 2.92 % 4.85 % 4 +std::string copy{str_with_len_N};/2048_mean 129 ns 128 ns 4 +std::string copy{str_with_len_N};/2048_median 129 ns 127 ns 4 +std::string copy{str_with_len_N};/2048_stddev 4.16 ns 4.77 ns 4 +std::string copy{str_with_len_N};/2048_cv 3.23 % 3.73 % 4 +std::string copy{str_with_len_N};/4096_mean 180 ns 179 ns 4 +std::string copy{str_with_len_N};/4096_median 179 ns 178 ns 4 +std::string copy{str_with_len_N};/4096_stddev 2.90 ns 4.01 ns 4 +std::string copy{str_with_len_N};/4096_cv 1.61 % 2.24 % 4 +stringa copy{str_with_len_N};/15_mean 4.00 ns 4.01 ns 4 +stringa copy{str_with_len_N};/15_median 3.99 ns 4.04 ns 4 +stringa copy{str_with_len_N};/15_stddev 0.067 ns 0.087 ns 4 +stringa copy{str_with_len_N};/15_cv 1.68 % 2.16 % 4 +stringa copy{str_with_len_N};/16_mean 4.02 ns 4.04 ns 4 +stringa copy{str_with_len_N};/16_median 4.02 ns 4.06 ns 4 +stringa copy{str_with_len_N};/16_stddev 0.044 ns 0.080 ns 4 +stringa copy{str_with_len_N};/16_cv 1.10 % 1.98 % 4 +stringa copy{str_with_len_N};/23_mean 4.10 ns 4.01 ns 4 +stringa copy{str_with_len_N};/23_median 4.02 ns 3.97 ns 4 +stringa copy{str_with_len_N};/23_stddev 0.236 ns 0.123 ns 4 +stringa copy{str_with_len_N};/23_cv 5.76 % 3.07 % 4 +stringa copy{str_with_len_N};/24_mean 18.4 ns 18.4 ns 4 +stringa copy{str_with_len_N};/24_median 18.3 ns 18.4 ns 4 +stringa copy{str_with_len_N};/24_stddev 0.305 ns 0.342 ns 4 +stringa copy{str_with_len_N};/24_cv 1.66 % 1.86 % 4 +stringa copy{str_with_len_N};/32_mean 18.4 ns 18.3 ns 4 +stringa copy{str_with_len_N};/32_median 18.3 ns 18.4 ns 4 +stringa copy{str_with_len_N};/32_stddev 0.112 ns 0.192 ns 4 +stringa copy{str_with_len_N};/32_cv 0.61 % 1.05 % 4 stringa copy{str_with_len_N};/64_mean 18.3 ns 18.3 ns 4 -stringa copy{str_with_len_N};/64_median 18.3 ns 18.4 ns 4 -stringa copy{str_with_len_N};/64_stddev 0.080 ns 0.192 ns 4 -stringa copy{str_with_len_N};/64_cv 0.44 % 1.05 % 4 +stringa copy{str_with_len_N};/64_median 18.3 ns 18.2 ns 4 +stringa copy{str_with_len_N};/64_stddev 0.112 ns 0.401 ns 4 +stringa copy{str_with_len_N};/64_cv 0.61 % 2.19 % 4 stringa copy{str_with_len_N};/128_mean 18.4 ns 18.4 ns 4 -stringa copy{str_with_len_N};/128_median 18.3 ns 18.4 ns 4 -stringa copy{str_with_len_N};/128_stddev 0.188 ns 0.000 ns 4 -stringa copy{str_with_len_N};/128_cv 1.02 % 0.00 % 4 -stringa copy{str_with_len_N};/256_mean 18.3 ns 18.3 ns 4 -stringa copy{str_with_len_N};/256_median 18.3 ns 18.4 ns 4 -stringa copy{str_with_len_N};/256_stddev 0.100 ns 0.209 ns 4 -stringa copy{str_with_len_N};/256_cv 0.54 % 1.14 % 4 -stringa copy{str_with_len_N};/512_mean 18.4 ns 18.3 ns 4 -stringa copy{str_with_len_N};/512_median 18.4 ns 18.4 ns 4 -stringa copy{str_with_len_N};/512_stddev 0.097 ns 0.209 ns 4 -stringa copy{str_with_len_N};/512_cv 0.53 % 1.14 % 4 -stringa copy{str_with_len_N};/1024_mean 19.1 ns 19.0 ns 4 -stringa copy{str_with_len_N};/1024_median 18.4 ns 18.2 ns 4 -stringa copy{str_with_len_N};/1024_stddev 1.45 ns 1.67 ns 4 -stringa copy{str_with_len_N};/1024_cv 7.61 % 8.81 % 4 -stringa copy{str_with_len_N};/2048_mean 18.3 ns 18.3 ns 4 -stringa copy{str_with_len_N};/2048_median 18.3 ns 18.4 ns 4 -stringa copy{str_with_len_N};/2048_stddev 0.111 ns 0.192 ns 4 -stringa copy{str_with_len_N};/2048_cv 0.61 % 1.05 % 4 -stringa copy{str_with_len_N};/4096_mean 18.4 ns 18.3 ns 4 -stringa copy{str_with_len_N};/4096_median 18.5 ns 18.4 ns 4 -stringa copy{str_with_len_N};/4096_stddev 0.058 ns 0.209 ns 4 -stringa copy{str_with_len_N};/4096_cv 0.31 % 1.14 % 4 -lstringa<16> copy{str_with_len_N};/15_mean 4.91 ns 4.89 ns 4 -lstringa<16> copy{str_with_len_N};/15_median 4.91 ns 4.92 ns 4 -lstringa<16> copy{str_with_len_N};/15_stddev 0.074 ns 0.104 ns 4 -lstringa<16> copy{str_with_len_N};/15_cv 1.52 % 2.12 % 4 -lstringa<16> copy{str_with_len_N};/16_mean 9.01 ns 9.02 ns 4 -lstringa<16> copy{str_with_len_N};/16_median 9.00 ns 8.98 ns 4 -lstringa<16> copy{str_with_len_N};/16_stddev 0.154 ns 0.167 ns 4 -lstringa<16> copy{str_with_len_N};/16_cv 1.71 % 1.85 % 4 -lstringa<16> copy{str_with_len_N};/23_mean 9.15 ns 9.05 ns 4 -lstringa<16> copy{str_with_len_N};/23_median 9.20 ns 9.00 ns 4 -lstringa<16> copy{str_with_len_N};/23_stddev 0.332 ns 0.314 ns 4 -lstringa<16> copy{str_with_len_N};/23_cv 3.63 % 3.47 % 4 -lstringa<16> copy{str_with_len_N};/24_mean 79.3 ns 79.3 ns 4 -lstringa<16> copy{str_with_len_N};/24_median 79.3 ns 79.3 ns 4 -lstringa<16> copy{str_with_len_N};/24_stddev 0.727 ns 1.01 ns 4 -lstringa<16> copy{str_with_len_N};/24_cv 0.92 % 1.27 % 4 -lstringa<16> copy{str_with_len_N};/32_mean 81.4 ns 81.6 ns 4 -lstringa<16> copy{str_with_len_N};/32_median 81.6 ns 81.6 ns 4 -lstringa<16> copy{str_with_len_N};/32_stddev 1.16 ns 1.71 ns 4 -lstringa<16> copy{str_with_len_N};/32_cv 1.42 % 2.09 % 4 -lstringa<16> copy{str_with_len_N};/64_mean 89.5 ns 87.9 ns 4 -lstringa<16> copy{str_with_len_N};/64_median 87.3 ns 86.7 ns 4 -lstringa<16> copy{str_with_len_N};/64_stddev 6.15 ns 5.27 ns 4 -lstringa<16> copy{str_with_len_N};/64_cv 6.87 % 6.00 % 4 -lstringa<16> copy{str_with_len_N};/128_mean 86.7 ns 85.9 ns 4 -lstringa<16> copy{str_with_len_N};/128_median 87.1 ns 86.3 ns 4 -lstringa<16> copy{str_with_len_N};/128_stddev 1.32 ns 1.67 ns 4 -lstringa<16> copy{str_with_len_N};/128_cv 1.53 % 1.94 % 4 -lstringa<16> copy{str_with_len_N};/256_mean 86.3 ns 86.3 ns 4 -lstringa<16> copy{str_with_len_N};/256_median 85.8 ns 87.2 ns 4 -lstringa<16> copy{str_with_len_N};/256_stddev 1.60 ns 1.74 ns 4 -lstringa<16> copy{str_with_len_N};/256_cv 1.85 % 2.02 % 4 -lstringa<16> copy{str_with_len_N};/512_mean 90.0 ns 89.7 ns 4 -lstringa<16> copy{str_with_len_N};/512_median 88.8 ns 89.1 ns 4 -lstringa<16> copy{str_with_len_N};/512_stddev 2.66 ns 2.34 ns 4 -lstringa<16> copy{str_with_len_N};/512_cv 2.96 % 2.61 % 4 -lstringa<16> copy{str_with_len_N};/1024_mean 99.4 ns 99.4 ns 4 -lstringa<16> copy{str_with_len_N};/1024_median 98.9 ns 99.4 ns 4 -lstringa<16> copy{str_with_len_N};/1024_stddev 3.30 ns 2.70 ns 4 -lstringa<16> copy{str_with_len_N};/1024_cv 3.32 % 2.72 % 4 -lstringa<16> copy{str_with_len_N};/2048_mean 128 ns 128 ns 4 -lstringa<16> copy{str_with_len_N};/2048_median 129 ns 128 ns 4 -lstringa<16> copy{str_with_len_N};/2048_stddev 2.93 ns 1.40 ns 4 -lstringa<16> copy{str_with_len_N};/2048_cv 2.29 % 1.09 % 4 -lstringa<16> copy{str_with_len_N};/4096_mean 189 ns 188 ns 4 -lstringa<16> copy{str_with_len_N};/4096_median 189 ns 188 ns 4 -lstringa<16> copy{str_with_len_N};/4096_stddev 0.863 ns 3.42 ns 4 -lstringa<16> copy{str_with_len_N};/4096_cv 0.46 % 1.81 % 4 -lstringa<512> copy{str_with_len_N};/15_mean 4.07 ns 4.05 ns 4 -lstringa<512> copy{str_with_len_N};/15_median 4.06 ns 4.05 ns 4 -lstringa<512> copy{str_with_len_N};/15_stddev 0.080 ns 0.113 ns 4 -lstringa<512> copy{str_with_len_N};/15_cv 1.98 % 2.78 % 4 -lstringa<512> copy{str_with_len_N};/16_mean 9.17 ns 9.11 ns 4 -lstringa<512> copy{str_with_len_N};/16_median 9.23 ns 9.16 ns 4 -lstringa<512> copy{str_with_len_N};/16_stddev 0.178 ns 0.167 ns 4 -lstringa<512> copy{str_with_len_N};/16_cv 1.94 % 1.83 % 4 -lstringa<512> copy{str_with_len_N};/23_mean 9.33 ns 9.31 ns 4 -lstringa<512> copy{str_with_len_N};/23_median 9.25 ns 9.21 ns 4 -lstringa<512> copy{str_with_len_N};/23_stddev 0.361 ns 0.362 ns 4 -lstringa<512> copy{str_with_len_N};/23_cv 3.87 % 3.89 % 4 -lstringa<512> copy{str_with_len_N};/24_mean 9.11 ns 9.09 ns 4 -lstringa<512> copy{str_with_len_N};/24_median 9.11 ns 9.03 ns 4 -lstringa<512> copy{str_with_len_N};/24_stddev 0.099 ns 0.122 ns 4 -lstringa<512> copy{str_with_len_N};/24_cv 1.09 % 1.34 % 4 -lstringa<512> copy{str_with_len_N};/32_mean 12.1 ns 12.1 ns 4 -lstringa<512> copy{str_with_len_N};/32_median 12.1 ns 12.0 ns 4 -lstringa<512> copy{str_with_len_N};/32_stddev 0.244 ns 0.351 ns 4 -lstringa<512> copy{str_with_len_N};/32_cv 2.01 % 2.91 % 4 -lstringa<512> copy{str_with_len_N};/64_mean 12.3 ns 12.3 ns 4 -lstringa<512> copy{str_with_len_N};/64_median 12.3 ns 12.3 ns 4 -lstringa<512> copy{str_with_len_N};/64_stddev 0.172 ns 0.228 ns 4 -lstringa<512> copy{str_with_len_N};/64_cv 1.40 % 1.86 % 4 -lstringa<512> copy{str_with_len_N};/128_mean 12.5 ns 12.5 ns 4 -lstringa<512> copy{str_with_len_N};/128_median 12.4 ns 12.5 ns 4 -lstringa<512> copy{str_with_len_N};/128_stddev 0.366 ns 0.307 ns 4 -lstringa<512> copy{str_with_len_N};/128_cv 2.93 % 2.46 % 4 +stringa copy{str_with_len_N};/128_median 18.3 ns 18.2 ns 4 +stringa copy{str_with_len_N};/128_stddev 0.423 ns 0.592 ns 4 +stringa copy{str_with_len_N};/128_cv 2.29 % 3.21 % 4 +stringa copy{str_with_len_N};/256_mean 18.3 ns 18.2 ns 4 +stringa copy{str_with_len_N};/256_median 18.2 ns 18.2 ns 4 +stringa copy{str_with_len_N};/256_stddev 0.079 ns 0.242 ns 4 +stringa copy{str_with_len_N};/256_cv 0.43 % 1.33 % 4 +stringa copy{str_with_len_N};/512_mean 18.2 ns 18.2 ns 4 +stringa copy{str_with_len_N};/512_median 18.2 ns 18.2 ns 4 +stringa copy{str_with_len_N};/512_stddev 0.197 ns 0.222 ns 4 +stringa copy{str_with_len_N};/512_cv 1.08 % 1.22 % 4 +stringa copy{str_with_len_N};/1024_mean 18.2 ns 18.2 ns 4 +stringa copy{str_with_len_N};/1024_median 18.2 ns 18.2 ns 4 +stringa copy{str_with_len_N};/1024_stddev 0.026 ns 0.222 ns 4 +stringa copy{str_with_len_N};/1024_cv 0.14 % 1.22 % 4 +stringa copy{str_with_len_N};/2048_mean 18.3 ns 18.2 ns 4 +stringa copy{str_with_len_N};/2048_median 18.3 ns 18.0 ns 4 +stringa copy{str_with_len_N};/2048_stddev 0.170 ns 0.384 ns 4 +stringa copy{str_with_len_N};/2048_cv 0.93 % 2.11 % 4 +stringa copy{str_with_len_N};/4096_mean 18.3 ns 18.2 ns 4 +stringa copy{str_with_len_N};/4096_median 18.3 ns 18.2 ns 4 +stringa copy{str_with_len_N};/4096_stddev 0.148 ns 0.222 ns 4 +stringa copy{str_with_len_N};/4096_cv 0.81 % 1.22 % 4 +lstringa<16> copy{str_with_len_N};/15_mean 4.84 ns 4.81 ns 4 +lstringa<16> copy{str_with_len_N};/15_median 4.85 ns 4.81 ns 4 +lstringa<16> copy{str_with_len_N};/15_stddev 0.016 ns 0.081 ns 4 +lstringa<16> copy{str_with_len_N};/15_cv 0.33 % 1.67 % 4 +lstringa<16> copy{str_with_len_N};/16_mean 8.98 ns 9.00 ns 4 +lstringa<16> copy{str_with_len_N};/16_median 8.93 ns 9.00 ns 4 +lstringa<16> copy{str_with_len_N};/16_stddev 0.148 ns 0.171 ns 4 +lstringa<16> copy{str_with_len_N};/16_cv 1.64 % 1.90 % 4 +lstringa<16> copy{str_with_len_N};/23_mean 9.08 ns 9.10 ns 4 +lstringa<16> copy{str_with_len_N};/23_median 9.07 ns 9.10 ns 4 +lstringa<16> copy{str_with_len_N};/23_stddev 0.196 ns 0.121 ns 4 +lstringa<16> copy{str_with_len_N};/23_cv 2.16 % 1.33 % 4 +lstringa<16> copy{str_with_len_N};/24_mean 81.2 ns 81.1 ns 4 +lstringa<16> copy{str_with_len_N};/24_median 81.4 ns 82.0 ns 4 +lstringa<16> copy{str_with_len_N};/24_stddev 1.51 ns 1.74 ns 4 +lstringa<16> copy{str_with_len_N};/24_cv 1.86 % 2.15 % 4 +lstringa<16> copy{str_with_len_N};/32_mean 85.0 ns 84.6 ns 4 +lstringa<16> copy{str_with_len_N};/32_median 84.7 ns 85.4 ns 4 +lstringa<16> copy{str_with_len_N};/32_stddev 1.05 ns 1.74 ns 4 +lstringa<16> copy{str_with_len_N};/32_cv 1.23 % 2.06 % 4 +lstringa<16> copy{str_with_len_N};/64_mean 83.7 ns 83.7 ns 4 +lstringa<16> copy{str_with_len_N};/64_median 83.3 ns 83.7 ns 4 +lstringa<16> copy{str_with_len_N};/64_stddev 2.13 ns 1.42 ns 4 +lstringa<16> copy{str_with_len_N};/64_cv 2.54 % 1.70 % 4 +lstringa<16> copy{str_with_len_N};/128_mean 90.0 ns 90.2 ns 4 +lstringa<16> copy{str_with_len_N};/128_median 89.1 ns 89.8 ns 4 +lstringa<16> copy{str_with_len_N};/128_stddev 2.91 ns 2.98 ns 4 +lstringa<16> copy{str_with_len_N};/128_cv 3.23 % 3.30 % 4 +lstringa<16> copy{str_with_len_N};/256_mean 93.2 ns 92.9 ns 4 +lstringa<16> copy{str_with_len_N};/256_median 92.7 ns 92.4 ns 4 +lstringa<16> copy{str_with_len_N};/256_stddev 1.26 ns 0.872 ns 4 +lstringa<16> copy{str_with_len_N};/256_cv 1.35 % 0.94 % 4 +lstringa<16> copy{str_with_len_N};/512_mean 91.0 ns 90.5 ns 4 +lstringa<16> copy{str_with_len_N};/512_median 91.4 ns 90.0 ns 4 +lstringa<16> copy{str_with_len_N};/512_stddev 2.38 ns 3.14 ns 4 +lstringa<16> copy{str_with_len_N};/512_cv 2.61 % 3.47 % 4 +lstringa<16> copy{str_with_len_N};/1024_mean 98.2 ns 98.3 ns 4 +lstringa<16> copy{str_with_len_N};/1024_median 98.4 ns 98.9 ns 4 +lstringa<16> copy{str_with_len_N};/1024_stddev 3.04 ns 2.34 ns 4 +lstringa<16> copy{str_with_len_N};/1024_cv 3.10 % 2.38 % 4 +lstringa<16> copy{str_with_len_N};/2048_mean 130 ns 129 ns 4 +lstringa<16> copy{str_with_len_N};/2048_median 130 ns 128 ns 4 +lstringa<16> copy{str_with_len_N};/2048_stddev 4.39 ns 6.19 ns 4 +lstringa<16> copy{str_with_len_N};/2048_cv 3.39 % 4.79 % 4 +lstringa<16> copy{str_with_len_N};/4096_mean 183 ns 184 ns 4 +lstringa<16> copy{str_with_len_N};/4096_median 182 ns 184 ns 4 +lstringa<16> copy{str_with_len_N};/4096_stddev 3.28 ns 3.13 ns 4 +lstringa<16> copy{str_with_len_N};/4096_cv 1.79 % 1.70 % 4 +lstringa<512> copy{str_with_len_N};/15_mean 4.03 ns 4.03 ns 4 +lstringa<512> copy{str_with_len_N};/15_median 4.05 ns 4.05 ns 4 +lstringa<512> copy{str_with_len_N};/15_stddev 0.122 ns 0.141 ns 4 +lstringa<512> copy{str_with_len_N};/15_cv 3.03 % 3.51 % 4 +lstringa<512> copy{str_with_len_N};/16_mean 8.78 ns 8.79 ns 4 +lstringa<512> copy{str_with_len_N};/16_median 8.82 ns 8.89 ns 4 +lstringa<512> copy{str_with_len_N};/16_stddev 0.200 ns 0.296 ns 4 +lstringa<512> copy{str_with_len_N};/16_cv 2.28 % 3.37 % 4 +lstringa<512> copy{str_with_len_N};/23_mean 8.82 ns 8.81 ns 4 +lstringa<512> copy{str_with_len_N};/23_median 8.82 ns 8.81 ns 4 +lstringa<512> copy{str_with_len_N};/23_stddev 0.215 ns 0.225 ns 4 +lstringa<512> copy{str_with_len_N};/23_cv 2.44 % 2.56 % 4 +lstringa<512> copy{str_with_len_N};/24_mean 8.74 ns 8.74 ns 4 +lstringa<512> copy{str_with_len_N};/24_median 8.75 ns 8.79 ns 4 +lstringa<512> copy{str_with_len_N};/24_stddev 0.175 ns 0.105 ns 4 +lstringa<512> copy{str_with_len_N};/24_cv 2.00 % 1.20 % 4 +lstringa<512> copy{str_with_len_N};/32_mean 11.9 ns 12.0 ns 4 +lstringa<512> copy{str_with_len_N};/32_median 11.9 ns 12.0 ns 4 +lstringa<512> copy{str_with_len_N};/32_stddev 0.235 ns 0.199 ns 4 +lstringa<512> copy{str_with_len_N};/32_cv 1.97 % 1.67 % 4 +lstringa<512> copy{str_with_len_N};/64_mean 12.3 ns 12.2 ns 4 +lstringa<512> copy{str_with_len_N};/64_median 12.2 ns 12.3 ns 4 +lstringa<512> copy{str_with_len_N};/64_stddev 0.273 ns 0.140 ns 4 +lstringa<512> copy{str_with_len_N};/64_cv 2.22 % 1.14 % 4 +lstringa<512> copy{str_with_len_N};/128_mean 12.4 ns 12.3 ns 4 +lstringa<512> copy{str_with_len_N};/128_median 12.4 ns 12.4 ns 4 +lstringa<512> copy{str_with_len_N};/128_stddev 0.131 ns 0.267 ns 4 +lstringa<512> copy{str_with_len_N};/128_cv 1.06 % 2.16 % 4 lstringa<512> copy{str_with_len_N};/256_mean 13.4 ns 13.4 ns 4 -lstringa<512> copy{str_with_len_N};/256_median 13.4 ns 13.5 ns 4 -lstringa<512> copy{str_with_len_N};/256_stddev 0.214 ns 0.157 ns 4 -lstringa<512> copy{str_with_len_N};/256_cv 1.59 % 1.17 % 4 -lstringa<512> copy{str_with_len_N};/512_mean 15.3 ns 15.2 ns 4 -lstringa<512> copy{str_with_len_N};/512_median 15.5 ns 15.4 ns 4 -lstringa<512> copy{str_with_len_N};/512_stddev 0.456 ns 0.544 ns 4 -lstringa<512> copy{str_with_len_N};/512_cv 2.98 % 3.57 % 4 -lstringa<512> copy{str_with_len_N};/1024_mean 99.8 ns 99.9 ns 4 -lstringa<512> copy{str_with_len_N};/1024_median 100.0 ns 99.4 ns 4 -lstringa<512> copy{str_with_len_N};/1024_stddev 2.42 ns 2.00 ns 4 -lstringa<512> copy{str_with_len_N};/1024_cv 2.43 % 2.01 % 4 -lstringa<512> copy{str_with_len_N};/2048_mean 136 ns 135 ns 4 -lstringa<512> copy{str_with_len_N};/2048_median 136 ns 134 ns 4 -lstringa<512> copy{str_with_len_N};/2048_stddev 13.0 ns 13.8 ns 4 -lstringa<512> copy{str_with_len_N};/2048_cv 9.54 % 10.17 % 4 -lstringa<512> copy{str_with_len_N};/4096_mean 191 ns 190 ns 4 -lstringa<512> copy{str_with_len_N};/4096_median 192 ns 193 ns 4 -lstringa<512> copy{str_with_len_N};/4096_stddev 4.60 ns 4.19 ns 4 -lstringa<512> copy{str_with_len_N};/4096_cv 2.40 % 2.20 % 4 +lstringa<512> copy{str_with_len_N};/256_median 13.4 ns 13.4 ns 4 +lstringa<512> copy{str_with_len_N};/256_stddev 0.405 ns 0.456 ns 4 +lstringa<512> copy{str_with_len_N};/256_cv 3.01 % 3.40 % 4 +lstringa<512> copy{str_with_len_N};/512_mean 14.7 ns 14.6 ns 4 +lstringa<512> copy{str_with_len_N};/512_median 14.8 ns 14.6 ns 4 +lstringa<512> copy{str_with_len_N};/512_stddev 0.228 ns 0.181 ns 4 +lstringa<512> copy{str_with_len_N};/512_cv 1.55 % 1.24 % 4 +lstringa<512> copy{str_with_len_N};/1024_mean 93.5 ns 94.0 ns 4 +lstringa<512> copy{str_with_len_N};/1024_median 94.0 ns 94.0 ns 4 +lstringa<512> copy{str_with_len_N};/1024_stddev 1.97 ns 1.41 ns 4 +lstringa<512> copy{str_with_len_N};/1024_cv 2.11 % 1.50 % 4 +lstringa<512> copy{str_with_len_N};/2048_mean 127 ns 127 ns 4 +lstringa<512> copy{str_with_len_N};/2048_median 127 ns 127 ns 4 +lstringa<512> copy{str_with_len_N};/2048_stddev 3.21 ns 3.60 ns 4 +lstringa<512> copy{str_with_len_N};/2048_cv 2.54 % 2.84 % 4 +lstringa<512> copy{str_with_len_N};/4096_mean 192 ns 190 ns 4 +lstringa<512> copy{str_with_len_N};/4096_median 192 ns 188 ns 4 +lstringa<512> copy{str_with_len_N};/4096_stddev 5.17 ns 6.41 ns 4 +lstringa<512> copy{str_with_len_N};/4096_cv 2.70 % 3.37 % 4 ----- Convert to int '1234567' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_mean 31.7 ns 31.7 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 31.8 ns 31.9 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.535 ns 0.701 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 1.69 % 2.21 % 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 13.6 ns 13.5 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 13.6 ns 13.5 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.307 ns 0.256 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 2.26 % 1.90 % 4 -stringa s = "123456789"; int res = s.to_int_mean 15.1 ns 15.1 ns 4 -stringa s = "123456789"; int res = s.to_int_median 15.1 ns 15.2 ns 4 -stringa s = "123456789"; int res = s.to_int_stddev 0.312 ns 0.301 ns 4 -stringa s = "123456789"; int res = s.to_int_cv 2.06 % 1.98 % 4 -ssa s = "123456789"; int res = s.to_int_mean 14.8 ns 14.8 ns 4 -ssa s = "123456789"; int res = s.to_int_median 14.8 ns 14.8 ns 4 -ssa s = "123456789"; int res = s.to_int_stddev 0.211 ns 0.201 ns 4 -ssa s = "123456789"; int res = s.to_int_cv 1.43 % 1.36 % 4 -lstringa<20> s = "123456789"; int res = s.to_int_mean 15.0 ns 14.9 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_median 15.0 ns 14.8 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.344 ns 0.314 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_cv 2.30 % 2.11 % 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_mean 31.5 ns 31.5 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 31.6 ns 31.5 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 0.398 ns 0.598 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 1.26 % 1.90 % 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 14.8 ns 14.8 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 14.7 ns 14.8 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.205 ns 0.256 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 1.39 % 1.74 % 4 +stringa s = "123456789"; int res = s.to_int_mean 15.9 ns 15.9 ns 4 +stringa s = "123456789"; int res = s.to_int_median 15.9 ns 16.0 ns 4 +stringa s = "123456789"; int res = s.to_int_stddev 0.233 ns 0.349 ns 4 +stringa s = "123456789"; int res = s.to_int_cv 1.47 % 2.20 % 4 +ssa s = "123456789"; int res = s.to_int_mean 15.2 ns 15.3 ns 4 +ssa s = "123456789"; int res = s.to_int_median 15.2 ns 15.2 ns 4 +ssa s = "123456789"; int res = s.to_int_stddev 0.140 ns 0.334 ns 4 +ssa s = "123456789"; int res = s.to_int_cv 0.92 % 2.19 % 4 +lstringa<20> s = "123456789"; int res = s.to_int_mean 15.3 ns 15.3 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_median 15.3 ns 15.2 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.324 ns 0.301 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_cv 2.11 % 1.96 % 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 35.4 ns 35.3 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 35.3 ns 35.3 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 1.10 ns 0.886 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 3.11 % 2.51 % 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 9.45 ns 9.36 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 9.41 ns 9.42 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.095 ns 0.105 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 1.01 % 1.12 % 4 -stringa s = "abcDef"; int res = s.to_int_mean 13.4 ns 13.4 ns 4 -stringa s = "abcDef"; int res = s.to_int_median 13.4 ns 13.5 ns 4 -stringa s = "abcDef"; int res = s.to_int_stddev 0.245 ns 0.157 ns 4 -stringa s = "abcDef"; int res = s.to_int_cv 1.82 % 1.17 % 4 -ssa s = "abcDef"; int res = s.to_int_mean 12.5 ns 12.4 ns 4 -ssa s = "abcDef"; int res = s.to_int_median 12.4 ns 12.4 ns 4 -ssa s = "abcDef"; int res = s.to_int_stddev 0.309 ns 0.360 ns 4 -ssa s = "abcDef"; int res = s.to_int_cv 2.48 % 2.90 % 4 -lstringa<20> s = "abcDef"; int res = s.to_int_mean 13.8 ns 13.7 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_median 13.8 ns 13.5 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.069 ns 0.314 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_cv 0.50 % 2.30 % 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_mean 34.5 ns 34.5 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 34.2 ns 34.5 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 0.778 ns 0.655 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 2.25 % 1.90 % 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 9.16 ns 9.16 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 9.18 ns 9.21 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.100 ns 0.105 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 1.09 % 1.14 % 4 +stringa s = "abcDef"; int res = s.to_int_mean 13.8 ns 13.8 ns 4 +stringa s = "abcDef"; int res = s.to_int_median 13.8 ns 14.0 ns 4 +stringa s = "abcDef"; int res = s.to_int_stddev 0.206 ns 0.279 ns 4 +stringa s = "abcDef"; int res = s.to_int_cv 1.50 % 2.02 % 4 +ssa s = "abcDef"; int res = s.to_int_mean 13.4 ns 13.3 ns 4 +ssa s = "abcDef"; int res = s.to_int_median 13.3 ns 13.1 ns 4 +ssa s = "abcDef"; int res = s.to_int_stddev 0.249 ns 0.483 ns 4 +ssa s = "abcDef"; int res = s.to_int_cv 1.86 % 3.65 % 4 +lstringa<20> s = "abcDef"; int res = s.to_int_mean 13.6 ns 13.6 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_median 13.5 ns 13.5 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.294 ns 0.477 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_cv 2.16 % 3.50 % 4 ----- Convert to int ' 1234567' ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_mean 44.8 ns 44.8 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 44.3 ns 44.5 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 1.04 ns 1.27 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 2.33 % 2.84 % 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 21.6 ns 21.6 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 21.5 ns 21.5 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.244 ns 0.244 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 1.13 % 1.13 % 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 16.9 ns 16.9 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 17.0 ns 16.9 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.234 ns 0.313 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 1.38 % 1.86 % 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_mean 44.1 ns 43.7 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 44.0 ns 43.9 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 0.764 ns 0.488 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 1.73 % 1.12 % 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 22.3 ns 22.4 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 22.2 ns 22.2 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.733 ns 0.893 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 3.28 % 3.99 % 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 18.8 ns 18.7 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 18.8 ns 18.8 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.305 ns 0.483 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 1.63 % 2.58 % 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 105 ns 105 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 105 ns 105 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 3.76 ns 4.77 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 3.57 % 4.52 % 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 79.8 ns 79.3 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 80.1 ns 79.3 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 1.32 ns 1.41 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 1.66 % 1.78 % 4 -ssa s = "1234.567e10"; double res = *s.to_double()_mean 36.2 ns 36.1 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_median 36.3 ns 36.1 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.436 ns 0.655 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_cv 1.20 % 1.81 % 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_mean 103 ns 103 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 103 ns 101 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 2.57 ns 2.96 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 2.50 % 2.89 % 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 77.6 ns 77.6 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 77.4 ns 77.6 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 0.603 ns 1.01 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 0.78 % 1.30 % 4 +ssa s = "1234.567e10"; double res = *s.to_double()_mean 36.4 ns 36.2 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_median 36.5 ns 36.0 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.772 ns 0.419 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_cv 2.12 % 1.16 % 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 5868 ns 5859 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_median 5767 ns 5703 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 356 ns 372 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_cv 6.07 % 6.35 % 4 -std::string str; ... str += "abbaabbaabbaabba";_mean 1286 ns 1288 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_median 1295 ns 1294 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_stddev 27.8 ns 30.7 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_cv 2.16 % 2.39 % 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 948 ns 952 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_median 949 ns 952 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 13.8 ns 12.1 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 1.46 % 1.27 % 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 542 ns 539 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_median 542 ns 539 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 12.8 ns 20.2 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 2.37 % 3.74 % 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 366 ns 366 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_median 366 ns 368 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 3.20 ns 4.19 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 0.88 % 1.14 % 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 229 ns 229 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 227 ns 227 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 5.49 ns 6.91 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 2.40 % 3.01 % 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_mean 5669 ns 5664 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_median 5669 ns 5625 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 120 ns 78.1 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.11 % 1.38 % 4 +std::string str; ... str += "abbaabbaabbaabba";_mean 1305 ns 1295 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_median 1290 ns 1287 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_stddev 31.9 ns 39.5 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_cv 2.45 % 3.05 % 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 986 ns 984 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_median 952 ns 942 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 93.0 ns 99.6 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 9.44 % 10.13 % 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 582 ns 579 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_median 597 ns 586 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 33.2 ns 35.1 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 5.71 % 6.06 % 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 400 ns 398 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_median 402 ns 400 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 12.0 ns 12.3 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 2.99 % 3.09 % 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 244 ns 244 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 247 ns 246 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 14.3 ns 11.5 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 5.85 % 4.71 % 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 5621 ns 5625 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 5559 ns 5547 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 232 ns 221 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 4.12 % 3.93 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 3832 ns 3830 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_median 3823 ns 3809 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 120 ns 80.1 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 3.13 % 2.09 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 813 ns 815 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 811 ns 811 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 11.0 ns 16.7 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.35 % 2.05 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 538 ns 537 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 538 ns 537 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 8.22 ns 8.05 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.53 % 1.50 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 385 ns 385 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 386 ns 385 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 5.67 ns 6.55 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.47 % 1.70 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 269 ns 268 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 270 ns 268 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 5.60 ns 3.83 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.08 % 1.43 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_mean 5946 ns 5929 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 6041 ns 6069 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 423 ns 463 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 7.12 % 7.80 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 4420 ns 4453 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_median 4310 ns 4297 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 454 ns 486 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 10.27 % 10.91 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 920 ns 921 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 923 ns 921 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 38.7 ns 32.2 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 4.21 % 3.50 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 635 ns 631 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 630 ns 628 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 25.9 ns 28.8 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 4.08 % 4.56 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 384 ns 385 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 382 ns 385 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 6.56 ns 6.83 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.71 % 1.77 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 273 ns 273 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 274 ns 276 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 7.34 ns 8.39 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.69 % 3.07 % 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 278650 ns 275735 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 280445 ns 275735 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 5164 ns 3424 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 1.85 % 1.24 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 196731 ns 195679 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 197320 ns 196725 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 4161 ns 6278 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.11 % 3.21 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 23803 ns 23803 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 23890 ns 23803 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 316 ns 302 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.33 % 1.27 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 22568 ns 22583 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 22649 ns 22461 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 358 ns 244 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.58 % 1.08 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 21625 ns 21606 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 21622 ns 21484 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 282 ns 244 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.30 % 1.13 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 21182 ns 21118 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 21068 ns 21240 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 245 ns 467 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.16 % 2.21 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_mean 272220 ns 270025 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 273181 ns 268368 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 6633 ns 6344 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 2.44 % 2.35 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 203527 ns 204050 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 205311 ns 207189 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 11031 ns 11008 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 5.42 % 5.39 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 24303 ns 24275 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 24189 ns 24275 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 444 ns 322 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.83 % 1.33 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 22770 ns 22705 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 22625 ns 22461 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 701 ns 846 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.08 % 3.72 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 22095 ns 22103 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 21907 ns 21972 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 384 ns 262 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.74 % 1.18 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 21427 ns 21362 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 21403 ns 21240 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 825 ns 834 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.85 % 3.90 % 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 5248 ns 5232 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_median 5217 ns 5232 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_stddev 71.0 ns 80.5 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_cv 1.35 % 1.54 % 4 -std::string str; ... str += str_var1 + str_var2;_mean 4021 ns 4013 ns 4 -std::string str; ... str += str_var1 + str_var2;_median 4019 ns 3990 ns 4 -std::string str; ... str += str_var1 + str_var2;_stddev 32.5 ns 45.3 ns 4 -std::string str; ... str += str_var1 + str_var2;_cv 0.81 % 1.13 % 4 -lstringa<16> str; ... str += str_var1 + str_var2;_mean 900 ns 900 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_median 903 ns 900 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_stddev 28.7 ns 17.1 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_cv 3.19 % 1.90 % 4 -lstringa<128> str; ... str += str_var1 + str_var2;_mean 622 ns 617 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_median 620 ns 614 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_stddev 17.5 ns 17.6 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_cv 2.81 % 2.84 % 4 -lstringa<512> str; ... str += str_var1 + str_var2;_mean 462 ns 459 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_median 463 ns 459 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_stddev 12.8 ns 7.97 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_cv 2.77 % 1.74 % 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_mean 351 ns 349 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_median 350 ns 345 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 8.25 ns 7.67 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_cv 2.35 % 2.20 % 4 +std::stringstream str; ... str << str_var1 << str_var2;_mean 5265 ns 5273 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_median 5311 ns 5312 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_stddev 120 ns 78.1 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_cv 2.28 % 1.48 % 4 +std::string str; ... str += str_var1 + str_var2;_mean 4034 ns 4033 ns 4 +std::string str; ... str += str_var1 + str_var2;_median 4025 ns 4011 ns 4 +std::string str; ... str += str_var1 + str_var2;_stddev 101 ns 110 ns 4 +std::string str; ... str += str_var1 + str_var2;_cv 2.49 % 2.72 % 4 +lstringa<16> str; ... str += str_var1 + str_var2;_mean 911 ns 910 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_median 916 ns 910 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_stddev 20.7 ns 27.0 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_cv 2.27 % 2.97 % 4 +lstringa<128> str; ... str += str_var1 + str_var2;_mean 620 ns 621 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_median 613 ns 614 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_stddev 19.7 ns 24.2 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_cv 3.17 % 3.89 % 4 +lstringa<512> str; ... str += str_var1 + str_var2;_mean 469 ns 470 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_median 468 ns 470 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_stddev 17.8 ns 13.1 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_cv 3.80 % 2.78 % 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_mean 362 ns 363 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_median 364 ns 364 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 6.49 ns 7.35 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_cv 1.79 % 2.03 % 4 -- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; str << "test = " << k << " times";_mean 11625 ns 11658 ns 4 -std::stringstream str; str << "test = " << k << " times";_median 11546 ns 11597 ns 4 -std::stringstream str; str << "test = " << k << " times";_stddev 236 ns 234 ns 4 -std::stringstream str; str << "test = " << k << " times";_cv 2.03 % 2.01 % 4 -std::string str = "test = " + std::to_string(k) + " times";_mean 1233 ns 1233 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_median 1241 ns 1233 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_stddev 35.4 ns 31.5 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_cv 2.87 % 2.56 % 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 2806 ns 2809 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 2807 ns 2794 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 34.3 ns 60.1 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 1.22 % 2.14 % 4 -std::string str = std::format("test = {} times", k);_mean 2367 ns 2354 ns 4 -std::string str = std::format("test = {} times", k);_median 2373 ns 2354 ns 4 -std::string str = std::format("test = {} times", k);_stddev 31.3 ns 42.7 ns 4 -std::string str = std::format("test = {} times", k);_cv 1.32 % 1.81 % 4 -lstringa<8> str; str.format("test = {} times", k);_mean 2624 ns 2609 ns 4 -lstringa<8> str; str.format("test = {} times", k);_median 2623 ns 2609 ns 4 -lstringa<8> str; str.format("test = {} times", k);_stddev 24.7 ns 48.4 ns 4 -lstringa<8> str; str.format("test = {} times", k);_cv 0.94 % 1.86 % 4 -lstringa<32> str; str.format("test = {} times", k);_mean 1481 ns 1477 ns 4 -lstringa<32> str; str.format("test = {} times", k);_median 1487 ns 1477 ns 4 -lstringa<32> str; str.format("test = {} times", k);_stddev 17.9 ns 22.2 ns 4 -lstringa<32> str; str.format("test = {} times", k);_cv 1.21 % 1.50 % 4 -lstringa<8> str = "test = " + k + " times";_mean 898 ns 902 ns 4 -lstringa<8> str = "test = " + k + " times";_median 894 ns 898 ns 4 -lstringa<8> str = "test = " + k + " times";_stddev 14.3 ns 16.7 ns 4 -lstringa<8> str = "test = " + k + " times";_cv 1.59 % 1.85 % 4 -lstringa<32> str = "test = " + k + " times";_mean 194 ns 194 ns 4 -lstringa<32> str = "test = " + k + " times";_median 193 ns 193 ns 4 -lstringa<32> str = "test = " + k + " times";_stddev 2.97 ns 2.09 ns 4 -lstringa<32> str = "test = " + k + " times";_cv 1.53 % 1.08 % 4 -stringa str = "test = " + k + " times";_mean 236 ns 237 ns 4 -stringa str = "test = " + k + " times";_median 237 ns 238 ns 4 -stringa str = "test = " + k + " times";_stddev 3.73 ns 5.01 ns 4 -stringa str = "test = " + k + " times";_cv 1.58 % 2.12 % 4 +std::stringstream str; str << "test = " << k << " times";_mean 11467 ns 11457 ns 4 +std::stringstream str; str << "test = " << k << " times";_median 11413 ns 11457 ns 4 +std::stringstream str; str << "test = " << k << " times";_stddev 229 ns 181 ns 4 +std::stringstream str; str << "test = " << k << " times";_cv 2.00 % 1.58 % 4 +std::string str = "test = " + std::to_string(k) + " times";_mean 1162 ns 1160 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_median 1165 ns 1160 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_stddev 27.1 ns 31.5 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_cv 2.33 % 2.72 % 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 2743 ns 2747 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 2743 ns 2762 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 57.0 ns 79.0 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 2.08 % 2.88 % 4 +std::string str = std::format("test = {} times", k);_mean 2397 ns 2393 ns 4 +std::string str = std::format("test = {} times", k);_median 2349 ns 2344 ns 4 +std::string str = std::format("test = {} times", k);_stddev 146 ns 174 ns 4 +std::string str = std::format("test = {} times", k);_cv 6.08 % 7.26 % 4 +lstringa<8> str; str.format("test = {} times", k);_mean 2712 ns 2698 ns 4 +lstringa<8> str; str.format("test = {} times", k);_median 2722 ns 2698 ns 4 +lstringa<8> str; str.format("test = {} times", k);_stddev 70.1 ns 76.5 ns 4 +lstringa<8> str; str.format("test = {} times", k);_cv 2.59 % 2.84 % 4 +lstringa<32> str; str.format("test = {} times", k);_mean 1521 ns 1517 ns 4 +lstringa<32> str; str.format("test = {} times", k);_median 1523 ns 1517 ns 4 +lstringa<32> str; str.format("test = {} times", k);_stddev 14.0 ns 20.1 ns 4 +lstringa<32> str; str.format("test = {} times", k);_cv 0.92 % 1.33 % 4 +lstringa<8> str = "test = " + k + " times";_mean 899 ns 900 ns 4 +lstringa<8> str = "test = " + k + " times";_median 898 ns 900 ns 4 +lstringa<8> str = "test = " + k + " times";_stddev 17.4 ns 24.2 ns 4 +lstringa<8> str = "test = " + k + " times";_cv 1.93 % 2.69 % 4 +lstringa<32> str = "test = " + k + " times";_mean 177 ns 177 ns 4 +lstringa<32> str = "test = " + k + " times";_median 175 ns 176 ns 4 +lstringa<32> str = "test = " + k + " times";_stddev 3.19 ns 5.27 ns 4 +lstringa<32> str = "test = " + k + " times";_cv 1.81 % 2.98 % 4 +stringa str = "test = " + k + " times";_mean 178 ns 178 ns 4 +stringa str = "test = " + k + " times";_median 177 ns 178 ns 4 +stringa str = "test = " + k + " times";_stddev 4.71 ns 4.95 ns 4 +stringa str = "test = " + k + " times";_cv 2.64 % 2.78 % 4 -- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string::find + substr + std::strtol_mean 543 ns 541 ns 4 -std::string::find + substr + std::strtol_median 541 ns 544 ns 4 -std::string::find + substr + std::strtol_stddev 5.22 ns 6.98 ns 4 -std::string::find + substr + std::strtol_cv 0.96 % 1.29 % 4 -ssa::splitter + ssa::as_int_mean 296 ns 295 ns 4 -ssa::splitter + ssa::as_int_median 297 ns 298 ns 4 -ssa::splitter + ssa::as_int_stddev 7.35 ns 11.5 ns 4 -ssa::splitter + ssa::as_int_cv 2.48 % 3.89 % 4 -ssa::splitf + functor_mean 213 ns 214 ns 4 -ssa::splitf + functor_median 212 ns 212 ns 4 -ssa::splitf + functor_stddev 3.75 ns 4.67 ns 4 -ssa::splitf + functor_cv 1.76 % 2.19 % 4 +std::string::find + substr + std::strtol_mean 551 ns 551 ns 4 +std::string::find + substr + std::strtol_median 552 ns 551 ns 4 +std::string::find + substr + std::strtol_stddev 4.82 ns 8.05 ns 4 +std::string::find + substr + std::strtol_cv 0.87 % 1.46 % 4 +ssa::splitter + ssa::as_int_mean 300 ns 300 ns 4 +ssa::splitter + ssa::as_int_median 301 ns 301 ns 4 +ssa::splitter + ssa::as_int_stddev 7.17 ns 7.90 ns 4 +ssa::splitter + ssa::as_int_cv 2.39 % 2.64 % 4 +ssa::splitf + functor_mean 215 ns 214 ns 4 +ssa::splitf + functor_median 214 ns 212 ns 4 +ssa::splitf + functor_stddev 4.75 ns 4.67 ns 4 +ssa::splitf + functor_cv 2.21 % 2.19 % 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 1250 ns 1251 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_median 1260 ns 1257 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_stddev 38.3 ns 41.7 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_cv 3.07 % 3.33 % 4 -replace symbols with std::string find_first_of + replace_mean 2160 ns 2154 ns 4 -replace symbols with std::string find_first_of + replace_median 2171 ns 2154 ns 4 -replace symbols with std::string find_first_of + replace_stddev 38.2 ns 26.2 ns 4 -replace symbols with std::string find_first_of + replace_cv 1.77 % 1.22 % 4 -replace symbols with std::string_view find_first_of + copy_mean 2559 ns 2553 ns 4 -replace symbols with std::string_view find_first_of + copy_median 2549 ns 2539 ns 4 -replace symbols with std::string_view find_first_of + copy_stddev 46.5 ns 53.4 ns 4 -replace symbols with std::string_view find_first_of + copy_cv 1.82 % 2.09 % 4 -replace runtime symbols with string expressions and without remembering all search results_mean 1585 ns 1587 ns 4 -replace runtime symbols with string expressions and without remembering all search results_median 1583 ns 1587 ns 4 -replace runtime symbols with string expressions and without remembering all search results_stddev 8.16 ns 20.1 ns 4 -replace runtime symbols with string expressions and without remembering all search results_cv 0.51 % 1.27 % 4 -replace runtime symbols with simstr and memorization of all search results_mean 1423 ns 1420 ns 4 -replace runtime symbols with simstr and memorization of all search results_median 1424 ns 1413 ns 4 -replace runtime symbols with simstr and memorization of all search results_stddev 20.0 ns 15.7 ns 4 -replace runtime symbols with simstr and memorization of all search results_cv 1.41 % 1.10 % 4 -replace const symbols with string expressions and without remembering all search results_mean 1306 ns 1304 ns 4 -replace const symbols with string expressions and without remembering all search results_median 1308 ns 1311 ns 4 -replace const symbols with string expressions and without remembering all search results_stddev 26.8 ns 35.1 ns 4 -replace const symbols with string expressions and without remembering all search results_cv 2.05 % 2.69 % 4 -replace const symbols with string expressions and memorization of all search results_mean 1240 ns 1242 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_mean 1224 ns 1221 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_median 1224 ns 1228 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_stddev 16.4 ns 14.0 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_cv 1.34 % 1.14 % 4 +replace symbols with std::string find_first_of + replace_mean 2264 ns 2188 ns 4 +replace symbols with std::string find_first_of + replace_median 2198 ns 2176 ns 4 +replace symbols with std::string find_first_of + replace_stddev 215 ns 101 ns 4 +replace symbols with std::string find_first_of + replace_cv 9.51 % 4.60 % 4 +replace symbols with std::string_view find_first_of + copy_mean 2662 ns 2665 ns 4 +replace symbols with std::string_view find_first_of + copy_median 2665 ns 2679 ns 4 +replace symbols with std::string_view find_first_of + copy_stddev 19.1 ns 27.9 ns 4 +replace symbols with std::string_view find_first_of + copy_cv 0.72 % 1.05 % 4 +replace runtime symbols with string expressions and without remembering all search results_mean 1582 ns 1578 ns 4 +replace runtime symbols with string expressions and without remembering all search results_median 1580 ns 1587 ns 4 +replace runtime symbols with string expressions and without remembering all search results_stddev 27.7 ns 33.4 ns 4 +replace runtime symbols with string expressions and without remembering all search results_cv 1.75 % 2.12 % 4 +replace runtime symbols with simstr and memorization of all search results_mean 1398 ns 1395 ns 4 +replace runtime symbols with simstr and memorization of all search results_median 1396 ns 1395 ns 4 +replace runtime symbols with simstr and memorization of all search results_stddev 30.5 ns 22.8 ns 4 +replace runtime symbols with simstr and memorization of all search results_cv 2.18 % 1.63 % 4 +replace const symbols with string expressions and without remembering all search results_mean 1251 ns 1235 ns 4 +replace const symbols with string expressions and without remembering all search results_median 1240 ns 1242 ns 4 +replace const symbols with string expressions and without remembering all search results_stddev 47.3 ns 26.7 ns 4 +replace const symbols with string expressions and without remembering all search results_cv 3.78 % 2.16 % 4 +replace const symbols with string expressions and memorization of all search results_mean 1243 ns 1242 ns 4 replace const symbols with string expressions and memorization of all search results_median 1240 ns 1228 ns 4 -replace const symbols with string expressions and memorization of all search results_stddev 20.1 ns 27.9 ns 4 -replace const symbols with string expressions and memorization of all search results_cv 1.62 % 2.25 % 4 +replace const symbols with string expressions and memorization of all search results_stddev 21.3 ns 27.9 ns 4 +replace const symbols with string expressions and memorization of all search results_cv 1.71 % 2.25 % 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 327 ns 326 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_median 327 ns 326 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_stddev 2.67 ns 4.43 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_cv 0.82 % 1.36 % 4 -Short replace symbols with std::string find_first_of + replace_mean 434 ns 436 ns 4 -Short replace symbols with std::string find_first_of + replace_median 435 ns 438 ns 4 -Short replace symbols with std::string find_first_of + replace_stddev 3.90 ns 9.02 ns 4 -Short replace symbols with std::string find_first_of + replace_cv 0.90 % 2.07 % 4 -Short replace symbols with std::string_view find_first_of + copy_mean 368 ns 367 ns 4 -Short replace symbols with std::string_view find_first_of + copy_median 364 ns 365 ns 4 -Short replace symbols with std::string_view find_first_of + copy_stddev 8.85 ns 7.68 ns 4 -Short replace symbols with std::string_view find_first_of + copy_cv 2.40 % 2.09 % 4 -Short replace runtime symbols with string expressions and without remembering all search results_mean 306 ns 305 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_median 306 ns 307 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_stddev 3.43 ns 3.49 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_cv 1.12 % 1.14 % 4 -Short replace runtime symbols with simstr and memorization of all search results_mean 409 ns 410 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_median 408 ns 408 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_stddev 8.79 ns 11.4 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_cv 2.15 % 2.78 % 4 -Short replace const symbols with string expressions and without remembering all search results_mean 268 ns 268 ns 4 -Short replace const symbols with string expressions and without remembering all search results_median 265 ns 267 ns 4 -Short replace const symbols with string expressions and without remembering all search results_stddev 7.49 ns 7.46 ns 4 -Short replace const symbols with string expressions and without remembering all search results_cv 2.80 % 2.78 % 4 -Short replace const symbols with string expressions and memorization of all search results_mean 346 ns 343 ns 4 -Short replace const symbols with string expressions and memorization of all search results_median 346 ns 341 ns 4 -Short replace const symbols with string expressions and memorization of all search results_stddev 2.71 ns 7.68 ns 4 -Short replace const symbols with string expressions and memorization of all search results_cv 0.78 % 2.24 % 4 +Short Naive (and wrong) replace symbols with std::string find + replace_mean 337 ns 335 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_median 336 ns 333 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_stddev 7.71 ns 12.5 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_cv 2.28 % 3.73 % 4 +Short replace symbols with std::string find_first_of + replace_mean 423 ns 424 ns 4 +Short replace symbols with std::string find_first_of + replace_median 425 ns 424 ns 4 +Short replace symbols with std::string find_first_of + replace_stddev 5.99 ns 7.69 ns 4 +Short replace symbols with std::string find_first_of + replace_cv 1.42 % 1.81 % 4 +Short replace symbols with std::string_view find_first_of + copy_mean 350 ns 349 ns 4 +Short replace symbols with std::string_view find_first_of + copy_median 350 ns 349 ns 4 +Short replace symbols with std::string_view find_first_of + copy_stddev 2.62 ns 4.43 ns 4 +Short replace symbols with std::string_view find_first_of + copy_cv 0.75 % 1.27 % 4 +Short replace runtime symbols with string expressions and without remembering all search results_mean 298 ns 298 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_median 297 ns 298 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_stddev 4.04 ns 3.62 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_cv 1.36 % 1.22 % 4 +Short replace runtime symbols with simstr and memorization of all search results_mean 396 ns 397 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_median 394 ns 394 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_stddev 9.88 ns 8.68 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_cv 2.50 % 2.19 % 4 +Short replace const symbols with string expressions and without remembering all search results_mean 253 ns 254 ns 4 +Short replace const symbols with string expressions and without remembering all search results_median 250 ns 249 ns 4 +Short replace const symbols with string expressions and without remembering all search results_stddev 16.7 ns 17.4 ns 4 +Short replace const symbols with string expressions and without remembering all search results_cv 6.59 % 6.84 % 4 +Short replace const symbols with string expressions and memorization of all search results_mean 349 ns 345 ns 4 +Short replace const symbols with string expressions and memorization of all search results_median 349 ns 345 ns 4 +Short replace const symbols with string expressions and memorization of all search results_stddev 3.72 ns 13.1 ns 4 +Short replace const symbols with string expressions and memorization of all search results_cv 1.07 % 3.80 % 4 ----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to ---- in std::string|64_mean 246 ns 246 ns 4 -replace bb to ---- in std::string|64_median 248 ns 248 ns 4 -replace bb to ---- in std::string|64_stddev 5.28 ns 7.89 ns 4 -replace bb to ---- in std::string|64_cv 2.15 % 3.21 % 4 -replace bb to ---- in std::string|256_mean 797 ns 793 ns 4 -replace bb to ---- in std::string|256_median 791 ns 793 ns 4 -replace bb to ---- in std::string|256_stddev 17.8 ns 10.1 ns 4 -replace bb to ---- in std::string|256_cv 2.23 % 1.27 % 4 -replace bb to ---- in std::string|512_mean 1484 ns 1475 ns 4 -replace bb to ---- in std::string|512_median 1479 ns 1475 ns 4 -replace bb to ---- in std::string|512_stddev 13.6 ns 25.6 ns 4 -replace bb to ---- in std::string|512_cv 0.91 % 1.74 % 4 -replace bb to ---- in std::string|1024_mean 3187 ns 3191 ns 4 -replace bb to ---- in std::string|1024_median 3197 ns 3174 ns 4 -replace bb to ---- in std::string|1024_stddev 42.2 ns 66.8 ns 4 -replace bb to ---- in std::string|1024_cv 1.33 % 2.09 % 4 -replace bb to ---- in std::string|2048_mean 8264 ns 8240 ns 4 -replace bb to ---- in std::string|2048_median 8235 ns 8109 ns 4 -replace bb to ---- in std::string|2048_stddev 410 ns 459 ns 4 -replace bb to ---- in std::string|2048_cv 4.96 % 5.57 % 4 +replace bb to ---- in std::string|64_mean 241 ns 242 ns 4 +replace bb to ---- in std::string|64_median 233 ns 233 ns 4 +replace bb to ---- in std::string|64_stddev 18.7 ns 20.2 ns 4 +replace bb to ---- in std::string|64_cv 7.73 % 8.35 % 4 +replace bb to ---- in std::string|256_mean 791 ns 789 ns 4 +replace bb to ---- in std::string|256_median 789 ns 785 ns 4 +replace bb to ---- in std::string|256_stddev 7.73 ns 8.72 ns 4 +replace bb to ---- in std::string|256_cv 0.98 % 1.10 % 4 +replace bb to ---- in std::string|512_mean 1425 ns 1420 ns 4 +replace bb to ---- in std::string|512_median 1432 ns 1428 ns 4 +replace bb to ---- in std::string|512_stddev 26.5 ns 30.1 ns 4 +replace bb to ---- in std::string|512_cv 1.86 % 2.12 % 4 +replace bb to ---- in std::string|1024_mean 3130 ns 3122 ns 4 +replace bb to ---- in std::string|1024_median 3102 ns 3104 ns 4 +replace bb to ---- in std::string|1024_stddev 88.3 ns 66.8 ns 4 +replace bb to ---- in std::string|1024_cv 2.82 % 2.14 % 4 +replace bb to ---- in std::string|2048_mean 7950 ns 7978 ns 4 +replace bb to ---- in std::string|2048_median 7981 ns 8022 ns 4 +replace bb to ---- in std::string|2048_stddev 194 ns 219 ns 4 +replace bb to ---- in std::string|2048_cv 2.44 % 2.75 % 4 replace bb to ---- in lstringa<8>|64_mean 234 ns 233 ns 4 -replace bb to ---- in lstringa<8>|64_median 233 ns 232 ns 4 -replace bb to ---- in lstringa<8>|64_stddev 7.59 ns 9.53 ns 4 -replace bb to ---- in lstringa<8>|64_cv 3.25 % 4.09 % 4 -replace bb to ---- in lstringa<8>|256_mean 674 ns 670 ns 4 -replace bb to ---- in lstringa<8>|256_median 675 ns 670 ns 4 -replace bb to ---- in lstringa<8>|256_stddev 2.88 ns 11.4 ns 4 -replace bb to ---- in lstringa<8>|256_cv 0.43 % 1.70 % 4 -replace bb to ---- in lstringa<8>|512_mean 1132 ns 1135 ns 4 -replace bb to ---- in lstringa<8>|512_median 1141 ns 1147 ns 4 -replace bb to ---- in lstringa<8>|512_stddev 36.7 ns 42.3 ns 4 -replace bb to ---- in lstringa<8>|512_cv 3.24 % 3.72 % 4 -replace bb to ---- in lstringa<8>|1024_mean 2070 ns 2074 ns 4 -replace bb to ---- in lstringa<8>|1024_median 2063 ns 2063 ns 4 -replace bb to ---- in lstringa<8>|1024_stddev 29.1 ns 43.4 ns 4 -replace bb to ---- in lstringa<8>|1024_cv 1.40 % 2.09 % 4 -replace bb to ---- in lstringa<8>|2048_mean 3928 ns 3854 ns 4 -replace bb to ---- in lstringa<8>|2048_median 3967 ns 3854 ns 4 -replace bb to ---- in lstringa<8>|2048_stddev 96.7 ns 52.4 ns 4 -replace bb to ---- in lstringa<8>|2048_cv 2.46 % 1.36 % 4 -replace bb to ---- by init stringa|64_mean 204 ns 205 ns 4 -replace bb to ---- by init stringa|64_median 202 ns 203 ns 4 -replace bb to ---- by init stringa|64_stddev 9.92 ns 9.04 ns 4 -replace bb to ---- by init stringa|64_cv 4.85 % 4.41 % 4 -replace bb to ---- by init stringa|256_mean 483 ns 484 ns 4 -replace bb to ---- by init stringa|256_median 484 ns 487 ns 4 -replace bb to ---- by init stringa|256_stddev 14.9 ns 17.9 ns 4 -replace bb to ---- by init stringa|256_cv 3.08 % 3.69 % 4 -replace bb to ---- by init stringa|512_mean 1060 ns 1060 ns 4 -replace bb to ---- by init stringa|512_median 1064 ns 1060 ns 4 -replace bb to ---- by init stringa|512_stddev 12.0 ns 22.8 ns 4 -replace bb to ---- by init stringa|512_cv 1.13 % 2.15 % 4 -replace bb to ---- by init stringa|1024_mean 2279 ns 2271 ns 4 -replace bb to ---- by init stringa|1024_median 2297 ns 2295 ns 4 -replace bb to ---- by init stringa|1024_stddev 63.3 ns 48.8 ns 4 -replace bb to ---- by init stringa|1024_cv 2.78 % 2.15 % 4 -replace bb to ---- by init stringa|2048_mean 4526 ns 4526 ns 4 -replace bb to ---- by init stringa|2048_median 4521 ns 4501 ns 4 -replace bb to ---- by init stringa|2048_stddev 44.2 ns 96.8 ns 4 -replace bb to ---- by init stringa|2048_cv 0.98 % 2.14 % 4 +replace bb to ---- in lstringa<8>|64_median 230 ns 229 ns 4 +replace bb to ---- in lstringa<8>|64_stddev 11.7 ns 11.5 ns 4 +replace bb to ---- in lstringa<8>|64_cv 4.99 % 4.95 % 4 +replace bb to ---- in lstringa<8>|256_mean 662 ns 658 ns 4 +replace bb to ---- in lstringa<8>|256_median 662 ns 663 ns 4 +replace bb to ---- in lstringa<8>|256_stddev 13.7 ns 21.9 ns 4 +replace bb to ---- in lstringa<8>|256_cv 2.07 % 3.33 % 4 +replace bb to ---- in lstringa<8>|512_mean 1118 ns 1123 ns 4 +replace bb to ---- in lstringa<8>|512_median 1102 ns 1111 ns 4 +replace bb to ---- in lstringa<8>|512_stddev 57.0 ns 52.7 ns 4 +replace bb to ---- in lstringa<8>|512_cv 5.10 % 4.70 % 4 +replace bb to ---- in lstringa<8>|1024_mean 1999 ns 1990 ns 4 +replace bb to ---- in lstringa<8>|1024_median 1994 ns 1978 ns 4 +replace bb to ---- in lstringa<8>|1024_stddev 22.1 ns 46.7 ns 4 +replace bb to ---- in lstringa<8>|1024_cv 1.11 % 2.35 % 4 +replace bb to ---- in lstringa<8>|2048_mean 3914 ns 3892 ns 4 +replace bb to ---- in lstringa<8>|2048_median 3855 ns 3809 ns 4 +replace bb to ---- in lstringa<8>|2048_stddev 217 ns 199 ns 4 +replace bb to ---- in lstringa<8>|2048_cv 5.54 % 5.12 % 4 +replace bb to ---- by init stringa|64_mean 195 ns 196 ns 4 +replace bb to ---- by init stringa|64_median 196 ns 195 ns 4 +replace bb to ---- by init stringa|64_stddev 2.23 ns 4.01 ns 4 +replace bb to ---- by init stringa|64_cv 1.14 % 2.05 % 4 +replace bb to ---- by init stringa|256_mean 465 ns 466 ns 4 +replace bb to ---- by init stringa|256_median 462 ns 466 ns 4 +replace bb to ---- by init stringa|256_stddev 11.5 ns 13.5 ns 4 +replace bb to ---- by init stringa|256_cv 2.48 % 2.90 % 4 +replace bb to ---- by init stringa|512_mean 1064 ns 1057 ns 4 +replace bb to ---- by init stringa|512_median 1061 ns 1057 ns 4 +replace bb to ---- by init stringa|512_stddev 18.8 ns 27.0 ns 4 +replace bb to ---- by init stringa|512_cv 1.76 % 2.56 % 4 +replace bb to ---- by init stringa|1024_mean 2218 ns 2209 ns 4 +replace bb to ---- by init stringa|1024_median 2220 ns 2222 ns 4 +replace bb to ---- by init stringa|1024_stddev 28.9 ns 46.7 ns 4 +replace bb to ---- by init stringa|1024_cv 1.30 % 2.12 % 4 +replace bb to ---- by init stringa|2048_mean 4628 ns 4630 ns 4 +replace bb to ---- by init stringa|2048_median 4521 ns 4551 ns 4 +replace bb to ---- by init stringa|2048_stddev 253 ns 198 ns 4 +replace bb to ---- by init stringa|2048_cv 5.48 % 4.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 213 ns 214 ns 4 -replace bb to -- in std::string|64_median 211 ns 212 ns 4 -replace bb to -- in std::string|64_stddev 5.30 ns 4.67 ns 4 -replace bb to -- in std::string|64_cv 2.48 % 2.19 % 4 -replace bb to -- in std::string|256_mean 540 ns 539 ns 4 -replace bb to -- in std::string|256_median 543 ns 547 ns 4 -replace bb to -- in std::string|256_stddev 14.4 ns 15.6 ns 4 -replace bb to -- in std::string|256_cv 2.67 % 2.90 % 4 -replace bb to -- in std::string|512_mean 975 ns 970 ns 4 -replace bb to -- in std::string|512_median 974 ns 977 ns 4 -replace bb to -- in std::string|512_stddev 4.44 ns 12.2 ns 4 -replace bb to -- in std::string|512_cv 0.46 % 1.26 % 4 -replace bb to -- in std::string|1024_mean 1812 ns 1789 ns 4 -replace bb to -- in std::string|1024_median 1798 ns 1800 ns 4 -replace bb to -- in std::string|1024_stddev 42.8 ns 52.7 ns 4 -replace bb to -- in std::string|1024_cv 2.36 % 2.94 % 4 -replace bb to -- in std::string|2048_mean 3562 ns 3570 ns 4 -replace bb to -- in std::string|2048_median 3551 ns 3570 ns 4 -replace bb to -- in std::string|2048_stddev 30.6 ns 46.3 ns 4 -replace bb to -- in std::string|2048_cv 0.86 % 1.30 % 4 -replace bb to -- in lstringa<8>|64_mean 196 ns 197 ns 4 -replace bb to -- in lstringa<8>|64_median 195 ns 195 ns 4 -replace bb to -- in lstringa<8>|64_stddev 4.93 ns 6.14 ns 4 -replace bb to -- in lstringa<8>|64_cv 2.51 % 3.13 % 4 -replace bb to -- in lstringa<8>|256_mean 459 ns 458 ns 4 -replace bb to -- in lstringa<8>|256_median 459 ns 455 ns 4 -replace bb to -- in lstringa<8>|256_stddev 15.0 ns 17.9 ns 4 -replace bb to -- in lstringa<8>|256_cv 3.26 % 3.90 % 4 -replace bb to -- in lstringa<8>|512_mean 791 ns 793 ns 4 -replace bb to -- in lstringa<8>|512_median 796 ns 802 ns 4 -replace bb to -- in lstringa<8>|512_stddev 16.1 ns 17.4 ns 4 -replace bb to -- in lstringa<8>|512_cv 2.03 % 2.20 % 4 -replace bb to -- in lstringa<8>|1024_mean 1519 ns 1522 ns 4 -replace bb to -- in lstringa<8>|1024_median 1523 ns 1522 ns 4 -replace bb to -- in lstringa<8>|1024_stddev 30.0 ns 40.5 ns 4 -replace bb to -- in lstringa<8>|1024_cv 1.98 % 2.66 % 4 -replace bb to -- in lstringa<8>|2048_mean 2888 ns 2897 ns 4 -replace bb to -- in lstringa<8>|2048_median 2902 ns 2916 ns 4 -replace bb to -- in lstringa<8>|2048_stddev 49.1 ns 38.4 ns 4 -replace bb to -- in lstringa<8>|2048_cv 1.70 % 1.32 % 4 -replace bb to -- by init stringa|64_mean 176 ns 176 ns 4 -replace bb to -- by init stringa|64_median 175 ns 175 ns 4 -replace bb to -- by init stringa|64_stddev 7.58 ns 8.29 ns 4 -replace bb to -- by init stringa|64_cv 4.31 % 4.70 % 4 -replace bb to -- by init stringa|256_mean 389 ns 385 ns 4 -replace bb to -- by init stringa|256_median 391 ns 385 ns 4 -replace bb to -- by init stringa|256_stddev 6.20 ns 11.7 ns 4 -replace bb to -- by init stringa|256_cv 1.59 % 3.04 % 4 -replace bb to -- by init stringa|512_mean 647 ns 645 ns 4 -replace bb to -- by init stringa|512_median 648 ns 649 ns 4 -replace bb to -- by init stringa|512_stddev 11.7 ns 13.4 ns 4 -replace bb to -- by init stringa|512_cv 1.81 % 2.07 % 4 -replace bb to -- by init stringa|1024_mean 1222 ns 1227 ns 4 -replace bb to -- by init stringa|1024_median 1217 ns 1221 ns 4 -replace bb to -- by init stringa|1024_stddev 35.2 ns 36.6 ns 4 -replace bb to -- by init stringa|1024_cv 2.88 % 2.99 % 4 -replace bb to -- by init stringa|2048_mean 2280 ns 2263 ns 4 -replace bb to -- by init stringa|2048_median 2281 ns 2250 ns 4 -replace bb to -- by init stringa|2048_stddev 23.1 ns 26.2 ns 4 -replace bb to -- by init stringa|2048_cv 1.01 % 1.16 % 4 +replace bb to -- in std::string|64_mean 200 ns 198 ns 4 +replace bb to -- in std::string|64_median 200 ns 199 ns 4 +replace bb to -- in std::string|64_stddev 5.51 ns 9.35 ns 4 +replace bb to -- in std::string|64_cv 2.76 % 4.71 % 4 +replace bb to -- in std::string|256_mean 527 ns 520 ns 4 +replace bb to -- in std::string|256_median 523 ns 516 ns 4 +replace bb to -- in std::string|256_stddev 23.4 ns 23.4 ns 4 +replace bb to -- in std::string|256_cv 4.44 % 4.51 % 4 +replace bb to -- in std::string|512_mean 925 ns 926 ns 4 +replace bb to -- in std::string|512_median 925 ns 921 ns 4 +replace bb to -- in std::string|512_stddev 10.3 ns 10.5 ns 4 +replace bb to -- in std::string|512_cv 1.12 % 1.13 % 4 +replace bb to -- in std::string|1024_mean 1849 ns 1852 ns 4 +replace bb to -- in std::string|1024_median 1783 ns 1779 ns 4 +replace bb to -- in std::string|1024_stddev 166 ns 162 ns 4 +replace bb to -- in std::string|1024_cv 9.00 % 8.73 % 4 +replace bb to -- in std::string|2048_mean 3432 ns 3414 ns 4 +replace bb to -- in std::string|2048_median 3444 ns 3414 ns 4 +replace bb to -- in std::string|2048_stddev 92.5 ns 99.1 ns 4 +replace bb to -- in std::string|2048_cv 2.69 % 2.90 % 4 +replace bb to -- in lstringa<8>|64_mean 184 ns 184 ns 4 +replace bb to -- in lstringa<8>|64_median 182 ns 184 ns 4 +replace bb to -- in lstringa<8>|64_stddev 6.17 ns 5.85 ns 4 +replace bb to -- in lstringa<8>|64_cv 3.36 % 3.19 % 4 +replace bb to -- in lstringa<8>|256_mean 441 ns 443 ns 4 +replace bb to -- in lstringa<8>|256_median 441 ns 443 ns 4 +replace bb to -- in lstringa<8>|256_stddev 4.07 ns 7.69 ns 4 +replace bb to -- in lstringa<8>|256_cv 0.92 % 1.74 % 4 +replace bb to -- in lstringa<8>|512_mean 773 ns 772 ns 4 +replace bb to -- in lstringa<8>|512_median 771 ns 767 ns 4 +replace bb to -- in lstringa<8>|512_stddev 5.07 ns 8.72 ns 4 +replace bb to -- in lstringa<8>|512_cv 0.66 % 1.13 % 4 +replace bb to -- in lstringa<8>|1024_mean 1438 ns 1439 ns 4 +replace bb to -- in lstringa<8>|1024_median 1436 ns 1430 ns 4 +replace bb to -- in lstringa<8>|1024_stddev 19.8 ns 17.4 ns 4 +replace bb to -- in lstringa<8>|1024_cv 1.38 % 1.21 % 4 +replace bb to -- in lstringa<8>|2048_mean 2797 ns 2787 ns 4 +replace bb to -- in lstringa<8>|2048_median 2812 ns 2816 ns 4 +replace bb to -- in lstringa<8>|2048_stddev 74.9 ns 83.9 ns 4 +replace bb to -- in lstringa<8>|2048_cv 2.68 % 3.01 % 4 +replace bb to -- by init stringa|64_mean 165 ns 164 ns 4 +replace bb to -- by init stringa|64_median 167 ns 165 ns 4 +replace bb to -- by init stringa|64_stddev 4.54 ns 4.83 ns 4 +replace bb to -- by init stringa|64_cv 2.76 % 2.94 % 4 +replace bb to -- by init stringa|256_mean 371 ns 370 ns 4 +replace bb to -- by init stringa|256_median 368 ns 368 ns 4 +replace bb to -- by init stringa|256_stddev 6.71 ns 4.19 ns 4 +replace bb to -- by init stringa|256_cv 1.81 % 1.13 % 4 +replace bb to -- by init stringa|512_mean 613 ns 614 ns 4 +replace bb to -- by init stringa|512_median 614 ns 614 ns 4 +replace bb to -- by init stringa|512_stddev 9.32 ns 11.4 ns 4 +replace bb to -- by init stringa|512_cv 1.52 % 1.86 % 4 +replace bb to -- by init stringa|1024_mean 1103 ns 1105 ns 4 +replace bb to -- by init stringa|1024_median 1109 ns 1111 ns 4 +replace bb to -- by init stringa|1024_stddev 19.7 ns 23.4 ns 4 +replace bb to -- by init stringa|1024_cv 1.79 % 2.12 % 4 +replace bb to -- by init stringa|2048_mean 2080 ns 2075 ns 4 +replace bb to -- by init stringa|2048_median 2083 ns 2075 ns 4 +replace bb to -- by init stringa|2048_stddev 13.8 ns 28.2 ns 4 +replace bb to -- by init stringa|2048_cv 0.66 % 1.36 % 4 ----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -hashStrMapA emplace & find stringa;_mean 4240370 ns 4235693 ns 4 -hashStrMapA emplace & find stringa;_median 4229996 ns 4235693 ns 4 -hashStrMapA emplace & find stringa;_stddev 54733 ns 76854 ns 4 -hashStrMapA emplace & find stringa;_cv 1.29 % 1.81 % 4 -std::unordered_map emplace & find std::string;_mean 5465021 ns 5468750 ns 4 -std::unordered_map emplace & find std::string;_median 5474793 ns 5468750 ns 4 -std::unordered_map emplace & find std::string;_stddev 291111 ns 382733 ns 4 -std::unordered_map emplace & find std::string;_cv 5.33 % 7.00 % 4 -hashStrMapA emplace & find ssa;_mean 3925646 ns 3906250 ns 4 -hashStrMapA emplace & find ssa;_median 3942482 ns 3906250 ns 4 -hashStrMapA emplace & find ssa;_stddev 63167 ns 74173 ns 4 -hashStrMapA emplace & find ssa;_cv 1.61 % 1.90 % 4 -std::unordered_map emplace & find std::string_view;_mean 6242693 ns 6243025 ns 4 -std::unordered_map emplace & find std::string_view;_median 6227330 ns 6208147 ns 4 -std::unordered_map emplace & find std::string_view;_stddev 144165 ns 133570 ns 4 -std::unordered_map emplace & find std::string_view;_cv 2.31 % 2.14 % 4 +hashStrMapA emplace & find stringa;_mean 4404870 ns 4400414 ns 4 +hashStrMapA emplace & find stringa;_median 4416405 ns 4376883 ns 4 +hashStrMapA emplace & find stringa;_stddev 71727 ns 90119 ns 4 +hashStrMapA emplace & find stringa;_cv 1.63 % 2.05 % 4 +std::unordered_map emplace & find std::string;_mean 5721296 ns 5650112 ns 4 +std::unordered_map emplace & find std::string;_median 5688711 ns 5580357 ns 4 +std::unordered_map emplace & find std::string;_stddev 198446 ns 267139 ns 4 +std::unordered_map emplace & find std::string;_cv 3.47 % 4.73 % 4 +hashStrMapA emplace & find ssa;_mean 3899002 ns 3906250 ns 4 +hashStrMapA emplace & find ssa;_median 3893037 ns 3884427 ns 4 +hashStrMapA emplace & find ssa;_stddev 121491 ns 149077 ns 4 +hashStrMapA emplace & find ssa;_cv 3.12 % 3.82 % 4 +std::unordered_map emplace & find std::string_view;_mean 6299827 ns 6243025 ns 4 +std::unordered_map emplace & find std::string_view;_median 6282895 ns 6208147 ns 4 +std::unordered_map emplace & find std::string_view;_stddev 115741 ns 133570 ns 4 +std::unordered_map emplace & find std::string_view;_cv 1.84 % 2.14 % 4 ----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Build func full name std::string;_mean 1664 ns 1665 ns 4 -Build func full name std::string;_median 1663 ns 1674 ns 4 -Build func full name std::string;_stddev 14.7 ns 17.4 ns 4 -Build func full name std::string;_cv 0.88 % 1.05 % 4 -Build func full name std::string 1;_mean 1769 ns 1765 ns 4 -Build func full name std::string 1;_median 1696 ns 1688 ns 4 -Build func full name std::string 1;_stddev 158 ns 153 ns 4 -Build func full name std::string 1;_cv 8.95 % 8.70 % 4 -Build func full name std::stream;_mean 9778 ns 9766 ns 4 -Build func full name std::stream;_median 9752 ns 9766 ns 4 -Build func full name std::stream;_stddev 146 ns 199 ns 4 -Build func full name std::stream;_cv 1.49 % 2.04 % 4 -Build func full name stringa;_mean 873 ns 874 ns 4 -Build func full name stringa;_median 871 ns 868 ns 4 -Build func full name stringa;_stddev 6.20 ns 20.0 ns 4 -Build func full name stringa;_cv 0.71 % 2.29 % 4 -Build func full name stringa 1;_mean 1040 ns 1039 ns 4 -Build func full name stringa 1;_median 1030 ns 1018 ns 4 -Build func full name stringa 1;_stddev 39.4 ns 52.8 ns 4 -Build func full name stringa 1;_cv 3.79 % 5.08 % 4 +Build func full name std::string;_mean 1577 ns 1569 ns 4 +Build func full name std::string;_median 1566 ns 1569 ns 4 +Build func full name std::string;_stddev 32.8 ns 28.5 ns 4 +Build func full name std::string;_cv 2.08 % 1.81 % 4 +Build func full name std::string 1;_mean 1622 ns 1613 ns 4 +Build func full name std::string 1;_median 1622 ns 1622 ns 4 +Build func full name std::string 1;_stddev 26.1 ns 33.4 ns 4 +Build func full name std::string 1;_cv 1.61 % 2.07 % 4 +Build func full name std::stream;_mean 9579 ns 9583 ns 4 +Build func full name std::stream;_median 9627 ns 9766 ns 4 +Build func full name std::stream;_stddev 201 ns 366 ns 4 +Build func full name std::stream;_cv 2.10 % 3.82 % 4 +Build func full name stringa;_mean 857 ns 854 ns 4 +Build func full name stringa;_median 857 ns 854 ns 4 +Build func full name stringa;_stddev 5.26 ns 14.2 ns 4 +Build func full name stringa;_cv 0.61 % 1.67 % 4 +Build func full name stringa 1;_mean 1025 ns 1025 ns 4 +Build func full name stringa 1;_median 999 ns 1001 ns 4 +Build func full name stringa 1;_stddev 59.3 ns 66.1 ns 4 +Build func full name stringa 1;_cv 5.79 % 6.45 % 4 diff --git a/bench/results/004-Xeon E5-2682 v4, WASM Chrome 143, Clang-21.txt b/bench/results/004-Xeon E5-2682 v4, WASM Chrome 143, Clang-21.txt index fd75c76..6bf0a51 100644 --- a/bench/results/004-Xeon E5-2682 v4, WASM Chrome 143, Clang-21.txt +++ b/bench/results/004-Xeon E5-2682 v4, WASM Chrome 143, Clang-21.txt @@ -6,925 +6,962 @@ Chrome/143.0.0.0 webasm -------------------------------------------------------------------------------------------------------------------------------------------------------- Benchmark Time CPU Iterations -------------------------------------------------------------------------------------------------------------------------------------------------------- +----- Concatenate email ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 +Concat email std::format_mean 964 ns 964 ns 4 +Concat email std::format_median 969 ns 969 ns 4 +Concat email std::format_stddev 28.0 ns 28.0 ns 4 +Concat email std::format_cv 2.90 % 2.90 % 4 +Concat email std::stringstream_mean 2458 ns 2458 ns 4 +Concat email std::stringstream_median 2426 ns 2426 ns 4 +Concat email std::stringstream_stddev 124 ns 124 ns 4 +Concat email std::stringstream_cv 5.04 % 5.04 % 4 +Concat email stringzilla append_mean 594 ns 594 ns 4 +Concat email stringzilla append_median 593 ns 593 ns 4 +Concat email stringzilla append_stddev 10.9 ns 10.9 ns 4 +Concat email stringzilla append_cv 1.83 % 1.83 % 4 +Concat email stringzilla concat_mean 213 ns 213 ns 4 +Concat email stringzilla concat_median 211 ns 211 ns 4 +Concat email stringzilla concat_stddev 4.00 ns 4.00 ns 4 +Concat email stringzilla concat_cv 1.88 % 1.88 % 4 +Concat email std::string append_mean 623 ns 623 ns 4 +Concat email std::string append_median 628 ns 628 ns 4 +Concat email std::string append_stddev 16.8 ns 16.8 ns 4 +Concat email std::string append_cv 2.69 % 2.69 % 4 +Concat email std::string by strexpr_mean 158 ns 158 ns 4 +Concat email std::string by strexpr_median 159 ns 159 ns 4 +Concat email std::string by strexpr_stddev 6.98 ns 6.98 ns 4 +Concat email std::string by strexpr_cv 4.41 % 4.41 % 4 +Concat email stringa_mean 124 ns 124 ns 4 +Concat email stringa_median 125 ns 125 ns 4 +Concat email stringa_stddev 7.25 ns 7.25 ns 4 +Concat email stringa_cv 5.86 % 5.86 % 4 ----- Concatenate string + Number + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string and number by std to std::string_mean 1035 ns 1035 ns 4 -Concat std::string and number by std to std::string_median 1033 ns 1033 ns 4 -Concat std::string and number by std to std::string_stddev 16.9 ns 16.9 ns 4 -Concat std::string and number by std to std::string_cv 1.63 % 1.63 % 4 -Concat std::string and number by StrExpr to std::string_mean 505 ns 505 ns 4 -Concat std::string and number by StrExpr to std::string_median 509 ns 509 ns 4 -Concat std::string and number by StrExpr to std::string_stddev 13.5 ns 13.5 ns 4 -Concat std::string and number by StrExpr to std::string_cv 2.66 % 2.66 % 4 -Concat stringa and number by StrExpr to simstr::stringa_mean 224 ns 224 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_median 217 ns 217 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_stddev 16.9 ns 16.9 ns 4 -Concat stringa and number by StrExpr to simstr::stringa_cv 7.55 % 7.55 % 4 -Concat stringa and number by e_concat to simstr::stringa_mean 224 ns 224 ns 4 -Concat stringa and number by e_concat to simstr::stringa_median 223 ns 223 ns 4 -Concat stringa and number by e_concat to simstr::stringa_stddev 3.66 ns 3.66 ns 4 -Concat stringa and number by e_concat to simstr::stringa_cv 1.63 % 1.63 % 4 +Concat std::string and number by std to std::string_mean 1831 ns 1831 ns 4 +Concat std::string and number by std to std::string_median 1779 ns 1779 ns 4 +Concat std::string and number by std to std::string_stddev 117 ns 117 ns 4 +Concat std::string and number by std to std::string_cv 6.37 % 6.37 % 4 +Concat std::string and number by StrExpr to std::string_mean 947 ns 947 ns 4 +Concat std::string and number by StrExpr to std::string_median 939 ns 939 ns 4 +Concat std::string and number by StrExpr to std::string_stddev 33.5 ns 33.5 ns 4 +Concat std::string and number by StrExpr to std::string_cv 3.54 % 3.54 % 4 +Concat stringa and number by StrExpr to simstr::stringa_mean 354 ns 354 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_median 354 ns 354 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_stddev 12.3 ns 12.3 ns 4 +Concat stringa and number by StrExpr to simstr::stringa_cv 3.48 % 3.48 % 4 +Concat stringa and number by e_concat to simstr::stringa_mean 377 ns 377 ns 4 +Concat stringa and number by e_concat to simstr::stringa_median 381 ns 381 ns 4 +Concat stringa and number by e_concat to simstr::stringa_stddev 20.7 ns 20.7 ns 4 +Concat stringa and number by e_concat to simstr::stringa_cv 5.48 % 5.48 % 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 2034 ns 2034 ns 4 -Concat std::string and format hex number and literal to std::string_median 2040 ns 2040 ns 4 -Concat std::string and format hex number and literal to std::string_stddev 20.9 ns 20.9 ns 4 -Concat std::string and format hex number and literal to std::string_cv 1.03 % 1.03 % 4 -std::format std::string and hex number by literal to std::string_mean 2519 ns 2519 ns 4 -std::format std::string and hex number by literal to std::string_median 2492 ns 2492 ns 4 -std::format std::string and hex number by literal to std::string_stddev 74.1 ns 74.1 ns 4 -std::format std::string and hex number by literal to std::string_cv 2.94 % 2.94 % 4 -Concat std::string and std::to_chars and string to std::string_mean 617 ns 617 ns 4 -Concat std::string and std::to_chars and string to std::string_median 615 ns 615 ns 4 -Concat std::string and std::to_chars and string to std::string_stddev 11.3 ns 11.3 ns 4 -Concat std::string and std::to_chars and string to std::string_cv 1.83 % 1.83 % 4 -Concat std::string and hex number and literal by StrExpr to std::string_mean 473 ns 473 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_median 472 ns 472 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_stddev 14.4 ns 14.4 ns 4 -Concat std::string and hex number and literal by StrExpr to std::string_cv 3.04 % 3.04 % 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 184 ns 184 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 184 ns 184 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 3.53 ns 3.53 ns 4 -Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 1.92 % 1.92 % 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 190 ns 190 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_median 190 ns 190 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 2.76 ns 2.76 ns 4 -Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 1.46 % 1.46 % 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_mean 333 ns 333 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_median 324 ns 324 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 24.3 ns 24.3 ns 4 -Subst stringa and hex number by e_subst literal to simstr::stringa_cv 7.29 % 7.29 % 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 833 ns 833 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 830 ns 830 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 6.12 ns 6.12 ns 4 -Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 0.73 % 0.73 % 4 +Concat std::string and format hex number and literal to std::string_mean 3883 ns 3883 ns 4 +Concat std::string and format hex number and literal to std::string_median 3863 ns 3863 ns 4 +Concat std::string and format hex number and literal to std::string_stddev 153 ns 153 ns 4 +Concat std::string and format hex number and literal to std::string_cv 3.93 % 3.93 % 4 +std::format std::string and hex number by literal to std::string_mean 4986 ns 4986 ns 4 +std::format std::string and hex number by literal to std::string_median 4942 ns 4942 ns 4 +std::format std::string and hex number by literal to std::string_stddev 145 ns 145 ns 4 +std::format std::string and hex number by literal to std::string_cv 2.91 % 2.91 % 4 +Concat std::string and std::to_chars and string to std::string_mean 1124 ns 1124 ns 4 +Concat std::string and std::to_chars and string to std::string_median 1116 ns 1116 ns 4 +Concat std::string and std::to_chars and string to std::string_stddev 26.9 ns 26.9 ns 4 +Concat std::string and std::to_chars and string to std::string_cv 2.39 % 2.39 % 4 +Concat std::string and hex number and literal by StrExpr to std::string_mean 873 ns 873 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_median 873 ns 873 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_stddev 16.1 ns 16.1 ns 4 +Concat std::string and hex number and literal by StrExpr to std::string_cv 1.84 % 1.84 % 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_mean 257 ns 257 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_median 256 ns 256 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_stddev 17.0 ns 17.0 ns 4 +Concat stringa and hex number and literal by StrExpr to simstr::stringa_cv 6.64 % 6.64 % 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_mean 269 ns 269 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_median 261 ns 261 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_stddev 16.9 ns 16.9 ns 4 +Concat stringa and hex number and literal by e_concat to simstr::stringa_cv 6.28 % 6.28 % 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_mean 541 ns 541 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_median 542 ns 542 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_stddev 19.0 ns 19.0 ns 4 +Subst stringa and hex number by e_subst literal to simstr::stringa_cv 3.52 % 3.52 % 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_mean 1765 ns 1765 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_median 1752 ns 1752 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_stddev 42.3 ns 42.3 ns 4 +Subst stringa and hex number by e_vsubst stra to simstr::stringa_cv 2.39 % 2.40 % 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 380 ns 380 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 378 ns 378 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 9.65 ns 9.65 ns 4 -"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 2.54 % 2.54 % 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 580 ns 580 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 566 ns 566 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 33.3 ns 33.3 ns 4 -e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 5.75 % 5.75 % 4 -e_vsubst(pattern, i / 0x8a010_fmt)_mean 1424 ns 1424 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_median 1423 ns 1423 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_stddev 11.3 ns 11.3 ns 4 -e_vsubst(pattern, i / 0x8a010_fmt)_cv 0.79 % 0.79 % 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 2133 ns 2133 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 2135 ns 2135 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 70.7 ns 70.7 ns 4 -fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 3.32 % 3.32 % 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 2874 ns 2874 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 2863 ns 2863 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 36.5 ns 36.5 ns 4 -fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.27 % 1.27 % 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_mean 2951 ns 2951 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_median 2962 ns 2962 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 28.3 ns 28.3 ns 4 -std::format("abcdefghihklmopqr {:#010o} end", i)_cv 0.96 % 0.96 % 4 -std::vformat(pattern, std::make_format_args(i))_mean 3034 ns 3034 ns 4 -std::vformat(pattern, std::make_format_args(i))_median 3013 ns 3013 ns 4 -std::vformat(pattern, std::make_format_args(i))_stddev 135 ns 135 ns 4 -std::vformat(pattern, std::make_format_args(i))_cv 4.45 % 4.44 % 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 8267 ns 8267 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 8209 ns 8209 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 157 ns 157 ns 4 -strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 1.89 % 1.90 % 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_mean 843 ns 843 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_median 838 ns 838 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_stddev 30.8 ns 30.8 ns 4 +"abcdefghihklmopqr "_ss + i / 0x8a010_fmt + " end"_cv 3.66 % 3.66 % 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_mean 1112 ns 1112 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_median 1109 ns 1109 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_stddev 29.0 ns 29.0 ns 4 +e_subst("abcdefghihklmopqr {} end", i / 0x8a010_fmt)_cv 2.61 % 2.61 % 4 +e_vsubst(pattern, i / 0x8a010_fmt)_mean 2885 ns 2885 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_median 2907 ns 2907 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_stddev 68.1 ns 68.1 ns 4 +e_vsubst(pattern, i / 0x8a010_fmt)_cv 2.36 % 2.36 % 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_mean 4562 ns 4562 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_median 4601 ns 4601 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_stddev 149 ns 149 ns 4 +fmt::format(FMT_COMPILE("abcdefghihklmopqr {:#010o} end"), i)_cv 3.28 % 3.28 % 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_mean 4550 ns 4550 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_median 4516 ns 4516 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_stddev 88.7 ns 88.7 ns 4 +fmt::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.95 % 1.95 % 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_mean 5661 ns 5661 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_median 5668 ns 5668 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_stddev 99.7 ns 99.7 ns 4 +std::format("abcdefghihklmopqr {:#010o} end", i)_cv 1.76 % 1.76 % 4 +std::vformat(pattern, std::make_format_args(i))_mean 5730 ns 5730 ns 4 +std::vformat(pattern, std::make_format_args(i))_median 5771 ns 5771 ns 4 +std::vformat(pattern, std::make_format_args(i))_stddev 197 ns 197 ns 4 +std::vformat(pattern, std::make_format_args(i))_cv 3.44 % 3.44 % 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_mean 19623 ns 19623 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_median 19520 ns 19520 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_stddev 833 ns 833 ns 4 +strm << "abcdefghihklmopqr 0" << std::oct << std::setw(9) << std::setfill('0') << i << " end"_cv 4.25 % 4.25 % 4 ----- Concatenate string + "Literal" ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat std::string by std to std::string_mean 104 ns 104 ns 4 -Concat std::string by std to std::string_median 104 ns 104 ns 4 -Concat std::string by std to std::string_stddev 2.29 ns 2.29 ns 4 -Concat std::string by std to std::string_cv 2.20 % 2.20 % 4 -Concat std::string by StrExpr to std::string_mean 119 ns 119 ns 4 -Concat std::string by StrExpr to std::string_median 118 ns 118 ns 4 -Concat std::string by StrExpr to std::string_stddev 3.37 ns 3.37 ns 4 -Concat std::string by StrExpr to std::string_cv 2.84 % 2.84 % 4 -Concat stringa by StrExpr to stringa_mean 95.1 ns 95.1 ns 4 -Concat stringa by StrExpr to stringa_median 94.8 ns 94.8 ns 4 -Concat stringa by StrExpr to stringa_stddev 1.15 ns 1.15 ns 4 -Concat stringa by StrExpr to stringa_cv 1.21 % 1.21 % 4 +Concat std::string by std to std::string_mean 143 ns 143 ns 4 +Concat std::string by std to std::string_median 143 ns 143 ns 4 +Concat std::string by std to std::string_stddev 5.16 ns 5.16 ns 4 +Concat std::string by std to std::string_cv 3.61 % 3.61 % 4 +Concat std::string by StrExpr to std::string_mean 168 ns 168 ns 4 +Concat std::string by StrExpr to std::string_median 167 ns 167 ns 4 +Concat std::string by StrExpr to std::string_stddev 2.82 ns 2.82 ns 4 +Concat std::string by StrExpr to std::string_cv 1.68 % 1.68 % 4 +Concat stringa by StrExpr to stringa_mean 136 ns 136 ns 4 +Concat stringa by StrExpr to stringa_median 137 ns 137 ns 4 +Concat stringa by StrExpr to stringa_stddev 5.18 ns 5.19 ns 4 +Concat stringa by StrExpr to stringa_cv 3.80 % 3.80 % 4 ----- Find three concatenated string in string_view -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Find concat three std::string_mean 217 ns 217 ns 4 -Find concat three std::string_median 217 ns 217 ns 4 -Find concat three std::string_stddev 3.91 ns 3.91 ns 4 -Find concat three std::string_cv 1.80 % 1.80 % 4 -Find concat three strexpr_mean 107 ns 107 ns 4 -Find concat three strexpr_median 107 ns 107 ns 4 -Find concat three strexpr_stddev 2.12 ns 2.12 ns 4 -Find concat three strexpr_cv 1.98 % 1.98 % 4 -Find concat three simstr_mean 61.5 ns 61.5 ns 4 -Find concat three simstr_median 61.5 ns 61.5 ns 4 -Find concat three simstr_stddev 1.22 ns 1.23 ns 4 -Find concat three simstr_cv 1.99 % 1.99 % 4 +Find concat three std::string_mean 542 ns 542 ns 4 +Find concat three std::string_median 538 ns 538 ns 4 +Find concat three std::string_stddev 8.52 ns 8.52 ns 4 +Find concat three std::string_cv 1.57 % 1.57 % 4 +Find concat three strexpr_mean 294 ns 294 ns 4 +Find concat three strexpr_median 293 ns 293 ns 4 +Find concat three strexpr_stddev 6.47 ns 6.47 ns 4 +Find concat three strexpr_cv 2.20 % 2.20 % 4 +Find concat three simstr_mean 174 ns 174 ns 4 +Find concat three simstr_median 173 ns 173 ns 4 +Find concat three simstr_stddev 3.03 ns 3.03 ns 4 +Find concat three simstr_cv 1.74 % 1.74 % 4 +Find concat three stringzilla string_mean 619 ns 619 ns 4 +Find concat three stringzilla string_median 613 ns 613 ns 4 +Find concat three stringzilla string_stddev 22.3 ns 22.3 ns 4 +Find concat three stringzilla string_cv 3.60 % 3.60 % 4 ----- Build Type Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -BuildTypeNameStr 0/0_mean 21.3 ns 21.3 ns 4 -BuildTypeNameStr 0/0_median 21.3 ns 21.3 ns 4 -BuildTypeNameStr 0/0_stddev 0.119 ns 0.119 ns 4 -BuildTypeNameStr 0/0_cv 0.56 % 0.56 % 4 -BuildTypeNameExp 0/0_mean 23.4 ns 23.4 ns 4 -BuildTypeNameExp 0/0_median 23.4 ns 23.4 ns 4 -BuildTypeNameExp 0/0_stddev 0.346 ns 0.346 ns 4 -BuildTypeNameExp 0/0_cv 1.48 % 1.48 % 4 -BuildTypeNameSim 0/0_mean 19.2 ns 19.2 ns 4 -BuildTypeNameSim 0/0_median 19.4 ns 19.4 ns 4 -BuildTypeNameSim 0/0_stddev 0.418 ns 0.418 ns 4 -BuildTypeNameSim 0/0_cv 2.17 % 2.17 % 4 -BuildTypeNameStr 10/10_mean 374 ns 374 ns 4 -BuildTypeNameStr 10/10_median 374 ns 374 ns 4 -BuildTypeNameStr 10/10_stddev 8.65 ns 8.65 ns 4 -BuildTypeNameStr 10/10_cv 2.31 % 2.31 % 4 -BuildTypeNameExp 10/10_mean 109 ns 109 ns 4 -BuildTypeNameExp 10/10_median 109 ns 109 ns 4 -BuildTypeNameExp 10/10_stddev 2.70 ns 2.70 ns 4 -BuildTypeNameExp 10/10_cv 2.48 % 2.48 % 4 -BuildTypeNameSim 10/10_mean 63.6 ns 63.6 ns 4 -BuildTypeNameSim 10/10_median 63.6 ns 63.6 ns 4 -BuildTypeNameSim 10/10_stddev 0.768 ns 0.768 ns 4 -BuildTypeNameSim 10/10_cv 1.21 % 1.21 % 4 +BuildTypeNameStr 0/0_mean 27.4 ns 27.4 ns 4 +BuildTypeNameStr 0/0_median 27.7 ns 27.7 ns 4 +BuildTypeNameStr 0/0_stddev 0.735 ns 0.735 ns 4 +BuildTypeNameStr 0/0_cv 2.68 % 2.68 % 4 +BuildTypeNameExp 0/0_mean 28.9 ns 28.9 ns 4 +BuildTypeNameExp 0/0_median 28.5 ns 28.5 ns 4 +BuildTypeNameExp 0/0_stddev 1.31 ns 1.31 ns 4 +BuildTypeNameExp 0/0_cv 4.54 % 4.54 % 4 +BuildTypeNameSim 0/0_mean 38.4 ns 38.4 ns 4 +BuildTypeNameSim 0/0_median 38.4 ns 38.4 ns 4 +BuildTypeNameSim 0/0_stddev 1.05 ns 1.05 ns 4 +BuildTypeNameSim 0/0_cv 2.74 % 2.74 % 4 +BuildTypeNameStr 10/10_mean 652 ns 652 ns 4 +BuildTypeNameStr 10/10_median 648 ns 648 ns 4 +BuildTypeNameStr 10/10_stddev 17.3 ns 17.3 ns 4 +BuildTypeNameStr 10/10_cv 2.66 % 2.66 % 4 +BuildTypeNameExp 10/10_mean 196 ns 196 ns 4 +BuildTypeNameExp 10/10_median 195 ns 195 ns 4 +BuildTypeNameExp 10/10_stddev 3.78 ns 3.78 ns 4 +BuildTypeNameExp 10/10_cv 1.93 % 1.93 % 4 +BuildTypeNameSim 10/10_mean 141 ns 141 ns 4 +BuildTypeNameSim 10/10_median 142 ns 142 ns 4 +BuildTypeNameSim 10/10_stddev 6.43 ns 6.43 ns 4 +BuildTypeNameSim 10/10_cv 4.57 % 4.57 % 4 ----- Replace string by copy -----/repeats:1 0.000 ns 0.000 ns 1000000000000 -Concat with replace str_mean 495 ns 495 ns 4 -Concat with replace str_median 493 ns 493 ns 4 -Concat with replace str_stddev 7.47 ns 7.47 ns 4 -Concat with replace str_cv 1.51 % 1.51 % 4 -Concat with replace exp_mean 239 ns 239 ns 4 -Concat with replace exp_median 236 ns 236 ns 4 -Concat with replace exp_stddev 13.8 ns 13.8 ns 4 -Concat with replace exp_cv 5.80 % 5.80 % 4 +Concat with replace str_mean 1074 ns 1074 ns 4 +Concat with replace str_median 1069 ns 1069 ns 4 +Concat with replace str_stddev 33.7 ns 33.7 ns 4 +Concat with replace str_cv 3.13 % 3.13 % 4 +Concat with replace exp_mean 519 ns 519 ns 4 +Concat with replace exp_median 521 ns 521 ns 4 +Concat with replace exp_stddev 15.4 ns 15.4 ns 4 +Concat with replace exp_cv 2.97 % 2.97 % 4 ----- Create Empty Str ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e;_mean 2.14 ns 2.14 ns 4 -std::string e;_median 2.13 ns 2.13 ns 4 -std::string e;_stddev 0.008 ns 0.008 ns 4 -std::string e;_cv 0.39 % 0.39 % 4 -std::string_view e;_mean 0.730 ns 0.730 ns 4 -std::string_view e;_median 0.728 ns 0.728 ns 4 -std::string_view e;_stddev 0.011 ns 0.011 ns 4 -std::string_view e;_cv 1.58 % 1.58 % 4 -ssa e;_mean 0.364 ns 0.364 ns 4 -ssa e;_median 0.362 ns 0.362 ns 4 -ssa e;_stddev 0.004 ns 0.004 ns 4 -ssa e;_cv 1.06 % 1.06 % 4 -stringa e;_mean 2.17 ns 2.17 ns 4 -stringa e;_median 2.17 ns 2.17 ns 4 -stringa e;_stddev 0.019 ns 0.019 ns 4 -stringa e;_cv 0.87 % 0.87 % 4 -lstringa<20> e;_mean 2.18 ns 2.18 ns 4 -lstringa<20> e;_median 2.19 ns 2.19 ns 4 -lstringa<20> e;_stddev 0.025 ns 0.025 ns 4 -lstringa<20> e;_cv 1.15 % 1.15 % 4 -lstringa<40> e;_mean 2.26 ns 2.26 ns 4 -lstringa<40> e;_median 2.26 ns 2.26 ns 4 -lstringa<40> e;_stddev 0.014 ns 0.014 ns 4 -lstringa<40> e;_cv 0.61 % 0.61 % 4 +std::string e;_mean 2.60 ns 2.60 ns 4 +std::string e;_median 2.56 ns 2.56 ns 4 +std::string e;_stddev 0.104 ns 0.104 ns 4 +std::string e;_cv 4.00 % 4.00 % 4 +std::string_view e;_mean 2.15 ns 2.15 ns 4 +std::string_view e;_median 2.15 ns 2.15 ns 4 +std::string_view e;_stddev 0.014 ns 0.014 ns 4 +std::string_view e;_cv 0.65 % 0.65 % 4 +ssa e;_mean 2.16 ns 2.16 ns 4 +ssa e;_median 2.14 ns 2.14 ns 4 +ssa e;_stddev 0.039 ns 0.039 ns 4 +ssa e;_cv 1.81 % 1.81 % 4 +stringa e;_mean 5.52 ns 5.52 ns 4 +stringa e;_median 5.52 ns 5.52 ns 4 +stringa e;_stddev 0.024 ns 0.024 ns 4 +stringa e;_cv 0.43 % 0.43 % 4 +lstringa<20> e;_mean 9.16 ns 9.16 ns 4 +lstringa<20> e;_median 9.16 ns 9.16 ns 4 +lstringa<20> e;_stddev 0.026 ns 0.026 ns 4 +lstringa<20> e;_cv 0.29 % 0.29 % 4 +lstringa<40> e;_mean 8.53 ns 8.53 ns 4 +lstringa<40> e;_median 8.53 ns 8.53 ns 4 +lstringa<40> e;_stddev 0.038 ns 0.038 ns 4 +lstringa<40> e;_cv 0.44 % 0.44 % 4 ----- Create Str from short literal (9 symbols) --------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "Test text";_mean 2.43 ns 2.43 ns 4 -std::string e = "Test text";_median 2.43 ns 2.43 ns 4 -std::string e = "Test text";_stddev 0.059 ns 0.059 ns 4 -std::string e = "Test text";_cv 2.41 % 2.41 % 4 -std::string_view e = "Test text";_mean 1.10 ns 1.10 ns 4 -std::string_view e = "Test text";_median 1.09 ns 1.09 ns 4 -std::string_view e = "Test text";_stddev 0.031 ns 0.031 ns 4 -std::string_view e = "Test text";_cv 2.79 % 2.79 % 4 -ssa e = "Test text";_mean 0.732 ns 0.732 ns 4 -ssa e = "Test text";_median 0.732 ns 0.732 ns 4 -ssa e = "Test text";_stddev 0.008 ns 0.008 ns 4 -ssa e = "Test text";_cv 1.10 % 1.10 % 4 -stringa e = "Test text";_mean 2.19 ns 2.19 ns 4 -stringa e = "Test text";_median 2.19 ns 2.19 ns 4 -stringa e = "Test text";_stddev 0.027 ns 0.027 ns 4 -stringa e = "Test text";_cv 1.25 % 1.25 % 4 -lstringa<20> e = "Test text";_mean 2.57 ns 2.57 ns 4 -lstringa<20> e = "Test text";_median 2.57 ns 2.57 ns 4 -lstringa<20> e = "Test text";_stddev 0.025 ns 0.025 ns 4 -lstringa<20> e = "Test text";_cv 0.98 % 0.98 % 4 -lstringa<40> e = "Test text";_mean 2.62 ns 2.62 ns 4 -lstringa<40> e = "Test text";_median 2.62 ns 2.62 ns 4 -lstringa<40> e = "Test text";_stddev 0.012 ns 0.012 ns 4 -lstringa<40> e = "Test text";_cv 0.46 % 0.46 % 4 +std::string e = "Test text";_mean 10.4 ns 10.4 ns 4 +std::string e = "Test text";_median 10.3 ns 10.3 ns 4 +std::string e = "Test text";_stddev 0.030 ns 0.030 ns 4 +std::string e = "Test text";_cv 0.29 % 0.29 % 4 +std::string_view e = "Test text";_mean 2.18 ns 2.18 ns 4 +std::string_view e = "Test text";_median 2.18 ns 2.18 ns 4 +std::string_view e = "Test text";_stddev 0.029 ns 0.029 ns 4 +std::string_view e = "Test text";_cv 1.35 % 1.35 % 4 +ssa e = "Test text";_mean 2.17 ns 2.17 ns 4 +ssa e = "Test text";_median 2.17 ns 2.17 ns 4 +ssa e = "Test text";_stddev 0.023 ns 0.023 ns 4 +ssa e = "Test text";_cv 1.05 % 1.05 % 4 +stringa e = "Test text";_mean 8.30 ns 8.30 ns 4 +stringa e = "Test text";_median 8.29 ns 8.29 ns 4 +stringa e = "Test text";_stddev 0.036 ns 0.036 ns 4 +stringa e = "Test text";_cv 0.43 % 0.43 % 4 +lstringa<20> e = "Test text";_mean 3.89 ns 3.89 ns 4 +lstringa<20> e = "Test text";_median 3.90 ns 3.90 ns 4 +lstringa<20> e = "Test text";_stddev 0.043 ns 0.043 ns 4 +lstringa<20> e = "Test text";_cv 1.10 % 1.10 % 4 +lstringa<40> e = "Test text";_mean 3.93 ns 3.93 ns 4 +lstringa<40> e = "Test text";_median 3.91 ns 3.91 ns 4 +lstringa<40> e = "Test text";_stddev 0.054 ns 0.054 ns 4 +lstringa<40> e = "Test text";_cv 1.36 % 1.36 % 4 ----- Create Str from long literal (30 symbols) ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string e = "123456789012345678901234567890";_mean 22.4 ns 22.4 ns 4 -std::string e = "123456789012345678901234567890";_median 22.3 ns 22.3 ns 4 -std::string e = "123456789012345678901234567890";_stddev 0.716 ns 0.716 ns 4 -std::string e = "123456789012345678901234567890";_cv 3.19 % 3.19 % 4 -std::string_view e = "123456789012345678901234567890";_mean 1.18 ns 1.18 ns 4 -std::string_view e = "123456789012345678901234567890";_median 1.18 ns 1.18 ns 4 -std::string_view e = "123456789012345678901234567890";_stddev 0.056 ns 0.056 ns 4 -std::string_view e = "123456789012345678901234567890";_cv 4.77 % 4.77 % 4 -ssa e = "123456789012345678901234567890";_mean 0.778 ns 0.778 ns 4 -ssa e = "123456789012345678901234567890";_median 0.774 ns 0.774 ns 4 -ssa e = "123456789012345678901234567890";_stddev 0.020 ns 0.020 ns 4 -ssa e = "123456789012345678901234567890";_cv 2.59 % 2.59 % 4 -stringa e = "123456789012345678901234567890";_mean 2.22 ns 2.22 ns 4 -stringa e = "123456789012345678901234567890";_median 2.21 ns 2.21 ns 4 -stringa e = "123456789012345678901234567890";_stddev 0.051 ns 0.051 ns 4 -stringa e = "123456789012345678901234567890";_cv 2.28 % 2.28 % 4 -lstringa<20> e = "123456789012345678901234567890";_mean 24.8 ns 24.8 ns 4 -lstringa<20> e = "123456789012345678901234567890";_median 24.8 ns 24.8 ns 4 -lstringa<20> e = "123456789012345678901234567890";_stddev 0.315 ns 0.315 ns 4 -lstringa<20> e = "123456789012345678901234567890";_cv 1.27 % 1.27 % 4 -lstringa<40> e = "123456789012345678901234567890";_mean 3.16 ns 3.16 ns 4 -lstringa<40> e = "123456789012345678901234567890";_median 3.18 ns 3.18 ns 4 -lstringa<40> e = "123456789012345678901234567890";_stddev 0.081 ns 0.081 ns 4 -lstringa<40> e = "123456789012345678901234567890";_cv 2.58 % 2.58 % 4 +std::string e = "123456789012345678901234567890";_mean 68.6 ns 68.6 ns 4 +std::string e = "123456789012345678901234567890";_median 68.9 ns 68.9 ns 4 +std::string e = "123456789012345678901234567890";_stddev 0.993 ns 0.993 ns 4 +std::string e = "123456789012345678901234567890";_cv 1.45 % 1.45 % 4 +std::string_view e = "123456789012345678901234567890";_mean 2.19 ns 2.19 ns 4 +std::string_view e = "123456789012345678901234567890";_median 2.18 ns 2.18 ns 4 +std::string_view e = "123456789012345678901234567890";_stddev 0.032 ns 0.032 ns 4 +std::string_view e = "123456789012345678901234567890";_cv 1.46 % 1.46 % 4 +ssa e = "123456789012345678901234567890";_mean 2.18 ns 2.18 ns 4 +ssa e = "123456789012345678901234567890";_median 2.18 ns 2.18 ns 4 +ssa e = "123456789012345678901234567890";_stddev 0.015 ns 0.015 ns 4 +ssa e = "123456789012345678901234567890";_cv 0.70 % 0.70 % 4 +stringa e = "123456789012345678901234567890";_mean 8.30 ns 8.30 ns 4 +stringa e = "123456789012345678901234567890";_median 8.30 ns 8.30 ns 4 +stringa e = "123456789012345678901234567890";_stddev 0.035 ns 0.035 ns 4 +stringa e = "123456789012345678901234567890";_cv 0.42 % 0.42 % 4 +lstringa<20> e = "123456789012345678901234567890";_mean 68.6 ns 68.6 ns 4 +lstringa<20> e = "123456789012345678901234567890";_median 68.5 ns 68.5 ns 4 +lstringa<20> e = "123456789012345678901234567890";_stddev 1.62 ns 1.62 ns 4 +lstringa<20> e = "123456789012345678901234567890";_cv 2.36 % 2.36 % 4 +lstringa<40> e = "123456789012345678901234567890";_mean 11.4 ns 11.4 ns 4 +lstringa<40> e = "123456789012345678901234567890";_median 11.5 ns 11.5 ns 4 +lstringa<40> e = "123456789012345678901234567890";_stddev 0.078 ns 0.078 ns 4 +lstringa<40> e = "123456789012345678901234567890";_cv 0.68 % 0.68 % 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 3.86 ns 3.86 ns 4 -std::string e = "Test text"; auto c{e};_median 3.77 ns 3.77 ns 4 -std::string e = "Test text"; auto c{e};_stddev 0.191 ns 0.191 ns 4 -std::string e = "Test text"; auto c{e};_cv 4.96 % 4.96 % 4 -std::string_view e = "Test text"; auto c{e};_mean 1.14 ns 1.14 ns 4 -std::string_view e = "Test text"; auto c{e};_median 1.14 ns 1.14 ns 4 -std::string_view e = "Test text"; auto c{e};_stddev 0.037 ns 0.037 ns 4 -std::string_view e = "Test text"; auto c{e};_cv 3.24 % 3.24 % 4 -ssa e = "Test text"; auto c{e};_mean 1.19 ns 1.19 ns 4 -ssa e = "Test text"; auto c{e};_median 1.19 ns 1.19 ns 4 -ssa e = "Test text"; auto c{e};_stddev 0.044 ns 0.044 ns 4 -ssa e = "Test text"; auto c{e};_cv 3.72 % 3.72 % 4 -stringa e = "Test text"; auto c{e};_mean 2.53 ns 2.53 ns 4 -stringa e = "Test text"; auto c{e};_median 2.52 ns 2.52 ns 4 -stringa e = "Test text"; auto c{e};_stddev 0.046 ns 0.046 ns 4 -stringa e = "Test text"; auto c{e};_cv 1.81 % 1.81 % 4 -lstringa<20> e = "Test text"; auto c{e};_mean 4.78 ns 4.78 ns 4 -lstringa<20> e = "Test text"; auto c{e};_median 4.77 ns 4.77 ns 4 -lstringa<20> e = "Test text"; auto c{e};_stddev 0.094 ns 0.094 ns 4 -lstringa<20> e = "Test text"; auto c{e};_cv 1.97 % 1.97 % 4 -lstringa<40> e = "Test text"; auto c{e};_mean 4.80 ns 4.80 ns 4 -lstringa<40> e = "Test text"; auto c{e};_median 4.78 ns 4.78 ns 4 -lstringa<40> e = "Test text"; auto c{e};_stddev 0.109 ns 0.109 ns 4 -lstringa<40> e = "Test text"; auto c{e};_cv 2.27 % 2.27 % 4 +std::string e = "Test text"; auto c{e};_mean 7.32 ns 7.32 ns 4 +std::string e = "Test text"; auto c{e};_median 7.33 ns 7.33 ns 4 +std::string e = "Test text"; auto c{e};_stddev 0.088 ns 0.088 ns 4 +std::string e = "Test text"; auto c{e};_cv 1.21 % 1.21 % 4 +std::string_view e = "Test text"; auto c{e};_mean 2.17 ns 2.17 ns 4 +std::string_view e = "Test text"; auto c{e};_median 2.18 ns 2.18 ns 4 +std::string_view e = "Test text"; auto c{e};_stddev 0.020 ns 0.020 ns 4 +std::string_view e = "Test text"; auto c{e};_cv 0.92 % 0.92 % 4 +ssa e = "Test text"; auto c{e};_mean 2.18 ns 2.18 ns 4 +ssa e = "Test text"; auto c{e};_median 2.18 ns 2.18 ns 4 +ssa e = "Test text"; auto c{e};_stddev 0.008 ns 0.008 ns 4 +ssa e = "Test text"; auto c{e};_cv 0.35 % 0.35 % 4 +stringa e = "Test text"; auto c{e};_mean 6.33 ns 6.33 ns 4 +stringa e = "Test text"; auto c{e};_median 6.32 ns 6.32 ns 4 +stringa e = "Test text"; auto c{e};_stddev 0.029 ns 0.029 ns 4 +stringa e = "Test text"; auto c{e};_cv 0.46 % 0.46 % 4 +lstringa<20> e = "Test text"; auto c{e};_mean 7.15 ns 7.15 ns 4 +lstringa<20> e = "Test text"; auto c{e};_median 7.15 ns 7.15 ns 4 +lstringa<20> e = "Test text"; auto c{e};_stddev 0.104 ns 0.104 ns 4 +lstringa<20> e = "Test text"; auto c{e};_cv 1.45 % 1.45 % 4 +lstringa<40> e = "Test text"; auto c{e};_mean 7.33 ns 7.33 ns 4 +lstringa<40> e = "Test text"; auto c{e};_median 7.30 ns 7.30 ns 4 +lstringa<40> e = "Test text"; auto c{e};_stddev 0.086 ns 0.086 ns 4 +lstringa<40> e = "Test text"; auto c{e};_cv 1.18 % 1.18 % 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 46.7 ns 46.7 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_median 46.6 ns 46.6 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_stddev 1.08 ns 1.08 ns 4 -std::string e = "123456789012345678901234567890"; auto c{e};_cv 2.31 % 2.31 % 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 1.09 ns 1.09 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_median 1.09 ns 1.09 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.007 ns 0.007 ns 4 -std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 0.60 % 0.60 % 4 -ssa e = "123456789012345678901234567890"; auto c{e};_mean 0.737 ns 0.737 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_median 0.736 ns 0.736 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.009 ns 0.009 ns 4 -ssa e = "123456789012345678901234567890"; auto c{e};_cv 1.24 % 1.24 % 4 -stringa e = "123456789012345678901234567890"; auto c{e};_mean 2.16 ns 2.16 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_median 2.16 ns 2.16 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.025 ns 0.025 ns 4 -stringa e = "123456789012345678901234567890"; auto c{e};_cv 1.14 % 1.14 % 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 21.9 ns 21.9 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 21.8 ns 21.8 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 0.441 ns 0.441 ns 4 -lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 2.01 % 2.01 % 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 15.0 ns 15.0 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 15.0 ns 15.0 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.089 ns 0.089 ns 4 -lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 0.60 % 0.60 % 4 +std::string e = "123456789012345678901234567890"; auto c{e};_mean 120 ns 120 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_median 121 ns 121 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_stddev 3.63 ns 3.63 ns 4 +std::string e = "123456789012345678901234567890"; auto c{e};_cv 3.03 % 3.03 % 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_mean 2.22 ns 2.22 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_median 2.22 ns 2.22 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_stddev 0.031 ns 0.031 ns 4 +std::string_view e = "123456789012345678901234567890"; auto c{e};_cv 1.40 % 1.40 % 4 +ssa e = "123456789012345678901234567890"; auto c{e};_mean 2.16 ns 2.16 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_median 2.15 ns 2.15 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_stddev 0.021 ns 0.021 ns 4 +ssa e = "123456789012345678901234567890"; auto c{e};_cv 0.99 % 0.99 % 4 +stringa e = "123456789012345678901234567890"; auto c{e};_mean 8.35 ns 8.35 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_median 8.34 ns 8.34 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_stddev 0.052 ns 0.052 ns 4 +stringa e = "123456789012345678901234567890"; auto c{e};_cv 0.62 % 0.62 % 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_mean 67.2 ns 67.2 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_median 66.8 ns 66.8 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_stddev 2.44 ns 2.44 ns 4 +lstringa<20> e = "123456789012345678901234567890"; auto c{e};_cv 3.63 % 3.63 % 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_mean 19.7 ns 19.7 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_median 19.9 ns 19.9 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_stddev 0.518 ns 0.518 ns 4 +lstringa<40> e = "123456789012345678901234567890"; auto c{e};_cv 2.62 % 2.62 % 4 ----- Find 9 symbols text in end of 99 symbols text ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string::find;_mean 43.3 ns 43.3 ns 4 -std::string::find;_median 43.2 ns 43.2 ns 4 -std::string::find;_stddev 0.425 ns 0.426 ns 4 -std::string::find;_cv 0.98 % 0.98 % 4 -std::string_view::find;_mean 45.3 ns 45.3 ns 4 -std::string_view::find;_median 45.1 ns 45.1 ns 4 -std::string_view::find;_stddev 0.457 ns 0.457 ns 4 -std::string_view::find;_cv 1.01 % 1.01 % 4 -ssa::find;_mean 43.4 ns 43.4 ns 4 -ssa::find;_median 43.4 ns 43.4 ns 4 -ssa::find;_stddev 0.667 ns 0.667 ns 4 -ssa::find;_cv 1.54 % 1.54 % 4 -stringa::find;_mean 43.5 ns 43.5 ns 4 -stringa::find;_median 43.5 ns 43.5 ns 4 -stringa::find;_stddev 0.666 ns 0.666 ns 4 -stringa::find;_cv 1.53 % 1.53 % 4 -lstringa<20>::find;_mean 38.7 ns 38.7 ns 4 -lstringa<20>::find;_median 38.7 ns 38.7 ns 4 -lstringa<20>::find;_stddev 0.098 ns 0.098 ns 4 -lstringa<20>::find;_cv 0.25 % 0.25 % 4 -lstringa<40>::find;_mean 40.2 ns 40.2 ns 4 -lstringa<40>::find;_median 40.4 ns 40.4 ns 4 -lstringa<40>::find;_stddev 0.525 ns 0.525 ns 4 -lstringa<40>::find;_cv 1.30 % 1.30 % 4 +sz::string::find;_mean 227 ns 227 ns 4 +sz::string::find;_median 227 ns 227 ns 4 +sz::string::find;_stddev 3.79 ns 3.79 ns 4 +sz::string::find;_cv 1.67 % 1.67 % 4 +std::string::find;_mean 99.1 ns 99.1 ns 4 +std::string::find;_median 99.5 ns 99.5 ns 4 +std::string::find;_stddev 1.42 ns 1.42 ns 4 +std::string::find;_cv 1.43 % 1.43 % 4 +std::string_view::find;_mean 97.5 ns 97.5 ns 4 +std::string_view::find;_median 96.6 ns 96.6 ns 4 +std::string_view::find;_stddev 2.75 ns 2.75 ns 4 +std::string_view::find;_cv 2.82 % 2.82 % 4 +ssa::find;_mean 96.3 ns 96.3 ns 4 +ssa::find;_median 96.6 ns 96.6 ns 4 +ssa::find;_stddev 1.81 ns 1.81 ns 4 +ssa::find;_cv 1.88 % 1.88 % 4 +stringa::find;_mean 97.2 ns 97.2 ns 4 +stringa::find;_median 96.5 ns 96.5 ns 4 +stringa::find;_stddev 1.65 ns 1.65 ns 4 +stringa::find;_cv 1.69 % 1.69 % 4 +lstringa<20>::find;_mean 97.6 ns 97.6 ns 4 +lstringa<20>::find;_median 97.6 ns 97.6 ns 4 +lstringa<20>::find;_stddev 0.528 ns 0.528 ns 4 +lstringa<20>::find;_cv 0.54 % 0.54 % 4 +lstringa<40>::find;_mean 96.0 ns 96.0 ns 4 +lstringa<40>::find;_median 96.1 ns 96.1 ns 4 +lstringa<40>::find;_stddev 0.872 ns 0.873 ns 4 +lstringa<40>::find;_cv 0.91 % 0.91 % 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 49.3 ns 49.3 ns 4 -std::string copy{str_with_len_N};/15_median 49.1 ns 49.1 ns 4 -std::string copy{str_with_len_N};/15_stddev 1.47 ns 1.47 ns 4 -std::string copy{str_with_len_N};/15_cv 2.98 % 2.98 % 4 -std::string copy{str_with_len_N};/16_mean 48.3 ns 48.3 ns 4 -std::string copy{str_with_len_N};/16_median 48.2 ns 48.2 ns 4 -std::string copy{str_with_len_N};/16_stddev 0.527 ns 0.527 ns 4 -std::string copy{str_with_len_N};/16_cv 1.09 % 1.09 % 4 -std::string copy{str_with_len_N};/23_mean 49.1 ns 49.1 ns 4 -std::string copy{str_with_len_N};/23_median 49.1 ns 49.1 ns 4 -std::string copy{str_with_len_N};/23_stddev 0.755 ns 0.755 ns 4 -std::string copy{str_with_len_N};/23_cv 1.54 % 1.54 % 4 -std::string copy{str_with_len_N};/24_mean 48.1 ns 48.1 ns 4 -std::string copy{str_with_len_N};/24_median 48.2 ns 48.2 ns 4 -std::string copy{str_with_len_N};/24_stddev 0.677 ns 0.677 ns 4 -std::string copy{str_with_len_N};/24_cv 1.41 % 1.41 % 4 -std::string copy{str_with_len_N};/32_mean 51.5 ns 51.5 ns 4 -std::string copy{str_with_len_N};/32_median 51.1 ns 51.1 ns 4 -std::string copy{str_with_len_N};/32_stddev 1.18 ns 1.18 ns 4 -std::string copy{str_with_len_N};/32_cv 2.30 % 2.30 % 4 -std::string copy{str_with_len_N};/64_mean 53.0 ns 53.0 ns 4 -std::string copy{str_with_len_N};/64_median 52.7 ns 52.7 ns 4 -std::string copy{str_with_len_N};/64_stddev 1.25 ns 1.25 ns 4 -std::string copy{str_with_len_N};/64_cv 2.35 % 2.35 % 4 -std::string copy{str_with_len_N};/128_mean 52.6 ns 52.6 ns 4 -std::string copy{str_with_len_N};/128_median 52.6 ns 52.6 ns 4 -std::string copy{str_with_len_N};/128_stddev 0.900 ns 0.900 ns 4 -std::string copy{str_with_len_N};/128_cv 1.71 % 1.71 % 4 -std::string copy{str_with_len_N};/256_mean 59.2 ns 59.2 ns 4 -std::string copy{str_with_len_N};/256_median 53.2 ns 53.2 ns 4 -std::string copy{str_with_len_N};/256_stddev 12.5 ns 12.5 ns 4 -std::string copy{str_with_len_N};/256_cv 21.06 % 21.06 % 4 -std::string copy{str_with_len_N};/512_mean 59.5 ns 59.5 ns 4 -std::string copy{str_with_len_N};/512_median 59.3 ns 59.3 ns 4 -std::string copy{str_with_len_N};/512_stddev 3.97 ns 3.97 ns 4 -std::string copy{str_with_len_N};/512_cv 6.68 % 6.68 % 4 -std::string copy{str_with_len_N};/1024_mean 68.5 ns 68.5 ns 4 -std::string copy{str_with_len_N};/1024_median 68.5 ns 68.6 ns 4 -std::string copy{str_with_len_N};/1024_stddev 5.29 ns 5.29 ns 4 -std::string copy{str_with_len_N};/1024_cv 7.72 % 7.72 % 4 -std::string copy{str_with_len_N};/2048_mean 90.5 ns 90.5 ns 4 -std::string copy{str_with_len_N};/2048_median 90.2 ns 90.2 ns 4 -std::string copy{str_with_len_N};/2048_stddev 7.02 ns 7.02 ns 4 -std::string copy{str_with_len_N};/2048_cv 7.76 % 7.76 % 4 -std::string copy{str_with_len_N};/4096_mean 133 ns 133 ns 4 -std::string copy{str_with_len_N};/4096_median 133 ns 133 ns 4 -std::string copy{str_with_len_N};/4096_stddev 2.50 ns 2.50 ns 4 -std::string copy{str_with_len_N};/4096_cv 1.88 % 1.88 % 4 -stringa copy{str_with_len_N};/15_mean 2.36 ns 2.36 ns 4 -stringa copy{str_with_len_N};/15_median 2.36 ns 2.36 ns 4 -stringa copy{str_with_len_N};/15_stddev 0.040 ns 0.040 ns 4 -stringa copy{str_with_len_N};/15_cv 1.72 % 1.72 % 4 -stringa copy{str_with_len_N};/16_mean 4.79 ns 4.79 ns 4 -stringa copy{str_with_len_N};/16_median 4.79 ns 4.79 ns 4 -stringa copy{str_with_len_N};/16_stddev 0.061 ns 0.061 ns 4 -stringa copy{str_with_len_N};/16_cv 1.27 % 1.27 % 4 -stringa copy{str_with_len_N};/23_mean 4.82 ns 4.82 ns 4 -stringa copy{str_with_len_N};/23_median 4.81 ns 4.81 ns 4 -stringa copy{str_with_len_N};/23_stddev 0.062 ns 0.062 ns 4 -stringa copy{str_with_len_N};/23_cv 1.29 % 1.29 % 4 -stringa copy{str_with_len_N};/24_mean 4.79 ns 4.79 ns 4 -stringa copy{str_with_len_N};/24_median 4.78 ns 4.78 ns 4 -stringa copy{str_with_len_N};/24_stddev 0.056 ns 0.056 ns 4 -stringa copy{str_with_len_N};/24_cv 1.18 % 1.18 % 4 -stringa copy{str_with_len_N};/32_mean 4.81 ns 4.81 ns 4 -stringa copy{str_with_len_N};/32_median 4.82 ns 4.82 ns 4 -stringa copy{str_with_len_N};/32_stddev 0.048 ns 0.048 ns 4 -stringa copy{str_with_len_N};/32_cv 1.01 % 1.01 % 4 -stringa copy{str_with_len_N};/64_mean 4.83 ns 4.83 ns 4 -stringa copy{str_with_len_N};/64_median 4.78 ns 4.78 ns 4 -stringa copy{str_with_len_N};/64_stddev 0.166 ns 0.166 ns 4 -stringa copy{str_with_len_N};/64_cv 3.43 % 3.43 % 4 -stringa copy{str_with_len_N};/128_mean 4.77 ns 4.77 ns 4 -stringa copy{str_with_len_N};/128_median 4.76 ns 4.76 ns 4 -stringa copy{str_with_len_N};/128_stddev 0.070 ns 0.070 ns 4 -stringa copy{str_with_len_N};/128_cv 1.46 % 1.46 % 4 -stringa copy{str_with_len_N};/256_mean 4.81 ns 4.81 ns 4 -stringa copy{str_with_len_N};/256_median 4.81 ns 4.81 ns 4 -stringa copy{str_with_len_N};/256_stddev 0.059 ns 0.059 ns 4 -stringa copy{str_with_len_N};/256_cv 1.23 % 1.23 % 4 -stringa copy{str_with_len_N};/512_mean 4.77 ns 4.77 ns 4 -stringa copy{str_with_len_N};/512_median 4.76 ns 4.76 ns 4 -stringa copy{str_with_len_N};/512_stddev 0.032 ns 0.032 ns 4 -stringa copy{str_with_len_N};/512_cv 0.68 % 0.68 % 4 -stringa copy{str_with_len_N};/1024_mean 4.83 ns 4.83 ns 4 -stringa copy{str_with_len_N};/1024_median 4.83 ns 4.83 ns 4 -stringa copy{str_with_len_N};/1024_stddev 0.043 ns 0.043 ns 4 -stringa copy{str_with_len_N};/1024_cv 0.90 % 0.90 % 4 -stringa copy{str_with_len_N};/2048_mean 4.82 ns 4.82 ns 4 -stringa copy{str_with_len_N};/2048_median 4.79 ns 4.79 ns 4 -stringa copy{str_with_len_N};/2048_stddev 0.072 ns 0.072 ns 4 -stringa copy{str_with_len_N};/2048_cv 1.50 % 1.50 % 4 -stringa copy{str_with_len_N};/4096_mean 4.77 ns 4.77 ns 4 -stringa copy{str_with_len_N};/4096_median 4.77 ns 4.77 ns 4 -stringa copy{str_with_len_N};/4096_stddev 0.043 ns 0.043 ns 4 -stringa copy{str_with_len_N};/4096_cv 0.89 % 0.89 % 4 -lstringa<16> copy{str_with_len_N};/15_mean 4.05 ns 4.05 ns 4 -lstringa<16> copy{str_with_len_N};/15_median 4.06 ns 4.06 ns 4 -lstringa<16> copy{str_with_len_N};/15_stddev 0.064 ns 0.064 ns 4 -lstringa<16> copy{str_with_len_N};/15_cv 1.59 % 1.59 % 4 -lstringa<16> copy{str_with_len_N};/16_mean 14.5 ns 14.5 ns 4 -lstringa<16> copy{str_with_len_N};/16_median 14.6 ns 14.6 ns 4 -lstringa<16> copy{str_with_len_N};/16_stddev 0.232 ns 0.232 ns 4 -lstringa<16> copy{str_with_len_N};/16_cv 1.60 % 1.60 % 4 -lstringa<16> copy{str_with_len_N};/23_mean 35.6 ns 35.6 ns 4 -lstringa<16> copy{str_with_len_N};/23_median 35.4 ns 35.4 ns 4 -lstringa<16> copy{str_with_len_N};/23_stddev 0.844 ns 0.844 ns 4 -lstringa<16> copy{str_with_len_N};/23_cv 2.37 % 2.37 % 4 -lstringa<16> copy{str_with_len_N};/24_mean 35.4 ns 35.4 ns 4 -lstringa<16> copy{str_with_len_N};/24_median 35.2 ns 35.2 ns 4 -lstringa<16> copy{str_with_len_N};/24_stddev 0.567 ns 0.567 ns 4 -lstringa<16> copy{str_with_len_N};/24_cv 1.60 % 1.60 % 4 -lstringa<16> copy{str_with_len_N};/32_mean 38.4 ns 38.4 ns 4 -lstringa<16> copy{str_with_len_N};/32_median 38.4 ns 38.4 ns 4 -lstringa<16> copy{str_with_len_N};/32_stddev 0.519 ns 0.519 ns 4 -lstringa<16> copy{str_with_len_N};/32_cv 1.35 % 1.35 % 4 -lstringa<16> copy{str_with_len_N};/64_mean 38.3 ns 38.3 ns 4 -lstringa<16> copy{str_with_len_N};/64_median 38.3 ns 38.3 ns 4 -lstringa<16> copy{str_with_len_N};/64_stddev 0.509 ns 0.509 ns 4 -lstringa<16> copy{str_with_len_N};/64_cv 1.33 % 1.33 % 4 -lstringa<16> copy{str_with_len_N};/128_mean 39.6 ns 39.6 ns 4 -lstringa<16> copy{str_with_len_N};/128_median 38.8 ns 38.8 ns 4 -lstringa<16> copy{str_with_len_N};/128_stddev 2.10 ns 2.10 ns 4 -lstringa<16> copy{str_with_len_N};/128_cv 5.31 % 5.31 % 4 -lstringa<16> copy{str_with_len_N};/256_mean 45.5 ns 45.5 ns 4 -lstringa<16> copy{str_with_len_N};/256_median 39.3 ns 39.3 ns 4 -lstringa<16> copy{str_with_len_N};/256_stddev 12.7 ns 12.7 ns 4 -lstringa<16> copy{str_with_len_N};/256_cv 28.04 % 28.04 % 4 -lstringa<16> copy{str_with_len_N};/512_mean 44.0 ns 44.0 ns 4 -lstringa<16> copy{str_with_len_N};/512_median 44.0 ns 44.0 ns 4 -lstringa<16> copy{str_with_len_N};/512_stddev 2.59 ns 2.59 ns 4 -lstringa<16> copy{str_with_len_N};/512_cv 5.88 % 5.88 % 4 -lstringa<16> copy{str_with_len_N};/1024_mean 54.9 ns 54.9 ns 4 -lstringa<16> copy{str_with_len_N};/1024_median 54.3 ns 54.3 ns 4 -lstringa<16> copy{str_with_len_N};/1024_stddev 4.67 ns 4.67 ns 4 -lstringa<16> copy{str_with_len_N};/1024_cv 8.51 % 8.51 % 4 -lstringa<16> copy{str_with_len_N};/2048_mean 76.6 ns 76.6 ns 4 -lstringa<16> copy{str_with_len_N};/2048_median 75.7 ns 75.7 ns 4 -lstringa<16> copy{str_with_len_N};/2048_stddev 7.67 ns 7.67 ns 4 -lstringa<16> copy{str_with_len_N};/2048_cv 10.00 % 10.00 % 4 -lstringa<16> copy{str_with_len_N};/4096_mean 122 ns 122 ns 4 -lstringa<16> copy{str_with_len_N};/4096_median 122 ns 122 ns 4 -lstringa<16> copy{str_with_len_N};/4096_stddev 2.81 ns 2.81 ns 4 -lstringa<16> copy{str_with_len_N};/4096_cv 2.31 % 2.31 % 4 -lstringa<512> copy{str_with_len_N};/15_mean 4.44 ns 4.44 ns 4 -lstringa<512> copy{str_with_len_N};/15_median 4.47 ns 4.47 ns 4 -lstringa<512> copy{str_with_len_N};/15_stddev 0.089 ns 0.089 ns 4 -lstringa<512> copy{str_with_len_N};/15_cv 2.00 % 2.00 % 4 -lstringa<512> copy{str_with_len_N};/16_mean 15.0 ns 15.0 ns 4 -lstringa<512> copy{str_with_len_N};/16_median 15.0 ns 15.0 ns 4 -lstringa<512> copy{str_with_len_N};/16_stddev 0.159 ns 0.159 ns 4 -lstringa<512> copy{str_with_len_N};/16_cv 1.06 % 1.06 % 4 -lstringa<512> copy{str_with_len_N};/23_mean 15.0 ns 15.0 ns 4 -lstringa<512> copy{str_with_len_N};/23_median 15.0 ns 15.0 ns 4 -lstringa<512> copy{str_with_len_N};/23_stddev 0.162 ns 0.162 ns 4 -lstringa<512> copy{str_with_len_N};/23_cv 1.08 % 1.08 % 4 -lstringa<512> copy{str_with_len_N};/24_mean 15.1 ns 15.1 ns 4 -lstringa<512> copy{str_with_len_N};/24_median 15.1 ns 15.1 ns 4 -lstringa<512> copy{str_with_len_N};/24_stddev 0.312 ns 0.312 ns 4 -lstringa<512> copy{str_with_len_N};/24_cv 2.07 % 2.07 % 4 -lstringa<512> copy{str_with_len_N};/32_mean 17.8 ns 17.8 ns 4 -lstringa<512> copy{str_with_len_N};/32_median 17.8 ns 17.8 ns 4 -lstringa<512> copy{str_with_len_N};/32_stddev 0.168 ns 0.168 ns 4 -lstringa<512> copy{str_with_len_N};/32_cv 0.95 % 0.95 % 4 -lstringa<512> copy{str_with_len_N};/64_mean 18.4 ns 18.4 ns 4 -lstringa<512> copy{str_with_len_N};/64_median 18.3 ns 18.3 ns 4 -lstringa<512> copy{str_with_len_N};/64_stddev 0.497 ns 0.498 ns 4 -lstringa<512> copy{str_with_len_N};/64_cv 2.70 % 2.70 % 4 -lstringa<512> copy{str_with_len_N};/128_mean 18.5 ns 18.5 ns 4 -lstringa<512> copy{str_with_len_N};/128_median 18.5 ns 18.5 ns 4 -lstringa<512> copy{str_with_len_N};/128_stddev 0.272 ns 0.272 ns 4 -lstringa<512> copy{str_with_len_N};/128_cv 1.47 % 1.47 % 4 -lstringa<512> copy{str_with_len_N};/256_mean 20.5 ns 20.5 ns 4 -lstringa<512> copy{str_with_len_N};/256_median 20.6 ns 20.6 ns 4 -lstringa<512> copy{str_with_len_N};/256_stddev 0.361 ns 0.361 ns 4 -lstringa<512> copy{str_with_len_N};/256_cv 1.76 % 1.76 % 4 -lstringa<512> copy{str_with_len_N};/512_mean 23.2 ns 23.2 ns 4 -lstringa<512> copy{str_with_len_N};/512_median 23.2 ns 23.2 ns 4 -lstringa<512> copy{str_with_len_N};/512_stddev 0.043 ns 0.043 ns 4 -lstringa<512> copy{str_with_len_N};/512_cv 0.18 % 0.18 % 4 -lstringa<512> copy{str_with_len_N};/1024_mean 55.2 ns 55.2 ns 4 -lstringa<512> copy{str_with_len_N};/1024_median 53.8 ns 53.8 ns 4 -lstringa<512> copy{str_with_len_N};/1024_stddev 4.51 ns 4.51 ns 4 -lstringa<512> copy{str_with_len_N};/1024_cv 8.18 % 8.18 % 4 -lstringa<512> copy{str_with_len_N};/2048_mean 76.0 ns 76.0 ns 4 -lstringa<512> copy{str_with_len_N};/2048_median 76.0 ns 76.0 ns 4 -lstringa<512> copy{str_with_len_N};/2048_stddev 6.65 ns 6.65 ns 4 -lstringa<512> copy{str_with_len_N};/2048_cv 8.75 % 8.75 % 4 -lstringa<512> copy{str_with_len_N};/4096_mean 122 ns 122 ns 4 -lstringa<512> copy{str_with_len_N};/4096_median 122 ns 122 ns 4 -lstringa<512> copy{str_with_len_N};/4096_stddev 5.22 ns 5.22 ns 4 -lstringa<512> copy{str_with_len_N};/4096_cv 4.27 % 4.27 % 4 +std::string copy{str_with_len_N};/15_mean 125 ns 125 ns 4 +std::string copy{str_with_len_N};/15_median 123 ns 123 ns 4 +std::string copy{str_with_len_N};/15_stddev 8.82 ns 8.82 ns 4 +std::string copy{str_with_len_N};/15_cv 7.08 % 7.08 % 4 +std::string copy{str_with_len_N};/16_mean 123 ns 123 ns 4 +std::string copy{str_with_len_N};/16_median 123 ns 123 ns 4 +std::string copy{str_with_len_N};/16_stddev 4.16 ns 4.16 ns 4 +std::string copy{str_with_len_N};/16_cv 3.39 % 3.39 % 4 +std::string copy{str_with_len_N};/23_mean 128 ns 128 ns 4 +std::string copy{str_with_len_N};/23_median 129 ns 129 ns 4 +std::string copy{str_with_len_N};/23_stddev 3.91 ns 3.91 ns 4 +std::string copy{str_with_len_N};/23_cv 3.06 % 3.06 % 4 +std::string copy{str_with_len_N};/24_mean 120 ns 120 ns 4 +std::string copy{str_with_len_N};/24_median 120 ns 120 ns 4 +std::string copy{str_with_len_N};/24_stddev 2.92 ns 2.92 ns 4 +std::string copy{str_with_len_N};/24_cv 2.43 % 2.43 % 4 +std::string copy{str_with_len_N};/32_mean 128 ns 128 ns 4 +std::string copy{str_with_len_N};/32_median 125 ns 125 ns 4 +std::string copy{str_with_len_N};/32_stddev 5.43 ns 5.43 ns 4 +std::string copy{str_with_len_N};/32_cv 4.25 % 4.25 % 4 +std::string copy{str_with_len_N};/64_mean 131 ns 131 ns 4 +std::string copy{str_with_len_N};/64_median 131 ns 131 ns 4 +std::string copy{str_with_len_N};/64_stddev 5.76 ns 5.76 ns 4 +std::string copy{str_with_len_N};/64_cv 4.40 % 4.40 % 4 +std::string copy{str_with_len_N};/128_mean 132 ns 132 ns 4 +std::string copy{str_with_len_N};/128_median 132 ns 132 ns 4 +std::string copy{str_with_len_N};/128_stddev 1.51 ns 1.51 ns 4 +std::string copy{str_with_len_N};/128_cv 1.15 % 1.15 % 4 +std::string copy{str_with_len_N};/256_mean 161 ns 161 ns 4 +std::string copy{str_with_len_N};/256_median 149 ns 149 ns 4 +std::string copy{str_with_len_N};/256_stddev 27.6 ns 27.6 ns 4 +std::string copy{str_with_len_N};/256_cv 17.09 % 17.09 % 4 +std::string copy{str_with_len_N};/512_mean 149 ns 149 ns 4 +std::string copy{str_with_len_N};/512_median 150 ns 150 ns 4 +std::string copy{str_with_len_N};/512_stddev 2.08 ns 2.08 ns 4 +std::string copy{str_with_len_N};/512_cv 1.39 % 1.39 % 4 +std::string copy{str_with_len_N};/1024_mean 156 ns 156 ns 4 +std::string copy{str_with_len_N};/1024_median 157 ns 157 ns 4 +std::string copy{str_with_len_N};/1024_stddev 4.59 ns 4.59 ns 4 +std::string copy{str_with_len_N};/1024_cv 2.94 % 2.94 % 4 +std::string copy{str_with_len_N};/2048_mean 206 ns 206 ns 4 +std::string copy{str_with_len_N};/2048_median 204 ns 204 ns 4 +std::string copy{str_with_len_N};/2048_stddev 24.0 ns 24.0 ns 4 +std::string copy{str_with_len_N};/2048_cv 11.64 % 11.64 % 4 +std::string copy{str_with_len_N};/4096_mean 271 ns 271 ns 4 +std::string copy{str_with_len_N};/4096_median 271 ns 271 ns 4 +std::string copy{str_with_len_N};/4096_stddev 4.00 ns 4.00 ns 4 +std::string copy{str_with_len_N};/4096_cv 1.48 % 1.48 % 4 +stringa copy{str_with_len_N};/15_mean 4.60 ns 4.60 ns 4 +stringa copy{str_with_len_N};/15_median 4.59 ns 4.59 ns 4 +stringa copy{str_with_len_N};/15_stddev 0.126 ns 0.126 ns 4 +stringa copy{str_with_len_N};/15_cv 2.73 % 2.73 % 4 +stringa copy{str_with_len_N};/16_mean 7.36 ns 7.36 ns 4 +stringa copy{str_with_len_N};/16_median 7.29 ns 7.29 ns 4 +stringa copy{str_with_len_N};/16_stddev 0.189 ns 0.189 ns 4 +stringa copy{str_with_len_N};/16_cv 2.57 % 2.57 % 4 +stringa copy{str_with_len_N};/23_mean 7.39 ns 7.39 ns 4 +stringa copy{str_with_len_N};/23_median 7.38 ns 7.38 ns 4 +stringa copy{str_with_len_N};/23_stddev 0.077 ns 0.077 ns 4 +stringa copy{str_with_len_N};/23_cv 1.04 % 1.04 % 4 +stringa copy{str_with_len_N};/24_mean 7.35 ns 7.35 ns 4 +stringa copy{str_with_len_N};/24_median 7.37 ns 7.37 ns 4 +stringa copy{str_with_len_N};/24_stddev 0.143 ns 0.143 ns 4 +stringa copy{str_with_len_N};/24_cv 1.94 % 1.94 % 4 +stringa copy{str_with_len_N};/32_mean 7.33 ns 7.33 ns 4 +stringa copy{str_with_len_N};/32_median 7.33 ns 7.33 ns 4 +stringa copy{str_with_len_N};/32_stddev 0.120 ns 0.120 ns 4 +stringa copy{str_with_len_N};/32_cv 1.64 % 1.64 % 4 +stringa copy{str_with_len_N};/64_mean 7.37 ns 7.37 ns 4 +stringa copy{str_with_len_N};/64_median 7.34 ns 7.34 ns 4 +stringa copy{str_with_len_N};/64_stddev 0.098 ns 0.098 ns 4 +stringa copy{str_with_len_N};/64_cv 1.33 % 1.34 % 4 +stringa copy{str_with_len_N};/128_mean 7.30 ns 7.30 ns 4 +stringa copy{str_with_len_N};/128_median 7.30 ns 7.30 ns 4 +stringa copy{str_with_len_N};/128_stddev 0.053 ns 0.053 ns 4 +stringa copy{str_with_len_N};/128_cv 0.73 % 0.73 % 4 +stringa copy{str_with_len_N};/256_mean 7.33 ns 7.33 ns 4 +stringa copy{str_with_len_N};/256_median 7.35 ns 7.35 ns 4 +stringa copy{str_with_len_N};/256_stddev 0.111 ns 0.111 ns 4 +stringa copy{str_with_len_N};/256_cv 1.52 % 1.52 % 4 +stringa copy{str_with_len_N};/512_mean 7.44 ns 7.44 ns 4 +stringa copy{str_with_len_N};/512_median 7.46 ns 7.46 ns 4 +stringa copy{str_with_len_N};/512_stddev 0.220 ns 0.220 ns 4 +stringa copy{str_with_len_N};/512_cv 2.96 % 2.96 % 4 +stringa copy{str_with_len_N};/1024_mean 7.35 ns 7.35 ns 4 +stringa copy{str_with_len_N};/1024_median 7.37 ns 7.37 ns 4 +stringa copy{str_with_len_N};/1024_stddev 0.098 ns 0.098 ns 4 +stringa copy{str_with_len_N};/1024_cv 1.33 % 1.33 % 4 +stringa copy{str_with_len_N};/2048_mean 7.33 ns 7.33 ns 4 +stringa copy{str_with_len_N};/2048_median 7.31 ns 7.31 ns 4 +stringa copy{str_with_len_N};/2048_stddev 0.131 ns 0.131 ns 4 +stringa copy{str_with_len_N};/2048_cv 1.79 % 1.79 % 4 +stringa copy{str_with_len_N};/4096_mean 7.36 ns 7.36 ns 4 +stringa copy{str_with_len_N};/4096_median 7.32 ns 7.32 ns 4 +stringa copy{str_with_len_N};/4096_stddev 0.103 ns 0.103 ns 4 +stringa copy{str_with_len_N};/4096_cv 1.41 % 1.41 % 4 +lstringa<16> copy{str_with_len_N};/15_mean 7.29 ns 7.29 ns 4 +lstringa<16> copy{str_with_len_N};/15_median 7.24 ns 7.24 ns 4 +lstringa<16> copy{str_with_len_N};/15_stddev 0.141 ns 0.141 ns 4 +lstringa<16> copy{str_with_len_N};/15_cv 1.93 % 1.93 % 4 +lstringa<16> copy{str_with_len_N};/16_mean 19.3 ns 19.3 ns 4 +lstringa<16> copy{str_with_len_N};/16_median 19.2 ns 19.2 ns 4 +lstringa<16> copy{str_with_len_N};/16_stddev 0.690 ns 0.690 ns 4 +lstringa<16> copy{str_with_len_N};/16_cv 3.57 % 3.57 % 4 +lstringa<16> copy{str_with_len_N};/23_mean 85.0 ns 85.0 ns 4 +lstringa<16> copy{str_with_len_N};/23_median 84.0 ns 84.0 ns 4 +lstringa<16> copy{str_with_len_N};/23_stddev 3.41 ns 3.41 ns 4 +lstringa<16> copy{str_with_len_N};/23_cv 4.02 % 4.02 % 4 +lstringa<16> copy{str_with_len_N};/24_mean 85.7 ns 85.7 ns 4 +lstringa<16> copy{str_with_len_N};/24_median 86.3 ns 86.3 ns 4 +lstringa<16> copy{str_with_len_N};/24_stddev 2.96 ns 2.96 ns 4 +lstringa<16> copy{str_with_len_N};/24_cv 3.46 % 3.46 % 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 92.8 ns 92.8 ns 4 +lstringa<16> copy{str_with_len_N};/32_stddev 2.24 ns 2.24 ns 4 +lstringa<16> copy{str_with_len_N};/32_cv 2.40 % 2.40 % 4 +lstringa<16> copy{str_with_len_N};/64_mean 92.8 ns 92.8 ns 4 +lstringa<16> copy{str_with_len_N};/64_median 91.9 ns 91.9 ns 4 +lstringa<16> copy{str_with_len_N};/64_stddev 5.61 ns 5.61 ns 4 +lstringa<16> copy{str_with_len_N};/64_cv 6.04 % 6.04 % 4 +lstringa<16> copy{str_with_len_N};/128_mean 95.0 ns 95.0 ns 4 +lstringa<16> copy{str_with_len_N};/128_median 93.7 ns 93.7 ns 4 +lstringa<16> copy{str_with_len_N};/128_stddev 5.33 ns 5.33 ns 4 +lstringa<16> copy{str_with_len_N};/128_cv 5.62 % 5.62 % 4 +lstringa<16> copy{str_with_len_N};/256_mean 126 ns 126 ns 4 +lstringa<16> copy{str_with_len_N};/256_median 115 ns 115 ns 4 +lstringa<16> copy{str_with_len_N};/256_stddev 25.4 ns 25.4 ns 4 +lstringa<16> copy{str_with_len_N};/256_cv 20.19 % 20.19 % 4 +lstringa<16> copy{str_with_len_N};/512_mean 119 ns 119 ns 4 +lstringa<16> copy{str_with_len_N};/512_median 120 ns 120 ns 4 +lstringa<16> copy{str_with_len_N};/512_stddev 3.20 ns 3.20 ns 4 +lstringa<16> copy{str_with_len_N};/512_cv 2.70 % 2.70 % 4 +lstringa<16> copy{str_with_len_N};/1024_mean 120 ns 120 ns 4 +lstringa<16> copy{str_with_len_N};/1024_median 119 ns 119 ns 4 +lstringa<16> copy{str_with_len_N};/1024_stddev 8.08 ns 8.08 ns 4 +lstringa<16> copy{str_with_len_N};/1024_cv 6.75 % 6.75 % 4 +lstringa<16> copy{str_with_len_N};/2048_mean 169 ns 169 ns 4 +lstringa<16> copy{str_with_len_N};/2048_median 170 ns 170 ns 4 +lstringa<16> copy{str_with_len_N};/2048_stddev 19.0 ns 19.0 ns 4 +lstringa<16> copy{str_with_len_N};/2048_cv 11.27 % 11.27 % 4 +lstringa<16> copy{str_with_len_N};/4096_mean 236 ns 236 ns 4 +lstringa<16> copy{str_with_len_N};/4096_median 237 ns 237 ns 4 +lstringa<16> copy{str_with_len_N};/4096_stddev 6.50 ns 6.50 ns 4 +lstringa<16> copy{str_with_len_N};/4096_cv 2.76 % 2.76 % 4 +lstringa<512> copy{str_with_len_N};/15_mean 7.25 ns 7.25 ns 4 +lstringa<512> copy{str_with_len_N};/15_median 7.23 ns 7.23 ns 4 +lstringa<512> copy{str_with_len_N};/15_stddev 0.070 ns 0.070 ns 4 +lstringa<512> copy{str_with_len_N};/15_cv 0.97 % 0.97 % 4 +lstringa<512> copy{str_with_len_N};/16_mean 19.5 ns 19.5 ns 4 +lstringa<512> copy{str_with_len_N};/16_median 19.6 ns 19.6 ns 4 +lstringa<512> copy{str_with_len_N};/16_stddev 0.229 ns 0.229 ns 4 +lstringa<512> copy{str_with_len_N};/16_cv 1.17 % 1.17 % 4 +lstringa<512> copy{str_with_len_N};/23_mean 19.9 ns 19.9 ns 4 +lstringa<512> copy{str_with_len_N};/23_median 19.8 ns 19.8 ns 4 +lstringa<512> copy{str_with_len_N};/23_stddev 0.583 ns 0.583 ns 4 +lstringa<512> copy{str_with_len_N};/23_cv 2.92 % 2.92 % 4 +lstringa<512> copy{str_with_len_N};/24_mean 19.4 ns 19.4 ns 4 +lstringa<512> copy{str_with_len_N};/24_median 19.5 ns 19.5 ns 4 +lstringa<512> copy{str_with_len_N};/24_stddev 0.655 ns 0.655 ns 4 +lstringa<512> copy{str_with_len_N};/24_cv 3.38 % 3.38 % 4 +lstringa<512> copy{str_with_len_N};/32_mean 22.7 ns 22.7 ns 4 +lstringa<512> copy{str_with_len_N};/32_median 22.4 ns 22.4 ns 4 +lstringa<512> copy{str_with_len_N};/32_stddev 1.59 ns 1.59 ns 4 +lstringa<512> copy{str_with_len_N};/32_cv 7.01 % 7.01 % 4 +lstringa<512> copy{str_with_len_N};/64_mean 22.4 ns 22.4 ns 4 +lstringa<512> copy{str_with_len_N};/64_median 22.4 ns 22.4 ns 4 +lstringa<512> copy{str_with_len_N};/64_stddev 0.583 ns 0.583 ns 4 +lstringa<512> copy{str_with_len_N};/64_cv 2.60 % 2.60 % 4 +lstringa<512> copy{str_with_len_N};/128_mean 23.6 ns 23.6 ns 4 +lstringa<512> copy{str_with_len_N};/128_median 23.8 ns 23.8 ns 4 +lstringa<512> copy{str_with_len_N};/128_stddev 1.36 ns 1.36 ns 4 +lstringa<512> copy{str_with_len_N};/128_cv 5.75 % 5.75 % 4 +lstringa<512> copy{str_with_len_N};/256_mean 24.8 ns 24.8 ns 4 +lstringa<512> copy{str_with_len_N};/256_median 24.8 ns 24.8 ns 4 +lstringa<512> copy{str_with_len_N};/256_stddev 0.346 ns 0.346 ns 4 +lstringa<512> copy{str_with_len_N};/256_cv 1.39 % 1.39 % 4 +lstringa<512> copy{str_with_len_N};/512_mean 28.3 ns 28.3 ns 4 +lstringa<512> copy{str_with_len_N};/512_median 28.2 ns 28.2 ns 4 +lstringa<512> copy{str_with_len_N};/512_stddev 0.566 ns 0.566 ns 4 +lstringa<512> copy{str_with_len_N};/512_cv 2.00 % 2.00 % 4 +lstringa<512> copy{str_with_len_N};/1024_mean 121 ns 121 ns 4 +lstringa<512> copy{str_with_len_N};/1024_median 121 ns 121 ns 4 +lstringa<512> copy{str_with_len_N};/1024_stddev 3.41 ns 3.41 ns 4 +lstringa<512> copy{str_with_len_N};/1024_cv 2.83 % 2.82 % 4 +lstringa<512> copy{str_with_len_N};/2048_mean 167 ns 167 ns 4 +lstringa<512> copy{str_with_len_N};/2048_median 167 ns 167 ns 4 +lstringa<512> copy{str_with_len_N};/2048_stddev 24.6 ns 24.6 ns 4 +lstringa<512> copy{str_with_len_N};/2048_cv 14.70 % 14.70 % 4 +lstringa<512> copy{str_with_len_N};/4096_mean 237 ns 237 ns 4 +lstringa<512> copy{str_with_len_N};/4096_median 237 ns 237 ns 4 +lstringa<512> copy{str_with_len_N};/4096_stddev 5.27 ns 5.27 ns 4 +lstringa<512> copy{str_with_len_N};/4096_cv 2.23 % 2.23 % 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 93.0 ns 93.0 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 93.1 ns 93.1 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 1.93 ns 1.93 ns 4 -std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 2.07 % 2.07 % 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 26.7 ns 26.7 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 26.7 ns 26.7 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.606 ns 0.605 ns 4 -std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 2.27 % 2.27 % 4 -stringa s = "123456789"; int res = s.to_int_mean 19.1 ns 19.1 ns 4 -stringa s = "123456789"; int res = s.to_int_median 19.0 ns 19.0 ns 4 -stringa s = "123456789"; int res = s.to_int_stddev 0.300 ns 0.300 ns 4 -stringa s = "123456789"; int res = s.to_int_cv 1.57 % 1.57 % 4 -ssa s = "123456789"; int res = s.to_int_mean 18.6 ns 18.6 ns 4 -ssa s = "123456789"; int res = s.to_int_median 18.6 ns 18.6 ns 4 -ssa s = "123456789"; int res = s.to_int_stddev 0.129 ns 0.129 ns 4 -ssa s = "123456789"; int res = s.to_int_cv 0.69 % 0.69 % 4 -lstringa<20> s = "123456789"; int res = s.to_int_mean 18.9 ns 18.9 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_median 18.9 ns 18.9 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_stddev 0.237 ns 0.237 ns 4 -lstringa<20> s = "123456789"; int res = s.to_int_cv 1.26 % 1.26 % 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_mean 203 ns 203 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_median 201 ns 201 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_stddev 6.45 ns 6.45 ns 4 +std::string s = "123456789"; int res = std::strtol(s.c_str(), 0, 10);_cv 3.17 % 3.17 % 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_mean 2.18 ns 2.18 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_median 2.18 ns 2.18 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_stddev 0.016 ns 0.016 ns 4 +std::string_view s = "123456789"; std::from_chars(s.data(), s.data() + s.size(), res, 10);_cv 0.73 % 0.73 % 4 +stringa s = "123456789"; int res = s.to_int_mean 50.4 ns 50.4 ns 4 +stringa s = "123456789"; int res = s.to_int_median 50.8 ns 50.8 ns 4 +stringa s = "123456789"; int res = s.to_int_stddev 1.87 ns 1.88 ns 4 +stringa s = "123456789"; int res = s.to_int_cv 3.72 % 3.72 % 4 +ssa s = "123456789"; int res = s.to_int_mean 47.5 ns 47.5 ns 4 +ssa s = "123456789"; int res = s.to_int_median 47.7 ns 47.7 ns 4 +ssa s = "123456789"; int res = s.to_int_stddev 0.785 ns 0.785 ns 4 +ssa s = "123456789"; int res = s.to_int_cv 1.65 % 1.65 % 4 +lstringa<20> s = "123456789"; int res = s.to_int_mean 46.7 ns 46.7 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_median 46.5 ns 46.5 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_stddev 1.12 ns 1.12 ns 4 +lstringa<20> s = "123456789"; int res = s.to_int_cv 2.39 % 2.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 67.9 ns 67.9 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 68.0 ns 68.0 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 0.389 ns 0.389 ns 4 -std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 0.57 % 0.57 % 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 25.8 ns 25.8 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 25.5 ns 25.5 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.994 ns 0.994 ns 4 -std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 3.85 % 3.85 % 4 -stringa s = "abcDef"; int res = s.to_int_mean 19.2 ns 19.2 ns 4 -stringa s = "abcDef"; int res = s.to_int_median 19.2 ns 19.2 ns 4 -stringa s = "abcDef"; int res = s.to_int_stddev 0.447 ns 0.447 ns 4 -stringa s = "abcDef"; int res = s.to_int_cv 2.32 % 2.32 % 4 -ssa s = "abcDef"; int res = s.to_int_mean 19.0 ns 19.0 ns 4 -ssa s = "abcDef"; int res = s.to_int_median 19.1 ns 19.1 ns 4 -ssa s = "abcDef"; int res = s.to_int_stddev 0.119 ns 0.119 ns 4 -ssa s = "abcDef"; int res = s.to_int_cv 0.63 % 0.63 % 4 -lstringa<20> s = "abcDef"; int res = s.to_int_mean 19.6 ns 19.6 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_median 19.4 ns 19.4 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_stddev 0.765 ns 0.764 ns 4 -lstringa<20> s = "abcDef"; int res = s.to_int_cv 3.90 % 3.90 % 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_mean 151 ns 151 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_median 152 ns 152 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_stddev 7.30 ns 7.30 ns 4 +std::string s = "abcDef"; int res = std::strtol(s.c_str(), 0, 16);_cv 4.82 % 4.82 % 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_mean 53.9 ns 53.9 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_median 53.8 ns 53.8 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_stddev 0.397 ns 0.397 ns 4 +std::string_view s = "abcDef"; std::from_chars(s.data(), s.data() + s.size(), res, 16);_cv 0.74 % 0.74 % 4 +stringa s = "abcDef"; int res = s.to_int_mean 46.1 ns 46.1 ns 4 +stringa s = "abcDef"; int res = s.to_int_median 46.0 ns 46.0 ns 4 +stringa s = "abcDef"; int res = s.to_int_stddev 1.01 ns 1.01 ns 4 +stringa s = "abcDef"; int res = s.to_int_cv 2.19 % 2.19 % 4 +ssa s = "abcDef"; int res = s.to_int_mean 44.8 ns 44.8 ns 4 +ssa s = "abcDef"; int res = s.to_int_median 45.1 ns 45.1 ns 4 +ssa s = "abcDef"; int res = s.to_int_stddev 0.717 ns 0.717 ns 4 +ssa s = "abcDef"; int res = s.to_int_cv 1.60 % 1.60 % 4 +lstringa<20> s = "abcDef"; int res = s.to_int_mean 44.0 ns 44.0 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_median 44.0 ns 44.0 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_stddev 1.07 ns 1.07 ns 4 +lstringa<20> s = "abcDef"; int res = s.to_int_cv 2.44 % 2.44 % 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 98.4 ns 98.4 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 98.1 ns 98.1 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 2.62 ns 2.62 ns 4 -std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 2.66 % 2.66 % 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 24.4 ns 24.4 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 24.3 ns 24.3 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.634 ns 0.634 ns 4 -stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 2.60 % 2.60 % 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 19.3 ns 19.3 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 19.3 ns 19.3 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 0.184 ns 0.184 ns 4 -ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 0.95 % 0.95 % 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_mean 219 ns 219 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_median 218 ns 218 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_stddev 2.43 ns 2.43 ns 4 +std::string s = " 123456789"; int res = std::strtol(s.c_str(), 0, 0);_cv 1.11 % 1.11 % 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_mean 35.2 ns 35.2 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_median 35.0 ns 35.0 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_stddev 0.582 ns 0.582 ns 4 +stringa s = " 123456789"; int res = s.to_int; // Check overflow_cv 1.65 % 1.65 % 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_mean 44.3 ns 44.3 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_median 43.9 ns 43.9 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_stddev 1.16 ns 1.16 ns 4 +ssa s = " 123456789"; int res = s.to_int; // No check overflow_cv 2.62 % 2.62 % 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 308 ns 308 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 308 ns 308 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 2.38 ns 2.38 ns 4 -std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 0.77 % 0.77 % 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 109 ns 109 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 109 ns 109 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 0.843 ns 0.843 ns 4 -std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 0.77 % 0.77 % 4 -ssa s = "1234.567e10"; double res = *s.to_double()_mean 42.1 ns 42.1 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_median 42.2 ns 42.2 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_stddev 0.547 ns 0.547 ns 4 -ssa s = "1234.567e10"; double res = *s.to_double()_cv 1.30 % 1.30 % 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_mean 633 ns 633 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_median 633 ns 633 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_stddev 10.2 ns 10.2 ns 4 +std::string s = "1234.567e10"; double res = std::strtod(s.c_str(), nullptr);_cv 1.60 % 1.60 % 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_mean 279 ns 279 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_median 279 ns 279 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_stddev 5.10 ns 5.10 ns 4 +std::string_view s = "1234.567e10"; std::from_chars(s.data(), s.data() + s.size(), res);_cv 1.83 % 1.83 % 4 +ssa s = "1234.567e10"; double res = *s.to_double()_mean 91.4 ns 91.4 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_median 91.2 ns 91.2 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_stddev 1.57 ns 1.57 ns 4 +ssa s = "1234.567e10"; double res = *s.to_double()_cv 1.72 % 1.72 % 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 6617 ns 6617 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_median 6578 ns 6578 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 172 ns 172 ns 4 -std::stringstream str; ... str << "abbaabbaabbaabba";_cv 2.60 % 2.60 % 4 -std::string str; ... str += "abbaabbaabbaabba";_mean 775 ns 775 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_median 775 ns 775 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_stddev 1.89 ns 1.89 ns 4 -std::string str; ... str += "abbaabbaabbaabba";_cv 0.24 % 0.24 % 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 700 ns 700 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_median 697 ns 697 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 14.0 ns 14.0 ns 4 -lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 1.99 % 1.99 % 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 574 ns 574 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_median 575 ns 575 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 4.60 ns 4.60 ns 4 -lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 0.80 % 0.80 % 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 519 ns 519 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_median 519 ns 519 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 4.50 ns 4.50 ns 4 -lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 0.87 % 0.87 % 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 420 ns 420 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 420 ns 420 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 6.73 ns 6.73 ns 4 -lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 1.60 % 1.60 % 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_mean 15882 ns 15882 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_median 16083 ns 16084 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_stddev 600 ns 600 ns 4 +std::stringstream str; ... str << "abbaabbaabbaabba";_cv 3.78 % 3.78 % 4 +std::string str; ... str += "abbaabbaabbaabba";_mean 1402 ns 1402 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_median 1395 ns 1395 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_stddev 30.0 ns 30.0 ns 4 +std::string str; ... str += "abbaabbaabbaabba";_cv 2.14 % 2.14 % 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_mean 1320 ns 1320 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_median 1307 ns 1307 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_stddev 35.8 ns 35.8 ns 4 +lstringa<8> str; ... str += "abbaabbaabbaabba";_cv 2.71 % 2.71 % 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_mean 889 ns 889 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_median 880 ns 880 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_stddev 23.0 ns 23.0 ns 4 +lstringa<128> str; ... str += "abbaabbaabbaabba";_cv 2.59 % 2.59 % 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_mean 624 ns 624 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_median 623 ns 623 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_stddev 19.9 ns 19.9 ns 4 +lstringa<512> str; ... str += "abbaabbaabbaabba";_cv 3.19 % 3.19 % 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_mean 497 ns 497 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_median 498 ns 498 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_stddev 6.34 ns 6.35 ns 4 +lstringa<1024> str; ... str += "abbaabbaabbaabba";_cv 1.28 % 1.28 % 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 7050 ns 7050 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 7065 ns 7065 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 86.9 ns 86.9 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 1.23 % 1.23 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 2182 ns 2182 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_median 2183 ns 2183 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 20.2 ns 20.2 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 0.92 % 0.92 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 978 ns 978 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 986 ns 986 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 21.9 ns 21.9 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.24 % 2.24 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 838 ns 838 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 840 ns 840 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 22.4 ns 22.4 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.68 % 2.68 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 735 ns 735 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 731 ns 731 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 21.7 ns 21.7 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.95 % 2.95 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 663 ns 663 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 665 ns 665 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 9.71 ns 9.71 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.46 % 1.46 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_mean 16035 ns 16035 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_median 15924 ns 15924 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_stddev 385 ns 385 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba";_cv 2.40 % 2.40 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_mean 4646 ns 4646 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_median 4654 ns 4654 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_stddev 172 ns 172 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba";_cv 3.71 % 3.71 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_mean 1514 ns 1514 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_median 1504 ns 1504 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_stddev 41.0 ns 41.0 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba";_cv 2.71 % 2.71 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_mean 1209 ns 1209 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_median 1215 ns 1215 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_stddev 22.8 ns 22.8 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba";_cv 1.88 % 1.88 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_mean 986 ns 986 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_median 978 ns 978 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_stddev 60.1 ns 60.1 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba";_cv 6.09 % 6.09 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_mean 827 ns 827 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_median 820 ns 820 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_stddev 27.2 ns 27.2 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba";_cv 3.29 % 3.29 % 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 346232 ns 346235 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 350597 ns 350600 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 11487 ns 11488 ns 4 -std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 3.32 % 3.32 % 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 119182 ns 119182 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 119674 ns 119675 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1204 ns 1203 ns 4 -std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.01 % 1.01 % 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 50289 ns 50289 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 50125 ns 50125 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 992 ns 992 ns 4 -lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.97 % 1.97 % 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 47056 ns 47057 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 47163 ns 47163 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1168 ns 1168 ns 4 -lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.48 % 2.48 % 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 47969 ns 47970 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 48021 ns 48022 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1624 ns 1624 ns 4 -lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.38 % 3.38 % 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 47909 ns 47910 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 47769 ns 47769 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 882 ns 882 ns 4 -lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 1.84 % 1.84 % 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_mean 821457 ns 821463 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_median 829913 ns 829919 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_stddev 17805 ns 17805 ns 4 +std::stringstream str; ... str << str_var << "abbaabbaabbaabba"; 2048 times_cv 2.17 % 2.17 % 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 238655 ns 238657 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 236241 ns 236241 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 5974 ns 5974 ns 4 +std::string str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.50 % 2.50 % 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 58092 ns 58093 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 57987 ns 57988 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1647 ns 1647 ns 4 +lstringa<8> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.83 % 2.83 % 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 56704 ns 56704 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 56621 ns 56621 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 2166 ns 2166 ns 4 +lstringa<128> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 3.82 % 3.82 % 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 55779 ns 55779 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 55479 ns 55479 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 1155 ns 1154 ns 4 +lstringa<512> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 2.07 % 2.07 % 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_mean 56710 ns 56710 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_median 56268 ns 56268 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_stddev 2816 ns 2816 ns 4 +lstringa<1024> str; ... str += str_var + "abbaabbaabbaabba"; 2048 times_cv 4.97 % 4.96 % 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 7139 ns 7139 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_median 7170 ns 7171 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_stddev 151 ns 151 ns 4 -std::stringstream str; ... str << str_var1 << str_var2;_cv 2.11 % 2.11 % 4 -std::string str; ... str += str_var1 + str_var2;_mean 2572 ns 2572 ns 4 -std::string str; ... str += str_var1 + str_var2;_median 2563 ns 2563 ns 4 -std::string str; ... str += str_var1 + str_var2;_stddev 58.0 ns 58.0 ns 4 -std::string str; ... str += str_var1 + str_var2;_cv 2.26 % 2.26 % 4 -lstringa<16> str; ... str += str_var1 + str_var2;_mean 1204 ns 1204 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_median 1202 ns 1202 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_stddev 54.0 ns 54.0 ns 4 -lstringa<16> str; ... str += str_var1 + str_var2;_cv 4.48 % 4.48 % 4 -lstringa<128> str; ... str += str_var1 + str_var2;_mean 1079 ns 1079 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_median 1076 ns 1076 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_stddev 16.2 ns 16.2 ns 4 -lstringa<128> str; ... str += str_var1 + str_var2;_cv 1.50 % 1.50 % 4 -lstringa<512> str; ... str += str_var1 + str_var2;_mean 993 ns 993 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_median 995 ns 995 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_stddev 43.9 ns 43.9 ns 4 -lstringa<512> str; ... str += str_var1 + str_var2;_cv 4.42 % 4.42 % 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_mean 947 ns 947 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_median 955 ns 955 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 25.9 ns 25.9 ns 4 -lstringa<1024> str; ... str += str_var1 + str_var2;_cv 2.73 % 2.73 % 4 +std::stringstream str; ... str << str_var1 << str_var2;_mean 16125 ns 16126 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_median 16192 ns 16192 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_stddev 164 ns 164 ns 4 +std::stringstream str; ... str << str_var1 << str_var2;_cv 1.02 % 1.02 % 4 +std::string str; ... str += str_var1 + str_var2;_mean 5089 ns 5089 ns 4 +std::string str; ... str += str_var1 + str_var2;_median 5084 ns 5084 ns 4 +std::string str; ... str += str_var1 + str_var2;_stddev 439 ns 439 ns 4 +std::string str; ... str += str_var1 + str_var2;_cv 8.62 % 8.62 % 4 +lstringa<16> str; ... str += str_var1 + str_var2;_mean 1846 ns 1846 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_median 1829 ns 1829 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_stddev 104 ns 104 ns 4 +lstringa<16> str; ... str += str_var1 + str_var2;_cv 5.64 % 5.64 % 4 +lstringa<128> str; ... str += str_var1 + str_var2;_mean 1663 ns 1663 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_median 1672 ns 1672 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_stddev 82.2 ns 82.2 ns 4 +lstringa<128> str; ... str += str_var1 + str_var2;_cv 4.94 % 4.94 % 4 +lstringa<512> str; ... str += str_var1 + str_var2;_mean 1291 ns 1291 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_median 1283 ns 1283 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_stddev 76.0 ns 76.0 ns 4 +lstringa<512> str; ... str += str_var1 + str_var2;_cv 5.89 % 5.89 % 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_mean 1066 ns 1066 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_median 1048 ns 1048 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_stddev 96.3 ns 96.3 ns 4 +lstringa<1024> str; ... str += str_var1 + str_var2;_cv 9.03 % 9.03 % 4 -- Append text, number, text --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::stringstream str; str << "test = " << k << " times";_mean 11745 ns 11746 ns 4 -std::stringstream str; str << "test = " << k << " times";_median 11646 ns 11646 ns 4 -std::stringstream str; str << "test = " << k << " times";_stddev 368 ns 368 ns 4 -std::stringstream str; str << "test = " << k << " times";_cv 3.13 % 3.13 % 4 -std::string str = "test = " + std::to_string(k) + " times";_mean 1627 ns 1627 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_median 1625 ns 1625 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_stddev 23.3 ns 23.3 ns 4 -std::string str = "test = " + std::to_string(k) + " times";_cv 1.43 % 1.43 % 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 5392 ns 5392 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 5390 ns 5390 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 55.3 ns 55.2 ns 4 -char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 1.02 % 1.02 % 4 -std::string str = std::format("test = {} times", k);_mean 2823 ns 2823 ns 4 -std::string str = std::format("test = {} times", k);_median 2818 ns 2818 ns 4 -std::string str = std::format("test = {} times", k);_stddev 69.6 ns 69.6 ns 4 -std::string str = std::format("test = {} times", k);_cv 2.47 % 2.47 % 4 -lstringa<8> str; str.format("test = {} times", k);_mean 4756 ns 4756 ns 4 -lstringa<8> str; str.format("test = {} times", k);_median 4775 ns 4775 ns 4 -lstringa<8> str; str.format("test = {} times", k);_stddev 83.2 ns 83.2 ns 4 -lstringa<8> str; str.format("test = {} times", k);_cv 1.75 % 1.75 % 4 -lstringa<32> str; str.format("test = {} times", k);_mean 4212 ns 4212 ns 4 -lstringa<32> str; str.format("test = {} times", k);_median 4254 ns 4254 ns 4 -lstringa<32> str; str.format("test = {} times", k);_stddev 125 ns 125 ns 4 -lstringa<32> str; str.format("test = {} times", k);_cv 2.98 % 2.98 % 4 -lstringa<8> str = "test = " + k + " times";_mean 565 ns 565 ns 4 -lstringa<8> str = "test = " + k + " times";_median 564 ns 564 ns 4 -lstringa<8> str = "test = " + k + " times";_stddev 5.85 ns 5.85 ns 4 -lstringa<8> str = "test = " + k + " times";_cv 1.04 % 1.04 % 4 -lstringa<32> str = "test = " + k + " times";_mean 338 ns 338 ns 4 -lstringa<32> str = "test = " + k + " times";_median 340 ns 340 ns 4 -lstringa<32> str = "test = " + k + " times";_stddev 9.71 ns 9.71 ns 4 -lstringa<32> str = "test = " + k + " times";_cv 2.87 % 2.87 % 4 -stringa str = "test = " + k + " times";_mean 564 ns 564 ns 4 -stringa str = "test = " + k + " times";_median 561 ns 561 ns 4 -stringa str = "test = " + k + " times";_stddev 16.3 ns 16.3 ns 4 -stringa str = "test = " + k + " times";_cv 2.89 % 2.89 % 4 +std::stringstream str; str << "test = " << k << " times";_mean 25591 ns 25592 ns 4 +std::stringstream str; str << "test = " << k << " times";_median 25197 ns 25198 ns 4 +std::stringstream str; str << "test = " << k << " times";_stddev 1652 ns 1652 ns 4 +std::stringstream str; str << "test = " << k << " times";_cv 6.46 % 6.46 % 4 +std::string str = "test = " + std::to_string(k) + " times";_mean 3456 ns 3456 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_median 3414 ns 3414 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_stddev 106 ns 106 ns 4 +std::string str = "test = " + std::to_string(k) + " times";_cv 3.06 % 3.06 % 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_mean 10939 ns 10939 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_median 10966 ns 10966 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_stddev 107 ns 107 ns 4 +char buf[100]; sprintf(buf, "test = %u times", k); std::string str = buf;_cv 0.97 % 0.97 % 4 +std::string str = std::format("test = {} times", k);_mean 5707 ns 5707 ns 4 +std::string str = std::format("test = {} times", k);_median 5689 ns 5689 ns 4 +std::string str = std::format("test = {} times", k);_stddev 156 ns 156 ns 4 +std::string str = std::format("test = {} times", k);_cv 2.73 % 2.73 % 4 +lstringa<8> str; str.format("test = {} times", k);_mean 8601 ns 8601 ns 4 +lstringa<8> str; str.format("test = {} times", k);_median 8627 ns 8627 ns 4 +lstringa<8> str; str.format("test = {} times", k);_stddev 264 ns 264 ns 4 +lstringa<8> str; str.format("test = {} times", k);_cv 3.07 % 3.07 % 4 +lstringa<32> str; str.format("test = {} times", k);_mean 7339 ns 7340 ns 4 +lstringa<32> str; str.format("test = {} times", k);_median 7368 ns 7368 ns 4 +lstringa<32> str; str.format("test = {} times", k);_stddev 237 ns 237 ns 4 +lstringa<32> str; str.format("test = {} times", k);_cv 3.23 % 3.23 % 4 +lstringa<8> str = "test = " + k + " times";_mean 1332 ns 1332 ns 4 +lstringa<8> str = "test = " + k + " times";_median 1331 ns 1331 ns 4 +lstringa<8> str = "test = " + k + " times";_stddev 65.3 ns 65.3 ns 4 +lstringa<8> str = "test = " + k + " times";_cv 4.90 % 4.90 % 4 +lstringa<32> str = "test = " + k + " times";_mean 570 ns 570 ns 4 +lstringa<32> str = "test = " + k + " times";_median 570 ns 570 ns 4 +lstringa<32> str = "test = " + k + " times";_stddev 7.02 ns 7.02 ns 4 +lstringa<32> str = "test = " + k + " times";_cv 1.23 % 1.23 % 4 +stringa str = "test = " + k + " times";_mean 1253 ns 1253 ns 4 +stringa str = "test = " + k + " times";_median 1253 ns 1253 ns 4 +stringa str = "test = " + k + " times";_stddev 21.4 ns 21.4 ns 4 +stringa str = "test = " + k + " times";_cv 1.71 % 1.71 % 4 -- Split text and convert to int --/repeats:1 0.000 ns 0.000 ns 1000000000000 -std::string::find + substr + std::strtol_mean 693 ns 693 ns 4 -std::string::find + substr + std::strtol_median 702 ns 702 ns 4 -std::string::find + substr + std::strtol_stddev 31.3 ns 31.3 ns 4 -std::string::find + substr + std::strtol_cv 4.51 % 4.51 % 4 -ssa::splitter + ssa::as_int_mean 250 ns 250 ns 4 -ssa::splitter + ssa::as_int_median 250 ns 250 ns 4 -ssa::splitter + ssa::as_int_stddev 1.11 ns 1.11 ns 4 -ssa::splitter + ssa::as_int_cv 0.45 % 0.45 % 4 -ssa::splitf + functor_mean 277 ns 277 ns 4 -ssa::splitf + functor_median 276 ns 276 ns 4 -ssa::splitf + functor_stddev 7.87 ns 7.87 ns 4 -ssa::splitf + functor_cv 2.85 % 2.85 % 4 +std::string::find + substr + std::strtol_mean 1483 ns 1483 ns 4 +std::string::find + substr + std::strtol_median 1489 ns 1489 ns 4 +std::string::find + substr + std::strtol_stddev 32.2 ns 32.2 ns 4 +std::string::find + substr + std::strtol_cv 2.17 % 2.17 % 4 +ssa::splitter + ssa::as_int_mean 587 ns 587 ns 4 +ssa::splitter + ssa::as_int_median 587 ns 587 ns 4 +ssa::splitter + ssa::as_int_stddev 9.68 ns 9.68 ns 4 +ssa::splitter + ssa::as_int_cv 1.65 % 1.65 % 4 +ssa::splitf + functor_mean 840 ns 840 ns 4 +ssa::splitf + functor_median 836 ns 836 ns 4 +ssa::splitf + functor_stddev 23.6 ns 23.6 ns 4 +ssa::splitf + functor_cv 2.81 % 2.81 % 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 3150 ns 3150 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_median 3130 ns 3130 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_stddev 105 ns 105 ns 4 -Naive (and wrong) replace symbols with std::string find + replace_cv 3.32 % 3.32 % 4 -replace symbols with std::string find_first_of + replace_mean 4982 ns 4982 ns 4 -replace symbols with std::string find_first_of + replace_median 4969 ns 4969 ns 4 -replace symbols with std::string find_first_of + replace_stddev 233 ns 233 ns 4 -replace symbols with std::string find_first_of + replace_cv 4.68 % 4.68 % 4 -replace symbols with std::string_view find_first_of + copy_mean 3246 ns 3246 ns 4 -replace symbols with std::string_view find_first_of + copy_median 3268 ns 3268 ns 4 -replace symbols with std::string_view find_first_of + copy_stddev 93.9 ns 93.9 ns 4 -replace symbols with std::string_view find_first_of + copy_cv 2.89 % 2.89 % 4 -replace runtime symbols with string expressions and without remembering all search results_mean 3117 ns 3117 ns 4 -replace runtime symbols with string expressions and without remembering all search results_median 3133 ns 3133 ns 4 -replace runtime symbols with string expressions and without remembering all search results_stddev 84.7 ns 84.7 ns 4 -replace runtime symbols with string expressions and without remembering all search results_cv 2.72 % 2.72 % 4 -replace runtime symbols with simstr and memorization of all search results_mean 2534 ns 2534 ns 4 -replace runtime symbols with simstr and memorization of all search results_median 2535 ns 2535 ns 4 -replace runtime symbols with simstr and memorization of all search results_stddev 24.1 ns 24.1 ns 4 -replace runtime symbols with simstr and memorization of all search results_cv 0.95 % 0.95 % 4 -replace const symbols with string expressions and without remembering all search results_mean 2608 ns 2608 ns 4 -replace const symbols with string expressions and without remembering all search results_median 2623 ns 2623 ns 4 -replace const symbols with string expressions and without remembering all search results_stddev 63.1 ns 63.1 ns 4 -replace const symbols with string expressions and without remembering all search results_cv 2.42 % 2.42 % 4 -replace const symbols with string expressions and memorization of all search results_mean 2259 ns 2259 ns 4 -replace const symbols with string expressions and memorization of all search results_median 2260 ns 2260 ns 4 -replace const symbols with string expressions and memorization of all search results_stddev 66.3 ns 66.3 ns 4 -replace const symbols with string expressions and memorization of all search results_cv 2.94 % 2.93 % 4 +Naive (and wrong) replace symbols with std::string find + replace_mean 4781 ns 4781 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_median 4755 ns 4755 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_stddev 102 ns 102 ns 4 +Naive (and wrong) replace symbols with std::string find + replace_cv 2.13 % 2.14 % 4 +replace symbols with std::string find_first_of + replace_mean 8914 ns 8914 ns 4 +replace symbols with std::string find_first_of + replace_median 8917 ns 8917 ns 4 +replace symbols with std::string find_first_of + replace_stddev 158 ns 158 ns 4 +replace symbols with std::string find_first_of + replace_cv 1.77 % 1.77 % 4 +replace symbols with std::string_view find_first_of + copy_mean 4601 ns 4601 ns 4 +replace symbols with std::string_view find_first_of + copy_median 4616 ns 4616 ns 4 +replace symbols with std::string_view find_first_of + copy_stddev 49.8 ns 49.7 ns 4 +replace symbols with std::string_view find_first_of + copy_cv 1.08 % 1.08 % 4 +replace runtime symbols with string expressions and without remembering all search results_mean 4270 ns 4270 ns 4 +replace runtime symbols with string expressions and without remembering all search results_median 4316 ns 4316 ns 4 +replace runtime symbols with string expressions and without remembering all search results_stddev 95.6 ns 95.6 ns 4 +replace runtime symbols with string expressions and without remembering all search results_cv 2.24 % 2.24 % 4 +replace runtime symbols with simstr and memorization of all search results_mean 3830 ns 3830 ns 4 +replace runtime symbols with simstr and memorization of all search results_median 3772 ns 3772 ns 4 +replace runtime symbols with simstr and memorization of all search results_stddev 168 ns 168 ns 4 +replace runtime symbols with simstr and memorization of all search results_cv 4.38 % 4.38 % 4 +replace const symbols with string expressions and without remembering all search results_mean 3372 ns 3372 ns 4 +replace const symbols with string expressions and without remembering all search results_median 3368 ns 3368 ns 4 +replace const symbols with string expressions and without remembering all search results_stddev 19.2 ns 19.2 ns 4 +replace const symbols with string expressions and without remembering all search results_cv 0.57 % 0.57 % 4 +replace const symbols with string expressions and memorization of all search results_mean 2905 ns 2905 ns 4 +replace const symbols with string expressions and memorization of all search results_median 2900 ns 2900 ns 4 +replace const symbols with string expressions and memorization of all search results_stddev 59.6 ns 59.6 ns 4 +replace const symbols with string expressions and memorization of all search results_cv 2.05 % 2.05 % 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 449 ns 449 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_median 455 ns 455 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_stddev 13.0 ns 13.0 ns 4 -Short Naive (and wrong) replace symbols with std::string find + replace_cv 2.89 % 2.89 % 4 -Short replace symbols with std::string find_first_of + replace_mean 628 ns 628 ns 4 -Short replace symbols with std::string find_first_of + replace_median 631 ns 631 ns 4 -Short replace symbols with std::string find_first_of + replace_stddev 10.1 ns 10.1 ns 4 -Short replace symbols with std::string find_first_of + replace_cv 1.62 % 1.62 % 4 -Short replace symbols with std::string_view find_first_of + copy_mean 474 ns 474 ns 4 -Short replace symbols with std::string_view find_first_of + copy_median 471 ns 471 ns 4 -Short replace symbols with std::string_view find_first_of + copy_stddev 24.3 ns 24.3 ns 4 -Short replace symbols with std::string_view find_first_of + copy_cv 5.14 % 5.14 % 4 -Short replace runtime symbols with string expressions and without remembering all search results_mean 376 ns 376 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_median 375 ns 375 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_stddev 6.81 ns 6.81 ns 4 -Short replace runtime symbols with string expressions and without remembering all search results_cv 1.81 % 1.81 % 4 -Short replace runtime symbols with simstr and memorization of all search results_mean 435 ns 435 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_median 437 ns 437 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_stddev 12.5 ns 12.5 ns 4 -Short replace runtime symbols with simstr and memorization of all search results_cv 2.88 % 2.88 % 4 -Short replace const symbols with string expressions and without remembering all search results_mean 285 ns 285 ns 4 -Short replace const symbols with string expressions and without remembering all search results_median 287 ns 287 ns 4 -Short replace const symbols with string expressions and without remembering all search results_stddev 8.98 ns 8.98 ns 4 -Short replace const symbols with string expressions and without remembering all search results_cv 3.15 % 3.15 % 4 -Short replace const symbols with string expressions and memorization of all search results_mean 312 ns 312 ns 4 -Short replace const symbols with string expressions and memorization of all search results_median 312 ns 312 ns 4 -Short replace const symbols with string expressions and memorization of all search results_stddev 5.70 ns 5.70 ns 4 -Short replace const symbols with string expressions and memorization of all search results_cv 1.82 % 1.82 % 4 +Short Naive (and wrong) replace symbols with std::string find + replace_mean 866 ns 866 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_median 864 ns 864 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_stddev 15.9 ns 15.9 ns 4 +Short Naive (and wrong) replace symbols with std::string find + replace_cv 1.83 % 1.83 % 4 +Short replace symbols with std::string find_first_of + replace_mean 1328 ns 1328 ns 4 +Short replace symbols with std::string find_first_of + replace_median 1326 ns 1326 ns 4 +Short replace symbols with std::string find_first_of + replace_stddev 22.7 ns 22.7 ns 4 +Short replace symbols with std::string find_first_of + replace_cv 1.71 % 1.71 % 4 +Short replace symbols with std::string_view find_first_of + copy_mean 797 ns 797 ns 4 +Short replace symbols with std::string_view find_first_of + copy_median 794 ns 794 ns 4 +Short replace symbols with std::string_view find_first_of + copy_stddev 11.7 ns 11.7 ns 4 +Short replace symbols with std::string_view find_first_of + copy_cv 1.47 % 1.47 % 4 +Short replace runtime symbols with string expressions and without remembering all search results_mean 656 ns 656 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_median 657 ns 657 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_stddev 5.26 ns 5.26 ns 4 +Short replace runtime symbols with string expressions and without remembering all search results_cv 0.80 % 0.80 % 4 +Short replace runtime symbols with simstr and memorization of all search results_mean 831 ns 831 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_median 816 ns 816 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_stddev 42.4 ns 42.4 ns 4 +Short replace runtime symbols with simstr and memorization of all search results_cv 5.10 % 5.10 % 4 +Short replace const symbols with string expressions and without remembering all search results_mean 438 ns 438 ns 4 +Short replace const symbols with string expressions and without remembering all search results_median 440 ns 440 ns 4 +Short replace const symbols with string expressions and without remembering all search results_stddev 14.2 ns 14.2 ns 4 +Short replace const symbols with string expressions and without remembering all search results_cv 3.24 % 3.24 % 4 +Short replace const symbols with string expressions and memorization of all search results_mean 553 ns 553 ns 4 +Short replace const symbols with string expressions and memorization of all search results_median 544 ns 544 ns 4 +Short replace const symbols with string expressions and memorization of all search results_stddev 21.3 ns 21.3 ns 4 +Short replace const symbols with string expressions and memorization of all search results_cv 3.85 % 3.85 % 4 ----- Replace All Str To Longer Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to ---- in std::string|64_mean 422 ns 422 ns 4 -replace bb to ---- in std::string|64_median 420 ns 420 ns 4 -replace bb to ---- in std::string|64_stddev 13.0 ns 13.0 ns 4 -replace bb to ---- in std::string|64_cv 3.09 % 3.10 % 4 -replace bb to ---- in std::string|256_mean 1229 ns 1229 ns 4 -replace bb to ---- in std::string|256_median 1248 ns 1248 ns 4 -replace bb to ---- in std::string|256_stddev 43.1 ns 43.1 ns 4 -replace bb to ---- in std::string|256_cv 3.51 % 3.51 % 4 -replace bb to ---- in std::string|512_mean 2359 ns 2359 ns 4 -replace bb to ---- in std::string|512_median 2319 ns 2319 ns 4 -replace bb to ---- in std::string|512_stddev 101 ns 101 ns 4 -replace bb to ---- in std::string|512_cv 4.30 % 4.30 % 4 -replace bb to ---- in std::string|1024_mean 5079 ns 5079 ns 4 -replace bb to ---- in std::string|1024_median 5035 ns 5035 ns 4 -replace bb to ---- in std::string|1024_stddev 203 ns 203 ns 4 -replace bb to ---- in std::string|1024_cv 4.01 % 4.01 % 4 -replace bb to ---- in std::string|2048_mean 12214 ns 12214 ns 4 -replace bb to ---- in std::string|2048_median 12009 ns 12009 ns 4 -replace bb to ---- in std::string|2048_stddev 492 ns 492 ns 4 -replace bb to ---- in std::string|2048_cv 4.03 % 4.03 % 4 -replace bb to ---- in lstringa<8>|64_mean 311 ns 311 ns 4 -replace bb to ---- in lstringa<8>|64_median 310 ns 310 ns 4 -replace bb to ---- in lstringa<8>|64_stddev 1.61 ns 1.61 ns 4 -replace bb to ---- in lstringa<8>|64_cv 0.52 % 0.52 % 4 -replace bb to ---- in lstringa<8>|256_mean 964 ns 964 ns 4 -replace bb to ---- in lstringa<8>|256_median 957 ns 957 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 4.46 % 4.46 % 4 -replace bb to ---- in lstringa<8>|512_mean 1801 ns 1801 ns 4 -replace bb to ---- in lstringa<8>|512_median 1784 ns 1784 ns 4 -replace bb to ---- in lstringa<8>|512_stddev 75.1 ns 75.1 ns 4 +replace bb to ---- in std::string|64_mean 754 ns 754 ns 4 +replace bb to ---- in std::string|64_median 755 ns 755 ns 4 +replace bb to ---- in std::string|64_stddev 7.06 ns 7.06 ns 4 +replace bb to ---- in std::string|64_cv 0.94 % 0.94 % 4 +replace bb to ---- in std::string|256_mean 2292 ns 2292 ns 4 +replace bb to ---- in std::string|256_median 2278 ns 2278 ns 4 +replace bb to ---- in std::string|256_stddev 66.5 ns 66.5 ns 4 +replace bb to ---- in std::string|256_cv 2.90 % 2.90 % 4 +replace bb to ---- in std::string|512_mean 4359 ns 4359 ns 4 +replace bb to ---- in std::string|512_median 4347 ns 4347 ns 4 +replace bb to ---- in std::string|512_stddev 166 ns 166 ns 4 +replace bb to ---- in std::string|512_cv 3.80 % 3.81 % 4 +replace bb to ---- in std::string|1024_mean 8819 ns 8819 ns 4 +replace bb to ---- in std::string|1024_median 8770 ns 8770 ns 4 +replace bb to ---- in std::string|1024_stddev 327 ns 327 ns 4 +replace bb to ---- in std::string|1024_cv 3.70 % 3.70 % 4 +replace bb to ---- in std::string|2048_mean 18166 ns 18166 ns 4 +replace bb to ---- in std::string|2048_median 17790 ns 17790 ns 4 +replace bb to ---- in std::string|2048_stddev 846 ns 846 ns 4 +replace bb to ---- in std::string|2048_cv 4.66 % 4.66 % 4 +replace bb to ---- in lstringa<8>|64_mean 590 ns 590 ns 4 +replace bb to ---- in lstringa<8>|64_median 587 ns 587 ns 4 +replace bb to ---- in lstringa<8>|64_stddev 12.2 ns 12.2 ns 4 +replace bb to ---- in lstringa<8>|64_cv 2.08 % 2.08 % 4 +replace bb to ---- in lstringa<8>|256_mean 1916 ns 1916 ns 4 +replace bb to ---- in lstringa<8>|256_median 1929 ns 1929 ns 4 +replace bb to ---- in lstringa<8>|256_stddev 92.2 ns 92.2 ns 4 +replace bb to ---- in lstringa<8>|256_cv 4.81 % 4.81 % 4 +replace bb to ---- in lstringa<8>|512_mean 3332 ns 3332 ns 4 +replace bb to ---- in lstringa<8>|512_median 3278 ns 3278 ns 4 +replace bb to ---- in lstringa<8>|512_stddev 139 ns 139 ns 4 replace bb to ---- in lstringa<8>|512_cv 4.17 % 4.17 % 4 -replace bb to ---- in lstringa<8>|1024_mean 3329 ns 3329 ns 4 -replace bb to ---- in lstringa<8>|1024_median 3329 ns 3329 ns 4 -replace bb to ---- in lstringa<8>|1024_stddev 49.6 ns 49.6 ns 4 -replace bb to ---- in lstringa<8>|1024_cv 1.49 % 1.49 % 4 -replace bb to ---- in lstringa<8>|2048_mean 6478 ns 6478 ns 4 -replace bb to ---- in lstringa<8>|2048_median 6487 ns 6487 ns 4 -replace bb to ---- in lstringa<8>|2048_stddev 173 ns 173 ns 4 -replace bb to ---- in lstringa<8>|2048_cv 2.67 % 2.67 % 4 -replace bb to ---- by init stringa|64_mean 205 ns 205 ns 4 -replace bb to ---- by init stringa|64_median 205 ns 205 ns 4 -replace bb to ---- by init stringa|64_stddev 2.90 ns 2.90 ns 4 -replace bb to ---- by init stringa|64_cv 1.41 % 1.41 % 4 -replace bb to ---- by init stringa|256_mean 620 ns 620 ns 4 -replace bb to ---- by init stringa|256_median 617 ns 617 ns 4 -replace bb to ---- by init stringa|256_stddev 17.4 ns 17.4 ns 4 -replace bb to ---- by init stringa|256_cv 2.81 % 2.81 % 4 -replace bb to ---- by init stringa|512_mean 1395 ns 1395 ns 4 -replace bb to ---- by init stringa|512_median 1395 ns 1395 ns 4 -replace bb to ---- by init stringa|512_stddev 8.37 ns 8.37 ns 4 -replace bb to ---- by init stringa|512_cv 0.60 % 0.60 % 4 -replace bb to ---- by init stringa|1024_mean 2995 ns 2995 ns 4 -replace bb to ---- by init stringa|1024_median 2993 ns 2993 ns 4 -replace bb to ---- by init stringa|1024_stddev 137 ns 137 ns 4 -replace bb to ---- by init stringa|1024_cv 4.56 % 4.56 % 4 -replace bb to ---- by init stringa|2048_mean 5944 ns 5944 ns 4 -replace bb to ---- by init stringa|2048_median 5947 ns 5947 ns 4 -replace bb to ---- by init stringa|2048_stddev 53.7 ns 53.7 ns 4 -replace bb to ---- by init stringa|2048_cv 0.90 % 0.90 % 4 +replace bb to ---- in lstringa<8>|1024_mean 6057 ns 6057 ns 4 +replace bb to ---- in lstringa<8>|1024_median 6133 ns 6133 ns 4 +replace bb to ---- in lstringa<8>|1024_stddev 210 ns 210 ns 4 +replace bb to ---- in lstringa<8>|1024_cv 3.47 % 3.47 % 4 +replace bb to ---- in lstringa<8>|2048_mean 11959 ns 11959 ns 4 +replace bb to ---- in lstringa<8>|2048_median 11859 ns 11859 ns 4 +replace bb to ---- in lstringa<8>|2048_stddev 437 ns 437 ns 4 +replace bb to ---- in lstringa<8>|2048_cv 3.66 % 3.66 % 4 +replace bb to ---- by init stringa|64_mean 403 ns 403 ns 4 +replace bb to ---- by init stringa|64_median 393 ns 393 ns 4 +replace bb to ---- by init stringa|64_stddev 27.2 ns 27.2 ns 4 +replace bb to ---- by init stringa|64_cv 6.73 % 6.73 % 4 +replace bb to ---- by init stringa|256_mean 1149 ns 1149 ns 4 +replace bb to ---- by init stringa|256_median 1154 ns 1154 ns 4 +replace bb to ---- by init stringa|256_stddev 45.5 ns 45.5 ns 4 +replace bb to ---- by init stringa|256_cv 3.96 % 3.96 % 4 +replace bb to ---- by init stringa|512_mean 2695 ns 2695 ns 4 +replace bb to ---- by init stringa|512_median 2675 ns 2675 ns 4 +replace bb to ---- by init stringa|512_stddev 93.8 ns 93.8 ns 4 +replace bb to ---- by init stringa|512_cv 3.48 % 3.48 % 4 +replace bb to ---- by init stringa|1024_mean 5688 ns 5688 ns 4 +replace bb to ---- by init stringa|1024_median 5626 ns 5626 ns 4 +replace bb to ---- by init stringa|1024_stddev 207 ns 207 ns 4 +replace bb to ---- by init stringa|1024_cv 3.64 % 3.64 % 4 +replace bb to ---- by init stringa|2048_mean 11882 ns 11882 ns 4 +replace bb to ---- by init stringa|2048_median 11930 ns 11931 ns 4 +replace bb to ---- by init stringa|2048_stddev 180 ns 180 ns 4 +replace bb to ---- by init stringa|2048_cv 1.51 % 1.51 % 4 ----- Replace All Str To Same Size ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -replace bb to -- in std::string|64_mean 282 ns 282 ns 4 -replace bb to -- in std::string|64_median 279 ns 279 ns 4 -replace bb to -- in std::string|64_stddev 7.17 ns 7.17 ns 4 -replace bb to -- in std::string|64_cv 2.54 % 2.54 % 4 -replace bb to -- in std::string|256_mean 853 ns 853 ns 4 -replace bb to -- in std::string|256_median 853 ns 853 ns 4 -replace bb to -- in std::string|256_stddev 22.1 ns 22.1 ns 4 -replace bb to -- in std::string|256_cv 2.59 % 2.59 % 4 -replace bb to -- in std::string|512_mean 1670 ns 1670 ns 4 -replace bb to -- in std::string|512_median 1673 ns 1673 ns 4 -replace bb to -- in std::string|512_stddev 18.3 ns 18.3 ns 4 -replace bb to -- in std::string|512_cv 1.10 % 1.10 % 4 -replace bb to -- in std::string|1024_mean 3119 ns 3119 ns 4 -replace bb to -- in std::string|1024_median 3131 ns 3131 ns 4 -replace bb to -- in std::string|1024_stddev 58.4 ns 58.4 ns 4 -replace bb to -- in std::string|1024_cv 1.87 % 1.87 % 4 -replace bb to -- in std::string|2048_mean 6498 ns 6498 ns 4 -replace bb to -- in std::string|2048_median 6470 ns 6470 ns 4 -replace bb to -- in std::string|2048_stddev 89.6 ns 89.7 ns 4 -replace bb to -- in std::string|2048_cv 1.38 % 1.38 % 4 -replace bb to -- in lstringa<8>|64_mean 221 ns 221 ns 4 -replace bb to -- in lstringa<8>|64_median 220 ns 220 ns 4 -replace bb to -- in lstringa<8>|64_stddev 5.54 ns 5.53 ns 4 -replace bb to -- in lstringa<8>|64_cv 2.50 % 2.50 % 4 -replace bb to -- in lstringa<8>|256_mean 671 ns 671 ns 4 -replace bb to -- in lstringa<8>|256_median 670 ns 670 ns 4 -replace bb to -- in lstringa<8>|256_stddev 35.5 ns 35.5 ns 4 -replace bb to -- in lstringa<8>|256_cv 5.29 % 5.29 % 4 -replace bb to -- in lstringa<8>|512_mean 1237 ns 1237 ns 4 -replace bb to -- in lstringa<8>|512_median 1236 ns 1236 ns 4 -replace bb to -- in lstringa<8>|512_stddev 12.8 ns 12.8 ns 4 -replace bb to -- in lstringa<8>|512_cv 1.04 % 1.04 % 4 -replace bb to -- in lstringa<8>|1024_mean 2398 ns 2398 ns 4 -replace bb to -- in lstringa<8>|1024_median 2387 ns 2387 ns 4 -replace bb to -- in lstringa<8>|1024_stddev 52.8 ns 52.8 ns 4 -replace bb to -- in lstringa<8>|1024_cv 2.20 % 2.20 % 4 -replace bb to -- in lstringa<8>|2048_mean 4661 ns 4661 ns 4 -replace bb to -- in lstringa<8>|2048_median 4669 ns 4669 ns 4 -replace bb to -- in lstringa<8>|2048_stddev 40.2 ns 40.2 ns 4 -replace bb to -- in lstringa<8>|2048_cv 0.86 % 0.86 % 4 -replace bb to -- by init stringa|64_mean 171 ns 171 ns 4 -replace bb to -- by init stringa|64_median 170 ns 170 ns 4 -replace bb to -- by init stringa|64_stddev 4.59 ns 4.59 ns 4 -replace bb to -- by init stringa|64_cv 2.69 % 2.69 % 4 -replace bb to -- by init stringa|256_mean 528 ns 528 ns 4 -replace bb to -- by init stringa|256_median 531 ns 531 ns 4 -replace bb to -- by init stringa|256_stddev 17.2 ns 17.2 ns 4 -replace bb to -- by init stringa|256_cv 3.25 % 3.25 % 4 -replace bb to -- by init stringa|512_mean 881 ns 881 ns 4 -replace bb to -- by init stringa|512_median 886 ns 886 ns 4 -replace bb to -- by init stringa|512_stddev 27.2 ns 27.2 ns 4 -replace bb to -- by init stringa|512_cv 3.08 % 3.08 % 4 -replace bb to -- by init stringa|1024_mean 1721 ns 1721 ns 4 -replace bb to -- by init stringa|1024_median 1731 ns 1731 ns 4 -replace bb to -- by init stringa|1024_stddev 27.6 ns 27.6 ns 4 -replace bb to -- by init stringa|1024_cv 1.61 % 1.61 % 4 -replace bb to -- by init stringa|2048_mean 3318 ns 3318 ns 4 -replace bb to -- by init stringa|2048_median 3314 ns 3314 ns 4 -replace bb to -- by init stringa|2048_stddev 114 ns 114 ns 4 -replace bb to -- by init stringa|2048_cv 3.43 % 3.43 % 4 +replace bb to -- in std::string|64_mean 556 ns 556 ns 4 +replace bb to -- in std::string|64_median 554 ns 554 ns 4 +replace bb to -- in std::string|64_stddev 21.6 ns 21.6 ns 4 +replace bb to -- in std::string|64_cv 3.89 % 3.89 % 4 +replace bb to -- in std::string|256_mean 1773 ns 1773 ns 4 +replace bb to -- in std::string|256_median 1781 ns 1781 ns 4 +replace bb to -- in std::string|256_stddev 40.8 ns 40.7 ns 4 +replace bb to -- in std::string|256_cv 2.30 % 2.30 % 4 +replace bb to -- in std::string|512_mean 3125 ns 3125 ns 4 +replace bb to -- in std::string|512_median 3096 ns 3096 ns 4 +replace bb to -- in std::string|512_stddev 92.8 ns 92.8 ns 4 +replace bb to -- in std::string|512_cv 2.97 % 2.97 % 4 +replace bb to -- in std::string|1024_mean 6361 ns 6361 ns 4 +replace bb to -- in std::string|1024_median 6341 ns 6341 ns 4 +replace bb to -- in std::string|1024_stddev 135 ns 135 ns 4 +replace bb to -- in std::string|1024_cv 2.12 % 2.12 % 4 +replace bb to -- in std::string|2048_mean 11893 ns 11893 ns 4 +replace bb to -- in std::string|2048_median 11888 ns 11888 ns 4 +replace bb to -- in std::string|2048_stddev 513 ns 513 ns 4 +replace bb to -- in std::string|2048_cv 4.32 % 4.32 % 4 +replace bb to -- in lstringa<8>|64_mean 439 ns 439 ns 4 +replace bb to -- in lstringa<8>|64_median 440 ns 440 ns 4 +replace bb to -- in lstringa<8>|64_stddev 6.82 ns 6.82 ns 4 +replace bb to -- in lstringa<8>|64_cv 1.55 % 1.55 % 4 +replace bb to -- in lstringa<8>|256_mean 1355 ns 1355 ns 4 +replace bb to -- in lstringa<8>|256_median 1355 ns 1355 ns 4 +replace bb to -- in lstringa<8>|256_stddev 52.2 ns 52.2 ns 4 +replace bb to -- in lstringa<8>|256_cv 3.85 % 3.85 % 4 +replace bb to -- in lstringa<8>|512_mean 2540 ns 2540 ns 4 +replace bb to -- in lstringa<8>|512_median 2543 ns 2543 ns 4 +replace bb to -- in lstringa<8>|512_stddev 68.2 ns 68.2 ns 4 +replace bb to -- in lstringa<8>|512_cv 2.68 % 2.68 % 4 +replace bb to -- in lstringa<8>|1024_mean 4650 ns 4650 ns 4 +replace bb to -- in lstringa<8>|1024_median 4631 ns 4631 ns 4 +replace bb to -- in lstringa<8>|1024_stddev 185 ns 185 ns 4 +replace bb to -- in lstringa<8>|1024_cv 3.98 % 3.98 % 4 +replace bb to -- in lstringa<8>|2048_mean 9148 ns 9148 ns 4 +replace bb to -- in lstringa<8>|2048_median 9165 ns 9165 ns 4 +replace bb to -- in lstringa<8>|2048_stddev 267 ns 267 ns 4 +replace bb to -- in lstringa<8>|2048_cv 2.92 % 2.92 % 4 +replace bb to -- by init stringa|64_mean 309 ns 309 ns 4 +replace bb to -- by init stringa|64_median 313 ns 313 ns 4 +replace bb to -- by init stringa|64_stddev 9.28 ns 9.28 ns 4 +replace bb to -- by init stringa|64_cv 3.01 % 3.01 % 4 +replace bb to -- by init stringa|256_mean 967 ns 967 ns 4 +replace bb to -- by init stringa|256_median 975 ns 975 ns 4 +replace bb to -- by init stringa|256_stddev 39.3 ns 39.3 ns 4 +replace bb to -- by init stringa|256_cv 4.07 % 4.07 % 4 +replace bb to -- by init stringa|512_mean 1774 ns 1774 ns 4 +replace bb to -- by init stringa|512_median 1768 ns 1768 ns 4 +replace bb to -- by init stringa|512_stddev 66.1 ns 66.1 ns 4 +replace bb to -- by init stringa|512_cv 3.73 % 3.73 % 4 +replace bb to -- by init stringa|1024_mean 3375 ns 3375 ns 4 +replace bb to -- by init stringa|1024_median 3335 ns 3335 ns 4 +replace bb to -- by init stringa|1024_stddev 107 ns 107 ns 4 +replace bb to -- by init stringa|1024_cv 3.16 % 3.16 % 4 +replace bb to -- by init stringa|2048_mean 6646 ns 6646 ns 4 +replace bb to -- by init stringa|2048_median 6669 ns 6669 ns 4 +replace bb to -- by init stringa|2048_stddev 103 ns 103 ns 4 +replace bb to -- by init stringa|2048_cv 1.55 % 1.55 % 4 ----- Hash Map insert and find ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -hashStrMapA emplace & find stringa;_mean 3294169 ns 3294203 ns 4 -hashStrMapA emplace & find stringa;_median 3290069 ns 3290103 ns 4 -hashStrMapA emplace & find stringa;_stddev 52242 ns 52235 ns 4 -hashStrMapA emplace & find stringa;_cv 1.59 % 1.59 % 4 -std::unordered_map emplace & find std::string;_mean 3593372 ns 3593410 ns 4 -std::unordered_map emplace & find std::string;_median 3568808 ns 3568846 ns 4 -std::unordered_map emplace & find std::string;_stddev 58442 ns 58433 ns 4 -std::unordered_map emplace & find std::string;_cv 1.63 % 1.63 % 4 -hashStrMapA emplace & find ssa;_mean 3280453 ns 3280494 ns 4 -hashStrMapA emplace & find ssa;_median 3292058 ns 3292105 ns 4 -hashStrMapA emplace & find ssa;_stddev 31526 ns 31537 ns 4 -hashStrMapA emplace & find ssa;_cv 0.96 % 0.96 % 4 -std::unordered_map emplace & find std::string_view;_mean 3999371 ns 3999393 ns 4 -std::unordered_map emplace & find std::string_view;_median 3995266 ns 3995281 ns 4 -std::unordered_map emplace & find std::string_view;_stddev 94150 ns 94150 ns 4 -std::unordered_map emplace & find std::string_view;_cv 2.35 % 2.35 % 4 +hashStrMapA emplace & find stringa;_mean 5122075 ns 5122213 ns 4 +hashStrMapA emplace & find stringa;_median 5120675 ns 5120750 ns 4 +hashStrMapA emplace & find stringa;_stddev 26671 ns 26794 ns 4 +hashStrMapA emplace & find stringa;_cv 0.52 % 0.52 % 4 +std::unordered_map emplace & find std::string;_mean 6141653 ns 6141694 ns 4 +std::unordered_map emplace & find std::string;_median 6148781 ns 6148822 ns 4 +std::unordered_map emplace & find std::string;_stddev 171840 ns 171840 ns 4 +std::unordered_map emplace & find std::string;_cv 2.80 % 2.80 % 4 +hashStrMapA emplace & find ssa;_mean 5107848 ns 5107875 ns 4 +hashStrMapA emplace & find ssa;_median 5116589 ns 5116625 ns 4 +hashStrMapA emplace & find ssa;_stddev 55521 ns 55521 ns 4 +hashStrMapA emplace & find ssa;_cv 1.09 % 1.09 % 4 +std::unordered_map emplace & find std::string_view;_mean 7187813 ns 7187884 ns 4 +std::unordered_map emplace & find std::string_view;_median 7100597 ns 7100682 ns 4 +std::unordered_map emplace & find std::string_view;_stddev 230560 ns 230551 ns 4 +std::unordered_map emplace & find std::string_view;_cv 3.21 % 3.21 % 4 ----- Build Full Func Name ---------/repeats:1 0.000 ns 0.000 ns 1000000000000 -Build func full name std::string;_mean 3564 ns 3564 ns 4 -Build func full name std::string;_median 3521 ns 3521 ns 4 -Build func full name std::string;_stddev 114 ns 114 ns 4 -Build func full name std::string;_cv 3.20 % 3.20 % 4 -Build func full name std::string 1;_mean 3650 ns 3650 ns 4 -Build func full name std::string 1;_median 3618 ns 3618 ns 4 -Build func full name std::string 1;_stddev 205 ns 205 ns 4 -Build func full name std::string 1;_cv 5.63 % 5.63 % 4 -Build func full name std::stream;_mean 12092 ns 12092 ns 4 -Build func full name std::stream;_median 12016 ns 12016 ns 4 -Build func full name std::stream;_stddev 167 ns 167 ns 4 -Build func full name std::stream;_cv 1.38 % 1.38 % 4 -Build func full name stringa;_mean 1696 ns 1696 ns 4 -Build func full name stringa;_median 1696 ns 1696 ns 4 -Build func full name stringa;_stddev 54.0 ns 54.0 ns 4 -Build func full name stringa;_cv 3.19 % 3.19 % 4 -Build func full name stringa 1;_mean 2029 ns 2029 ns 4 -Build func full name stringa 1;_median 2049 ns 2049 ns 4 -Build func full name stringa 1;_stddev 114 ns 114 ns 4 -Build func full name stringa 1;_cv 5.62 % 5.62 % 4 +Build func full name std::string;_mean 5362 ns 5362 ns 4 +Build func full name std::string;_median 5343 ns 5343 ns 4 +Build func full name std::string;_stddev 105 ns 105 ns 4 +Build func full name std::string;_cv 1.96 % 1.96 % 4 +Build func full name std::string 1;_mean 6029 ns 6029 ns 4 +Build func full name std::string 1;_median 6037 ns 6037 ns 4 +Build func full name std::string 1;_stddev 34.7 ns 34.8 ns 4 +Build func full name std::string 1;_cv 0.58 % 0.58 % 4 +Build func full name std::stream;_mean 25412 ns 25413 ns 4 +Build func full name std::stream;_median 25270 ns 25270 ns 4 +Build func full name std::stream;_stddev 417 ns 417 ns 4 +Build func full name std::stream;_cv 1.64 % 1.64 % 4 +Build func full name stringa;_mean 2926 ns 2926 ns 4 +Build func full name stringa;_median 2930 ns 2930 ns 4 +Build func full name stringa;_stddev 42.6 ns 42.6 ns 4 +Build func full name stringa;_cv 1.46 % 1.45 % 4 +Build func full name stringa 1;_mean 3417 ns 3417 ns 4 +Build func full name stringa 1;_median 3459 ns 3459 ns 4 +Build func full name stringa 1;_stddev 108 ns 108 ns 4 +Build func full name stringa 1;_cv 3.16 % 3.16 % 4 diff --git a/tests/test_str.cpp b/tests/test_str.cpp index e1c56a3..a0cb95b 100644 --- a/tests/test_str.cpp +++ b/tests/test_str.cpp @@ -1328,9 +1328,9 @@ TEST(SimStr, LStrFormat) { } #else { - // char32_t в Windows совместим по размеру с wchar_t, поэтому для его форматирования можно использовать + // char32_t в Linux совместим по размеру с wchar_t, поэтому для его форматирования можно использовать // L"format_string", и передавать char32_t строковые объекты - // char32_t on Windows is compatible in size with wchar_t, so you can use L"format_string" to format it + // char32_t on Linux is compatible in size with wchar_t, so you can use L"format_string" to format it // and pass char32_t string objects lstringuu<2> text; text.format(L"{}{}", 'a', 'b'); @@ -2081,6 +2081,7 @@ TEST(SimStr, ConstEval) { #endif } // namespace simstr::tests + TEST(SimStr, StrNoNamespace) { std::string str = "test"; std::string test = +str + " = " + 10;