Re: Challenge for speed freaks

new topic     » goto parent     » topic index » view thread      » older message » newer message

Ray Smith writes:
> * has (or will) the "Translater" stifle the developemnt
> of Euphoria as any "offical" feature will need twice as much work?

The interpreter and translator share the same source code
for scanning, parsing, symbol table lookups, and run-time routines.
Where they differ is that the interpreter uses immediate 
execution of intermediate-language op codes, whereas the
translator converts those op codes into C source code, using
a multi-pass process with various optimizations (eliminating
unused routines, eliminating unnecessary Ref/DeRef's,
deducing information about the possible types of data stored 
in a variable to reduce if-statements and unnecesary code).

There are even some cool global optimizations, such as 
checking all calls to a routine and figuring out the possible
parameter types, e.g. you might declare a parameter as "object",
but if the translator finds that you are only passing integers 
it will use that info inside the routine to streamline the code. 
If you are only passing a specific hard-coded value, say 99,
it will take advantage of that too.

I would guess that most future changes are likely to be in the
shared code, and not require any duplication of design or coding effort,
just a bit of extra testing.

Regards,
   Rob Craig
   Rapid Deployment Software
   http://www.RapidEuphoria.com

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu