Re: fork or pthread for async I/O?

From: msitkows@au1.ibm.com
Date: Wed Feb 02 2000 - 14:08:21 PST

  • Next message: Oliver Rauch: "Re: fork or pthread for async I/O?"

    Hi,

    To begin with, fork() and pipe() have nothing to do with Posix, but have
    been Unix system calls since the dawn of time, and are executed inside the
    kernel.
    In theory, pthreads are also executed in kernel space, within the same
    process context but, if your kernel has not been compiled to be
    multi-threaded, the threads execute in user space, and just look like
    lightweight processes. Any advantage is overcome by the huge software
    overhead, (like maintaining mutexes, etc) necessary to house-keep the
    threads.
    Add to that, the fact that different versions of Unix (like AIX or Solaris)
    use slightly different implementations of pthreads with each release, and
    my advice would be, forget it. I think portability is more important, for a
    public software package.

    Best regards,
    Mark

    ------------------------------------------------------------------------
     Mark Sitkowski
     Design Simulation Systems Ltd
     14 Loddon Street
     Box Hill North, Victoria 3129 Australia
    ------------------------------------------------------------------------
     phone: (613-9) 897-1375 fax: (613-9) 897-1376
     Mobile: 0413-890-777 E-mail: marks@iaccess.com.au
     Web: www.angelfire.com/de/designsim
               www.asiafind.com/sites/designsim
    ------------------------------------------------------------------------

    --
    Source code, list archive, and docs: http://www.mostang.com/sane/
    To unsubscribe: echo unsubscribe sane-devel | mail majordomo@mostang.com
    



    This archive was generated by hypermail 2b29 : Wed Feb 02 2000 - 14:37:12 PST