[Development] epoll event dispatcher

Thiago Macieira thiago.macieira at intel.com
Fri Aug 9 20:17:51 CEST 2013


On sexta-feira, 9 de agosto de 2013 19:04:56, Oswald Buddenhagen wrote:
> i'll note that the qml guys identified that as a major bottleneck a few
> years ago and wrote their own timer code.

Probably for the same reason why we identified the glib GTimeout as a major 
bottleneck (and grew worse for a long-lived application[1]) back in 2006, so 
we decided not to use one GTimeout for each QTimer, but simply keep our own 
list and tell glib of one timer only: impedance mismatch. 

Sure, the glib code back in 2006 was a singly-linked priority list where 
everything got appended to the end (O(n) appending) and leaked. But we still 
keep our own list today for the simple reason that we don't have to tell glib 
about each timer, and have it allocate more resources in addition to ours. 

[1] that's actually the reason why QT_NO_GLIB exists: I needed to benchmark 
and debug the same Qt applications with and without glib. The application in 
question, back in Qt pre-4.2 days before KDE 4 got released, was the 
Teambuilder monitor. It was the only application I left running for a long 
time.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20130809/06420e6e/attachment.sig>


More information about the Development mailing list