Hi,

I've just started implementing a pthread extension to the PHP language.
Things just aren't as simple as I expected. I have no problems in creating
threads, mutexes and the like. But it seems that zend_execute and companion
functions use some global variables (executor globals, accessed via EG,
etc.) that are naturally shared with all threads that I create. This
obviously causes serious problems. My question is: how does the zend engine
internally handle threading? I know there is some kind of mutex mechanism
because Apache uses multiple threads instead of processed to handle client
requests. Without documentation, it is very hard to figure out how things
are done. If I was able to use the same threading mechanism within a
script, the extension would be more portable, too (afaik, pthreads work
only on unices...) All comments are welcome.

-Topi-
 << http://ee.oulu.fi/~topiolli >>


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to