Overview
A mutation engine is the input-generation component in a fuzzing loop that applies mutations to an input and produces new inputs for later fuzzing rounds. In coverage-based greybox fuzzing (CGF), the fuzzer records runtime coverage to decide whether an input is "interesting"; when it is, CGF applies mutations to that input to generate new inputs that are fed to the program under test in subsequent rounds.[1]
Role in ProcessorFuzz
ProcessorFuzz uses mutation in the broader CGF pattern, but its main contribution is not a new mutation engine. Its paper states that ProcessorFuzz uses CSR-transition coverage to guide processor fuzzing toward unique processor states by monitoring transitions in Control and Status Registers (CSRs), which are part of the architecture specification.[2]
ProcessorFuzz also uses ISA simulation to rapidly determine whether a test input is interesting, rather than relying on RTL simulation for that decision. The paper argues that ISA simulation is significantly faster than RTL simulation and helps eliminate repetitive test inputs while focusing on qualitatively distinct input patterns.[3]
In the ProcessorFuzz flow, a transition unit creates CSR-transition tuples and checks a transition map to determine whether a transition is new or duplicate. New transitions are added to the map and mark the current test input as interesting; the transition map starts empty and is maintained throughout the fuzzing session.[4]
Separation from feedback mechanisms
The ProcessorFuzz evaluation intentionally separates the mutation engine from the feedback metric. The authors state that they used the same mutation engine provided by DIFUZZRTL's open-source repository. They explain that using the same engine was important because their goal was to compare two coverage-feedback mechanisms—register coverage and CSR-transition coverage—rather than input-generation mechanisms.[5]
This separation matters because the mutation engine creates candidate inputs, while the coverage-feedback mechanism decides which inputs are interesting enough to keep exploring. In CGF generally, coverage feedback is used to determine whether an input increases coverage, and mutations are then applied to coverage-increasing inputs to generate new ones.[1]
Downstream validation in ProcessorFuzz
When the transition unit determines that an input produces a unique CSR transition, ProcessorFuzz launches RTL simulation and generates an extended RTL trace log. It then compares that log with the extended ISA trace log; any difference between the two logs is treated as a potential processor-design bug requiring further investigation. If the input does not produce a unique transition, ProcessorFuzz discards it and proceeds to the next fuzzing iteration.[6]
Key points
- A mutation engine supports fuzzing by producing new inputs from existing interesting inputs.
- In CGF, mutation is paired with coverage feedback: coverage determines whether an input is interesting, and mutations generate follow-on inputs.
- ProcessorFuzz reused DIFUZZRTL's mutation engine to hold input generation constant.
- ProcessorFuzz's comparison therefore focuses on feedback mechanisms: register coverage versus CSR-transition coverage.
- In ProcessorFuzz, interestingness is determined through CSR-transition coverage using ISA simulation before selected inputs are run in RTL simulation.
[1]: Coverage-based greybox fuzzing records runtime coverage to identify interesting inputs and applies mutations to those inputs to generate new inputs for subsequent fuzzing rounds. [2]: ProcessorFuzz uses CSR-transition coverage by monitoring transitions in Control and Status Registers to guide processor fuzzing toward unique processor states. [3]: ProcessorFuzz uses ISA simulation to determine whether a test input is interesting, arguing that ISA simulation is significantly faster than RTL simulation. [4]: ProcessorFuzz's transition unit checks CSR-transition tuples against a transition map; new transitions mark the current input as interesting. [5]: ProcessorFuzz uses the same mutation engine provided by DIFUZZRTL's open-source repository to compare feedback mechanisms rather than input-generation mechanisms. [6]: For inputs with unique CSR transitions, ProcessorFuzz runs RTL simulation, compares extended RTL and ISA trace logs, and treats differences as potential processor-design bugs.