httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sascha Schumann <sas...@schumann.cx>
Subject Re: [?PATCH?] using getpwnam_r in mod_userdir
Date Sat, 11 Nov 2000 01:01:25 GMT
> >     Remember that we need to have a wrapper anyway for all of
> >     those _r functions, because the source code will use _r
> >     functions even in non-threaded mode. (Unless you choose to
> >     duplicate code for both modes all over the place.)
>
> You can't do that either.  In many cases, the _r functions are much less
> efficient than the non-_r functions.  So, if you always use _r you lose
> efficiency.  Our wrappers would actually need to use _r or non-_r based on
> how it is compiled.

    I think you are confusing something now..

    An _r wrapper is only used, if the platform does not have the
    corresponding _r function.

    Thus, an _r wrapper always uses the non-_r function.

    Do you mean that native _r functions are much less efficient?

> >     I think we should use a single lock for protecting one
> >     sub-system. We need to define `sub-system' here. FreeBSD will
> >     need one lock for getpw functions.
> >
> >     If a certain platform shows signs of hidden inter-function
> >     dependencies, I'd be in favor of disabling threading on that
> >     platform. Experience will tell.
>
> My own personal opinion is that this is a bogus problem because some
> platforms aren't following the specs.  We shouldn't cater to broken
> platforms, especially not open source broken platforms.  Those platforms
> should be fixed correctly.

    I agree that fixing the platforms is the right mid-term to
    long-term approach. It is a bogus problem which will
    hopefully go away soon. In the mean-time, we should try to
    address the problem though. That is all a Portable Runtime is
    about.

    - Sascha


Mime
View raw message