Parrot virtual machine

Parrot is a discontinued register-based process virtual machine designed to run dynamic languages efficiently.

[1] Parrot was officially discontinued in August 2021, after being supplanted by MoarVM in its main use (Raku) and never becoming a mainstream VM for any of its other supported languages.

Parrot developers chose a register-based design, reasoning that it more closely resembles a hardware design, allowing the vast literature on compiler optimization to be used in generating bytecode for the Parrot virtual machine that could run at speeds closer to machine code.

[citation needed] Other register-based virtual machines inspired parts of Parrot's design, including LLVM, the Lua VM and Inferno's Dis.

Parrot has rich support for several features of functional programming including closures and continuations, both of which can be particularly difficult to implement correctly and portably, especially in conjunction with exception handling and threading.

The biggest advantage is the dynamic extendability of objects with methods, which allows for polymorphic containers (PMCs) and associated opcodes.

Implementing solutions to these problems at the virtual machine level obviates the need to solve them in the individual client languages.