lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi] any_member<Input>::str() slowness


From: Vadim Zeitlin
Subject: [lmi] any_member<Input>::str() slowness
Date: Thu, 11 Jun 2020 10:51:58 +0200

 Hello,

 I've almost finished my optimizations of column auto-sizing in the census
view: there is always more to do, but the time to do it for a census with
4000+ elements went down from ~2000ms to ~300ms and I think this should be
good enough for now, especially considering that the current, wxDVC-based,
version takes ~5500ms to do the same thing.

 However I'd like to mention one of the things which surprised me while I
was profiling this code (as usual with profiling, a lot of things surprised
me, but this was one of those that really stood out): any_member<>::str()
is really, really slow. How slow exactly depends on what you measure and
how you count, but roughly speaking this single function accounts for 30%
of the total time spent in column auto-sizing. I understand that this is
critical code and you are probably not terribly interested in making
changes to it (at least my previous attempt to optimize things in roughly
the same area in https://github.com/vadz/lmi/pull/114 never went anywhere),
but it still seems rather extraordinary that such simple operation consumes
so much time, and I think it would be worth looking into it and trying to
make it less inefficient.

 Again, I won't do it for now, all my optimizations to lmi code itself (as
opposed to those in wxGrid) are limited to census_view.cpp, but please let
me know if you think it would be worth doing it.

 Thanks in advance,
VZ

Attachment: pgpSDhJJA1u4d.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]