From: John S. Rodrigues
Subject: Multithreading on CLISP-2.29
Date: 
Message-ID: <C9E4C914A770F86E.6EF193A65A878D5C.D6A7D657B70C791A@lp.airnews.net>
I am a LISP rookie.

How do I use multi-threading in CLISP-2.29 ? I tried using the threads 
package, but I get the message "No package called threads". There is a 
threads.lisp file in the CLISP source. What am I missing??

Thanks,
John.

Included below is the code I am trying to 'multi-thread'. It's my 
prototype server.

;;;;(use-package 'threads)

(defun server (port)
   (let ((server (socket-server port)))
     (unwind-protect
       (loop
         (let ((socket (socket-accept server)))
           (handle-connection socket))
         ;; TODO - find out howto make threads:
         ;;(make-thread (format nil "Socket handler for socket ··@~A~%"
         ;;                         (socket-stream-host socket)
         ;;                         (socket-stream-port socket))
         ;;                 #'handle-connection socket))
         )
       (format t "Closing socket server~%")
       (socket-server-close server))))

(defun handle-connection (socket)
   (format t "Received packet from ~A port ~A~%"
           (socket-stream-host socket)
           (socket-stream-port socket))
   (format t "Socket status = ~A~%"
           (socket-status socket))
   (do ((x (read-line socket nil nil) (read-line socket nil nil)))
       ((or (null x)
            (null (socket-status socket))
            (equal :error (socket-status socket)))
        (progn
          (format t "DEBUG!! - x-val ~A~%" x)
          (format t "Closing the socket!!~%")
          (close socket)))
     (format t "~A~%" x)))
From: Bill Clementson
Subject: Re: Multithreading on CLISP-2.29
Date: 
Message-ID: <wkr8gpsfez.fsf@attbi.com>
"John S. Rodrigues" <········@airmail.net> writes:

> How do I use multi-threading in CLISP-2.29 ? I tried using the threads
> package, but I get the message "No package called threads". There is a
> threads.lisp file in the CLISP source. What am I missing??

The Sourceforge site for CLISP has a "tasks" page at the following URL:
http://sourceforge.net/pm/?group_id=1355

One of the tasks listed is "Multi-Threading" with a description of
"Finish the MT code (see multithread.txt and xthread.d)". You might want
to follow-up on the CLISP list to find out what the status of the
multi-threading task is.

--
Bill Clementson