[Development] The future of QFuture, and QtConcurrent (was "Is QtConcurrent's code generator still in use?")

Thiago Macieira thiago.macieira at intel.com
Fri Nov 16 00:39:00 CET 2012


On quinta-feira, 15 de novembro de 2012 21.07.09, Tony Van Eerd wrote:
> QThread:
> - needs new docs (coming in 5.0)
> - often misused ("you're doing it wrong")
> - results in too many dedicated threads (typically)
> - or threads created/destroyed too often
> 
> QtConcurrent::run()
> - I thought this was a better alternative for "one shot tasks"
> - now it sounds like QtConcurrent is not the way to go?
> 
> What should I be recommending to developers?

The solution we haven't written yet.

QThread is just fine if you need a long-running thread or one that will do 
blocking operations. If you need to start "one shot tasks", we're missing a 
good API to replace QtConcurrent for now.

I'd like to see someone give TBB a Qt-ish API wrapper.
-- 
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/20121115/13e3221f/attachment.sig>


More information about the Development mailing list