A historical question

Larry Bates lbates at swamisoft.com
Wed Sep 8 10:05:00 EDT 2004


Unless I'm mistaken it is nearly impossible to
"execute" any software without translating the
source into some intermediate (read bytecode) set
of tokens and operators.  All interpreters must
parse the source code and create some structured
representation (even if it is only internal) that
is normally VERY different from the source code
itself.  Some interpreters never save out this
"byte code", but it exists nevertheless.

Larry Bates
Syscon, Inc.

"Jerald" <jfj at freemail.gr> wrote in message
news:chmphe$21tc$1 at ulysses.noc.ntua.gr...
> Hi.
>
> I'd like to know when python started working with bytecode.
> It seems natural that in the first python implementations
> code was really interpreted : executed directly.
>
> As a result, in the first days, when the py-programmer
> said:
>
>    def foo ():
>        print 'foo'
>
> python stored the function body and executed it each time
> foo was called. In some time it was decided to compile
> this to bytecode, optimize it and call the bytecode instead.
>
> Is it so?
>
> I am very curious.
>
>
> Gerald





More information about the Python-list mailing list