関数__swtch_priの実現コードはどこにありますか?
void
__spin_lock_solid (spin_lock_t *lock)
{
while (__spin_lock_locked (lock) || ! __spin_try_lock (lock))
/* Yield to another thread (system call). */
__swtch_pri (0);
}
glibcでのみ宣言を見つけてください。以下を参照してください。
/* Attempt to context switch the current thread off the processor. Lower
the thread's priority as much as possible. The thread's priority will
be restored when it runs again. PRIORITY is currently unused. Return
true if there are other threads that can be run and false if not. */
extern boolean_t swtch_pri (int priority);
extern boolean_t __swtch_pri (int priority);