[REBOL] Re: Is Rebol code smaller?/Compiler!
From: tim:johnsons-web at: 19-Nov-2002 18:57
* Ammon Johnson <[ammon--rcslv--com]> [021119 13:29]:
> Hi,
>
> I will answer this much concerning REBOL and compiling;
>
> First, Carl said that REBOL code can be written so that it is too
> dynamic to compile.(Or somthing to that effect)
>
> Second Carl also agrees that we need more performance out of REBOL. He
> has talked several times about a function that they are working on that will
> actually compile REBOL code. Now the examples he gave for a compiled
> function would be heavy duty number crunching such as intensive algorithims
> and bitmap processing. As far as the general 'run of the mill' code, I don't
> think you will be able to compile it, and I think that the performance
> increase would be minimal. The real trouble with performance is in things
> like /View.
>
> All in all, I believe that RT is working on a solution to your current
> problem.
Hi Ammon:
This isn't my *current problem*, and I'm just being rhetorical here..
but I would throw out an idea that make some sense and relevance to
me:
Imagine a rebol script that reads another rebol script and converts
that script into "C" code that is compilable based on the following
conditions:
1)The "C" code implies an API which could be provided as object
code by RT itself, because I'm sure that they use something like it.
2)The code could then be either compiled directly or amended and then
compiled.
I could presume that RT already has those resources and could
fit them to any of the OS's that the rebol binary is compiled
to run on. Most Operating systems have a "C" compiler on board,
I suppose that cygwin could be considered the default windooze
compiler...
3)And it could be extendable by both extending the "preprocessor
script" and the "C api".
There just might be a market for something like that, and
hey, there's a lot of "C" programmers out there..
RT's approach seems to be to create a "universe of their own".
Perhaps it is worthwhile to think about how rebol can integrate
into existing systems more?
Just my two cents worth... in the meantime, I find that 75%
of my programming needs are met with rebol.
-tim-
> ----- Original Message -----
> From: "Tim Johnson" <[tim--johnsons-web--com]>
> To: <[rebol-list--rebol--com]>
> Sent: Tuesday, November 19, 2002 10:50 AM
> Subject: [REBOL] Re: Is Rebol code smaller?/Compiler!
>
> > <Tim> > There should be a rebol compiler or a system to translate rebol
> > > > > > code into an Ansi C "dialect", which could then be compiled.
> >
> > <Ammon > This has come up several times and the reason there is no
> compiler is
> > > > > because of the dynamic nature of the language. RT is working on a
> > > compile function, but it will only really work with heavy number
> crunching.
> > > > > Anything else done in the language is too dynamic to be compiled.
> ;-)
> >
> > <Tim> Is rebol more dynamic than 'scheme' or 'lisp'?
> > > > (bigloo has a syntax for compile-time typing of 'words)
> >
> > > Tim, I would be glad to answer your question, but I have not used
> any of
> > > the languages that you mentioned (besides, of course, REBOL) so I am
> > > entirely unqualified to answer. Sorry!
> >
> > Hi Ammon: (Rhetorical question, rhetorical answer)
> > Disclaimer: I'm a bread-butter-programmer that just happens to use rebol
> > and consider myself a mechanic among engineers and theoreticians when it
> > comes to this list but to the best of my understanding I'll try the
> following:
> >
> > REBOL is dynamic because it is interpreted. And according to [Carl--rebol],
> rebol
> > is influenced by LISP, and I can sure see that. Dynamic typing (a word
> is
> > typed when it is assigned a value) is a feature of interpreted
> languages.
> >
> > It is arguable that Perl gains performance over rebol because the
> > perl language syntax requires a certain amount of typing -
> > defining a variable as *scalar* as opposed to *vector*.
> >
> > Some dynamic scripting languages like python are very up-front about the
> > possibility that their scripted(interpreted) code might be slower than
> > that of compiled application and suggest that prototyping might be the
> > answer.
> >
> > On a more practical note, my company has been approached in the past
> > regarding converting rebol code to "C" (which can then be compiled into
> > free-standing executables that would (hopefully) offer superior
> performance).
> >
> > The argument as to whether rebol is *more* dynamic that LISP or scheme
> is
> > probably moot. The convenience (and potentially smaller code set) of
> > interpreted languages is certainly appealing to me.
> >
> > However when I and my fellow greying programmer colleagues drink too
> > much latte and get into wild orgies of speculation, we come down to
> > the agreement that the ideal programming language could be functional
> > as interpreted *or* compiled. (bigloo is an example of such a language
> > I think)
> >
> > I believe that there was a rebol compiler written at one time, or is
> > that an "urban legend"?
> > --
> > Tim Johnson <[tim--johnsons-web--com]>
> > http://www.alaska-internet-solutions.com
> > http://www.johnsons-web.com
> > --
> > To unsubscribe from this list, please send an email to
> > [rebol-request--rebol--com] with "unsubscribe" in the
> > subject, without the quotes.
> >
> >
>
> --
> To unsubscribe from this list, please send an email to
> [rebol-request--rebol--com] with "unsubscribe" in the
> subject, without the quotes.
--
Tim Johnson <[tim--johnsons-web--com]>
http://www.alaska-internet-solutions.com
http://www.johnsons-web.com