Perses: Syntax-Directed Program Reduction(github.com)
github.com
Perses: Syntax-Directed Program Reduction
https://github.com/uw-pluverse/perses
2 comments
Yes! Another well-known program reducer is C-Reduce [0]. When Csmith [1] started churning out very large programs that exhibited errors in C compilers, the compiler maintainers asked the researchers to please reduce the ~81KB files to a more manageable size so they could understand the errors better. C-Reduce was developed specifically to address that need.
[0] https://github.com/csmith-project/creduce
[1] https://github.com/csmith-project/csmith
[0] https://github.com/csmith-project/creduce
[1] https://github.com/csmith-project/csmith
I agree it looks similar to QuickCheck shrinking. Isn't necessary limited to compiler writers though; e.g. I can imagine a big numerical calculation (like a physics simulation), giving NaN outputs. This could presumably home-in on the problematic step (given an appropriate test script).
Yes. An example (in the associated paper) is to create a minimal reproduction of a crash so it's easier to debug.
Perses is also the name of this Prometheus dataviz project: https://github.com/perses/perses
Funny that the God of Destruction is such a hot name lately
Funny that the God of Destruction is such a hot name lately
In practice, how is this applied? Do compiler developers essentially use something similar to quick check to generate breaking programs and then use this to reduce those programs to a minimal form, or am I missing something else altogether?