This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: on the speed of std::string::find


Dennis Lubert wrote:

http://www.projectiwear.org/~plasmahh/string_bench_both.png
This is an update on the benchmarks. Sorry, it looks a bit crowded, but
nevertheless shows the relevant numbers. The new three lines show how
the different algorithms scale when the length of the string to be
searched for gets longer. So the new one scales nearly equally well to
the memmem implementations in both regards, and I think that the patch
is a huge improvement. If you still need further tests, let me know
about the details that shall be tested.


I don't, really, and I don't know how to thank you! I'm thinking that probably we should keep in touch for further improvements, definitely delayed after the release of gcc4.2.0, because indeed, I think we can do quite a bit better than the 'memmem' algorithm without the need for large tables, high startup times, annoying issues of that kind. Ideally, I'm striving for something generic, however, not limited to GNU systems and calling in any case char_traits, thus not restricted to char / wchar_t specializations. We'll see...

Thanks a lot again,
Paolo.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]