Unix threads vs. Posix threads

Unix threads vs. Posix threads

Post by Bill Deega » Tue, 18 Mar 1997 04:00:00



Is there a significant difference in the capabilities or performance
of Unix threads (thr_xxx) and Posix thread (pthread_xxx)?

-Bill

 
 
 

Unix threads vs. Posix threads

Post by Andrew Giert » Wed, 19 Mar 1997 04:00:00


 Bill> Is there a significant difference in the capabilities or performance
 Bill> of Unix threads (thr_xxx) and Posix thread (pthread_xxx)?

There is no such animal as "Unix threads".

There are various threads implementations that exist on various different
systems, but pthreads is the only standardised interface.

--
Andrew.

 
 
 

Unix threads vs. Posix threads

Post by Steve Kapp » Thu, 20 Mar 1997 04:00:00





> Bill> Is there a significant difference in the capabilities or performance
> Bill> of Unix threads (thr_xxx) and Posix thread (pthread_xxx)?

>There is no such animal as "Unix threads".

Unix International threads are thr_xxx.  These are native SVR4.

Quote:>There are various threads implementations that exist on various different
>systems, but pthreads is the only standardised interface.

True.

--
______________________________________________________________________
Steve Kappel                  http://www.winternet.com/~skappel

 
 
 

Unix threads vs. Posix threads

Post by Andrew Gabri » Sun, 23 Mar 1997 04:00:00




Quote:>Is there a significant difference in the capabilities or performance
>of Unix threads (thr_xxx) and Posix thread (pthread_xxx)?

The only platform I know of which has both is Solaris.
There is no difference in performance - they use the same
underlying system calls.

There are a few minor differences in capabilities, e.g. posix
has no thr_yield(), sched_yield() being the nearest but yielding
at the process rather than thread level (on platforms where
there's a difference). Also, you can't initiate a non-running
posix thread and set it running later (after some initialisation
say, for which you need the threadid), but UI threads has
thr_create(,,,,THR_SUSPENDED,) followed by thr_continue() which
enables this to be done. (UI threads also has thr_suspend() for
use with thr_continue(), but this is dubious to say the least.)

New applications should use posix threads - the only reason to
use UI threads would be if you _had_ to stick with Solaris 2.4
for some reason (or with Unixware).

--