Re: [QTime] Create Thread time Mesure
Do you really care how long it takes to start a thread? I would suggest that if your design is such that you are creating/terminating threads often enough that you are concerned with the overhead of doing so, then you should re-think your design... For example, start your thread and then feed it work via emitting a signal, or serializing a data structure like a QVector/QList/QMap, etc. that contains elements from the thread to work on.
Alternatives: use a thread pool or Qt's map/reduce type functionality.
Can you explain why this timing is critical for your needs?
I write the best type of code possible, code that I want to write, not code that someone tells me to write!
Bookmarks