On 5/17/10, KOSAKI Motohiro <kosaki.motohiro / gmail.com> wrote:
> setschedparam()? no, it's for real time thread mess. please don't use it.

But setpriority always modifies the current thread. :-/ The API of
#priority= is supposed to allow changing the priority from another
thread.

pthread_setschedparam is supposed to set the priority and policy of a
thread. What I was trying to do was enable the code in
native_thread_apply_priority, which looks like it's retaining the
current policy and changing just the priority. I thought that should
end up with the policy staying at SCHED_OTHER. But if it was changing
it to some real-time policy, that could explain what I saw.

Clearly, I need to try it the way you did it. The resulting
restriction on #priority= made me unhappy, tho, and I tried to "fix"
it. When that didn't work, I kind of lost interest...