summaryrefslogtreecommitdiffstats
path: root/header.LGPL3-COMM
diff options
context:
space:
mode:
authorDavid Faure <david.faure@kdab.com>2018-04-22 22:26:10 +0200
committerDavid Faure <david.faure@kdab.com>2018-04-23 06:48:12 +0000
commit46ec170d2be226c41b910a3709434e60c4310e6f (patch)
tree9be72b046de65b22d4e353abfddb5413a2d41a9b /header.LGPL3-COMM
parentc782ed3c48b31dc38b728947270df3fc3f3a7626 (diff)
Speed up QTimeZone::isTimeZoneIdAvailable by a factor 43
Creating and sorting a list of bytearrays just to check if one entry is present, is really overkill. By adding a new virtual method isTimeZoneIdAvailable() in the backend classes, we can do this much more efficiently. Implemented for Utc and Tz backends, the others fall back to the slow way. The new benchmark shows, in release mode: Before: 43 msecs per iteration (total: 86, iterations: 2) After: 1.1 msecs per iteration (total: 73, iterations: 64) Change-Id: Ic0d79a41d74e2ce6aa088fa7986c41d33902c36b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'header.LGPL3-COMM')
0 files changed, 0 insertions, 0 deletions