Sign up for the KDAB Newsletter
Stay on top of the latest news, publications, events and more.
Go to Sign-up
Hello, and welcome to the usual appointment with a new release of Qt!
Qt 5.7 has just been released, and once more, KDAB has been a huge part of it (we are shown in red on the graph):
Qt Project commit stats, up to June 2016. From http://www.macieira.org/blog/qt-stats/
In this blog post I will show some of the outstanding contributions by KDAB engineers to the 5.7 release.
The star of Qt 5.7 is the first stable release of Qt 3D 2.0. The new version of Qt 3D is a total redesign of its architecture into a modern and streamlined 3D engine, exploiting modern design patterns such as entity-component systems, and capable to scale due to the heavily threaded design. This important milestone was the result of a massive effort done by KDAB in coordination with The Qt Company.
If you want to know more about what Qt 3D can do for your application, you can watch this introductive webinar recorded by KDAB's Dr. Sean Harmer and Paul Lemire for the 5.7 release.
Thanks to KDAB's BogDan Vatra, this release of Qt saw many improvements to its Android support. In no particular order:
QtAndroid::hideSplashScreen
function, which allows a developer to programmatically hide the splash screen of their applications.A codebase as big as Qt needs constant fixes, improvements and bugfixes. Sometimes these come from bug reports, sometimes by reading code in order to understand it better, and in some other cases by analyzing the codebase using the latest tools available. KDAB is committed to keeping Qt in a great shape, and that is why KDAB engineers spend a lot of time polishing the Qt codebase.
Some of the results of these efforts are:
equal_range
, just like QMap and the other STL associative container. This function can be used to iterate on all the values of a (multi)hash that have the same key without performing any extra memory allocation. In other words, this code: // BAD!!! allocates a temporary QList // for holding the values corresponding to "key" foreach (const auto &value, hash.values(key)) { }can be changed to
const auto range = hash.equal_range(key); for (auto i = range.first; i != range.second; ++i) { }
which never throws (if hash
is const
), expands to less code and does not allocate memory.
memset
or memcpy
. KDAB's Senior Engineer Marc Mutz contributed many fixes to these undefined behaviours, fixes that made their way into Qt 5.6.1 and Qt 5.7.foreach
loops to ranged for loops. Ranged for loops expand to less code (because there is no implicit copy taking place), and since compilers recognize them as a syntactic structure, they can optimize them better. Over a thousand occurrences were changed, leading to savings in Qt both in terms of library size and runtime speed.QStack
usages with std::stack
led to 1KB of code saved per instance replaced; and introducing std::vector in central codepaths (such as the ones in QMetaObjectBuilder
) saved 4.5KB.QDirIterator
) uncompressed them. Then, reading a given resource via QFile
uncompressed it again. This was immediately fixed in this commit by KDAB's Director of Automotive, Volker Krause.Last but not least:
clang-cl
mkspec was added. This mkspec makes it possible to build Qt using the Clang frontend for MSVC. Stay tuned for more blog posts on this matter. :)QFlag::setFlag
method was added, to set or unset a flag in a bitmask without using bitwise operations.About KDAB
The KDAB Group is a globally recognized provider for software consulting, development and training, specializing in embedded devices and complex cross-platform desktop applications. In addition to being leading experts in Qt, C++ and 3D technologies for over two decades, KDAB provides deep expertise across the stack, including Linux, Rust and modern UI frameworks. With 100+ employees from 20 countries and offices in Sweden, Germany, USA, France and UK, we serve clients around the world.
2 Comments
24 - Jul - 2016
STiAT
A bit puzzled about the graph. You seem to have been there at initial feature input, missing out at the stabilization... which seems strange.
And I didn't know intel is contributing there... don't know even just one project of them making use of Qt. Which makes it quite strange they contribute ... not a huge amount, but quite a bit.
26 - Jul - 2016
Giuseppe D'Angelo
It's just the way it works :) If you take a look at the absolute numbers they also decrease approaching a release: http://www.macieira.org/blog/qt-stats/ About Intel: the QtCore maintainer works for Intel.