After I posed the riddle, more than a week ago, several people
contributed suggestions and points of view.
- Shachar Shemesh suggested to implement a queue without locks.
- Moish amended it with a suggestion to use a circular queue.
- Baruch Siach suggested to try the userspace RCU library
(http:/
On Wed, 13 Apr 2011 16:40:55, Ori Berger wrote:
>
> > A full fledged queue would force the consuming process (process A) to
> > read and process all data written by the producing process (process M)
> > even when process A needs only the most recent value whenever it reads
> > process M's data.
>
>
Omer,
you did not specify the timing constraints you have, so the very basic
thing mechanism is to use a posix semaphore for mutual exclusion access
to this memory.
this will work both on single-core and multi-core systems.
note that disabling interrupts is not possible from user space - so it
On 04/13/2011 05:04 PM, Omer Zak wrote:
If the counter is one byte wide, then any updates to it would be atomic
by definition (of course, the context is that only process M ever
modifies it).
While that is true, I was wrong in asserting that "atomic" is enough. It
needs to be ordered with res
On Wed, 2011-04-13 at 16:40 -0400, Ori Berger wrote:
> On 04/13/2011 09:41 AM, Omer Zak wrote:
>
> > A full fledged queue would force the consuming process (process A) to
> > read and process all data written by the producing process (process M)
> > even when process A needs only the most recent v
On 04/13/2011 09:41 AM, Omer Zak wrote:
A full fledged queue would force the consuming process (process A) to
read and process all data written by the producing process (process M)
even when process A needs only the most recent value whenever it reads
process M's data.
I forgot how this scheme
Hi Omer,
On Wed, Apr 13, 2011 at 04:07:42PM +0300, Omer Zak wrote:
> The system has several such processes, so it is desirable to have an
> inter-process mechanism having the absolute minimum overhead for
> unidirectional data transfers from measuring processes (like process M)
> to action taking
On 13/04/2011 15:41, Omer Zak wrote:
A full fledged queue would force the consuming process (process A) to
read and process all data written by the producing process (process M)
even when process A needs only the most recent value whenever it reads
process M's data.
On Wed, 2011-04-13 at 16:21 +
A full fledged queue would force the consuming process (process A) to
read and process all data written by the producing process (process M)
even when process A needs only the most recent value whenever it reads
process M's data.
On Wed, 2011-04-13 at 16:21 +0300, Shachar Shemesh wrote:
> On 13/04
On 13/04/11 16:07, Omer Zak wrote:
The riddle:
1. If the operating system being used is Linux, what other mechanisms
(besides turning off interrupts) are available to single-processor
systems to accomplish this?
2. If the system has a multi-core processor or several processors, which
low overhead
I have a riddle for you.
Given a system with real time processes.
One process (process M) monitors some quantity (say, temperature) and
makes measured values of the quantity available for another process
(process A).
Process A retrieves the measured temperature once in a while and takes
some acti
11 matches
Mail list logo