Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:47734 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 52182 invoked from network); 2 Apr 2010 07:30:55 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 2 Apr 2010 07:30:55 -0000 Authentication-Results: pb1.pair.com smtp.mail=lester@lsces.co.uk; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=lester@lsces.co.uk; sender-id=unknown Received-SPF: error (pb1.pair.com: domain lsces.co.uk from 213.123.26.180 cause and error) X-PHP-List-Original-Sender: lester@lsces.co.uk X-Host-Fingerprint: 213.123.26.180 c2beaomr02.btconnect.com Received: from [213.123.26.180] ([213.123.26.180:19422] helo=c2beaomr02.btconnect.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 3C/03-44965-C2D95BB4 for ; Fri, 02 Apr 2010 02:30:53 -0500 Received: from [10.0.0.5] (host81-138-11-136.in-addr.btopenworld.com [81.138.11.136]) by c2beaomr02.btconnect.com with ESMTP id DJT20082; Fri, 2 Apr 2010 08:30:49 +0100 (BST) X-Mirapoint-IP-Reputation: reputation=Fair-1, source=Queried, refid=0001.0A0B0301.4BB59D29.01BD, actions=tag Message-ID: <4BB59D29.7080100@lsces.co.uk> Date: Fri, 02 Apr 2010 08:30:49 +0100 User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.8) Gecko/20100217 Fedora/2.0.3-1.fc12 SeaMonkey/2.0.3 MIME-Version: 1.0 To: PHP internals References: <1941231697.20100401163215@gmail.com> <698DE66518E7CA45812BD18E807866CE03FA7EFF@us-ex1.zend.net> <4BB59771.2050706@quis.cx> In-Reply-To: <4BB59771.2050706@quis.cx> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Junkmail-Status: score=10/50, host=c2beaomr02.btconnect.com X-Junkmail-SD-Raw: score=unknown, refid=str=0001.0A0B0209.4BB59D2A.00E4,ss=1,fgs=0, ip=0.0.0.0, so=2009-07-20 21:54:04, dmn=5.7.1/2009-08-27, mode=single engine X-Junkmail-IWF: false Subject: Re: [PHP-DEV] php and multithreading (additional arguments) From: lester@lsces.co.uk (Lester Caine) Jille Timmermans wrote: > Op 2-4-2010 7:16, Andi Gutmans schreef >> I think that if we were ever to implement threading we would be best off >> to enable spawning worker threads that have their own context with no >> shared data (and therefore no requirement for locking). We could then >> have a message passing API between the threads. >> Advantages: >> - Real multi-threading. >> - Simple straightforward approach which doesn't require a comp. sci. >> degree to use correctly. >> - Very stable implementation. > That sounds like "I want threading; because it sounds cool!". What are > the advantages of this above multi-process? > The systemcall-overhead for message passing? Actually Andi's outline forms a nice simple base for something practical. It simply builds on the 'background' threading required to run asynchronous operations while not creating a unmanageable mess. But I still can't see any need to go beyond perhaps asynchronous SQL queries. It still requires that all the non-thread safe code is addressed first? Even if that simply means disabling extensions that are not safe? > And why did nobody mention Aprils Fools yesterday; when the > request-for-threading was sent ;) Because it was after noon when it was sent ;) -- Lester Caine - G8HFL ----------------------------- Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk// Firebird - http://www.firebirdsql.org/index.php