A
Armin Zingler
Hi,
surprise, it's me - again. Yeah, I know, many questions these days....
I'm doing work in background threads in order to keep the UI thread
responsive. I know that these threads consume 100% CPU time, but if
I set their priority to BelowNormal, the UI thread should still stay
responsive. The only thing that the UI thread does is starting other
threads. On an average, it starts about 10 threads per second. This
shouldn't put too much load on the UI thread.
However, at a certain point in time, the UI thread freezes. As I
know that the only thing the UI thread does is starting threads,
I logged the execution time of "starting a thread". The result
is surprising: It takes between 0.2 ms and 4 seconds!
Does anybody have an explanation why there is such a big deviation
between the execution times within a thread that has a higher priority
than all other threads?
Thanks again for reading!
surprise, it's me - again. Yeah, I know, many questions these days....
I'm doing work in background threads in order to keep the UI thread
responsive. I know that these threads consume 100% CPU time, but if
I set their priority to BelowNormal, the UI thread should still stay
responsive. The only thing that the UI thread does is starting other
threads. On an average, it starts about 10 threads per second. This
shouldn't put too much load on the UI thread.
However, at a certain point in time, the UI thread freezes. As I
know that the only thing the UI thread does is starting threads,
I logged the execution time of "starting a thread". The result
is surprising: It takes between 0.2 ms and 4 seconds!
Does anybody have an explanation why there is such a big deviation
between the execution times within a thread that has a higher priority
than all other threads?
Thanks again for reading!