Hello Wez,
Thanks for your feedback.
Indeed the mutex that i placed isn't useful and in fact this is a test patch
i made.
I didn't know TsHashTable :)
This says the mutex will not solve the problem to which i face.
The dl() function can't work with ZTS.
I coded other test source here :
http://mykii.binarysec.com/PHP/Zend_API_module_registry_TSRM/first_shot.patch
In fact the problem is deeper because there are other complex links as
list_destructors that isn't TS whereas this one is used for the management
of modules.
The design of construction and destruction of the modules aren't adapted to
TS environment.
I think it's necessary to redesign the Modular aspect of PHP in order to
solve these problems in-depth.
I have some ideas about this subject but my time is very restricted.
I propose to return to see you when I would have a serious proposal.
Regards,
Michael Vergoz
----- Original Message -----
From: "Wez Furlong" <[EMAIL PROTECTED]>
To: "Michael Vergoz" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>; <internals@lists.php.net>
Sent: Wednesday, March 07, 2007 7:09 AM
Subject: Re: [PHP-DEV] Thread safe problem on module_registry (Zend API
Feature/Change request)
Just curious, why did you choose to mutex around a hash instead of
using the zend_ts_hash functions?
Changing the access semantics while preserving the type and name of
that variable will cause any external modules that are unaware of that
change to subtly break, or if you're lucky, crash hard.
Seems "better" to make that break a little bit more obvious by
changing the name, or introducing an API to encapsulate the correct
access semantics.
These are just suggestions. My main comments are that the locking
macros are mildly ugly and that a lack of compile time enforcement on
the new locking requirement will cause people pain with modules
outside of the main php distribution.
--Wez.
On 3/5/07, Michael Vergoz <[EMAIL PROTECTED]> wrote:
Hello,
I made a patch that "mutex'ed" module_registry and module_count.
For the moment it doesn't solve the dl().
The patch for last CVS PHP_5_2
http://mykii.binarysec.com/PHP/module_registry_mutex/module_register_mutex.patch
Small description :
http://mykii.binarysec.com/PHP/module_registry_mutex/readme.txt
Regards,
Michael Vergoz
----- Original Message -----
From: "Richard Lynch" <[EMAIL PROTECTED]>
To: "Michael Vergoz" <[EMAIL PROTECTED]>
Cc: <internals@lists.php.net>
Sent: Thursday, March 01, 2007 11:06 PM
Subject: Re: [PHP-DEV] Thread safe problem on module_registry (Zend API
Feature/Change request)
> On Thu, March 1, 2007 7:29 am, Michael Vergoz wrote:
>
> I don't claim to understand this issue fully/deeply, but I'm
> definitely +1 on resurrecting 'dl' if this change fixes everything to
> everyone's satisfaction.
>
> Not that my vote actually counts, as I've never had the skills/time to
> actually contribute C code to PHP.
>
> I may be the only user on the planet with a shared host that lets me
> use 'dl' to pull in extensions, but there it is, and I kinda need it,
> as there are no other viable options to do what I need to do, other
> than changing to a new webhost I might not like... :-)
>
> --
> Some people have a "gift" link here.
> Know what I want?
> I want you to buy a CD from some starving artist.
> http://cdbaby.com/browse/from/lynch
> Yeah, I get a buck. So?
>
>
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php