Justtechjobs.com Find a programming school near you






Online Campus Both


php3-list | 199908

Re: [PHP3] Parallel, Multi Tasking, Forking whatever you want tocall From: Teodor Cimpoesu (teo <email protected>)
Date: 08/05/99

Aaron Leon Kaplan wrote:
>
> I was just wondering, is it possible to do smthng like:
> 1) php process creates shared memory
> 2) php process calls system ("child_prg &"); (shell background job)
> [or popen(...)]
> 3) child_prg forks
> 4) children of child_prg attach to shared mem and write their results
> 5) in the meantime the php process has waited for results on the shared
> memory
>
> Of course you will need at least one semaphore in this typical
> prdoucer-consumer problem...
>
> just my 2 cents....
> Aaron.
it is a good idea!
But involves of course writing an external program which will do the
stuff.
I'll try a little example in C.
Also add
[6)] eventually delete shared memory else you'll have a leak(of course
if
second call creates another shm segment).

-- 
CIMPOESU Teodor, Web Programmer

@ DIGICOM S.A. Bucharest, Romania @ Internet, site development @ teo <email protected>,+(401)-330.47.28

official home page ~ http://www.digiro.net/ Internet web page ~ http://internet.digiro.net/

-- PHP 3 Mailing List <http://www.php.net/> To unsubscribe, send an empty message to php3-unsubscribe <email protected> To subscribe to the digest, e-mail: php3-digest-subscribe <email protected> To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 To contact the list administrators, e-mail: php-list-admin <email protected>