Re: Wiki Article: Asynchronous Events and Family IPC

2022-05-07 Thread Jean-Christophe Helary
By the way, the picolisp twitter account is great !!! :-) JC > On May 8, 2022, at 14:08, Alexander Burger wrote: > > Hi all, > > a new Wiki article about internal background processing, asynchronous events > and > family IPC in PicoLisp: > > https://picolisp.

Wiki Article: Asynchronous Events and Family IPC

2022-05-07 Thread Alexander Burger
Hi all, a new Wiki article about internal background processing, asynchronous events and family IPC in PicoLisp: https://picolisp.com/wiki/?background I think this was not yet documented anywhere. ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe

Re: IPC

2009-02-09 Thread Tomas Hlavaty
Hi Alex, The fifo is there to defer requests for chopsticks when the philosopher is hungry or eating. Do you have any other mechanism in mind? As the tell - hear mechanism is a pipe, it behaves like a fifo. So I would expect that this would suffice. Not due to the logic of the algorithm,

Re: IPC

2009-02-08 Thread Tomas Hlavaty
Hi Alex, There is no other place where the internal event loop (the C-function waitFd()) is called. I see. I'm wondering whether the 'fifo' is really necessary? The fifo is there to defer requests for chopsticks when the philosopher is hungry or eating. Do you have any other mechanism in

Re: IPC

2009-02-07 Thread Tomas Hlavaty
Hi all, the Chandy / Misra solution to Dining Philosophers Problem in picolisp seems to be working now so the code is now at http://logand.com/sw/phil.l for anybody interested. The problem with the previous code was that once the hungry philosopher handed over his dirty fork, he had to ask to

Re: IPC

2009-02-02 Thread Tomas Hlavaty
called explicitly by a top level parent process. The reason is that upon a 'fork', the 'hear' channel is automatically set up in the child process to be used by the built-in IPC routines. I see, where can I find this automatic channel, is it a named pipe? If not, what channel is used for communication

Re: IPC

2009-02-01 Thread Alexander Burger
Hi Tomas, for phil.l, I'd suggest another change (besides the call to 'hear'). You tried to use 'rpc' to send messages to the other philosophers. While this is basically a correct idea, 'rpc' is not suitable in the current situation. It sends the message via standard output, and is intended to

IPC

2009-01-31 Thread Tomas Hlavaty
Hi Alex, I am struggling to understand picolisp IPC functions (hear, tell, rpc, sync...). I have attached code for the Dining Philosophers problem which gets stuck after calling 'hear' in the philosopher (child) process. The idea is that each philosopher is a process which opens a fifo and all