RE: [PHP-DEV] ZTS - why are you using it?
| From: | Johannes Schlüter | Date: | Tue, 29 Jan 2013 11:45:21 +0000 |
| Subject: | RE: [PHP-DEV] ZTS - why are you using it? | ||
| References: | 1 2 3 4 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-65359@lists.php.net to get a copy of this message | ||
On Tue, 2013-01-29 at 12:15 +0100, Pierre Joye wrote:
>
> Laziness and design mistake. Everything on windows (AD,IIS, asp.net,
> etc)
> uses thread.
Well, most other things don't create "shared-nothing" environments like
PHP does. ASP, not only due to the Application object, for instance
isn't shared-nothing like PHP but sharing state. So what we're doing,
basically, is emulate a separation of threads, similar to what an
operating system should do with processes.
Of course an opcode cache isn't shred-nothing either, and maybe sharing
opcodes within a process is faster than doing this in shared memory.
>
> Miss the rest of my mail or? Current implementation is outdated and
> slow.
That is true. Many modern compilers and environments provide better
support for thread local storages ....
What I see is that TSRM brings a lot of complexity and introduces risk
of bugs in there as many developers don't think about. Most of us are
focused on the nice and simple world of single-threaded computing. And I
assume that we can still find quite some threading bugs when going on a
hunt for them ... so besides of pure executable performance there is
also the cost of developer power for (proper) maintenance ...
johannes