diff options
| author | John Lindgren <john.lindgren@aol.com> | 2015-08-29 15:06:00 -0400 |
|---|---|---|
| committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2016-05-24 10:39:00 +0000 |
| commit | 36aaf851ff2814e9e5c024e21b866c403137ff26 (patch) | |
| tree | 06bdeef6a9336638b22d5f4c057023e8ab7d4a73 /qmake/generators/unix/unixmake2.cpp | |
| parent | 1af802a9a62f7237800db17419e57c6f848ed00d (diff) | |
Optimize QIconLoader::findIconHelper()
Profiling QIconLoader::findIconHelper() shows that a significant portion of CPU time is being spent in
QDir::exists(), which creates a new QFileInfo object for the sole purpose of determining whether the passed-in
file path is relative or absolute, and then calls QFile::exists(). In this context, we can just as easily
generate the absolute path and call QFile::exists() directly, avoiding the creation of extra QDir and QFileInfo
objects.
Change-Id: Ib0b4568b6c16d423eb6c1b15158e44ff141e6175
Task-number: QTBUG-46767
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Diffstat (limited to 'qmake/generators/unix/unixmake2.cpp')
0 files changed, 0 insertions, 0 deletions
