httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Collins" <robert.coll...@itdomain.com.au>
Subject Re: [PATCH] 1.3: changing accept mutex for Cygwin
Date Fri, 18 Jan 2002 09:46:37 GMT

===
----- Original Message -----
From: "Stipe Tolj" <tolj@wapme-systems.de>

> > > manglement aside, I'm -1 without an answer to the question on this
> > > code which I posted previously...
> > >
> > > the answer may simply be
> > >
> > > "with Cygwin, all pthread mutexes are cross-process, so there is
no
> > > need for such a call"

"With Cygwin, no pthread mutexes are cross-process, so the parameter
value PTHREAD_PROCESS_SHARED is invalid".

I have  implemented a proof-of-concept cross-process mutex, but it's not
stable code at this point.

> > 2) not all systems which support pthread mutexes have the support to
> >    make them work cross-process; such systems either neglect to
define
> >    PTHREAD_PROCESS_SHARED or return an error from
> >    pthread_mutexattr_setpshared(,PTHREAD_PROCESS_SHARED)

And this applies to us.

> > 3) Cygwin always returns an error from
> >    pthread_mutexattr_setpshared(,PTHREAD_PROCESS_SHARED)
> >
> > 4) it is possible for Apache to appear to work correctly without
> >    proper accept serialization
> >
> > My conclusion from these facts/assumptions is that with Stipe's
change
> > he is falling into #4 above.  In other words, he isn't getting
working
> > accept serialization.  If that is true, I would prefer that for
Cygwin
> > we (Stipe) set whatever is required so that we don't try to do
accept
> > serialization at all, rather than using the pthread mutex support in
a
> > non-working manner.

I'll happily accept contributions to Cygwin to get cross-process mutex's
stable, or I can provide some assistance should Stipe wish to implement
native win32 mutex's for apache/cygwin (which is an ok if-not-preferred
configuration).

Rob


Mime
View raw message