Matt S Trout > Rakudo-Star-2012.08_001 >


Annotate this POD


NAME ^ - opcode fuzzer


This is a fuzzer for Parrot, written in Python using the Fusil library. It attempts to break Parrot by generating calls to random PIR opcodes.


This script requires Python 2.5+ to run. The Fusil and python-ptrace libraries are also required.


Short version: sudo python tools/dev/ is run like any other Fusil-based fuzzer. Fusil likes to be run as the root user so that the child process in which Parrot runs can be put in a more restricted environment, limiting potential damage.

Fusil assumes the existence of a fusil user and group. Parrot runs as this user/group as part of its restricted environment. Passing --unsafe allows it to run as the current user. Although it is not likely that this will cause any damage to your system, it is possible. needs access to Parrot's source code in order to figure out which PMCs and ops are available. It assumes that it's running in the root directory of Parrot's source code. You can specify a different directory using the --parrot-root switch.



Represents the path to the Parrot root directory. By default, this is the current directory.


Specifies which runcore to use when running Parrot. The default is the slow core. This option corresponds directly to Parrot's --runcore option. Other runcores include fast.

Run parrot --help for more details.


Some PMC's and opcodes are known to cause false positives or results of limited value. These are blacklisted by default. Using --ignore-blacklist causes the fuzzer to use all available PMC's and opcodes, even those known to behave badly during testing.


Represents the number of instructions during the test run. Note that a larger number such as 20 does not necessarily result in more failures. Defaults to 3.


This program is distributed under the same license as Parrot itself.

syntax highlighting: