Summary: Instruction Set Architecture of
Mamba, a New Virtual Machine for Python
David Pereira and John Aycock
Department of Computer Science
University of Calgary
2500 University Drive N.W.
Calgary, Alberta, Canada T2N 1N4
{pereira,aycock}@cpsc.ucalgary.ca
TR 2002-706-09
Abstract: Python programs are implemented by compiling them into code for a
virtual machine. Mamba is a new virtual machine for Python whose design is
minimalist and register-based. In contrast, the current Python virtual machine is
stack-based and contains almost six times as many instructions as Mamba. We
anticipate that our smaller instruction set will greatly simplify optimization
implementation. In this paper we detail Mamba's instruction set and execution
model.
1
Programming Model
Mamba is a new virtual machine for the Python language. Its instruction set is quite different from the
instruction set of the standard Python virtual machine; there are 18 register-based instructions instead of