[Ecls-list] Query about changes

Juan Jose Garcia-Ripoll juanjose.garciaripoll at googlemail.com
Sun Aug 30 21:39:44 UTC 2009

I am right now in the process of re-coding some ideas from Jean Claude
Beaudoin about signal handling and multithreading.

One thing I got so far is the possibility of having multiple toplevels
sharing the console. It works more or less as shown below and a bit
better than what is currently implemented.

The only problem is that while ECL's functions do have the needed code
to grab a lock for reading/writing to the console, ordinary user code
will not. Currently I have solved this by setting the standard input
to be a C stream, which is locking, but there might be problems when
the user sets up other streams -- one might have race conditions with
the debugger and the user trying to read from the standard input.

So my question is, how would you like this interface to be? For those
embedding ECL there might also be other considerations. For instance,
this code might be completely irrelevant when each thread has its own
console, as in programs with multiple windows.


ECL (Embeddable Common-Lisp) 9.8.4
Copyright (C) 1984 Taiichi Yuasa and Masami Hagiya
Copyright (C) 1993 Giuseppe Attardi
Copyright (C) 2000 Juan J. Garcia-Ripoll
ECL is free software, and you are welcome to redistribute it
under certain conditions; see file 'Copyright' for details.
Type :h for Help.
Top level in: #<process SI:TOP-LEVEL 00380fc0>.
> :w

Debugger's waiting list:

   >1: #<process SI:TOP-LEVEL 00380fc0>

> (mp:process-run-function 'background 'si::top-level)

#<process BACKGROUND 020506c0>
> :w

Debugger's waiting list:

   >1: #<process SI:TOP-LEVEL 00380fc0>
    2: #<process BACKGROUND 020506c0>

> :s 2

Top level in: #<process BACKGROUND 020506c0>.
> :w

Debugger's waiting list:

    1: #<process SI:TOP-LEVEL 00380fc0>
   >2: #<process BACKGROUND 020506c0>

Instituto de Física Fundamental, CSIC
c/ Serrano, 113b, Madrid 28006 (Spain)

More information about the ecl-devel mailing list