Re: Thread behaviour using pthread
- From: "Igor" <igor_k70@xxxxxxxxxxx>
- Date: Fri, 31 Mar 2006 15:30:10 -0500
Hi Loic,
I tried this attribute same results. Did not change anything when thread set
to fifo or rr...
I keep on trying.
Thanks,
Igor
<loic-dev@xxxxxxx> wrote in message
news:1143234128.449381.207080@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hello Igor,a
I have tried using pthread library on Linux (2.6 kernel) and found that
setting parameters in the attr structure
do not seem to change anything in the thread behaviour - changing sched
policy (RR, FIFO) or RT priority. So, it seems that any changes to attr
structure for a thread are transparent. The only way I could change the
behaviour is by using process level calls like sched_setscheduler etc.on
thread.
Is there anything I am missing?
Yes. You must set the inheritsched attribute to PTHREAD_EXPLICIT_SCHED;
otherwise the thread created inherits the schedpolicy and schedparam
attributes from the creating thread.
HTH,
Loic.
.
- Follow-Ups:
- Re: Thread behaviour using pthread
- From: "Nils O. Selåsdal"
- Re: Thread behaviour using pthread
- References:
- Thread behaviour using pthread
- From: Igor
- Re: Thread behaviour using pthread
- From: loic-dev
- Thread behaviour using pthread
- Prev by Date: Re: /usr/bin/ld cannot locate libmysqlclient, when it is there
- Next by Date: Re: Thread behaviour using pthread
- Previous by thread: Re: Thread behaviour using pthread
- Next by thread: Re: Thread behaviour using pthread
- Index(es):