March 20, 2005
Simple Grid Protocol

recommended by pjb

Simple Grid Protocol 1.0 is a Grid-style framework for doing distributed clisp computation on Linux and BSD, by Brendan Kosowski [via Markus Fix].

(format t "~%Grid Demo. Performs multiplication & shows which CPU Resource Server was used.~%~%")
(format t "Input 1st integer: ")
(setq x (read-line))
(format t "Input 2nd integer: ")
(setq y (read-line))

(multiple-value-setq (result ip) (porta
    (list 'progn
        (list 'setq 'x x)
        (list 'setq 'y y)
        '(progn
            (* x y)
        ))))

(format t "Result of multiplication = ~a~%" result)
(format t "CPU Resource Server used = ~a~%" ip)

Despite the questionable style in the example, it'd be neat if the framework were really that transparent.

Posted by jjwiseman at March 20, 2005 12:09 AM
Comments

Help a beginner out -- what's the questionable style in the example? Is it the use of setq to instantiate new vars?

Posted by: rs on March 20, 2005 12:20 PM

The indentation, for one, is completely unlike any existing normal Lisp.

Here's how the multiple-value-setq might be, normally:

(multiple-value-setq (result ip)
__(porta
___`(progn
______(setq x ,x)
______(setq y ,y)
______(* x y))))

I tend to understand Lisp by looking at how everything is indented. When someone chooses an eccentric indentation style, it can be very hard to read.

Posted by: Zach Beane on March 21, 2005 09:12 AM
Post a comment
Name:


Email Address:


URL:




Unless you answer this question, your comment will be classified as spam and will not be posted.
(I'll give you a hint: the answer is “lisp”.)

Comments:


Remember info?