[Bese-devel] Problems with MP::STARTUP-IDLE-AND-TOP-LEVEL-LOOPS in start.lisp

Fabricio Chalub chalub at gmail.com
Sun Aug 28 17:06:10 UTC 2005


Hi,

a side effect of adding STARTUP-IDLE-AND-TOP-LEVEL-LOOPS in start.lisp
is that CMUCL stops loading start.lisp at that point, since that
function creates a new REPL.  A search on Google shows that people
usually recommends that function as an addition to .CMUCL-INIT.LISP.

It seems that some further magic is needed for the correct MP
initialization.  A possible source of inspiration comes from
PORTEABLEASERVE's INSTALL.lisp that has been bit by this problem in the
past ('DOUBLE-KLUDGE', below).  Unfortunately, I can't retrieve the last
version from CVS as Sourceforge appears to be down for maintenance now.

---- begin of INSTALL.LISP cut
  ;; Startup multiprocessing.
  ;;
  ;; this isn't strictly necessary, but scheduling feels very coarse
  ;; before the evaluation of (startup-idle-and-top-level-loops) --
  ;; answer delays of about 1s per http request.
  ;;
  ;; KLUDGE: startup-idle-and-top-level-loops can only be evaluated
  ;; once, so we look for something resembling an existing idle loop
  ;; before invoking it.
  #||
  #+mp
  (unless (find-if
           #'(lambda (proc) (string= (mp:process-name proc) "Idle Loop"))
           (mp:all-processes))
    (mp::startup-idle-and-top-level-loops))
  ||#
  ;; DOUBLE KLUDGE: The preceding (commented-out) form caused the
  ;; loading of INSTALL.lisp to abort silently (!), so we do the
  ;; following, pilfered from eclipse the window manager:
  #+mp
  (setf mp::*idle-process* mp::*initial-process*)
---- end of INSTALL.LISP cut

So, apparently UCW should use

   #+(and cmu mp)
   (setf mp::*idle-process* mp::*initial-process*)

instead of the MP::S-I-A-T-L-L + FIND-IF call.

Cheers,
Fabricio




More information about the bese-devel mailing list