scsh-users
[Top] [All Lists]

Re: I/O timings

To: scsh@martigny.ai.mit.edu
Subject: Re: I/O timings
From: sjenkins@iastate.edu (Steven L Jenkins)
Date: 19 Apr 1996 14:32:57 GMT
Organization: Iowa State University, Ames, Iowa USA
In article <j7vratli97a.fsf@mahasamatman.cs.rice.edu>,
Shriram Krishnamurthi <shriram@cs.rice.edu> wrote:
>sjenkins@iastate.edu (Steven L Jenkins) wrote:
>
>> I haven't played with Cormac's system, but I've played a good bit with
>> Soft Scheme and have been extremely disappointed in it's performance -- it
>> makes scsh look like a greyhound speed-wise.
>
>Huh?  I don't even begin to understand this comparison.  Soft Scheme
>is not a compiler; it's a language pre-processor (if you will).  Scsh
>is a language implementation.  Soft Scheme is entirely dependent upon
>the underlying Scheme for its performance, while Scsh is (in a sense)
>the underlying Scheme itself.


Right.  My comparison with scsh is because of the performance issue (ie,
folks have complained about scsh being slow, a memory pig, etc..).
The performance of SoftScheme is much worse.  My reference to the DrScheme/
mzscheme family is because that system is being designed to include lots
of useful development tools, and SoftScheme could be a candidate for
inclusion in there.

>
>>                                              But in an 'optimizing'
>> compiler, such speed can be worth it's cost when combined with something
>> that can produce results.
>
>Perhaps you've misunderstood the purpose of Soft Scheme.  It isn't
>meant to be an interactive tool that gets invoked each time you type
>an expression into the repl, say.  You're supposed to do an off-line
>analysis, and run only the output file.  Of course, it does the
>analysis fairly quickly, so in a pinch (but not too much of one) you
>could use it in the former manner.

Yes, I guess I understand how it is meant to be used, but to me,
it would be quite nice to have a SoftScheme-like tool available
in a Scheme development system -- say a flag you choose, or constant to
be set when running that would provide ML-like type information as
you code.  And SoftScheme is too big to be the right tool for that job.
(It took over two minutes to load (under SCM), then analyzing a file of 
4 simple Scheme expressions took around 10 seconds, and this was on a 
Sun server 1000e with 256M of RAM..and no one else
on but me.).  I find that intolerable regardless of how the tool is
meant to be used.  Now, to be fair, the performance under Chez Scheme
is better.  But not everyone has $5k to plunk down for a Scheme system..

FWIW, the file contained:
(define foo 3)

(define (even x) (if (zero? x) #t (odd (- x 1))))
(define (odd x) (if (zero? x) #f (even (- x 1))))

(define map
  (lambda (f ls)
    (if (null? ls) '()
        (cons (f (car ls)) (map f (cdr ls))))))

Which isn't exactly brain surgery to infer..(ok, the mutual recursion
could require some kind of topological sorting or deferred evaluation, but it's
not *that* hard or time-consuming.)
 
(note: ``ML-like'' does not mean every expression in Scheme would have a
meaningful type inferred -- polymorphism, mutation, and denoted values
vs expressed values cause some nice hairy-monster problems. It simply means
that instead of an REP loop you would have a RETP (read, eval, type, print 
value and type) loop.

Steven

PS I think you guys at Rice are doing some hot Scheme stuff..and was
really just asking if you had plans to incorporate a type analyzer into
DrScheme (and recommending that SoftScheme as it currently is, *not* be
the analyzer).


<Prev in Thread] Current Thread [Next in Thread>