2008년 6월 15일 일요일

SquirrelFish

사용자 삽입 이미지

SquirrelFish is a register-based, direct-threaded, high-level bytecode engine, with a sliding register window calling convention. It lazily generates bytecodes from a syntax tree, using a simple one-pass compiler with built-in copy propagation.

SquirrelFish’s bytecode engine elegantly eliminates almost all of the overhead of a tree-walking interpreter.
  1. First, a bytecode stream exactly describes the operations needed to execute a program. Compiling to bytecode implicitly strips away irrelevant grammatical structure.

  2. Second, a bytecode dispatch is a single direct memory read, followed by a single indirect branch. Therefore, executing a bytecode instruction is much faster than visiting a syntax tree node.

  3. Third, with the syntax tree gone, the interpreter no longer needs to propagate execution state between syntax tree nodes.

출처: Announcing SquirrelFish via Simon Willison’s Weblog

P.S> SquirrelFish - Wikipedia

댓글 없음:

댓글 쓰기