[Development] QT_XCB_NATIVE_PAINTING makes worse that without of it

Denis Shienkov denis.shienkov at gmail.com
Fri Mar 22 17:19:29 CET 2019


Hmmm.. thanks.. it is very bad... :(

My goal it is to accelerate my QWidget application in some way... I use the
QWT library to render a curves..

That ~30% CPU loading occured even at a low "frame-rate" (about ~2 updates
per second)... But I need about 20-30 updates per second... In this case
the CPU load increases up to 100% and the UI freezes.. It is wery bad,
because on Desktop-systems the CPU load is ~0%.

Is any suggestions to minimize the CPU load on iMX6 target (using QWidget
application)? Maybe is it possible to use an OpenGL at all with X11? Or
something else? Because any other suggestions related to the application
code optimization has not sense (because there are the QWT library already
is optimized). Re-writing an application to Quick is not an option too...

BR,
Denis


пт, 22 мар. 2019 г. в 19:06, Allan Sandfeld Jensen <kde at carewolf.com>:

> On Freitag, 22. März 2019 12:46:59 CET Denis Shienkov wrote:
> > Hi guys.
> >
> > I have iMX6 board with Qt 5.11.2 and Qt-widgets based application. I have
> > compiled my Qt with an 'xcb_native_painting' option.
> >
> > I was hoping that this would speed up my UI and reduce the load on the
> CPU,
> > but I was greatly mistaken:
> >
> > When the QT_XCB_NATIVE_PAINTING is not set, I got following top:
> >
> > * Xorg: 3.6 %
> > * app: 12.8 %
> >
> > When the QT_XCB_NATIVE_PAINTING is *set*, I got following top:
> >
> > * Xorg: 23 %
> > * app: 4.5 %
> >
> > What? QT_XCB_NATIVE_PAINTING makes it worse in 2x-times... WTF?
> >
> Sounds like XCB isn't as well optimized as Qt is ;)
>
> Note though, that there are number of techniques to make the native
> painting
> faster, such as always using qpixmap so the images stays buffered on the
> server side. You might be able to massage your program to be faster with
> native painting, but the whole reason for switching to Qt side painting
> was
> that for the average application developer Qt side was faster.
>
> 'Allan
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20190322/fdf65e6f/attachment.html>


More information about the Development mailing list