Re: Questions about Bytecode

Bison <Sean.D.Gillespie@gmail.com>
20 Apr 2007 10:24:00 -0400

          From comp.compilers

Related articles
Questions about Bytecode Sean.D.Gillespie@gmail.com (Bison) (2007-04-18)
Re: Questions about Bytecode englere_geo@yahoo.com (Eric) (2007-04-19)
Re: Questions about Bytecode DrDiettrich1@aol.com (Hans-Peter Diettrich) (2007-04-19)
Re: Questions about Bytecode cfc@shell01.TheWorld.com (Chris F Clark) (2007-04-19)
Re: Questions about Bytecode Sean.D.Gillespie@gmail.com (Bison) (2007-04-20)
Re: Questions about Bytecode anton@mips.complang.tuwien.ac.at (2007-04-23)
Re: Questions about Bytecode ajohnson@mathworks.com (Andy Johnson) (2007-04-23)
Re: Questions about Bytecode DrDiettrich1@aol.com (Hans-Peter Diettrich) (2007-04-23)
Re: Questions about Bytecode haberg@math.su.se (2007-04-23)
Re: Questions about Bytecode chris.dollin@hp.com (Chris Dollin) (2007-04-23)
Re: Questions about Bytecode gah@ugcs.caltech.edu (glen herrmannsfeldt) (2007-04-25)
[3 later articles]
| List of all articles for this month |
From: Bison <Sean.D.Gillespie@gmail.com>
Newsgroups: comp.compilers
Date: 20 Apr 2007 10:24:00 -0400
Organization: Compilers Central
References: 07-04-06107-04-068
Keywords: interpreter
Posted-Date: 20 Apr 2007 10:24:00 EDT

> This looks as if you intend to write out everything while parsing.
> Consider using multiple sections and tables in the created file,
> prepare them in memory or temporary files, and write out everything
> when finished. Having everything in memory will allow to run the
> parsed source immediately, without creating an precompiled file. Then
> you'll immediately use the structures as required by the VM, apart
> from what comes into mind while only parsing.


So it sounds like this is probably the best approach. As an example,
what would be a typical layout of a compiled file look like.


I'm guessing something like this:


headers (such as maybe cafebabe [as another example] and maybe version
numbers)
literals
ops


----


I'm also wondering how labels are implemented in the bytecode.


And as a final side note, is it more common to see one stack or two
stack machines. What benefits do they have?


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.