in reply to On Compiler/Interpreter seperation

The perl6 prototype currently works similar to perl5, where you can simply type ./perl6 script.pl and it will run just fine. This is because the prototype works in 5 stages:

  1. Generate a parse tree.
  2. Decipher parse tree, optimize, and output assembly code
  3. Assemble
  4. Compile
  5. Run

This has many advantages. For instance, you can stop at one step, and pick up again later at it (e.g. stop after compilation to create an executatble). How it will work \ in the "Real Thing" hasn't been decided yet. However, even if the entire process takes longer than perl5's, thats not really a problem. If you really need the speed, you can stop at stage 3 or 4 to create a program that skips the slower steps.

Replies are listed 'Best First'.
Re: Re: On Compiler/Interpreter seperation
by laughingboy (Monk) on Aug 19, 2002 at 15:55 UTC
    I'm curious: what's the difference between stage 3 (assembly) and stage 4 (compilation) ?

    laughingboy

      Sorry, I wasn't too clear there. Step 3 (Assemble) assembles (using the assembler assemble.pl) parrot assembly into bytecode. From there, one of two things happens: either the program is compiled into an executable, or is run. :)