From: Cyber Surfer
Subject: Re: The New Lisp Machine
Date: 
Message-ID: <memo.222682@cix.compulink.co.uk>
In article <··········@jabba.ess.harris.com>,
···@mercury.Harris-ATD.com (Mike McDonald) writes:

>   We were talking about Unix, at least that's what Barry Margolin 
> to support because of all of those UNIX applications. Yes, I agree
> REAL hard to write a very complicated application that's portable 
> Dos, Mac, MVS, ... I believe that it is doable (at least for the k
> applications I'm interested in) across Unix platforms. As an examp

I was also writing about C, which doesn't have a select function in
any implementation I've used. Is this a Unix feature? This is an
important question to me, as the people likely to employ me are
more likely to not use Unix. I'd rather use Lisp than C, but I have
no choice about that, except in my own time and with my own money.

The Lisp Machine idea is a good one, and shouldn't be held back
by OS issues. Ideally, the OS should be in Lisp. To quote a certain
source of influenctial ideas: "A operating system is a collection
of things that don't belong in a language. There shouldn't be one."

That's a purist's approach, and I felt that way 10 years ago. Now,
I bow humbly before the alter of the real world, but I'm not happy.
After playing with a pure OOP language, I found a great deal of
disgust and contempt for it by most programmers, as it couldn't
produce images as small as C. As usual, they were comparing the
"Hello, World" type of program, which is not an app, therefore
not a real test.

It makes no difference to these people. They claim they're living
in the real world, and I won't argue with them, or evangelise.

10 years ago, I also wanted to use Unix. It's been a long wait,
and it's far from over. Oh dear, this is becoming another rant...

-- Cyber Surfing on CIX --

From: Thomas M. Breuel
Subject: Re: The New Lisp Machine
Date: 
Message-ID: <TMB.93May14154906@arolla.idiap.ch>
>>>>> On Fri, 14 May 1993 06:28:39 +0000, ············@cix.compulink.co.uk (Cyber Surfer) said:
> The Lisp Machine idea is a good one, and shouldn't be held back
> by OS issues. Ideally, the OS should be in Lisp.

Lisp Machine style, the OS was not only written in Lisp, it was part
of a single Lisp system.

I do agree that most current OS isolate processes and users too much
from one another, but I think the Lisp Machine isolated them too
little.

					Thomas.
From: GUI yexuan
Subject: AKCL compiler
Date: 
Message-ID: <C76ACn.3IG@newsflash.concordia.ca>
I have two questions about AKCL(or KCL):

(1) How to compile LISP code in AKCL. What I am doing is using 
    "COMPILE-FILE" to get object file. And then load the object file 
    into AKCL interpretor to execute it. For example, if the source code
    is in file "foo.lsp", I do the following:

    >(compile-file "foo.lsp")

    >(load "foo.o")

    Then execute the function in foo.o in AKCL interpretor.

    Can I compile the source file to get a executable file directly
    without having to load it into the interpretor for execution?

(2) I am writing a big program in C. Some functions can be better
    implemented in LISP. Can I call compiled AKCL functions from C code?
    How to do it?

Thanks.

 --------------------------------------------------------------------------
|   Yexuan GUI                          |                                 |
|                                       |  Phone:                         |
|   Logic and Formal Methods Laboratory |  (514) 848-3052                 |
|   Concordia University, ER-400-10     |                                 |
|   Montreal, Quebec  H3G 1M8           |  E-mail:                        |
|   Canada                              |  ···@cs.concordia.ca            |
 --------------------------------------------------------------------------
From: Wolfgang Koehler
Subject: Re: AKCL compiler
Date: 
Message-ID: <WOLF.93May17181020@gimli.first.gmd.de>
In article <··········@newsflash.concordia.ca> ···@cs.concordia.ca (GUI yexuan) writes:

   I have two questions about AKCL(or KCL):

   (1) How to compile LISP code in AKCL. What I am doing is using 
       "COMPILE-FILE" to get object file. And then load the object file 
       into AKCL interpretor to execute it. For example, if the source code
       is in file "foo.lsp", I do the following:

       >(compile-file "foo.lsp")

       >(load "foo.o")

       Then execute the function in foo.o in AKCL interpretor.

       Can I compile the source file to get a executable file directly
       without having to load it into the interpretor for execution?

Simple answer :

Call (si:save-system "xyz") after loading foo.o. (This terminates AKCL !)
The saved image "xyz" contains all loaded code. Compiled code alone is
not enough to run a program since the run time library is necessary.

   (2) I am writing a big program in C. Some functions can be better
       implemented in LISP. Can I call compiled AKCL functions from C code?
       How to do it?

I suppose you have to use the AKCL as a frame and then load the C-code into it.
(The manual describes this decently).
The other way (loading AKCL into a running C-program) probably will fail.
Of course, if you have all sources of AKCL, you can rebuild it linking it 
together with the C program. 

Wolfgang
--

-------------------------------------------------------------------------
    ... always look on the bright side of life ... (Monty Python)
-------------------------------------------------------------------------
Wolfgang Koehler                               ····@first.gmd.de
GMD-FIRST an der TU Berlin              German National Research Centre 
Tel. (Berlin 030) 6392-1908                 for Computer Science
From: GUI yexuan
Subject: Re: AKCL compiler
Date: 
Message-ID: <C7AG4A.L4@newsflash.concordia.ca>
In article <··················@gimli.first.gmd.de> ····@first.gmd.de writes:

>Simple answer :

>Call (si:save-system "xyz") after loading foo.o. (This terminates AKCL !)
>The saved image "xyz" contains all loaded code. Compiled code alone is
>not enough to run a program since the run time library is necessary.

Thank you for the help.

I still have a question:

If I have a function foo in the file foo.lsp like the following.

     (defun foo () ... )

I want to start the execution of function foo immediately after I
enter xyz under UNIX environment. How can I achieve that?

At present, after typing xyz, I am in KCL. I have to type (foo) to
start executing the function.

 --------------------------------------------------------------------------
|   GUI  Yexuan                         |                                  |
|                                       |  Phone:                          |
|   Logic and Formal Methods Laboratory |  (514) 848-3052                  |
|   Concordia University, ER-400-10     |                                  |
|   Montreal, Quebec  H3G 1M8           |  E-mail:                         |
|   Canada                              |  ···@cs.concordia.ca             |
 --------------------------------------------------------------------------
From: Themos Tsikas
Subject: Re: AKCL compiler
Date: 
Message-ID: <1993May20.110441.14185@vax.oxford.ac.uk>
In article <·········@newsflash.concordia.ca>, ···@cs.concordia.ca 
                              (GUI yexuan) writes:

> In article <··················@gimli.first.gmd.de> ····@first.gmd.de writes:
> 
>>Simple answer :
>>Call (si:save-system "xyz") after loading foo.o. (This terminates AKCL !)
>>The saved image "xyz" contains all loaded code. Compiled code alone is
>>not enough to run a program since the run time library is necessary.
> 
> Thank you for the help.
> 
> I still have a question:
> 
> If I have a function foo in the file foo.lsp like the following.
> 
>      (defun foo () ... )
> 
> I want to start the execution of function foo immediately after I
> enter xyz under UNIX environment. How can I achieve that?
> 
> At present, after typing xyz, I am in KCL. I have to type (foo) to
> start executing the function.

Say
(setq si::*top-level-hook* 'foo)

just before you save the image.

KCL documentation follows:

Documentation:
*TOP-LEVEL-HOOK*
Variable in the SI package:
If this variable has a function as its value at start up time, then
it is run immediately after the init.lsp file is loaded.    This is useful
for starting up an alternate top level loop.

This is an alternative:

Documentation:
TOP-LEVEL
Function in SI package:
Args: ()
KCL specific: Starts the standard top-level listner of KCL.  When the KCL
process is invoked, it calls SI:TOP-LEVEL by (FUNCALL 'SI:TOP-LEVEL).
     To change the top-level of KCL, redefine SI:TOP-LEVEL and save the core
image in a file.  When the saved imange is invoked, it will start the
redefined top-level.

--  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --
 Themos Tsikas                      e-mail: ······@nag.co.uk
 AXIOM Development Coordinator      tel.  : 44-(0)-865-511245               
                     Numerical Algorithms Group Ltd.                        
           Wilkinson House, Jordan Hill Rd., Oxford, UK OX2 8DR