You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by "Ralf S. Engelschall" <rs...@engelschall.com> on 1999/10/31 16:34:08 UTC

ANNOUNCE: GNU Portable Threads (Pth) 1.2.0 released

   ____  _   _     
  |  _ \| |_| |__    
  | |_) | __| '_ \                    ``Only those who attempt
  |  __/| |_| | | |                     the absurd can achieve
  |_|    \__|_| |_|                     the impossible.''

  GNU Pth - The GNU Portable Threads
  Version 1.2 now available!

  After an eight version long Beta period GNU Pth 1.2.0 is now finally
  available as a release version and 1.2 is now considered as the new
  stable series.

  Pth is a very portable POSIX/ANSI-C based library for Unix platforms
  which provides non-preemptive priority-based scheduling for multiple
  threads of execution (aka `multithreading') inside event-driven
  applications. All threads run in the same address space of the server
  application, but each thread has its own individual program-counter,
  run-time stack, signal mask and errno variable.

  The thread scheduling itself is done in a cooperative way, i.e., the
  threads are managed by a priority- and event-based non-preemptive
  scheduler. The intention is, that this way one can achieve better
  portability and run-time performance than with preemptive scheduling.
  The event facility allows threads to wait until various types of
  events occur, including pending I/O on filedescriptors, asynchronous
  signals, elapsed timers, pending I/O on message ports, thread and
  process termination, and even customized callback functions.

  Additionally Pth provides an optional emulation API for POSIX.1c
  threads (`Pthreads') which can be used for backward compatibility to
  existing multithreaded applications.

  Pth was successfully tested on FreeBSD, NetBSD, OpenBSD, BSDI,
  GNU/Linux, Solaris, HPUX, Tru63 (OSF/1), AIX, IRIX, UnixWare, SINIX,
  ReliantUNIX, ISC, AmigaOS, Rhapsody and AUX. And it should should
  automatically adjust itself to remaining Unix platforms, too.

  More about GNU Pth you can find under the following locations:

  http://www.gnu.org/software/pth/
  ftp://ftp.gnu.org/gnu/pth/

  Yours,
                                       Ralf S. Engelschall
                                       rse@engelschall.com
                                       www.engelschall.com

  PS: You can use GNU Pth as a drop-in replacement for a missing vendor
      Pthread library to run Apache 2.0 (with one of the threading MPMs like
      dexter) and this way get a multithreaded Apache 2.0 running on usually
      all Unix platforms - ranging from mostly all ancient Unix flavors to
      really all the modern ones.


Re: ANNOUNCE: GNU Portable Threads (Pth) 1.2.0 released

Posted by Manoj Kasichainula <ma...@io.com>.
On Wed, Nov 10, 1999 at 07:32:42AM -0800, Scott Hess wrote:
> It seems to me that this only works so long as your modules are written
> with cooperative multithreading in mind.

My understanding is that the pthreads spec doesn't require preemptive
scheduling, so a program designed to run on any pthreads-standard
system has to deal with this case.

I might be confusing pthreads with Java, though; I haven't found any
statement one way or the other on this for pthreads.

-- 
Manoj Kasichainula - manojk at io dot com - http://www.io.com/~manojk/


Re: ANNOUNCE: GNU Portable Threads (Pth) 1.2.0 released

Posted by Scott Hess <sc...@avantgo.com>.
Ralf S. Engelschall <rs...@engelschall.com> wrote:
>   The thread scheduling itself is done in a cooperative way, i.e., the
>   threads are managed by a priority- and event-based non-preemptive
>   scheduler.
<snip>
>   PS: You can use GNU Pth as a drop-in replacement for a missing vendor
>       Pthread library to run Apache 2.0 (with one of the threading MPMs
like
>       dexter) and this way get a multithreaded Apache 2.0 running on
usually
>       all Unix platforms - ranging from mostly all ancient Unix flavors
to
>       really all the modern ones.

It seems to me that this only works so long as your modules are written
with cooperative multithreading in mind.  If they simply go off and think
for long periods of time, then, as described, Pth will not allow other
threads to run.  Or am I missing something about your use of
'non-preemptive', here?

[Not trying to shoot you down, just pointing out that there's a potentially
annoying hole in using Pth as your pthreads, versus using MIT pthreads, for
instance.]

Later,
scott