Re: Semaphore vs. Shared memory
| From: | Ron Chmara | Date: | Thu, 19 Oct 2000 21:58:07 +0000 |
| Subject: | Re: Semaphore vs. Shared memory | ||
| References: | 1 | Groups: | php.doc |
| Request: | Send a blank email to phpdoc+get-969332579@lists.php.net to get a copy of this message | ||
Jesus Castagnetto wrote:
> You might have missed the talk I had w/ Derick about this topic
> (search for: "Shared memory functions in 2 different sections" in the
> list archives).
I vaguely remembered that something had come up....
> Below is a copy of one of the msgs:
> Quoting Derick Rethans <d.rethans@jdimedia.nl>:
> > there are 2 different sesions because of this:
> > - The functions in shmop.xml are more low level shared memory
> functions
> > than the ones in sem.xml.
> > - The functions in shmop.xml are only available when compiling
> > --with-shmop
> > - The functions in sem.xml are available when cmopiling
> --with-sysvshm
Jesus:
> I will add sentences clarifying this difference in both XML
> files, but
> still think that we could merge them into one module or perhaps
> rename
> the new shm_* functions. The naming of the functions is what
> will
> generate confusion, because if I were just using PHP, (not
> looking at
> the code, etc.) I will not expect to have two different modules
> with
> the similar naming conventions.
I Looked up shm funtions.... shm_open followed by shm_put_var certainly
*seemed* sensible to me, and neither page clued me into the issue of
requiring different compile time options to use these similar functions.
> Derick Rethans wrote:
> > Hello Ron,
> > there is no problem if they merge as long as you make sure that the 6
> > functions in shmop.xml are clearly marked that they work only when
> > --with-shmop is passed to configure. The other shared memory functions
> > work with --with-sysvshm.
We have a similar convergence issue in sybase.xml, and this is exactly what
we did (for with-sybase vs with-sybase-ct), we tagged the CT pages as functions
that require a different compile time option.
To disambiguate them, perhaps we should rename these functions to:
shmop_open
shmop_read
shmop_write
shmop_size
shmop_delete
shmop_close
And alias the old ones to allow for backwards compatibility?
Derick, does that make sense to you? (Assuming you have the time to make
the aliases and rename the functions?)
-Ron
--
Brought to you from boop!, the dual boot Linux/Win95 Compaq Presario 1625
laptop, currently running RedHat 6.1. Your bopping may vary.