Multithreaded Programming Guide

Major API Differences

Solaris threads and pthreads are very similar in both API action and syntax. The major differences are listed in Table 6–1 .

Table 6–1 Unique Solaris Threads and pthreads Features

Solaris Threads 

POSIX Threads 

thr_ prefix for threads function names, sema_ prefix for semaphore function names

pthread_ prefix for pthreads function names, sem_ prefix for semaphore function names

Ability to create “daemon” threads 

Cancellation semantics 

Suspending and continuing a thread 

Scheduling policies